Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sync with LangChain master #3

Open
wants to merge 461 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
461 commits
Select commit Hold shift + click to select a range
b3c7ed4
Adding bind_tools in ChatOctoAI (#26168)
sebascherny Sep 8, 2024
181e4fc
Add session expired retry to neo4j graph (#26182)
tomasonjo Sep 8, 2024
fa17b14
docs: fix typo in graph_constructing tutorial (#26134)
QasimKhan5x Sep 8, 2024
bca51ca
docs: Update func doc strings in tools_human (#26149)
matt-hull0 Sep 8, 2024
76bce42
docs: Update Google BigQuery Vector Search with new SQL filter featur…
Freezaa9 Sep 8, 2024
3e48c72
docs: add ai21 tool calling example (#26199)
miri-bar Sep 9, 2024
bab9de5
core[patch]: wrap mermaid node names w/ markdown in <p> tag (#26235)
vbarda Sep 10, 2024
e235a57
community: Add docstring for KeybertLinkExtractor (#26210)
cbornet Sep 10, 2024
56580b5
community: Add docstring for GLiNERLinkExtractor (#26218)
cbornet Sep 10, 2024
9cf7ae0
community: Add docstring for HtmlLinkExtractor (#26213)
cbornet Sep 10, 2024
fa229d6
docs: fix_typo_llm_chain_tutorial (#26229)
venkatram-dev Sep 10, 2024
16d41ea
docs: typos fixed (#26234)
CodeWithEmad Sep 10, 2024
4ffd27c
huggingface[patch]: add integration tests (#26269)
ccurme Sep 10, 2024
9792322
huggingface[patch]: add integration tests for embeddings (#26272)
ccurme Sep 10, 2024
212c688
core[minor]: Remove serialized manifest from tracing requests for non…
nfcampos Sep 10, 2024
17659ca
core[patch]: Release 0.2.39 (#26279)
baskaryan Sep 10, 2024
b993172
Keyword-like runnable config (#26295)
hinthornw Sep 11, 2024
7feae62
core[patch]: Support non ASCII characters in tool output if user does…
GyuminJack Sep 11, 2024
398718e
core[patch]: fix regression in convert_to_openai_tool with instances …
ccurme Sep 11, 2024
d87feb1
[Docs] Correct the admonition explaining min langchain-anthropic vers…
hinthornw Sep 11, 2024
feb3517
core[patch]: fix empty OpenAI tools when strict=True (#26287)
baskaryan Sep 11, 2024
396c0ae
docs: Adding LC Academy links (#26164)
jessicaou Sep 11, 2024
54c8508
groq: add back streaming tool calls (#26391)
efriis Sep 12, 2024
c0dd293
partners/groq: release 0.1.10 (#26393)
efriis Sep 12, 2024
28ad244
community, openai: support nested dicts (#26414)
hwchase17 Sep 13, 2024
1d98937
partners/openai: release 0.1.24 (#26417)
efriis Sep 13, 2024
8a02fd9
core: add additional import mappings to loads (#26406)
langchain-infra Sep 13, 2024
e32adad
community[patch]: Release 0.2.17 (#26432)
baskaryan Sep 13, 2024
0f2b32f
core[patch]: Release 0.2.40 (#26435)
baskaryan Sep 13, 2024
7fc9e99
openai[patch]: get output_type when using with_structured_output (#2…
liuhetian Sep 13, 2024
d9813bd
openai[patch]: Release 0.1.25 (#26439)
baskaryan Sep 13, 2024
c2a3021
multiple: pydantic 2 compatibility, v0.3 (#26443)
efriis Sep 13, 2024
d46ab19
core: release 0.3.0 (#26453)
efriis Sep 13, 2024
222caae
infra: fix release (#26455)
baskaryan Sep 13, 2024
fa8e0d9
docs: update version docs (#26457)
baskaryan Sep 13, 2024
44791ce
infra: rm pydantic from min version test (#26459)
baskaryan Sep 13, 2024
3125a89
infra: fix min version (#26461)
baskaryan Sep 13, 2024
9b30bdc
mistralai: release 0.2 (#26458)
ccurme Sep 13, 2024
d1462ba
text-splitters: release 0.3 (#26460)
ccurme Sep 13, 2024
f7ae12f
openai[minor]: Release 0.2.0 (#26464)
baskaryan Sep 13, 2024
125c989
huggingface: release 0.1 (#26463)
ccurme Sep 13, 2024
58c7414
langchain: release 0.3.0 (#26462)
efriis Sep 13, 2024
64bfe1f
groq[minor]: Release 0.2.0 (#26465)
baskaryan Sep 13, 2024
6997731
partners/anthropic: release 0.3.0 (#26466)
efriis Sep 13, 2024
832bc83
partners/anthropic: release 0.2.0 (#26469)
efriis Sep 13, 2024
995dfc6
partners/fireworks: release 0.2.0 (#26467)
efriis Sep 13, 2024
537f692
partners/ollama: release 0.2.0 (#26468)
efriis Sep 13, 2024
ca304ae
robocorp: rm package (now langchain-sema4) (#26471)
efriis Sep 13, 2024
17b397e
pinecone[minor]: Release 0.2.0 (#26474)
baskaryan Sep 13, 2024
900115a
community: release 0.3 (#26472)
ccurme Sep 13, 2024
6abb23c
exa[minor]: Release 0.2.0 (#26476)
baskaryan Sep 13, 2024
8abc7ff
experimental: release 0.3 (#26477)
ccurme Sep 13, 2024
a2bfa41
azure-dynamic-sessions[minor]: Release 0.2.0 (#26478)
baskaryan Sep 13, 2024
9c88037
huggingface[patch]: xfail test (#26479)
ccurme Sep 13, 2024
543a805
prompty[minor]: Release 0.1.0 (#26481)
baskaryan Sep 13, 2024
4e6620e
chroma[patch]: Release 0.1.4 (#26470)
baskaryan Sep 14, 2024
779a008
docs: update v3 versions (#26483)
baskaryan Sep 14, 2024
b47f4cf
mongodb[minor]: Release 0.2.0 (#26484)
baskaryan Sep 14, 2024
77ccb4b
cli[patch]: Update the migration script message (#26490)
eyurtsev Sep 14, 2024
2240ca2
docs: Fix Firecrawl v0 version (#26452)
nickscamara Sep 14, 2024
9c6aa3f
broken LangGraph docs link (#26438)
jessicaou Sep 14, 2024
f66b7ba
Update google_search.ipynb (#26420)
bhadreshpsavani Sep 14, 2024
4131be6
multiple: 0.3.0 not dev version (#26502)
efriis Sep 15, 2024
135afdf
docs: most 0.1 redirects too (#26494)
efriis Sep 15, 2024
9f5960a
docs: new algolia index (#26508)
efriis Sep 16, 2024
bd42344
docs: Update concepts.mdx (#26496)
ystkfujii Sep 16, 2024
ee4e113
nomic: release 0.1.3, core 0.3 compat but not required (#26511)
efriis Sep 16, 2024
1ab181f
voyageai: release 0.1.2 (#26512)
efriis Sep 16, 2024
88bc15d
standard-tests[patch]: add async test for structured output (#26527)
ccurme Sep 16, 2024
8889147
langchain-cli: release 0.0.31 (#26533)
eyurtsev Sep 16, 2024
0592c29
qdrant[patch]: release 0.1.4 (#26534)
ccurme Sep 16, 2024
5b4206a
box: 0.2.0 release (#26539)
eyurtsev Sep 16, 2024
8b985a4
milvus: 0.1.6 release (#26538)
eyurtsev Sep 16, 2024
c2588b3
unstructured: release 0.1.4 (#26540)
eyurtsev Sep 16, 2024
0154c58
docs: update integrations table in 0.3 guide (#26536)
ccurme Sep 16, 2024
63c3cc1
ci: updates issue and discussion templates (#26542)
eyurtsev Sep 16, 2024
a319a0f
docs: add redirects for tools and lcel (#26541)
baskaryan Sep 16, 2024
c6a7813
docs: show how to use langchain-cli for migration (#26535)
eyurtsev Sep 16, 2024
724a537
docs: Fix missing `self` argument in `_get_docs_with_query` method of…
SQpgducray Sep 16, 2024
8a2f2fc
docs: what langchain-cli migrate can do (#26547)
eyurtsev Sep 16, 2024
0bd98c9
docs: add sema4 to release table (#26549)
baskaryan Sep 16, 2024
3bcd641
Add check for prompt based approach in llm graph transformer (#26519)
tomasonjo Sep 16, 2024
99abd25
docs: clean up init_chat_model (#26551)
baskaryan Sep 16, 2024
31f61d4
docs: v0.3 nits (#26556)
baskaryan Sep 17, 2024
d8952b8
langchain[patch]: infer mistral provider in init_chat_model (#26557)
baskaryan Sep 17, 2024
6ba3c71
doc_fix_chroma_integration (#26565)
venkatram-dev Sep 17, 2024
6758894
docs: update v0.3 integrations table (#26571)
ccurme Sep 17, 2024
0a177ec
community: Enhance MongoDBLoader with flexible metadata and optimized…
comsa33 Sep 17, 2024
3e51fdc
infra: more skip if pull request libs (#26578)
efriis Sep 17, 2024
06cde06
core[minor]: remove beta from RemoveMessage (#26579)
isahers1 Sep 17, 2024
f4a6523
infra: only force reinstall on release (#26580)
efriis Sep 17, 2024
5fc4498
core[patch]: Fix "argument of type 'NoneType' is not iterable" error …
nfcampos Sep 17, 2024
145a49c
core[patch]: Release 0.3.1 (#26581)
baskaryan Sep 17, 2024
7c05f71
milvus[patch]: fix vectorstore integration tests (#26583)
ccurme Sep 17, 2024
e1d113e
core,openai,grow,fw[patch]: deprecate bind_functions, update chat mod…
baskaryan Sep 17, 2024
97b05d7
docs: anthropic api ref nit (#26591)
baskaryan Sep 17, 2024
194adc4
docs: pypi readme image links (#26590)
efriis Sep 17, 2024
2ef4c94
community: modify document links for tencent vectordb (#26316)
wlleiiwang Sep 17, 2024
3a99467
core[patch]: Add ruff rule UP006(use PEP585 annotations) (#26574)
cbornet Sep 17, 2024
c6bdd6f
community: Fix references in link extractors docstrings (#26314)
cbornet Sep 17, 2024
5ced41b
anthropic[patch]: fix tool call and tool res image_url handling (#26587)
baskaryan Sep 17, 2024
6ed50e7
community: Rename deployments server to AI gateway (#26368)
harupy Sep 17, 2024
1a62f98
anthropic[patch]: Release 0.2.1 (#26592)
baskaryan Sep 17, 2024
1a8e902
Improvement[Community] Improve `streamlit_callback_handler` (#26373)
ZhangShenao Sep 17, 2024
e2245fa
community[patch]: o1-preview and o1-mini costs (#26411)
ogawa65a Sep 17, 2024
c3b3f46
Improvement[Community] Improve api doc of `BeautifulSoupTransformer` …
ZhangShenao Sep 17, 2024
418b170
docs: Fix typo in conda environment code block in rag.ipynb (#26487)
IT-Bill Sep 17, 2024
6fe2536
docs: fix the `ImportError` in `google_speech_to_text.ipynb` (#26522)
gbaian10 Sep 17, 2024
f62d454
docs: fix typo on amazon_textract.ipynb (#26493)
marcorossiIT Sep 17, 2024
52729ac
docs: update hybrid search example with Elasticsearch retriever (#26328)
miguelgrinberg Sep 17, 2024
b246052
docs: fix typo in clickhouse vectorstore doc (#26598)
sanjay920 Sep 17, 2024
df38d52
docs: cleanup nav (#26546)
baskaryan Sep 18, 2024
de58942
docs: consolidate dropdowns (#26600)
baskaryan Sep 18, 2024
d158401
infra: master release checkout ref for release note (#26605)
efriis Sep 18, 2024
0f07cf6
docs: fixed typo in XML document loader (#26613)
pmcgleenon Sep 18, 2024
a47b332
core: Put Python version as a project requirement so it is considered…
cbornet Sep 18, 2024
84b8313
core: remove [project] tag from pyproject (#26633)
efriis Sep 18, 2024
9909354
core: use ruff.target-version instead (#26634)
efriis Sep 18, 2024
e0c36af
docs: v0.3 link redirect (#26632)
efriis Sep 18, 2024
acbb4e4
box: Add searchoptions for BoxRetriever, documentation for BoxRetriev…
shurrey Sep 19, 2024
03b9aca
community: Retry retriable errors in Neo4j (#26211)
tomasonjo Sep 19, 2024
8fb643a
partners/box: release 0.2.1 (#26644)
efriis Sep 19, 2024
85caaa7
docs[community]: Fix raw string in docstring (#26350)
tibor-reiss Sep 19, 2024
7835c06
langchain_chroma: Pass through kwargs to Chroma collection.delete (#2…
dan-cooke Sep 19, 2024
fd21ffe
core: Add N(naming) ruff rules (#25362)
cbornet Sep 19, 2024
4e0a6eb
community: Add warning when page_content is empty (#25955)
erikinfo Sep 19, 2024
a8561bc
Fix async parsing for llm graph transformer (#26650)
tomasonjo Sep 19, 2024
3fc0ea5
community : [bugfix] Use document ids as keys in AzureSearch vectorst…
MacanPN Sep 19, 2024
37b7202
community: remove sambaverse (#26265)
jhpiedrahitao Sep 19, 2024
55b641b
community: fix error in sambastudio embeddings (#26260)
jhpiedrahitao Sep 19, 2024
60dc19d
[community] Added PebbloTextLoader for loading text data in PebbloSaf…
Raj725 Sep 19, 2024
4d3d62c
docs: fix nomic link error (#26642)
yaoice Sep 19, 2024
f91bdd1
community[patch]: add to pypdf tests and run in CI (#26663)
ccurme Sep 19, 2024
28dd656
docs: highlight styling (#26636)
efriis Sep 19, 2024
7d49ee9
unstructured[patch]: add to integration tests (#26666)
ccurme Sep 19, 2024
c77c28e
[community] Fix WorkspaceClient error with pydantic validation (#26649)
serena-ruan Sep 19, 2024
311f861
core, community: move graph vectorstores to community (#26678)
efriis Sep 19, 2024
eef18de
unstructured[patch]: support loading URLs (#26670)
ccurme Sep 19, 2024
e8236e5
ci: restore qa template that was known to work (#26684)
eyurtsev Sep 19, 2024
409f353
core[patch]: support load from path for default namespaces (#26675)
baskaryan Sep 19, 2024
f087ab4
core[patch]: Fix load of ChatBedrock (#26679)
3coins Sep 19, 2024
c453b76
core[patch]: Release 0.3.2 (#26686)
baskaryan Sep 19, 2024
f7bb364
core[patch]: support js chat model namespaces (#26688)
baskaryan Sep 19, 2024
8f0c04f
Update tool_calling.ipynb (#26699)
guoqiang0401 Sep 20, 2024
9159492
fix:fix ChatZhipuAI tool call bug (#26693)
stein1988 Sep 20, 2024
eeab6a6
docs[patch]: update PDF loader docs (#26627)
ccurme Sep 20, 2024
acf8c2c
docs: Add migration instructions for v0.0.x memory abstractions (#26668)
eyurtsev Sep 20, 2024
baef763
Improvement[text-splitter] Fix import of `ExperimentalMarkdownSyntaxT…
ZhangShenao Sep 20, 2024
90031b1
support epsilla cloud vector database in langchain (#26065)
eric-epsilla Sep 20, 2024
19ce95d
Avoid copying runs (#26689)
hinthornw Sep 20, 2024
91f4711
core[patch],langchain[patch]: deprecate memory and entity abstraction…
eyurtsev Sep 20, 2024
8a9f709
docs: Update trim message usage in migrating_memory (#26722)
eyurtsev Sep 20, 2024
79b224f
core/langchain: fix version used in deprecation (#26724)
eyurtsev Sep 20, 2024
4fc69d6
core[patch]: Fix defusedxml import (#26718)
eyurtsev Sep 20, 2024
465e43c
core: release 0.3.3 (#26713)
efriis Sep 20, 2024
345edeb
core: In astream_events propagate cancellation reason to inner task (…
nfcampos Sep 20, 2024
4a27450
core: release 0.3.4 (#26729)
efriis Sep 20, 2024
f228537
community[patch]: add web loader tests (#26728)
ccurme Sep 20, 2024
a2023a1
huggingface; fix huggingface_endpoint.py (initialize clients only wit…
Wauplin Sep 20, 2024
e49c413
core: Add docstring for GraphVectorStoreRetriever (#26224)
cbornet Sep 20, 2024
58f339a
community: Fix links in GraphVectorStore pydoc (#25959)
cbornet Sep 20, 2024
4ac9a6f
core: fix "template" not allowed as prompt param (#26060)
ikbenale Sep 20, 2024
a8b2413
fix[experimental]: Fix text splitter with gradient (#26629)
tibor-reiss Sep 20, 2024
c6c508e
Refining Skip Count Calculation by Filtering Documents with `session_…
kk9393 Sep 20, 2024
2d21274
couchbase: Add ttl support to caches & chat_message_history (#26214)
nithishr Sep 20, 2024
864020e
[Tracer] add project name to run from tracer (#26736)
hinthornw Sep 20, 2024
3e2cb4e
openai: embeddings: supported chunk_size when check_embedding_ctx_len…
adubovik Sep 20, 2024
55af6fb
[LangChainTracer] Omit Chunk (#26602)
hinthornw Sep 21, 2024
238a31b
core: release 0.3.5 (#26737)
efriis Sep 21, 2024
f97ac92
community[patch]: Handle empty PR body in get_pull_request in Github …
gorros Sep 22, 2024
bb40a0f
Remove pydantic restricted namespaces from HuggingFaceInferenceAPIEmb…
galtay Sep 22, 2024
e1e4f88
openai[patch]: enable Azure structured output, parallel_tool_calls=Fa…
baskaryan Sep 23, 2024
fb9ac8d
fix(docs): Drop announcement bar (#26782)
bracesproul Sep 23, 2024
97b27f0
langchain[patch]: fix extended tests (#26788)
ccurme Sep 23, 2024
bba7af9
core[patch]: set default on Blob (#26787)
ccurme Sep 23, 2024
154a5ff
core[patch]: On Chain Start Fix for `Chain` Class (#26593)
keenborder786 Sep 23, 2024
1ce056d
docs[patch]: add memory migration guides to sidebar (#26711)
ccurme Sep 23, 2024
2a4c571
openai[patch]: fix azure integration tests (#26791)
ccurme Sep 23, 2024
603d38f
docs: make docs mdxv2 compatible (#26798)
efriis Sep 24, 2024
35081d2
docs: fix admonition formatting (#26801)
efriis Sep 24, 2024
e40a2b8
docs: fix mdx codefences (#26802)
efriis Sep 24, 2024
997d95c
community[patch]: callback before yield for bedrock llm (#26804)
subroy13 Sep 24, 2024
2b83c7c
community[patch]: Fix `tool_calls` parsing when streaming from DeepIn…
thunze Sep 24, 2024
408a930
community: Add Sambanova Cloud Chat model community integration (#26…
jhpiedrahitao Sep 24, 2024
de70a64
core: Run LangChainTracer inline (#26797)
nfcampos Sep 24, 2024
b1da532
community[patch]: callback before yield for deepsparse llm (#26822)
subroy13 Sep 24, 2024
f9ef688
docs: upgrade to docusaurus v3 (#26803)
efriis Sep 24, 2024
0414be4
experimental[major]: CVE-2024-46946 fix (#26783)
mercyspirit Sep 24, 2024
6c3ea26
partners/unstructured: release 0.1.5 (#26831)
Coniferish Sep 24, 2024
425c0f3
experimental: release 0.3.1 (#26830)
efriis Sep 24, 2024
9526936
docs: make build less verbose (#26833)
efriis Sep 24, 2024
3796e14
docs: remove one more print from build (#26834)
efriis Sep 24, 2024
9b6ac41
[Core] Inherit tracing metadata & tags (#26838)
hinthornw Sep 25, 2024
82b5b77
[Core] Add more interops tests (#26841)
hinthornw Sep 25, 2024
13acf9e
langchain[patch]: add deprecation warnings (#26853)
ccurme Sep 25, 2024
b61fb98
community[patch]: callback before yield for friendli (#26842)
subroy13 Sep 25, 2024
92003b3
community[patch]: [SharePointLoader] Fix validation error in _O365Set…
Raj725 Sep 25, 2024
7e5a9c3
community[minor]: [Pebblo] Enhance PebbloSafeLoader to take anonymize…
Raj725 Sep 25, 2024
3a1b925
core: Add ruff rules for comprehensions (C4) (#26829)
cbornet Sep 25, 2024
27c1214
docs[patch]: In conceptual docs explain constraints on ToolMessage (#…
eyurtsev Sep 25, 2024
d502858
Update main README.md to reference latest version of documentation (#…
DGaffney Sep 25, 2024
51c4393
community[patch]: Fix validation error in SettingsConfigDict across m…
Raj725 Sep 25, 2024
eaffa92
openai[patch]: Release 0.2.1 (#26858)
baskaryan Sep 25, 2024
a001006
docs[patch]: add guide for loading web pages (#26708)
ccurme Sep 25, 2024
87e2149
docs[patch]: remove deprecated loaders from feature tables (#26709)
ccurme Sep 25, 2024
ef2ab26
core: release 0.3.6 (#26863)
efriis Sep 25, 2024
9a31ad6
langchain: release 0.3.1 (#26868)
efriis Sep 25, 2024
25cb44c
0.3.1 release community (#26872)
eyurtsev Sep 25, 2024
e068407
community: bump core versoin (#26875)
efriis Sep 25, 2024
6f3c831
community: bump langchain version (#26876)
efriis Sep 25, 2024
edf879d
docs: update extraction_examples.ipynb (#26874)
jackpeplinski Sep 25, 2024
c750600
infra: update release secrets (#26878)
baskaryan Sep 26, 2024
2ea5f60
experimental: migrate to external repo (#26879)
efriis Sep 26, 2024
7091a1a
openai[patch]: increase token limit in azure integration tests (#26901)
ccurme Sep 26, 2024
121e79b
core: Fix `IndexError` when `trim_messages` invoked with empty list (…
sudosays Sep 26, 2024
11e703a
community[patch]: callback before yield for google palm (#26882)
subroy13 Sep 26, 2024
ba467f1
community[patch]: callback before yield for gigachat (#26881)
subroy13 Sep 26, 2024
7a99a4d
infra: fix experimental in dco imports check (#26905)
efriis Sep 26, 2024
2a0d9d0
docs: Fix trim_messages invocations in the memory migration guide (#2…
eyurtsev Sep 26, 2024
8bc12df
voyageai: new models (#26907)
efriis Sep 26, 2024
696114e
community: add sqlite-vec vectorstore (#25003)
abhiaagarwal Sep 26, 2024
02f5962
docs: add api referencs to langgraph (#26877)
eyurtsev Sep 26, 2024
c6350d6
core[fix]: using async rate limiter methods in async code (#26914)
esciara Sep 26, 2024
5f2cc4e
community[patch]: callback before yield for titan takeoff (#26930)
subroy13 Sep 27, 2024
adcfecd
community[patch]: callback before yield for textgen (#26929)
subroy13 Sep 27, 2024
7037ba0
community[patch]: callback before yield for mlx pipeline (#26928)
subroy13 Sep 27, 2024
2d9a09d
Fix typo in mlflow code example in mlflow.py (#26931)
Youshin Sep 27, 2024
7f37fd8
community[patch]: callback before yield for cloudflare (#26927)
subroy13 Sep 27, 2024
39987eb
openai[patch]: update deprecation target in API ref (#26921)
ccurme Sep 27, 2024
836c2a4
docs: update memory integrations page (#26912)
ccurme Sep 27, 2024
f4e738b
core: Add ruff rules for PIE (#26939)
cbornet Sep 27, 2024
c38ea7a
infra: api docs build (#26948)
efriis Sep 27, 2024
135164e
infra: api docs build ref update (#26949)
efriis Sep 27, 2024
9eb26c5
infra: api docs build ref experimental (#26950)
efriis Sep 27, 2024
67df944
infra: add CI job for running tutorial notebooks (#26944)
ccurme Sep 27, 2024
44eddd3
infra[patch]: update notebooks workflow (#26956)
ccurme Sep 27, 2024
de0b48c
docs: Upgrade examples with RunnableWithMessageHistory to langgraph m…
eyurtsev Sep 27, 2024
7809b31
core[patch]: Add ruff rules for flake8-simplify (SIM) (#26848)
cbornet Sep 27, 2024
29bf89d
community: Add conversions from GVS to networkx (#26906)
bjchambers Sep 27, 2024
b2c3159
infra: custom commit to external repo (#26962)
efriis Sep 27, 2024
ce2669c
docs: update code interpreter tool table to reflect riza file upload …
andrewmbenton Sep 29, 2024
9404e7a
openai[patch]: exclude http client (#26891)
baskaryan Sep 29, 2024
db8845a
core: Add ruff rules for pycodestyle Warning (W) (#26964)
cbornet Sep 30, 2024
c7120d8
groq[patch]: support tool_choice=any/required (#27000)
baskaryan Sep 30, 2024
0078493
fireworks[patch]: allow tool_choice with multiple tools (#26999)
baskaryan Sep 30, 2024
248be02
core[patch]: fix structured prompt template format (#27003)
baskaryan Sep 30, 2024
34bd718
core[patch]: Release 0.3.7 (#27004)
baskaryan Sep 30, 2024
e12f570
Merge pull request #26794
keenborder786 Sep 30, 2024
19ed316
docs: Fix typo in list of PDF loaders (#26774)
ronnix Sep 30, 2024
8020fc2
Merge branch 'master' of github.com:langchain-ai/langchain into langc…
qiuosier Sep 30, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
24 changes: 10 additions & 14 deletions .github/ISSUE_TEMPLATE/bug-report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -96,25 +96,21 @@ body:
attributes:
label: System Info
description: |
Please share your system info with us.
Please share your system info with us. Do NOT skip this step and please don't trim
the output. Most users don't include enough information here and it makes it harder
for us to help you.

"pip freeze | grep langchain"
platform (windows / linux / mac)
python version

OR if you're on a recent version of langchain-core you can paste the output of:
Run the following command in your terminal and paste the output here:

python -m langchain_core.sys_info
placeholder: |
"pip freeze | grep langchain"
platform
python version

Alternatively, if you're on a recent version of langchain-core you can paste the output of:
or if you have an existing python interpreter running:

python -m langchain_core.sys_info
from langchain_core import sys_info
sys_info.print_sys_info()

These will only surface LangChain packages, don't forget to include any other relevant
packages you're using (if you're not sure what's relevant, you can paste the entire output of `pip freeze`).
alternatively, put the entire output of `pip freeze` here.
placeholder: |
python -m langchain_core.sys_info
validations:
required: true
2 changes: 1 addition & 1 deletion .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Thank you for contributing to LangChain!

- [ ] **PR title**: "package: description"
- Where "package" is whichever of langchain, community, core, experimental, etc. is being modified. Use "docs: ..." for purely docs changes, "templates: ..." for template changes, "infra: ..." for CI changes.
- Where "package" is whichever of langchain, community, core, etc. is being modified. Use "docs: ..." for purely docs changes, "templates: ..." for template changes, "infra: ..." for CI changes.
- Example: "community: add foobar LLM"


Expand Down
129 changes: 102 additions & 27 deletions .github/scripts/check_diff.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,34 @@
import json
import os
import sys
import tomllib
from collections import defaultdict
from typing import Dict, List, Set
from pathlib import Path
import tomllib

from get_min_versions import get_min_version_from_toml


LANGCHAIN_DIRS = [
"libs/core",
"libs/text-splitters",
"libs/langchain",
"libs/community",
"libs/experimental",
]

# when set to True, we are ignoring core dependents
# in order to be able to get CI to pass for each individual
# package that depends on core
# e.g. if you touch core, we don't then add textsplitters/etc to CI
IGNORE_CORE_DEPENDENTS = False

# ignored partners are removed from dependents
# but still run if directly edited
IGNORED_PARTNERS = [
# remove huggingface from dependents because of CI instability
# specifically in huggingface jobs
# https://github.com/langchain-ai/langchain/issues/25558
"huggingface",
]


Expand Down Expand Up @@ -69,12 +85,10 @@ def dependents_graph() -> dict:
if "langchain" in dep:
dependents[dep].add(pkg_dir)

# remove huggingface from dependents because of CI instability
# specifically in huggingface jobs
# https://github.com/langchain-ai/langchain/issues/25558
for k in dependents:
if "libs/partners/huggingface" in dependents[k]:
dependents[k].remove("libs/partners/huggingface")
for partner in IGNORED_PARTNERS:
if f"libs/partners/{partner}" in dependents[k]:
dependents[k].remove(f"libs/partners/{partner}")
return dependents


Expand All @@ -92,44 +106,101 @@ def add_dependents(dirs_to_eval: Set[str], dependents: dict) -> List[str]:


def _get_configs_for_single_dir(job: str, dir_: str) -> List[Dict[str, str]]:
if dir_ == "libs/core":
return [
{"working-directory": dir_, "python-version": f"3.{v}"}
for v in range(8, 13)
]
min_python = "3.8"
max_python = "3.12"
if job == "test-pydantic":
return _get_pydantic_test_configs(dir_)

if dir_ == "libs/core":
py_versions = ["3.9", "3.10", "3.11", "3.12"]
# custom logic for specific directories
if dir_ == "libs/partners/milvus":
elif dir_ == "libs/partners/milvus":
# milvus poetry doesn't allow 3.12 because they
# declare deps in funny way
max_python = "3.11"
py_versions = ["3.9", "3.11"]

if dir_ in ["libs/community", "libs/langchain"] and job == "extended-tests":
elif dir_ in ["libs/community", "libs/langchain"] and job == "extended-tests":
# community extended test resolution in 3.12 is slow
# even in uv
max_python = "3.11"
py_versions = ["3.9", "3.11"]

if dir_ == "libs/community" and job == "compile-integration-tests":
elif dir_ == "libs/community" and job == "compile-integration-tests":
# community integration deps are slow in 3.12
max_python = "3.11"
py_versions = ["3.9", "3.11"]
else:
py_versions = ["3.9", "3.12"]

return [
{"working-directory": dir_, "python-version": min_python},
{"working-directory": dir_, "python-version": max_python},
return [{"working-directory": dir_, "python-version": py_v} for py_v in py_versions]


def _get_pydantic_test_configs(
dir_: str, *, python_version: str = "3.11"
) -> List[Dict[str, str]]:
with open("./libs/core/poetry.lock", "rb") as f:
core_poetry_lock_data = tomllib.load(f)
for package in core_poetry_lock_data["package"]:
if package["name"] == "pydantic":
core_max_pydantic_minor = package["version"].split(".")[1]
break

with open(f"./{dir_}/poetry.lock", "rb") as f:
dir_poetry_lock_data = tomllib.load(f)

for package in dir_poetry_lock_data["package"]:
if package["name"] == "pydantic":
dir_max_pydantic_minor = package["version"].split(".")[1]
break

core_min_pydantic_version = get_min_version_from_toml(
"./libs/core/pyproject.toml", "release", python_version, include=["pydantic"]
)["pydantic"]
core_min_pydantic_minor = (
core_min_pydantic_version.split(".")[1]
if "." in core_min_pydantic_version
else "0"
)
dir_min_pydantic_version = get_min_version_from_toml(
f"./{dir_}/pyproject.toml", "release", python_version, include=["pydantic"]
).get("pydantic", "0.0.0")
dir_min_pydantic_minor = (
dir_min_pydantic_version.split(".")[1]
if "." in dir_min_pydantic_version
else "0"
)

custom_mins = {
# depends on pydantic-settings 2.4 which requires pydantic 2.7
"libs/community": 7,
}

max_pydantic_minor = min(
int(dir_max_pydantic_minor),
int(core_max_pydantic_minor),
)
min_pydantic_minor = max(
int(dir_min_pydantic_minor),
int(core_min_pydantic_minor),
custom_mins.get(dir_, 0),
)

configs = [
{
"working-directory": dir_,
"pydantic-version": f"2.{v}.0",
"python-version": python_version,
}
for v in range(min_pydantic_minor, max_pydantic_minor + 1)
]
return configs


def _get_configs_for_multi_dirs(
job: str, dirs_to_run: List[str], dependents: dict
job: str, dirs_to_run: Dict[str, Set[str]], dependents: dict
) -> List[Dict[str, str]]:
if job == "lint":
dirs = add_dependents(
dirs_to_run["lint"] | dirs_to_run["test"] | dirs_to_run["extended-test"],
dependents,
)
elif job in ["test", "compile-integration-tests", "dependencies"]:
elif job in ["test", "compile-integration-tests", "dependencies", "test-pydantic"]:
dirs = add_dependents(
dirs_to_run["test"] | dirs_to_run["extended-test"], dependents
)
Expand Down Expand Up @@ -158,6 +229,7 @@ def _get_configs_for_multi_dirs(
dirs_to_run["lint"] = all_package_dirs()
dirs_to_run["test"] = all_package_dirs()
dirs_to_run["extended-test"] = set(LANGCHAIN_DIRS)

for file in files:
if any(
file.startswith(dir_)
Expand All @@ -175,8 +247,12 @@ def _get_configs_for_multi_dirs(
if any(file.startswith(dir_) for dir_ in LANGCHAIN_DIRS):
# add that dir and all dirs after in LANGCHAIN_DIRS
# for extended testing

found = False
for dir_ in LANGCHAIN_DIRS:
if dir_ == "libs/core" and IGNORE_CORE_DEPENDENTS:
dirs_to_run["extended-test"].add(dir_)
continue
if file.startswith(dir_):
found = True
if found:
Expand All @@ -188,7 +264,6 @@ def _get_configs_for_multi_dirs(
dirs_to_run["test"].add("libs/partners/mistralai")
dirs_to_run["test"].add("libs/partners/openai")
dirs_to_run["test"].add("libs/partners/anthropic")
dirs_to_run["test"].add("libs/partners/ai21")
dirs_to_run["test"].add("libs/partners/fireworks")
dirs_to_run["test"].add("libs/partners/groq")

Expand Down Expand Up @@ -218,7 +293,6 @@ def _get_configs_for_multi_dirs(

# we now have dirs_by_job
# todo: clean this up

map_job_to_configs = {
job: _get_configs_for_multi_dirs(job, dirs_to_run, dependents)
for job in [
Expand All @@ -227,6 +301,7 @@ def _get_configs_for_multi_dirs(
"extended-tests",
"compile-integration-tests",
"dependencies",
"test-pydantic",
]
}
map_job_to_configs["test-doc-imports"] = (
Expand Down
2 changes: 1 addition & 1 deletion .github/scripts/check_prerelease_dependencies.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

# see if we're releasing an rc
version = toml_data["tool"]["poetry"]["version"]
releasing_rc = "rc" in version
releasing_rc = "rc" in version or "dev" in version

# if not, iterate through dependencies and make sure none allow prereleases
if not releasing_rc:
Expand Down
53 changes: 48 additions & 5 deletions .github/scripts/get_min_versions.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import sys
from typing import Optional

if sys.version_info >= (3, 11):
import tomllib
Expand All @@ -7,6 +8,9 @@
import tomli as tomllib

from packaging.version import parse as parse_version
from packaging.specifiers import SpecifierSet
from packaging.version import Version

import re

MIN_VERSION_LIBS = [
Expand All @@ -17,7 +21,14 @@
"SQLAlchemy",
]

SKIP_IF_PULL_REQUEST = ["langchain-core"]
# some libs only get checked on release because of simultaneous changes in
# multiple libs
SKIP_IF_PULL_REQUEST = [
"langchain-core",
"langchain-text-splitters",
"langchain",
"langchain-community",
]


def get_min_version(version: str) -> str:
Expand Down Expand Up @@ -45,7 +56,13 @@ def get_min_version(version: str) -> str:
raise ValueError(f"Unrecognized version format: {version}")


def get_min_version_from_toml(toml_path: str, versions_for: str):
def get_min_version_from_toml(
toml_path: str,
versions_for: str,
python_version: str,
*,
include: Optional[list] = None,
):
# Parse the TOML file
with open(toml_path, "rb") as file:
toml_data = tomllib.load(file)
Expand All @@ -57,18 +74,26 @@ def get_min_version_from_toml(toml_path: str, versions_for: str):
min_versions = {}

# Iterate over the libs in MIN_VERSION_LIBS
for lib in MIN_VERSION_LIBS:
for lib in set(MIN_VERSION_LIBS + (include or [])):
if versions_for == "pull_request" and lib in SKIP_IF_PULL_REQUEST:
# some libs only get checked on release because of simultaneous
# changes
# changes in multiple libs
continue
# Check if the lib is present in the dependencies
if lib in dependencies:
if include and lib not in include:
continue
# Get the version string
version_string = dependencies[lib]

if isinstance(version_string, dict):
version_string = version_string["version"]
if isinstance(version_string, list):
version_string = [
vs
for vs in version_string
if check_python_version(python_version, vs["python"])
][0]["version"]

# Use parse_version to get the minimum supported version from version_string
min_version = get_min_version(version_string)
Expand All @@ -79,13 +104,31 @@ def get_min_version_from_toml(toml_path: str, versions_for: str):
return min_versions


def check_python_version(version_string, constraint_string):
"""
Check if the given Python version matches the given constraints.

:param version_string: A string representing the Python version (e.g. "3.8.5").
:param constraint_string: A string representing the package's Python version constraints (e.g. ">=3.6, <4.0").
:return: True if the version matches the constraints, False otherwise.
"""
try:
version = Version(version_string)
constraints = SpecifierSet(constraint_string)
return version in constraints
except Exception as e:
print(f"Error: {e}")
return False


if __name__ == "__main__":
# Get the TOML file path from the command line argument
toml_file = sys.argv[1]
versions_for = sys.argv[2]
python_version = sys.argv[3]
assert versions_for in ["release", "pull_request"]

# Call the function to get the minimum versions
min_versions = get_min_version_from_toml(toml_file, versions_for)
min_versions = get_min_version_from_toml(toml_file, versions_for, python_version)

print(" ".join([f"{lib}=={version}" for lib, version in min_versions.items()]))
Loading
Loading