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

fix: provider the latest duckduckgo_search API #5184

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
356 commits
Select commit Hold shift + click to select a range
3808689
Fixed docstring in faiss.py for load_local (#5440)
luckyduck May 30, 2023
3659475
Removes duplicated call from langchain/client/langchain.py (#5449)
patrickkeane May 30, 2023
c140214
`encoding_kwargs` for InstructEmbeddings (#5450)
Xmaster6y May 30, 2023
184244a
MRKL output parser no longer breaks well formed queries (#5432)
May 30, 2023
c793a64
docs: cleaning (#5413)
leo-gan May 30, 2023
f702d0a
Added async _acall to FakeListLLM (#5439)
camille-vanhoffelen May 30, 2023
53e9a99
Feat: Add batching to Qdrant (#5443)
kacperlukawski May 30, 2023
f30b403
Update psychicapi version (#5471)
Ayan-Bandyopadhyay May 30, 2023
61ce1d4
Add maximal relevance search to SKLearnVectorStore (#5430)
mrtj May 30, 2023
05771cb
add simple test for imports (#5461)
hwchase17 May 30, 2023
57f4f2c
Ability to specify credentials wihen using Google BigQuery as a data …
nsheils May 30, 2023
af6d7b0
convert the parameter 'text' to uppercase in the function 'parse' of …
ARSblithe212 May 30, 2023
efca78b
added n_threads functionality for gpt4all (#5427)
Vokturz May 30, 2023
7f85bf6
Allow for async use of SelfAskWithSearchChain (#5394)
pors May 31, 2023
6775dac
Allow ElasticsearchEmbeddings to create a connection with ES Client o…
jeffvestal May 31, 2023
b08a832
SQLite-backed Entity Memory (#5129)
JoseHervas May 31, 2023
3599b2e
py tracer fixes (#5377)
agola11 May 31, 2023
42b3024
Harrison/html splitter (#5468)
hwchase17 May 31, 2023
cc86975
Feature: Qdrant filters supports (#5446)
kacperlukawski May 31, 2023
fb3919e
Add matching engine vectorstore (#3350)
hwchase17 May 31, 2023
e188bac
code splitter docs (#5480)
hwchase17 May 31, 2023
92dc497
Bedrock llm and embeddings (#5464)
3coins May 31, 2023
73b6182
add more vars to text splitter (#5503)
hwchase17 May 31, 2023
248d57c
bump 187 (#5504)
dev2049 May 31, 2023
bf2a65d
Add Feedback Methods + Evaluation examples (#5166)
vowelparrot May 31, 2023
964c90d
Add allow_download as attribute for GPT4All (#5512)
Vokturz May 31, 2023
5a4c2d7
added DeepLearing.AI course link (#5518)
leo-gan May 31, 2023
d227c5d
Skips creating boto client for Bedrock if passed in constructor (#5523)
3coins May 31, 2023
c853ac3
Add Managed Motorhead (#5507)
softboyjimbo May 31, 2023
171b82f
Replace enumerate with zip. (#5527)
ttsugriy May 31, 2023
39d74f8
Add minor fixes for PySpark Document Loader Docs (#5525)
rithwik-db May 31, 2023
b80bbc9
docs: unstructured no longer requires installing detectron2 from sour…
MthwRobinson May 31, 2023
7231f99
Replace list comprehension with generator. (#5526)
ttsugriy May 31, 2023
0ed6ee4
Add param requests_kwargs for WebBaseLoader (#5485)
sevendark May 31, 2023
19bed37
Replace loop appends with list comprehension. (#5528)
ttsugriy May 31, 2023
3a7b2b3
[retrievers][knn] Replace loop appends with list comprehension. (#5529)
ttsugriy May 31, 2023
2c38ed4
Fix wrong class instantiation in docs MMR example (#5501)
tobiasvanderwerff Jun 1, 2023
12670d9
Add texts with embeddings to PGVector wrapper (#5500)
shenghann Jun 1, 2023
1701ae7
make BaseEntityStore inherit from BaseModel (#5478)
aditivin Jun 1, 2023
53adb8a
docs `ecosystem/integrations` update 3 (#5470)
leo-gan Jun 1, 2023
a900859
feat(integrations): Add WandbTracer (#4521)
parambharat Jun 1, 2023
3d567ca
add maxcompute (#5533)
dev2049 Jun 1, 2023
4268b84
add brave search util (#5538)
hwchase17 Jun 1, 2023
30f4a91
Corrects inconsistently misspelled variable name. (#5559)
patrickkeane Jun 1, 2023
6b174bb
Qdrant self query (#5567)
dev2049 Jun 1, 2023
58aabd6
bump 188 (#5568)
dev2049 Jun 1, 2023
4d8555b
make the elasticsearch api support version which below 8.x (#5495)
ARSblithe212 Jun 1, 2023
a8f58b2
Fix typo in docugami.ipynb (#5571)
eltociear Jun 1, 2023
927db98
Add missing comma in conv chat agent prompt json (#5573)
andrewlei Jun 1, 2023
4828a0b
Fix bedrock auth validation (#5574)
Jun 1, 2023
51290c4
Documentation fixes (linting and broken links) (#5563)
sseide Jun 1, 2023
2e0c4ab
nit (#5578)
dev2049 Jun 1, 2023
73f6953
Fix SQLAlchemy truncating text when it is too big (#5206)
wsantos Jun 2, 2023
a5a54e5
docs(integration): update colab and external links in WandbTracing do…
parambharat Jun 2, 2023
79328fc
Rm Template Title (#5616)
vowelparrot Jun 2, 2023
40ba2ea
human approval callback (#5581)
dev2049 Jun 2, 2023
be63db9
Es knn index search 5346 (#5569)
jeffvestal Jun 2, 2023
f074e30
Fix: Qdrant ids (#5515)
kacperlukawski Jun 2, 2023
a60f31e
Dev2049/add argilla callback (#5621)
dev2049 Jun 2, 2023
201fb7a
bump 189 (#5620)
dev2049 Jun 2, 2023
6a21bcd
fix chroma update_document to embed entire documents, fixes a charace…
cnellington Jun 2, 2023
7f729e5
Fix bedrock llm boto3 client instantiation (#5629)
Jun 2, 2023
6ac510e
Update Tracer Auth / Reduce Num Calls (#5517)
vowelparrot Jun 2, 2023
e6b30e9
fix import issue (#5636)
leo-gan Jun 2, 2023
3156234
feat: add `UnstructuredExcelLoader` for `.xlsx` and `.xls` files (#5617)
MthwRobinson Jun 3, 2023
76eebad
Fixed multi input prompt for MapReduceChain (#4979)
imeckr Jun 3, 2023
5a09e10
docs: `modules` pages simplified (#5116)
leo-gan Jun 3, 2023
6bd75b6
minor refactor GenerativeAgentMemory (#5315)
mbchang Jun 3, 2023
a3a8497
pref: reduce DB query error rate (#5339)
Undertone0809 Jun 3, 2023
5ca0644
Update confluence.py to return spaces between elements (#5383)
gardner Jun 3, 2023
6003ea2
Implements support for Personal Access Token Authentication in the Co…
felipeff Jun 3, 2023
978580d
Adds the option to pass the original prompt into the AgentExecutor fo…
nathan-az Jun 3, 2023
9d93b36
QuickFix for FinalStreamingStdOutCallbackHandler: Ignore new lines & …
UmerHA Jun 3, 2023
1796969
Add parameters to send_message() call for vertexai chat models (PaLM2…
khallbobo Jun 3, 2023
e4ce4cb
handle single arg to and/or (#5637)
dev2049 Jun 3, 2023
cb4fa68
docs `ecosystem/integrations` update 4 (#5590)
leo-gan Jun 3, 2023
31c3b73
nit: pgvector python example notebook, fix variable reference (#5595)
cjcjameson Jun 3, 2023
3a1c5eb
Harrison/update azure nb (#5665)
hwchase17 Jun 3, 2023
7a8e25c
Harrison/pubmed integration (#5664)
hwchase17 Jun 3, 2023
5a3f33a
removing client+namespace in favor of collection (#5610)
P-E-B Jun 3, 2023
a673535
fix: correct momento chat history notebook typo and title (#5646)
malandis Jun 3, 2023
3ef1e89
Created fix for 5475 (#5659)
rajib76 Jun 3, 2023
ee655f3
FileCallbackHandler (#5589)
mbchang Jun 3, 2023
ad53eae
refactor: BaseStringMessagePromptTemplate from_template method (#5332)
Sukitly Jun 3, 2023
3551344
Update youtube.py - Fix metadata validation error in YoutubeLoader (#…
ricardoreis Jun 3, 2023
a1f7141
Improve Error Messaging for APOC Procedure Failure in Neo4jGraph (#5547)
guangchen811 Jun 3, 2023
69af5f1
Support similarity_score_threshold retrieval with Chroma (#5655)
jiayao Jun 3, 2023
6243c32
This fixes issue #5651 - GPT4All wrapper loading issue (#5657)
bwv988 Jun 4, 2023
8ab249b
Add args_schema to google_places tool (#5680)
georgelroberts Jun 4, 2023
13e0435
Harrison/pipeline prompt (#5540)
hwchase17 Jun 4, 2023
74b48b8
Added Dependencies Status, Open issues and releases badges in Readme.…
nuhmanpk Jun 4, 2023
91514d6
SQL agent : Improved prompt engineering prevents agent guessing datab…
willsmithorg Jun 4, 2023
69e7b9b
Retitles Bedrock doc to appear in correct alphabetical order in site …
JasonWeill Jun 4, 2023
0c2a949
Update MongoDBChatMessageHistory to create an index on SessionId (#5632)
ldesousa-stf Jun 4, 2023
823cb98
Raise an exception in MKRL and Chat Output Parsers if parsing text wh…
nathan-az Jun 4, 2023
07fa1e5
refactor: extract token text splitter function (#5179)
JensMadsen Jun 4, 2023
7d503c3
sqlalchemy MovedIn20Warning declarative_base DEPRICATION fix (#5676)
kaahila Jun 4, 2023
41bbd0c
top_k and top_p transposed in vertexai (#5673)
mheguy-stingray Jun 4, 2023
a5a6f3b
bump version to 190 (#5704)
hwchase17 Jun 5, 2023
905998b
Addresses GPT4All wrapper model_type attribute issues #5720. (#5743)
bwv988 Jun 5, 2023
2b88921
docs: Added Deploying LLMs into production + a new ecosystem (#4047)
kouroshHakha Jun 5, 2023
15bb550
Adding support to save multiple memories at a time. Cuts save time by…
abhimalamkar Jun 5, 2023
0a16e7b
Cypher search: Check if generated Cypher is provided in backticks (#5…
tomasonjo Jun 5, 2023
3d08610
Zep Hybrid Search (#5742)
danielchalef Jun 5, 2023
ea99f92
Removes unnecessary backslash escaping for backticks in python (#5751)
spazm Jun 5, 2023
e35b394
Fix a typo in the documentation for the Slack document loader (#5745)
georgegeddes Jun 5, 2023
26c597d
Error in documentation: Chroma constructor (#5731)
gbrian Jun 5, 2023
108875c
Integrate Clickhouse as Vector Store (#5650)
haoch Jun 5, 2023
5db9973
Create OpenAIWhisperParser for generating Documents from audio files …
rlancemartin Jun 5, 2023
815512b
docs: `ecosystem/integrations` update 5 (#5752)
leo-gan Jun 5, 2023
51dcfaf
docs: updated `ecosystem/dependents` (#5753)
leo-gan Jun 5, 2023
e6a7e26
Add class attribute "return_generated_question" to class "BaseConvers…
felpigeon Jun 5, 2023
7789c37
Add aviary support (#5661)
waleedkadous Jun 5, 2023
7ee65e4
cohere retries (#5757)
hwchase17 Jun 5, 2023
3b631c4
Strips whitespace and \n from loc before filtering urls from sitemap …
ShelbyJenkins Jun 5, 2023
27ab3a0
Harrison/youtube multi language (#5758)
hwchase17 Jun 5, 2023
2163f62
fix markdown text splitter horizontal lines (#5625)
IlyaMichlin Jun 5, 2023
125bad3
Tracing Group (#5326)
agola11 Jun 6, 2023
304241a
Update tutorials.md (#5761)
edrickdch Jun 6, 2023
72584a3
feat: Support for `Tigris` Vector Database for vector search (#5703)
adilansari Jun 6, 2023
4848ade
Scores are explained in vectorestore docs (#5613)
berkedilekoglu Jun 6, 2023
77a03d4
bump ver 191 (#5766)
hwchase17 Jun 6, 2023
ac726e5
Use client from LCP-SDK (#5695)
vowelparrot Jun 6, 2023
a9199c1
fix ver 191 (#5784)
hwchase17 Jun 6, 2023
15c0a4f
Set Falsey (#5783)
vowelparrot Jun 6, 2023
2f9a4c6
Attribute support for html tags (#5782)
Xmaster6y Jun 6, 2023
5c374e9
support returning run info for llms, chat models and chains (#5666)
agola11 Jun 6, 2023
5f47075
fixing from_documents method of the MongoDB Atlas vector store (#5794)
P-E-B Jun 6, 2023
c78f949
Revise DATABRICKS_API_TOKEN as DATABRICKS_TOKEN (#5796)
gengliangwang Jun 6, 2023
9688727
YoutubeAudioLoader and updates to OpenAIWhisperParser (#5772)
rlancemartin Jun 6, 2023
10332e3
Base RunEvaluator Chain (#5750)
vowelparrot Jun 6, 2023
7960eb7
[Docs][Hotfix] Fix broken links (#5800)
kouroshHakha Jun 7, 2023
a09314e
Add UTF-8 json ouput support while langchain.debug is set to True. (#…
boxcounter Jun 7, 2023
d975d0c
WIP: openai settings (#5792)
hwchase17 Jun 7, 2023
a809a4a
added support for different types in ResponseSchema class (#5789)
MassimilianoBiancucci Jun 7, 2023
e110f96
fixed faiss integ tests (#5808)
bnassivet Jun 7, 2023
6e17a67
add doc about reusing MongoDBAtlasVectorSearch (#5805)
Pliman Jun 7, 2023
1c57a9b
Update adding_memory.ipynb (#5806)
ASwitlyk Jun 7, 2023
e9aad60
rm docs mongo (#5811)
hwchase17 Jun 7, 2023
aec1414
bump ver to 192 (#5812)
hwchase17 Jun 7, 2023
4028f77
fix: fullfill openai params when embedding (#5821)
warjiang Jun 7, 2023
609deed
bump version to 193 (#5838)
hwchase17 Jun 7, 2023
1d8226b
Add in the async methods and link the run id (#5810)
vowelparrot Jun 7, 2023
ac94e19
feat: issue-5712 add sleep tool (#5715)
whysage Jun 7, 2023
1c63876
Rm extraneous args to the trace group helper (#5801)
vowelparrot Jun 7, 2023
2d7b89b
FIX: backslash escaped (#5815)
ugfly1210 Jun 7, 2023
97f6e63
Add DeepInfra embeddings integration with tests and examples, better …
yessenzhar Jun 8, 2023
ed29496
Add how to use a custom scraping function with the sitemap loader. (#…
soos3d Jun 8, 2023
12196e1
feat: Add `UnstructuredCSVLoader` for CSV files (#5844)
MthwRobinson Jun 8, 2023
323d99c
Add logging in PBI tool (#5841)
eavanvalkenburg Jun 8, 2023
bd8c23c
Add additional VertexAI Params (#5837)
thehappydinoa Jun 8, 2023
401efcc
Update microsoft loader example with docx2txt dependency (#5832)
duarteocarmo Jun 8, 2023
04e0ebc
docs: add Shale Protocol integration guide (#5814)
renning22 Jun 8, 2023
25f9a06
qdrant vector store - search with relevancy scores (#5781)
bnassivet Jun 8, 2023
2a8c066
Update to Getting Started docs page for Memory (#5855)
daveaingram Jun 8, 2023
ff2cd56
Fix exporting GCP Vertex Matching Engine from vectorstores (#5793)
mjmammoth Jun 8, 2023
71562f6
Add knn and query search field options to ElasticKnnSearch (#5641)
jeffvestal Jun 8, 2023
81dbdf6
propagate callbacks to ConversationalRetrievalChain (#5572)
alecf Jun 8, 2023
33f8be0
Fix serialization issue with W&B (#5693)
jjzhuo Jun 8, 2023
4158155
Added SingleStoreDB Vector Store (#5619)
volodymyr-memsql Jun 8, 2023
942d3f4
Refactor and update databricks integration page (#5575)
liangz1 Jun 8, 2023
ef11125
Implement saving and loading of RetrievalQA chain (#5818)
liangz1 Jun 8, 2023
b3dc57d
Harrison/fauna loader (#5864)
hwchase17 Jun 8, 2023
4cc7808
Harrison/nebula graph (#5865)
hwchase17 Jun 8, 2023
5d6cdde
bump version to 194 (#5866)
hwchase17 Jun 8, 2023
8cd7385
fix: update qa_chain doc for "chai_type" (#5877)
warjiang Jun 8, 2023
df5c683
Update run eval imports in init (#5858)
vowelparrot Jun 8, 2023
ea460b2
Fix the shortcut conflict for document page search (#5874)
xming521 Jun 8, 2023
175e0ad
Fixes model arguments for amazon models (#5896)
3coins Jun 8, 2023
d8a3c38
Feature/add AWS Kendra Index Retriever (#5856)
hupe1980 Jun 8, 2023
217b009
Use LCP Client in Tracer (#5908)
vowelparrot Jun 9, 2023
8a6b3f8
Create snowflake Loader (#5825)
sergiolrinditex Jun 9, 2023
e8976a7
arxiv: Correct name of search client attribute to 'arxiv_search' from…
spazm Jun 9, 2023
5199a99
Fix typo (#5894)
TLazarevic Jun 9, 2023
2e36bb8
Baseten integration (#5862)
philipkiely-baseten Jun 9, 2023
5874596
Add start index to metadata in TextSplitter (#5912)
felpigeon Jun 9, 2023
860f217
Fix openai proxy error (#5914)
Fei-Wang Jun 9, 2023
5df76bf
Fix the issue where the parameters passed to VertexAI ignored #5889 (…
BigicecreamTaken Jun 9, 2023
0753c72
Add support for the endpoint URL in DynamoDBChatMesasgeHistory (#5836)
rubms Jun 9, 2023
74382c8
Expose full params in Qdrant (#5947)
kacperlukawski Jun 9, 2023
8456ae3
fixes to docs (#5919)
hwchase17 Jun 9, 2023
982572d
bump ver to 195 (#5949)
hwchase17 Jun 9, 2023
35dcbf6
Add load() to snowflake loader (#5956)
rlancemartin Jun 9, 2023
559c073
LOTR: Lord of the Retrievers. A retriever that merge several retrieve…
GMartin-dev Jun 10, 2023
c73bf87
bump version to 196 (#5988)
hwchase17 Jun 10, 2023
743f90a
Fix: SnowflakeLoader returning empty documents (#5967)
kaarthik108 Jun 10, 2023
a881f39
Fixed typo missing "use" (#5991)
constDave Jun 10, 2023
402e193
add test for structured tools (#5989)
hwchase17 Jun 10, 2023
31918d9
Fix handling of missing action & input for async MRKL agent (#5985)
danielgrittner Jun 10, 2023
b38d314
Add additional parameters to Graph Cypher Chain (#5979)
tomasonjo Jun 10, 2023
95a37bd
Add a new vector store - AwaDB (#5971) (#5992)
hwchase17 Jun 10, 2023
b23fd02
Create Airtable loader (#5958)
rlancemartin Jun 10, 2023
958e8da
feat: Add `UnstructuredXMLLoader` for `.xml` files (#5955)
qued Jun 10, 2023
0a0c034
Update to Vectara integration (#5950)
ofermend Jun 10, 2023
00f5003
fix: use model token limit not tokenizer ditto (#5939)
JensMadsen Jun 10, 2023
4dfd257
Fix: Grammer fix in documentation (#5925)
sateesh2020 Jun 10, 2023
ee69322
Fix IndexError in RecursiveCharacterTextSplitter (#5902)
TomTom101 Jun 10, 2023
3049931
add ocr_languages param for ConfluenceLoader.load() (#5823)
blankbro Jun 10, 2023
25f30d5
Harrison/arxiv fix (#5993)
hwchase17 Jun 11, 2023
7f7cb72
Obey handler.raise_error in _ahandle_event_for_handler (#6001)
pors Jun 11, 2023
9cbb492
support kwargs (#5990)
hwchase17 Jun 11, 2023
670ea1a
bump version to 197 (#6007)
hwchase17 Jun 11, 2023
f6ec845
Update databricks.md (#6006)
eltociear Jun 11, 2023
260cfa5
[APIChain] enhance the robustness or url (#6008)
jpzhangvincent Jun 11, 2023
35f3968
feat: :sparkles: Added filtering option to FAISS vectorstore (#5966)
vempaliakhil96 Jun 11, 2023
bb1ca71
fix: TypeError when loading confluence pages by cql (#5878)
haoqixu Jun 11, 2023
1568144
Harrison/embaas (#6010)
hwchase17 Jun 11, 2023
bf04b74
I before E (#6015)
vowelparrot Jun 11, 2023
fc3d07d
nc/load (#5733)
nfcampos Jun 11, 2023
1198156
Update check (#6020)
vowelparrot Jun 12, 2023
2bf7525
Langchain decorators (#6017)
ju-bezdek Jun 12, 2023
b79917f
Remove from PR template (#6018)
vowelparrot Jun 12, 2023
fce6f9a
add from_documents interface in awadb vector store (#6023)
ljeagle Jun 12, 2023
d40446b
Harrison/hologres (#6012)
hwchase17 Jun 12, 2023
6e35fe8
Update MongoDB Atlas support docs (#6022)
bafMdb Jun 12, 2023
b959e39
add dashscope text embedding (#5929)
wenmengzhou Jun 12, 2023
4c5264d
Harrison/cognitive search (#6011)
hwchase17 Jun 12, 2023
da251c4
bump ver to 198 (#6026)
hwchase17 Jun 12, 2023
8b52d43
Mongo db doc fix (#6042)
bafMdb Jun 12, 2023
0681a4c
embaas title
hwchase17 Jun 12, 2023
12bc0e2
comment out
hwchase17 Jun 12, 2023
38e5e25
chore: spedd up integration test by using smaller model (#6044)
JensMadsen Jun 12, 2023
d7de7b8
Text splitter for Markdown files by header (#5860)
rlancemartin Jun 12, 2023
5c37aac
Log tracer errors (#6066)
vowelparrot Jun 13, 2023
883a891
Add embaas document extraction api endpoints (#6048)
juliuslipp Jun 13, 2023
7f04c96
improve tools (#6062)
hwchase17 Jun 13, 2023
cfbc2c0
propogate kwargs fully (#6076)
hwchase17 Jun 13, 2023
fe37360
Enable serialization for anthropic (#6049)
nfcampos Jun 13, 2023
f4cdbc5
turn off repr (#6078)
hwchase17 Jun 13, 2023
bf7e800
Use Run object from SDK (#6067)
vowelparrot Jun 13, 2023
b115877
Fix for ModuleNotFoundError while running langchain-server. Issue #58…
solidate Jun 13, 2023
88102fc
Add tests and update notebook for MarkdownHeaderTextSplitter (#6069)
rlancemartin Jun 13, 2023
d56ebda
support functions (#6099)
hwchase17 Jun 13, 2023
af9fa13
convert tools to openai (#6100)
hwchase17 Jun 13, 2023
b7c9931
Implement `max_marginal_relevance_search` in `VectorStore` of Pinecon…
neo Jun 13, 2023
1d627fe
bump version to 199 (#6102)
hwchase17 Jun 13, 2023
843343a
Harrison/notebook functions (#6103)
hwchase17 Jun 13, 2023
4bebdbd
Add support for tags (#5898)
nfcampos Jun 13, 2023
63962cc
support streaming for functions (#6115)
hwchase17 Jun 13, 2023
e01f475
Return session name in runner response (#6112)
vowelparrot Jun 13, 2023
4b3e194
add functions agent (#6113)
hwchase17 Jun 14, 2023
0ea2cb1
bump ver to 200 (#6130)
hwchase17 Jun 14, 2023
d36d478
Add Run Collector Callback (#6133)
vowelparrot Jun 14, 2023
9946f75
Update Name (#6136)
vowelparrot Jun 14, 2023
f3e3394
Update readthedocs_documentation.ipynb (#6148)
maver1ck Jun 14, 2023
f10cdfb
typo: 'following following' to 'following' (#6163)
thiswillbeyourgithub Jun 14, 2023
2050204
Add docs for tags (#6155)
nfcampos Jun 14, 2023
71b35c4
feat: Add support for the Solidity language (#6054)
0xJord4n Jun 14, 2023
571ac6d
feat: add content_format param to ConfluenceLoader.load() (#5922)
haoqixu Jun 14, 2023
e2920a1
feat: use latest duckduckgo_search API to call
Undertone0809 Jun 19, 2023
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
  •  
  •  
  •  
41 changes: 41 additions & 0 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -115,8 +115,37 @@ To get a report of current coverage, run the following:
make coverage
```

### Working with Optional Dependencies

Langchain relies heavily on optional dependencies to keep the Langchain package lightweight.

If you're adding a new dependency to Langchain, assume that it will be an optional dependency, and
that most users won't have it installed.

Users that do not have the dependency installed should be able to **import** your code without
any side effects (no warnings, no errors, no exceptions).

To introduce the dependency to the pyproject.toml file correctly, please do the following:

1. Add the dependency to the main group as an optional dependency
```bash
poetry add --optional [package_name]
```
2. Open pyproject.toml and add the dependency to the `extended_testing` extra
3. Relock the poetry file to update the extra.
```bash
poetry lock --no-update
```
4. Add a unit test that the very least attempts to import the new code. Ideally the unit
test makes use of lightweight fixtures to test the logic of the code.
5. Please use the `@pytest.mark.requires(package_name)` decorator for any tests that require the dependency.

### Testing

See section about optional dependencies.

#### Unit Tests

Unit tests cover modular logic that does not require calls to outside APIs.

To run unit tests:
Expand All @@ -133,8 +162,20 @@ make docker_tests

If you add new logic, please add a unit test.



#### Integration Tests

Integration tests cover logic that requires making calls to outside APIs (often integration with other services).

**warning** Almost no tests should be integration tests.

Tests that require making network connections make it difficult for other
developers to test the code.

Instead favor relying on `responses` library and/or mock.patch to mock
requests using small fixtures.

To run integration tests:

```bash
Expand Down
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/bug-report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ body:
- @agola11

Tools / Toolkits
- @vowelparrot
- ...

placeholder: "@Username ..."

Expand Down
56 changes: 33 additions & 23 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -1,46 +1,56 @@
# Your PR Title (What it does)

<!--
Thank you for contributing to LangChain! Your PR will appear in our next release under the title you set. Please make sure it highlights your valuable contribution.
Thank you for contributing to LangChain! Your PR will appear in our release under the title you set. Please make sure it highlights your valuable contribution.

Replace this with a description of the change, the issue it fixes (if applicable), and relevant context. List any dependencies required for this change.

After you're done, someone will review your PR. They may suggest improvements. If no one reviews your PR within a few days, feel free to @-mention the same people again, as notifications can get lost.

Finally, we'd love to show appreciation for your contribution - if you'd like us to shout you out on Twitter, please also include your handle!
-->

<!-- Remove if not applicable -->

Fixes # (issue)

## Before submitting
#### Before submitting

<!-- If you're adding a new integration, please include:

<!-- If you're adding a new integration, include an integration test and an example notebook showing its use! -->
1. a test for the integration - favor unit tests that does not rely on network access.
2. an example notebook showing its use

## Who can review?

Community members can review the PR once tests pass. Tag maintainers/contributors who might be interested:
See contribution guidelines for more information on how to write tests, lint
etc:

https://github.com/hwchase17/langchain/blob/master/.github/CONTRIBUTING.md
-->

#### Who can review?

Tag maintainers/contributors who might be interested:

<!-- For a quicker response, figure out the right person to tag with @

@hwchase17 - project lead
@hwchase17 - project lead

Tracing / Callbacks
- @agola11

Async
- @agola11

Tracing / Callbacks
- @agola11
DataLoaders
- @eyurtsev

Async
- @agola11
Models
- @hwchase17
- @agola11

DataLoaders
- @eyurtsev
Agents / Tools / Toolkits
- @hwchase17

Models
- @hwchase17
- @agola11
VectorStores / Retrievers / Memory
- @dev2049

Agents / Tools / Toolkits
- @vowelparrot

VectorStores / Retrievers / Memory
- @dev2049

-->
5 changes: 4 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -149,4 +149,7 @@ wandb/

# integration test artifacts
data_map*
\[('_type', 'fake'), ('stop', None)]
\[('_type', 'fake'), ('stop', None)]

# Replit files
*replit*
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

⚡ Building applications with LLMs through composability ⚡

[![Release Notes](https://img.shields.io/github/release/hwchase17/langchain)](https://github.com/hwchase17/langchain/releases)
[![lint](https://github.com/hwchase17/langchain/actions/workflows/lint.yml/badge.svg)](https://github.com/hwchase17/langchain/actions/workflows/lint.yml)
[![test](https://github.com/hwchase17/langchain/actions/workflows/test.yml/badge.svg)](https://github.com/hwchase17/langchain/actions/workflows/test.yml)
[![linkcheck](https://github.com/hwchase17/langchain/actions/workflows/linkcheck.yml/badge.svg)](https://github.com/hwchase17/langchain/actions/workflows/linkcheck.yml)
Expand All @@ -12,6 +13,8 @@
[![Open in Dev Containers](https://img.shields.io/static/v1?label=Dev%20Containers&message=Open&color=blue&logo=visualstudiocode)](https://vscode.dev/redirect?url=vscode://ms-vscode-remote.remote-containers/cloneInVolume?url=https://github.com/hwchase17/langchain)
[![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/hwchase17/langchain)
[![GitHub star chart](https://img.shields.io/github/stars/hwchase17/langchain?style=social)](https://star-history.com/#hwchase17/langchain)
[![Dependency Status](https://img.shields.io/librariesio/github/hwchase17/langchain)](https://libraries.io/github/hwchase17/langchain)
[![Open Issues](https://img.shields.io/github/issues-raw/hwchase17/langchain)](https://github.com/hwchase17/langchain/issues)


Looking for the JS/TS version? Check out [LangChain.js](https://github.com/hwchase17/langchainjs).
Expand Down
1 change: 1 addition & 0 deletions docs/_static/js/mendablesearch.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ document.addEventListener('DOMContentLoaded', () => {
style: { darkMode: false, accentColor: '#010810' },
floatingButtonStyle: { color: '#ffffff', backgroundColor: '#010810' },
anon_key: '82842b36-3ea6-49b2-9fb8-52cfc4bde6bf', // Mendable Search Public ANON key, ok to be public
cmdShortcutKey:'j',
messageSettings: {
openSourcesInNewTab: false,
prettySources: true // Prettify the sources displayed now
Expand Down
137 changes: 137 additions & 0 deletions docs/additional_resources/deploy_llms.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,137 @@

===========================
Deploying LLMs in Production
===========================

In today's fast-paced technological landscape, the use of Large Language Models (LLMs) is rapidly expanding. As a result, it's crucial for developers to understand how to effectively deploy these models in production environments. LLM interfaces typically fall into two categories:

- **Case 1: Utilizing External LLM Providers (OpenAI, Anthropic, etc.)**
In this scenario, most of the computational burden is handled by the LLM providers, while LangChain simplifies the implementation of business logic around these services. This approach includes features such as prompt templating, chat message generation, caching, vector embedding database creation, preprocessing, etc.

- **Case 2: Self-hosted Open-Source Models**
Alternatively, developers can opt to use smaller, yet comparably capable, self-hosted open-source LLM models. This approach can significantly decrease costs, latency, and privacy concerns associated with transferring data to external LLM providers.

Regardless of the framework that forms the backbone of your product, deploying LLM applications comes with its own set of challenges. It's vital to understand the trade-offs and key considerations when evaluating serving frameworks.

Outline
=======

This guide aims to provide a comprehensive overview of the requirements for deploying LLMs in a production setting, focusing on:

- `Designing a Robust LLM Application Service <#robust>`_
- `Maintaining Cost-Efficiency <#cost>`_
- `Ensuring Rapid Iteration <#iteration>`_

Understanding these components is crucial when assessing serving systems. LangChain integrates with several open-source projects designed to tackle these issues, providing a robust framework for productionizing your LLM applications. Some notable frameworks include:

- `Ray Serve <../integrations/ray_serve.html>`_
- `BentoML <https://github.com/ssheng/BentoChain>`_
- `Modal <../integrations/modal.html>`_

These links will provide further information on each ecosystem, assisting you in finding the best fit for your LLM deployment needs.

Designing a Robust LLM Application Service
===========================================
.. _robust:

When deploying an LLM service in production, it's imperative to provide a seamless user experience free from outages. Achieving 24/7 service availability involves creating and maintaining several sub-systems surrounding your application.

Monitoring
----------

Monitoring forms an integral part of any system running in a production environment. In the context of LLMs, it is essential to monitor both performance and quality metrics.

**Performance Metrics:** These metrics provide insights into the efficiency and capacity of your model. Here are some key examples:

- Query per second (QPS): This measures the number of queries your model processes in a second, offering insights into its utilization.
- Latency: This metric quantifies the delay from when your client sends a request to when they receive a response.
- Tokens Per Second (TPS): This represents the number of tokens your model can generate in a second.

**Quality Metrics:** These metrics are typically customized according to the business use-case. For instance, how does the output of your system compare to a baseline, such as a previous version? Although these metrics can be calculated offline, you need to log the necessary data to use them later.

Fault tolerance
---------------

Your application may encounter errors such as exceptions in your model inference or business logic code, causing failures and disrupting traffic. Other potential issues could arise from the machine running your application, such as unexpected hardware breakdowns or loss of spot-instances during high-demand periods. One way to mitigate these risks is by increasing redundancy through replica scaling and implementing recovery mechanisms for failed replicas. However, model replicas aren't the only potential points of failure. It's essential to build resilience against various failures that could occur at any point in your stack.


Zero down time upgrade
----------------------

System upgrades are often necessary but can result in service disruptions if not handled correctly. One way to prevent downtime during upgrades is by implementing a smooth transition process from the old version to the new one. Ideally, the new version of your LLM service is deployed, and traffic gradually shifts from the old to the new version, maintaining a constant QPS throughout the process.


Load balancing
--------------

Load balancing, in simple terms, is a technique to distribute work evenly across multiple computers, servers, or other resources to optimize the utilization of the system, maximize throughput, minimize response time, and avoid overload of any single resource. Think of it as a traffic officer directing cars (requests) to different roads (servers) so that no single road becomes too congested.

There are several strategies for load balancing. For example, one common method is the *Round Robin* strategy, where each request is sent to the next server in line, cycling back to the first when all servers have received a request. This works well when all servers are equally capable. However, if some servers are more powerful than others, you might use a *Weighted Round Robin* or *Least Connections* strategy, where more requests are sent to the more powerful servers, or to those currently handling the fewest active requests. Let's imagine you're running a LLM chain. If your application becomes popular, you could have hundreds or even thousands of users asking questions at the same time. If one server gets too busy (high load), the load balancer would direct new requests to another server that is less busy. This way, all your users get a timely response and the system remains stable.



Maintaining Cost-Efficiency and Scalability
============================================
.. _cost:

Deploying LLM services can be costly, especially when you're handling a large volume of user interactions. Charges by LLM providers are usually based on tokens used, making a chat system inference on these models potentially expensive. However, several strategies can help manage these costs without compromising the quality of the service.


Self-hosting models
-------------------

Several smaller and open-source LLMs are emerging to tackle the issue of reliance on LLM providers. Self-hosting allows you to maintain similar quality to LLM provider models while managing costs. The challenge lies in building a reliable, high-performing LLM serving system on your own machines.

Resource Management and Auto-Scaling
------------------------------------

Computational logic within your application requires precise resource allocation. For instance, if part of your traffic is served by an OpenAI endpoint and another part by a self-hosted model, it's crucial to allocate suitable resources for each. Auto-scaling—adjusting resource allocation based on traffic—can significantly impact the cost of running your application. This strategy requires a balance between cost and responsiveness, ensuring neither resource over-provisioning nor compromised application responsiveness.

Utilizing Spot Instances
------------------------

On platforms like AWS, spot instances offer substantial cost savings, typically priced at about a third of on-demand instances. The trade-off is a higher crash rate, necessitating a robust fault-tolerance mechanism for effective use.

Independent Scaling
-------------------

When self-hosting your models, you should consider independent scaling. For example, if you have two translation models, one fine-tuned for French and another for Spanish, incoming requests might necessitate different scaling requirements for each.

Batching requests
-----------------

In the context of Large Language Models, batching requests can enhance efficiency by better utilizing your GPU resources. GPUs are inherently parallel processors, designed to handle multiple tasks simultaneously. If you send individual requests to the model, the GPU might not be fully utilized as it's only working on a single task at a time. On the other hand, by batching requests together, you're allowing the GPU to work on multiple tasks at once, maximizing its utilization and improving inference speed. This not only leads to cost savings but can also improve the overall latency of your LLM service.


In summary, managing costs while scaling your LLM services requires a strategic approach. Utilizing self-hosting models, managing resources effectively, employing auto-scaling, using spot instances, independently scaling models, and batching requests are key strategies to consider. Open-source libraries such as Ray Serve and BentoML are designed to deal with these complexities.



Ensuring Rapid Iteration
========================

.. _iteration:

The LLM landscape is evolving at an unprecedented pace, with new libraries and model architectures being introduced constantly. Consequently, it's crucial to avoid tying yourself to a solution specific to one particular framework. This is especially relevant in serving, where changes to your infrastructure can be time-consuming, expensive, and risky. Strive for infrastructure that is not locked into any specific machine learning library or framework, but instead offers a general-purpose, scalable serving layer. Here are some aspects where flexibility plays a key role:

Model composition
-----------------

Deploying systems like LangChain demands the ability to piece together different models and connect them via logic. Take the example of building a natural language input SQL query engine. Querying an LLM and obtaining the SQL command is only part of the system. You need to extract metadata from the connected database, construct a prompt for the LLM, run the SQL query on an engine, collect and feed back the response to the LLM as the query runs, and present the results to the user. This demonstrates the need to seamlessly integrate various complex components built in Python into a dynamic chain of logical blocks that can be served together.

Cloud providers
---------------

Many hosted solutions are restricted to a single cloud provider, which can limit your options in today's multi-cloud world. Depending on where your other infrastructure components are built, you might prefer to stick with your chosen cloud provider.


Infrastructure as Code (IaC)
---------------------------

Rapid iteration also involves the ability to recreate your infrastructure quickly and reliably. This is where Infrastructure as Code (IaC) tools like Terraform, CloudFormation, or Kubernetes YAML files come into play. They allow you to define your infrastructure in code files, which can be version controlled and quickly deployed, enabling faster and more reliable iterations.


CI/CD
-----

In a fast-paced environment, implementing CI/CD pipelines can significantly speed up the iteration process. They help automate the testing and deployment of your LLM applications, reducing the risk of errors and enabling faster feedback and iteration.
Loading