mirror of
https://github.com/langchain-ai/langgraph.git
synced 2026-09-10 03:37:51 +02:00
docs: Use bound model in convo history (#1082)
This fixes a small mistake in the manage-conversation-history notebook where the model bound with tools was not used, instead, the original model was used when invocations occur.
This commit is contained in:
@@ -138,7 +138,7 @@
|
||||
"\n",
|
||||
"# Define the function that calls the model\n",
|
||||
"def call_model(state: MessagesState):\n",
|
||||
" response = model.invoke(state[\"messages\"])\n",
|
||||
" response = bound_model.invoke(state[\"messages\"])\n",
|
||||
" # We return a list, because this will get added to the existing list\n",
|
||||
" return {\"messages\": response}\n",
|
||||
"\n",
|
||||
@@ -275,7 +275,7 @@
|
||||
"# Define the function that calls the model\n",
|
||||
"def call_model(state: MessagesState):\n",
|
||||
" messages = filter_messages(state[\"messages\"])\n",
|
||||
" response = model.invoke(messages)\n",
|
||||
" response = bound_model.invoke(messages)\n",
|
||||
" # We return a list, because this will get added to the existing list\n",
|
||||
" return {\"messages\": response}\n",
|
||||
"\n",
|
||||
|
||||
Reference in New Issue
Block a user