Skip to content

Building AI agents, atomically

Refactor article outline generator and deep query agent to use input_schema method

KennyVaneetvelde555e245eaf5f
diff --git a/examples/deep_research_multi_agent/article_outline_generator.py b/examples/deep_research_multi_agent/article_outline_generator.py
index 0c2372a..da6236d 100644
--- a/examples/deep_research_multi_agent/article_outline_generator.py
+++ b/examples/deep_research_multi_agent/article_outline_generator.py
@@ -112,7 +112,7 @@ while True:
print('Exiting chat...')
break
- response = agent.run(user_input)
+ response = agent.run(agent.input_schema(chat_input=user_input))
response_dict = response.dict()
def format_markdown_section(title, items):
diff --git a/examples/deep_research_multi_agent/deep_query_agent.py b/examples/deep_research_multi_agent/deep_query_agent.py
index 71934fe..b9f8a49 100644
--- a/examples/deep_research_multi_agent/deep_query_agent.py
+++ b/examples/deep_research_multi_agent/deep_query_agent.py
@@ -101,6 +101,6 @@ deep_query_agent = DeepQueryAgent(
if __name__ == "__main__":
# We can test the agent by running a topic through it and observing the generated queries.
console = Console()
- output = deep_query_agent.run('What are the benefits of exercise?')
+ output = deep_query_agent.run(deep_query_agent.input_schema(chat_input='Apple intelligence'))
console.print(output)
\ No newline at end of file
diff --git a/examples/orchestrated_agents.py b/examples/minimal_multi_agent_tool_use.py
similarity index 100%
rename from examples/orchestrated_agents.py
rename to examples/minimal_multi_agent_tool_use.py