mirror of
https://github.com/langchain-ai/langgraph.git
synced 2026-09-13 21:27:52 +02:00
docs (examples): replace SqliteSaver with MemorySaver (#1271)
This commit is contained in:
@@ -574,7 +574,7 @@
|
||||
}
|
||||
],
|
||||
"source": [
|
||||
"from langgraph.checkpoint.sqlite import SqliteSaver\n",
|
||||
"from langgraph.checkpoint.memory import MemorySaver\n",
|
||||
"from langgraph.graph import START, END, StateGraph\n",
|
||||
"from langgraph.prebuilt import tools_condition\n",
|
||||
"from IPython.display import Image, display\n",
|
||||
@@ -597,7 +597,7 @@
|
||||
"builder.add_edge(\"tools\", \"assistant\")\n",
|
||||
"\n",
|
||||
"# The checkpointer lets the graph persist its state\n",
|
||||
"memory = SqliteSaver.from_conn_string(\":memory:\")\n",
|
||||
"memory = MemorySaver()\n",
|
||||
"react_graph = builder.compile(checkpointer=memory)\n",
|
||||
"\n",
|
||||
"# Show\n",
|
||||
|
||||
@@ -253,7 +253,7 @@
|
||||
"\n",
|
||||
"\n",
|
||||
"from IPython.display import Image, display\n",
|
||||
"from langgraph.checkpoint.sqlite import SqliteSaver\n",
|
||||
"from langgraph.checkpoint.memory import MemorySaver\n",
|
||||
"from langgraph.graph import END, START, StateGraph\n",
|
||||
"from langgraph.prebuilt import tools_condition\n",
|
||||
"\n",
|
||||
@@ -275,7 +275,7 @@
|
||||
"builder.add_edge(\"tools\", \"assistant\")\n",
|
||||
"\n",
|
||||
"# The checkpointer lets the graph persist its state\n",
|
||||
"memory = SqliteSaver.from_conn_string(\":memory:\")\n",
|
||||
"memory = MemorySaver()\n",
|
||||
"react_graph = builder.compile(checkpointer=memory)\n",
|
||||
"\n",
|
||||
"# Show\n",
|
||||
|
||||
Reference in New Issue
Block a user