bump version to 128 (#2236)

doc
Harrison Chase 1 year ago committed by GitHub
parent 0ce4767076
commit e57b045402
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -46,11 +46,10 @@
"metadata": {},
"outputs": [
{
"name": "stdout",
"name": "stderr",
"output_type": "stream",
"text": [
"Running Chroma using direct local API.\n",
"Using DuckDB in-memory for database. Data will be transient.\n"
"Using embedded DuckDB without persistence: data will be transient\n"
]
}
],
@ -71,10 +70,6 @@
"name": "stdout",
"output_type": "stream",
"text": [
"In state after state, new laws have been passed, not only to suppress the vote, but to subvert entire elections. \n",
"\n",
"We cannot let this happen. \n",
"\n",
"Tonight. I call on the Senate to: Pass the Freedom to Vote Act. Pass the John Lewis Voting Rights Act. And while youre at it, pass the Disclose Act so Americans can know who is funding our elections. \n",
"\n",
"Tonight, Id like to honor someone who has dedicated his life to serve this country: Justice Stephen Breyer—an Army veteran, Constitutional scholar, and retiring Justice of the United States Supreme Court. Justice Breyer, thank you for your service. \n",
@ -234,10 +229,55 @@
"vectordb = Chroma(persist_directory=persist_directory, embedding_function=embedding)\n"
]
},
{
"cell_type": "markdown",
"id": "794a7552",
"metadata": {},
"source": [
"## Retriever options\n",
"\n",
"This section goes over different options for how to use Chroma as a retriever.\n",
"\n",
"### MMR\n",
"\n",
"In addition to using similarity search in the retriever object, you can also use `mmr`."
]
},
{
"cell_type": "code",
"execution_count": 6,
"id": "96ff911a",
"metadata": {},
"outputs": [],
"source": [
"retriever = db.as_retriever(search_type=\"mmr\")"
]
},
{
"cell_type": "code",
"execution_count": 8,
"id": "f00be6d0",
"metadata": {},
"outputs": [
{
"data": {
"text/plain": [
"Document(page_content='Tonight. I call on the Senate to: Pass the Freedom to Vote Act. Pass the John Lewis Voting Rights Act. And while youre at it, pass the Disclose Act so Americans can know who is funding our elections. \\n\\nTonight, Id like to honor someone who has dedicated his life to serve this country: Justice Stephen Breyer—an Army veteran, Constitutional scholar, and retiring Justice of the United States Supreme Court. Justice Breyer, thank you for your service. \\n\\nOne of the most serious constitutional responsibilities a President has is nominating someone to serve on the United States Supreme Court. \\n\\nAnd I did that 4 days ago, when I nominated Circuit Court of Appeals Judge Ketanji Brown Jackson. One of our nations top legal minds, who will continue Justice Breyers legacy of excellence.', metadata={'source': '../../../state_of_the_union.txt'})"
]
},
"execution_count": 8,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"retriever.get_relevant_documents(query)[0]"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "4dde7a0d",
"id": "a559c3f1",
"metadata": {},
"outputs": [],
"source": []

@ -1,6 +1,6 @@
[tool.poetry]
name = "langchain"
version = "0.0.127"
version = "0.0.128"
description = "Building applications with LLMs through composability"
authors = []
license = "MIT"

Loading…
Cancel
Save