Project files
Project files¶
This project contains the following files.
README.md: This filepydanticai.API.ipynb: notebook describing core PydanticAI APIspydanticai.example.ipynb: notebook with applied, end-to-end examplesrequirements.txt: Python dependencies used by this tutorialexample_dataset/: supporting markdown files used in examplesapi.mdbilling.mdintegrations.mdlimits.mdoverview.mdsecurity.mdsupport.mdtroubleshooting.md
- Docker/dev runtime files
Dockerfiledocker_build.shdocker_bash.shdocker_jupyter.shdocker_exec.shdocker_cmd.shdocker_clean.shdocker_push.shdocker_name.shversion.shrun_jupyter.shetc_sudoers
Setup and Dependencies¶
Building and Running the Docker Container¶
- Go to the project directory:
> cd tutorials/tutorial_pydanticAI - Build Docker image:
> ./docker_build.sh - Run container shell:
> ./docker_bash.sh - Launch Jupyter Notebook:
> ./docker_jupyter.sh
Environment Setup¶
Set the OPENAI_API_KEY environment variable for API access:
import os
os.environ["OPENAI_API_KEY"] = "<your_openai_api_key>"