Pydantic AI is a typed Python SDK for building AI agents that can use different language models and interfaces, including voice, image generation, and embeddings. Developers use it for applications ranging from structured data extraction to long-running multi-agent work. The catalogue entries provide workflows and configuration for its coding-agent and harness features.
Borrowing it
Nothing to install: this file belongs to pydantic/pydantic-ai. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/pydantic/pydantic-ai/main/.agents/skills/initialize-worktree/SKILL.mdgit clone --depth 1 https://github.com/pydantic/pydantic-aiWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/pydantic/pydantic-ai/initialize-worktree)<a href="https://agentmods.dev/skills/pydantic/pydantic-ai/initialize-worktree"><img src="https://agentmods.dev/badge/skills/pydantic/pydantic-ai/initialize-worktree/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/pydantic/pydantic-ai/initialize-worktree"><img src="https://agentmods.dev/badge/skills/pydantic/pydantic-ai/initialize-worktree.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00047 | $0.01751 |
| Opus 5.5 | $0.00019 | $0.00700 |
| Sonnet 5.5 | $0.00009 | $0.00350 |
| Haiku 4.5 | $0.00005 | $0.00175 |
Grade A, and why
initialize-worktree scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 155 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Initialize Worktree — From Problem to PR
Study a problem or GitHub issue, research the codebase, plan a fix, optionally implement it, and open the initial PR. Assumes the branch is already checked out.
Startup
- Read the root
AGENTS.md,agent_docs/index.mdand its relevant topic guides, plus every directory-specificAGENTS.mdgoverning a file you expect to touch. Reading these from the checked-out tree is correct here and only here: this skill starts fresh work on your own branch off the target branch, so nobody else has written them. Check that before you rely on it — if the branch already carries commits you did not author, stop and use/adopt-pr, which reads them from a policy-base checkout instead. - Read the
pushing-commits-to-the-reposkill — it owns the PR lifecycle this skill hands off to
Step 1 — Parse Input
Parse $ARGUMENTS:
- GitHub issue URL or number (e.g.
https://github.com/pydantic/pydantic-ai/issues/1234or#1234) → fetch viagh issue view <number> --json title,body,comments,labels,state,updatedAt - Free text → treat as problem description
- Empty → ask the user to link an issue or describe the problem.
Step 2 — Study
Inspect the codebase to understand the problem:
- For issues: read all comments to understand discussion, decisions, maintainer guidance
- Identify key files, affected areas, related tests
- Search for prior attempts or related PRs if relevant
Be thorough — this research informs everything downstream.
Step 3 — Write the branch-context files
Write .claude/skills/branch-context/issue-brief.md from scratch — the file does not exist on a clean checkout. The same schema ships as issue-brief.template.md beside it; use this one — keep it tight, this file is autoloaded on every future session and token cost compounds:
---
last_fetched_at: <ISO timestamp now>
last_fetched_comment_count: <count from gh issue view>
branch: <git rev-parse --abbrev-ref HEAD>
related_pr: TBD
issues:
- number: <N>
url: <url>
title: "<title>"
type: <bug|improvement|feature>
role: <primary|related|follow-up>
updated_at: <issue updatedAt from GitHub>
comments_fingerprint: <output of issue-comment-fingerprint for this issue>
---
# Issue Brief
## Issues
- [#<N> — <title>](<url>) — type: <...> — role: <...>
## Problem
<1–2 sentences>
## Current behavior vs. expected
(bugs only — omit for features/improvements)
## Scope
**In:**
- <...>
**Out:**
- <...>
## Success criteria
| # | Criterion | Test |
|---|-----------|------|
| 1 | <...> | <test path or "to add"> |
## Constraints
- <backwards-compat / public-API / provider-parity statements>
## Affected surface
- <file> — <role>
## References
- [<label>](<url>) — <relevance>
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- yesterday First seen · 155 lines · 47 tokens per session scan A b588ac9d4a1b
initialize-worktree is a skill published in the GitHub repository pydantic/pydantic-ai (20,771 stars, last pushed today), licensed MIT. It adds 47 tokens to every session and 1,751 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-10-21.
Other skills, from other repositories
git-workflow
Git operations: commits, branches, PRs, and conflict resolution.
mem0-test-integration
Verify a Mem0 integration produced by /mem0-integrate. Runs in the same workspace on the same branch (loose coupling) — installs dependencies, runs the repo's native test suite, then exercises a real end-to-end smoke flow against the user's API key. Produces a scorecard. TRIGGER when: user has just run /mem0-integrate…
mem0-integrate
Integrate Mem0 into an existing repository using a goal-driven, TDD pipeline. Detects the repo's language automatically and asks the user to pick between Mem0 Platform (managed) and Mem0 Open Source (self-hosted). Writes failing tests before any implementation. Produces a local feature branch plus .mem0-integration/…
gh
GitHub CLI skill for interacting with GitHub via the gh command line tool. Use when Bub needs to (1) Create, view, or manage GitHub repositories, (2) Work with issues and pull requests, (3) Create and manage releases, (4) Run and monitor GitHub Actions workflows, (5) Create and manage gists, (6) Install and manage…
data-analysis
Comprehensive data analysis skill for CSV files using Python and pandas.
diagram-design
Best practices for creating research diagrams with Excalidraw MCP tools.