Skip to main content
Loading navigation
Back to prompt library

Define Pydantic Schemas and Agent

Linked challenge: Develop an Industrial Smelter Equipment Restoration Agent with Pydantic AI and Writer

Prompt source

implementation1 lines1 sectionsNo variables0 checklist items
Import `Agent` from `pydantic_ai`. Define a `WorkOrder` model with `pot_id: str`, `max_temp_c: float`, `required_part_no: str`, and `priority: Literal['LOW', 'MEDIUM', 'HIGH']`. Initialize `Agent(model='writer:palms', result_type=WorkOrder)`.