Overview
Pydantic AI is a type-safe, structured-output agent framework for Python. It works with any OpenAI-compatible endpoint throughOpenAIChatModel + OpenAIProvider, so you can point it at Eden AI’s V3 API and access models from OpenAI, Anthropic, Google, Cohere, Meta, and more — behind one key, with EU-based, GDPR-aligned inference.
Installation
Quick Start
Point Pydantic AI’s OpenAI model at Eden AI:Available Models
Access models from multiple providers using theprovider/model format:
OpenAI
openai/gpt-5.5openai/gpt-5-mini
anthropic/claude-sonnet-5anthropic/claude-opus-4-8anthropic/claude-haiku-4-5
google/gemini-2.5-progoogle/gemini-3.5-flash
mistral/mistral-large-2512mistral/mistral-small-2603
Structured Output
Pydantic AI’s signature feature works unchanged — define a Pydanticoutput_type and the agent returns a validated object, whichever Eden AI model you choose:
Multi-Turn Conversations
Keep conversation history across runs withmessage_history:
Error Handling
Environment Variables
Next Steps
- Chat Completions - Core LLM endpoint
- List LLM Models - Browse available providers and models
- OpenAI SDK (Python) - Direct SDK usage