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

docs: fix 06-langchain-agents.ipynb #303

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions learn/generation/langchain/handbook/06-langchain-agents.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -377,7 +377,7 @@
"from langchain_experimental.sql import SQLDatabaseChain\n",
"\n",
"db = SQLDatabase(engine)\n",
"sql_chain = SQLDatabaseChain(llm=llm, database=db, verbose=True)"
"sql_chain = SQLDatabaseChain.from_llm(llm=llm, db=db, verbose=True)"
]
},
{
Expand Down Expand Up @@ -428,9 +428,9 @@
{
"cell_type": "markdown",
"source": [
"In this first example we will use slightly different type of agent - SQL Agent which can be instantiated with it's own method `create_sql_agent`. Other agents will be instantiated in more generic way as we will see below in other examples.\n",
"In this first example we will use a slightly different type of agent - SQL Agent which can be instantiated with its own method `create_sql_agent`. Other agents will be instantiated more generically as we will see below in other examples.\n",
"<br><br>\n",
"This method uses *toolkit* instead of simple list of `tools`. You can read more about them in the [documentation](https://python.langchain.com/docs/modules/agents/toolkits/). For this use case, we will use `SQLDatabaseToolkit`."
"This method uses *toolkit* instead of a simple list of `tools`. You can read more about them in the [documentation](https://python.langchain.com/docs/modules/agents/toolkits/). For this use case, we will use `SQLDatabaseToolkit`."
],
"metadata": {
"id": "Tgn6dRLEcxli"
Expand Down Expand Up @@ -1249,4 +1249,4 @@
},
"nbformat": 4,
"nbformat_minor": 5
}
}