Building Pydantic AI Agents
docling-project/docling
Patterns and tested examples for building agents with Pydantic AI: tools, capabilities, structured output, dependency injection, hooks, YAML specs, streaming and testing.
Create Pydantic models following the multi-model pattern with Base, Create, Update, Response, and InDB variants.
$ npx skills add microsoft/skills --skill pydantic-models-py -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install microsoft/skills pydantic-models-py --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/microsoft/skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.github/plugins/azure-sdk-python/skills/pydantic-models-py .claude/skills/pydantic-models-py && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "pydantic-models-py" agent skill from https://github.com/microsoft/skills/tree/main/.github/plugins/azure-sdk-python/skills/pydantic-models-py into .claude/skills/pydantic-models-py/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "pydantic-models-py", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/microsoft/skills/tree/main/.github/plugins/azure-sdk-python/skills/pydantic-models-pyType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add microsoft/skills --skill pydantic-models-py -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install microsoft/skills pydantic-models-py --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/microsoft/skills.git skills-src && mkdir -p .agents/skills && cp -r skills-src/.github/plugins/azure-sdk-python/skills/pydantic-models-py .agents/skills/pydantic-models-py && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "pydantic-models-py" agent skill from https://github.com/microsoft/skills/tree/main/.github/plugins/azure-sdk-python/skills/pydantic-models-py into .agents/skills/pydantic-models-py/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "pydantic-models-py", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add microsoft/skills --skill pydantic-models-py -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install microsoft/skills pydantic-models-py --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/microsoft/skills.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/.github/plugins/azure-sdk-python/skills/pydantic-models-py .cursor/skills/pydantic-models-py && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "pydantic-models-py" agent skill from https://github.com/microsoft/skills/tree/main/.github/plugins/azure-sdk-python/skills/pydantic-models-py into .cursor/skills/pydantic-models-py/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "pydantic-models-py", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/microsoft/skills.git --path .github/plugins/azure-sdk-python/skills/pydantic-models-py--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add microsoft/skills --skill pydantic-models-py -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install microsoft/skills pydantic-models-py --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/microsoft/skills.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/.github/plugins/azure-sdk-python/skills/pydantic-models-py .gemini/skills/pydantic-models-py && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "pydantic-models-py" agent skill from https://github.com/microsoft/skills/tree/main/.github/plugins/azure-sdk-python/skills/pydantic-models-py into .gemini/skills/pydantic-models-py/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "pydantic-models-py", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install microsoft/skills pydantic-models-pyInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add microsoft/skills --skill pydantic-models-py -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/microsoft/skills.git skills-src && mkdir -p .github/skills && cp -r skills-src/.github/plugins/azure-sdk-python/skills/pydantic-models-py .github/skills/pydantic-models-py && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "pydantic-models-py" agent skill from https://github.com/microsoft/skills/tree/main/.github/plugins/azure-sdk-python/skills/pydantic-models-py into .github/skills/pydantic-models-py/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "pydantic-models-py", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add microsoft/skills --skill pydantic-models-py -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install microsoft/skills pydantic-models-py --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/microsoft/skills.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/.github/plugins/azure-sdk-python/skills/pydantic-models-py .opencode/skills/pydantic-models-py && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "pydantic-models-py" agent skill from https://github.com/microsoft/skills/tree/main/.github/plugins/azure-sdk-python/skills/pydantic-models-py into .opencode/skills/pydantic-models-py/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "pydantic-models-py", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
pydantic-models-pyCreate Pydantic models following the multi-model pattern with Base, Create, Update, Response, and InDB variants.
Pydantic Models Py is an agent skill from microsoft/skills, published by the product's own GitHub organization. Create Pydantic models following the multi-model pattern with Base, Create, Update, Response, and InDB variants. Use when defining API request/response schemas, database models, or data validation in Python applications using Pydantic v2.
Its SKILL.md is about 500 tokens, which your agent loads only when the skill is triggered. The skill folder holds 4 other files, including reference files and assets (for example `assets/template.py` and `references/capabilities.md`).
It works with Pydantic and Python. The repository describes itself as: Skills, MCP servers, Custom Agents, Agents.md for SDKs to ground Coding Agents. The licence is MIT.
3 steps, taken from the first numbered list in SKILL.md.
Read from SKILL.md and the folder at commit 354361d. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
Ships script files (Python), which the agent can run.
From the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md.
From URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Pydantic Models Py loads about 496 tokens when it runs, and up to ~779 if it reads all its reference files. Until then it costs about 64 tokens; SKILL.md has 104 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from microsoft/skills at commit 354361d, republished under its MIT licence (© microsoft). 104 words, ~496 tokens.
.claude/skills/pydantic-models-py/SKILL.md (or your agent's skills folder). This skill also uses 2 other files; get the full folder from GitHub.Create Pydantic models following the multi-model pattern for clean API contracts.
Copy the template from assets/template.py and replace placeholders:
{{ResourceName}} → PascalCase name (e.g., Project){{resource_name}} → snake_case name (e.g., project)| Model | Purpose |
|---|---|
Base | Common fields shared across models |
Create | Request body for creation (required fields) |
Update | Request body for updates (all optional) |
Response | API response with all fields |
InDB | Database document with doc_type |
from datetime import datetime
from pydantic import BaseModel, ConfigDict, Field
class MyModel(BaseModel):
model_config = ConfigDict(populate_by_name=True)
workspace_id: str = Field(..., alias="workspaceId")
created_at: datetime = Field(..., alias="createdAt")class MyUpdate(BaseModel):
model_config = ConfigDict(populate_by_name=True)
name: Optional[str] = Field(None, min_length=1)
description: Optional[str] = Noneclass MyInDB(MyResponse):
doc_type: str = "my_resource"src/backend/app/models/src/backend/app/models/__init__.py| File | Contents |
|---|---|
| references/capabilities.md | Additional non-hero capabilities, operation-group coverage, and production checklists. |
© microsoft, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
SKILL.md and 2 other files (references, assets) in .github/plugins/azure-sdk-python/skills/pydantic-models-py of microsoft/skills.
Open the folder on GitHubat commit 354361d
We found 17 copies of this SKILL.md (exact, near-identical or edited) in other folders, from 6 other GitHub owners. This page covers the copy in microsoft/skills, which our catalogue first saw on October 7, 2026.
Pydantic Models Py next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Pydantic Models Py this skillmicrosoft/skills | 3.1k | 6 repos | ~496 | Automated safety check: Pass | MIT | |
| Building Pydantic AI Agentsdocling-project/docling | 68k | — | ~2.8k | Automated safety check: Pass | MIT | |
| Fastcrudbenavlabs/fastcrud | 1.6k | — | ~5k | Automated safety check: Pass | MIT | |
| Prompt Engineering Patternswshobson/agents | 40k | — | ~1.3k | Automated safety check: Pass | MIT | |
| A2ui Generate Pydantic Modelsa2ui-project/a2ui | 17k | — | ~2.3k | Automated safety check: Pass | Apache-2.0 | |
| Migrating Agno To Pydantic AIpydantic/pydantic-ai | 20k | — | ~1.8k | Automated safety check: Pass | MIT |
docling-project/docling
Patterns and tested examples for building agents with Pydantic AI: tools, capabilities, structured output, dependency injection, hooks, YAML specs, streaming and testing.
benavlabs/fastcrud
A skill your agent uses when building or modifying CRUD endpoints with FastCRUD (the fastcrud PyPI package) in a FastAPI project — covers FastCRUD, crudrouter, EndpointCreator, FilterConfig…
wshobson/agents
Reference for designing and tuning production LLM prompts: few-shot examples, chain-of-thought, structured outputs, templates and system prompts.
a2ui-project/a2ui
Automated generator for strongly typed Pydantic v2 data models and basic catalogs across any A2UI protocol version (v0.8, v0.9, v0.9.1, v1.0, etc.).
pydantic/pydantic-ai
Migrate Python Agno applications to Pydantic AI and, only when needed, Pydantic AI Harness.
timothywarner-org/claude-code
Scaffold production-ready Python MCP servers using FastMCP. An agent skill from timothywarner-org/claude-code.
microsoft/skills
Reference for building on Microsoft Foundry with the azure-ai-projects Python SDK: project clients, versioned agents, evaluations, connections, datasets and indexes.
microsoft/skills
Python guidance for the Azure AI Search SDK covering vector, hybrid and semantic search, index management and indexers, with Entra ID authentication preferred over keys.
microsoft/skills
Covers producer, consumer, and checkpoint-store setup for Azure Event Hubs streaming in Python, with Entra ID auth and partition targeting.
microsoft/skills
Builds podcast-style audio narration from text with Azure OpenAI's GPT Realtime Mini over WebSocket, from a Python FastAPI backend to a React player.
microsoft/skills
Build dark-themed React applications using Tailwind CSS with custom theming, glassmorphism effects, and Framer Motion animations.
microsoft/skills
Guide for creating effective skills for AI coding agents working with Azure SDKs and Microsoft Foundry services.
Create Pydantic models following the multi-model pattern with Base, Create, Update, Response, and InDB variants. Pydantic Models Py is an agent skill from microsoft/skills, published by the product's own GitHub organization. Create Pydantic models following the multi-model pattern with Base, Create, Update, Response, and InDB variants.
Pydantic Models Py fits situations like: defining API request/response schemas; database models; data validation in Python applications using Pydantic v2.
Run `npx skills add microsoft/skills --skill pydantic-models-py -a claude-code`. Or copy the skill folder (.github/plugins/azure-sdk-python/skills/pydantic-models-py in microsoft/skills) into .claude/skills/pydantic-models-py in your project. Claude Code loads it when a task matches its description.
Run `npx skills add microsoft/skills --skill pydantic-models-py -a codex`. Or copy the skill folder (.github/plugins/azure-sdk-python/skills/pydantic-models-py in microsoft/skills) into .agents/skills/pydantic-models-py in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add microsoft/skills --skill pydantic-models-py -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/pydantic-models-py, .gemini/skills/pydantic-models-py, .github/skills/pydantic-models-py and .opencode/skills/pydantic-models-py in your project.
Going by SKILL.md and its folder, Pydantic Models Py needs Python for the scripts in its folder. Our summary lists: Python 3.
SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
Pydantic Models Py is published under the MIT licence (declared in SKILL.md). It allows redistribution, so the full SKILL.md is shown on this page.
About 496 tokens (SKILL.md is roughly 2k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 283 tokens, read only when the agent opens those files.
Skills that share tags, products or a category with Pydantic Models Py: Building Pydantic AI Agents (docling-project/docling, 68k stars), Fastcrud (benavlabs/fastcrud, 1.6k stars), Prompt Engineering Patterns (wshobson/agents, 40k stars) and A2ui Generate Pydantic Models (a2ui-project/a2ui, 17k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
microsoft (a GitHub organization, an official publisher) maintains it in microsoft/skills, which has 3,086 GitHub stars. The repository holds 150 skills in this directory. The repository was last updated on October 6, 2026.
Source: microsoft/skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.