Skip to content

Commit 4ddb701

Browse files
committed
Removes tool call example
1 parent c3db3c7 commit 4ddb701

File tree

1 file changed

+20
-17
lines changed

1 file changed

+20
-17
lines changed

docs/tools.ipynb

Lines changed: 20 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@
5858
},
5959
{
6060
"cell_type": "code",
61-
"execution_count": null,
61+
"execution_count": 3,
6262
"id": "4d315465",
6363
"metadata": {},
6464
"outputs": [],
@@ -107,22 +107,12 @@
107107
"# Direct invoke\n",
108108
"html_text = tool.invoke(\n",
109109
" {\n",
110-
" \"url\": \"https://example.com\",\n",
111-
" \"output_format\": \"text\",\n",
110+
" \"url\": \"https://langchain.com\",\n",
111+
" \"output_format\": \"markdown\",\n",
112112
" \"render\": True,\n",
113113
" }\n",
114114
")\n",
115-
"print(html_text[:300], \"\")\n",
116-
"\n",
117-
"# Invoke with a ToolCall dict (for agents)\n",
118-
"tool_call = {\n",
119-
" \"args\": {\"url\": \"https://example.com\", \"render\": True},\n",
120-
" \"id\": \"1\",\n",
121-
" \"name\": \"scraperapi\",\n",
122-
" \"type\": \"tool_call\",\n",
123-
"}\n",
124-
"response = tool.invoke(tool_call)\n",
125-
"print(type(response), len(response))"
115+
"print(html_text[:300], \"\")"
126116
]
127117
},
128118
{
@@ -236,8 +226,7 @@
236226
"agent_executor = AgentExecutor(agent=agent, tools=tools, verbose=True)\n",
237227
"response = agent_executor.invoke({\n",
238228
" \"input\": \"can you browse hackernews and summarize the first website\"\n",
239-
"})\n",
240-
"print(response)"
229+
"})"
241230
]
242231
},
243232
{
@@ -262,8 +251,22 @@
262251
"main_language": "python",
263252
"notebook_metadata_filter": "-all"
264253
},
254+
"kernelspec": {
255+
"display_name": "Python 3",
256+
"language": "python",
257+
"name": "python3"
258+
},
265259
"language_info": {
266-
"name": "python"
260+
"codemirror_mode": {
261+
"name": "ipython",
262+
"version": 3
263+
},
264+
"file_extension": ".py",
265+
"mimetype": "text/x-python",
266+
"name": "python",
267+
"nbconvert_exporter": "python",
268+
"pygments_lexer": "ipython3",
269+
"version": "3.10.2"
267270
}
268271
},
269272
"nbformat": 4,

0 commit comments

Comments
 (0)