Skip to content

Commit 53c3cc0

Browse files
authored
docs: add tool use (#3)
Add contents about challenges faced
1 parent c693874 commit 53c3cc0

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

notes/day-02.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,13 @@
1313
- 可以使用 `uvx adk web` 命令启动 Web 界面与智能体交互
1414
- 支持使用 Gemini 模型(如 `gemini-2.5-flash``gemini-3`
1515
- 使用 `uvx` 可以直接运行 ADK 命令,无需预先安装 `google-adk`
16+
-`root_agent.yaml` 中加入 `tools` 字段即可配置工具
1617

1718
## Challenges Faced
1819

20+
- 后续使用方便起见,这次直接安装了完整的 `google-adk`
21+
- 注意⚠️:其中的 `MCP` 组件强制要求Python版本在**3.10**以上,新建环境时要注意编译器的选择
22+
- 在Pycharm终端调用agent互动时,无法显式输出日志,只能通过prompt要求输出思考过程
1923
- 网站上给的 command 是错误的,运行 `uvx --from google-adk adk web` 时默认时读取 a directory of agents,而不是在 agent directory。
2024
- Tutorial: AI agent with Google Search(YAML) instruction 也是错的. `adk web` 运行的时候directory应该在agent的parent folder里。
2125
- Tutorial: Multi-agent app with MCP (YAML) 要安装Node.Js 是firecrawl的dependency。firecrawl需要注册,free tier不需要花钱,api key能在设置里找到。
@@ -41,6 +45,9 @@ name: root_agent
4145
description: A helpful assistant for user questions.
4246
instruction: Answer user questions to the best of your knowledge.
4347
model: gemini-2.5-flash
48+
49+
tools:
50+
- name: google_search
4451
```
4552
### `adk api_server` 的使用
4653
以调取api的模式使用agent不能直接点击网页或者和UI直接交互。just in case有人和我一样不懂怎么调取api,下面是使用范例。

0 commit comments

Comments
 (0)