The phidata cookbook contains in-depth examples and code. From basic agents, function calling, structured output to advanced fine-tuning and evaluations.

Clone the cookbook

1

Fork & clone the phidata repo

We recommend forking the phidata repo first so you can customize the cookbooks, and contribute your own recipes back to the repo.

Fork & clone the phidata repo

git clone https://github.com/phidatahq/phidata

cd into the phidata directory

cd phidata
2

Create a virtual environment

Create a virtual environment with the required libraries and install the project in editable mode. You can use a helper script or run these steps manually.

3

Run any recipe

Set your OPENAI_API_KEY

Install openai and duckduckgo-search

pip install openai duckduckgo-search

Run the agents/web_search.py recipe

python cookbook/agents/01_web_search.py