Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions 01_ai_agents_first/13_agents_as_tool/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ async def main():
result = await Runner.run(agent, "What is the weather like today?")
print(result.final_output)

if _name_ == "_main_":
if __name__ == "__main__":
asyncio.run(main())

```
Expand Down Expand Up @@ -251,6 +251,4 @@ If later you need stricter control, replace a tool with a `@function_tool` that

- **📌 What it is**: Treat other agents like **callable tools** to keep orchestration in one place.
- **✅ When to use**: Short, focused subtasks—translate, extract, format—while preserving one conversational owner.
- **🔨 How to do it**: Start with `agent.as_tool(...)`; switch to a function tool that calls `Runner.run(...)` when you need more control.

If you want, I can turn this into a printable cheat-sheet or a small lab with checkpoints and expected outputs.
- **🔨 How to do it**: Start with `agent.as_tool(...)`; switch to a function tool that calls `Runner.run(...)` when you need more control.