Skip to main content
You can interact with the Agent as normally. It will reason before providing a final answer. You will see its chain of thought live as it is generated.
reasoning_model.py

Run the Example

1

Set up your virtual environment

2

Install dependencies

3

Export your API keys

4

Run the example

Save the code above as reasoning_model.py, then run:
Full source: cookbook/05_agent_os/advanced_demo/reasoning_model.py