Skip to content

Commit 779ed3e

Browse files
committed
chore: link
1 parent 694c0aa commit 779ed3e

File tree

1 file changed

+30
-23
lines changed

1 file changed

+30
-23
lines changed

learn/generation/langchain/langgraph/02-ollama-langgraph-agent/02-ollama-langgraph-agent.ipynb

Lines changed: 30 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1025,6 +1025,13 @@
10251025
"runnable = graph.compile()"
10261026
]
10271027
},
1028+
{
1029+
"cell_type": "markdown",
1030+
"metadata": {},
1031+
"source": [
1032+
"To view the graph we can generate a mermaid graph like so:"
1033+
]
1034+
},
10281035
{
10291036
"cell_type": "code",
10301037
"execution_count": 25,
@@ -1063,6 +1070,20 @@
10631070
")"
10641071
]
10651072
},
1073+
{
1074+
"cell_type": "markdown",
1075+
"metadata": {},
1076+
"source": [
1077+
"## Testing the Agent"
1078+
]
1079+
},
1080+
{
1081+
"cell_type": "markdown",
1082+
"metadata": {},
1083+
"source": [
1084+
"Our agent has now been constructed so we can test it. First, let's check for the best pizza in Rome:"
1085+
]
1086+
},
10661087
{
10671088
"cell_type": "code",
10681089
"execution_count": 26,
@@ -1091,6 +1112,13 @@
10911112
"})"
10921113
]
10931114
},
1115+
{
1116+
"cell_type": "markdown",
1117+
"metadata": {},
1118+
"source": [
1119+
"We extract the answer:"
1120+
]
1121+
},
10941122
{
10951123
"cell_type": "code",
10961124
"execution_count": 28,
@@ -1114,31 +1142,10 @@
11141142
]
11151143
},
11161144
{
1117-
"cell_type": "code",
1118-
"execution_count": 29,
1145+
"cell_type": "markdown",
11191146
"metadata": {},
1120-
"outputs": [
1121-
{
1122-
"name": "stdout",
1123-
"output_type": "stream",
1124-
"text": [
1125-
"run_oracle\n",
1126-
"router\n",
1127-
"run_tool | search.invoke(input={'query': 'gluten-free pizza in Rome'})\n",
1128-
"The food in Italy is just ridiculously good. I ate so much in Rome. Gluten free pizza.\n",
1129-
"Celiac Disease Videos\n",
1130-
"Italy: a gluten-free paradise?\n",
1131-
"run_oracle\n",
1132-
"router\n",
1133-
"run_tool | final_answer.invoke(input={'answer': 'Unfortunately, I was unable to find a specific recommendation for gluten-free pizza in Rome from the search results. However, based on the comments and reviews provided, it seems that Italy is generally considered a good destination for gluten-free options, especially when it comes to traditional Italian cuisine like pizza. The restaurant \"Pizza in Trevi\" mentioned in one of the reviews was described as a \"marvelous restaurant\" with a gluten-free option available, but it was noted that prices were on the higher side at around 30-40€ per person per meal.', 'phone_number': '', 'address': ''})\n"
1134-
]
1135-
}
1136-
],
11371147
"source": [
1138-
"out = runnable.invoke({\n",
1139-
" \"input\": \"where is the best gluten free pizza in rome?\",\n",
1140-
" \"chat_history\": [],\n",
1141-
"})"
1148+
"We are recommended [Seu Pizza Illuminati](https://maps.app.goo.gl/RMSdTUpH8D3oQETUA), a seemingly notorious pizzeria known for their less traditional and more experimental Neapolitan pizzas."
11421149
]
11431150
},
11441151
{

0 commit comments

Comments
 (0)