Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add robhowley/py-pit-skills --skill alembic-migrationsgit clone --depth 1 https://github.com/robhowley/py-pit-skillsWrote 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/robhowley/py-pit-skills/alembic-migrations)<a href="https://agentmods.dev/skills/robhowley/py-pit-skills/alembic-migrations"><img src="https://agentmods.dev/badge/skills/robhowley/py-pit-skills/alembic-migrations/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/robhowley/py-pit-skills/alembic-migrations"><img src="https://agentmods.dev/badge/skills/robhowley/py-pit-skills/alembic-migrations.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.00056 | $0.01755 |
| Opus 5 | $0.00028 | $0.00877 |
| Sonnet 5 | $0.00011 | $0.00351 |
| Haiku 4.5 | $0.00006 | $0.00176 |
Grade A, and why
alembic-migrations 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 9d ago.
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 — 384 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Skill: alembic-migrations
Core position
This skill establishes safe, disciplined database migration workflows using Alembic in SQLAlchemy 2.x projects.
Autogenerate output is treated as a draft, never final truth. All migrations must be reviewable, deterministic, and safe for production.
The skill prevents common failures such as:
- empty autogenerate revisions
- rename → drop/create data loss
- broken env.py metadata wiring
- migration history divergence
- unsafe schema changes
Py-pit enforcement rules
These rules are always applied when generating or reviewing migrations.
1. Model import guarantee
Alembic only detects models that are imported at runtime.
A canonical module must import every ORM model so metadata is complete.
Do not assume app/. Use the project's existing Base definition --
typically at {pkg_name}/db/base.py (see sqlalchemy-models skill).
Example:
# {pkg_name}/models/__init__.py
from {pkg_name}.models.user import User
from {pkg_name}.models.order import Order
Alembic must reference:
from {pkg_name}.db.base import Base
target_metadata = Base.metadata
This prevents empty migrations, the most common Alembic failure.
2. Rename correction rule
Alembic cannot detect column renames.
If autogenerate emits:
drop_column
add_column
for the same table in one revision, treat it as a rename.
Replace with:
op.alter_column("table", "old_name", new_column_name="new_name")
This prevents silent data loss.
3. Applied migration immutability
Never edit a migration that has already been applied.
Correct pattern:
revision A (applied)
revision B (fix)
Never:
edit revision A
Editing applied migrations breaks migration graphs across environments.
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.
- 9d ago First seen · 384 lines · 56 tokens per session scan A d4b6cc4b08bd
alembic-migrations is a skill published in the GitHub repository robhowley/py-pit-skills (5 stars, last pushed 5mo ago), licensed MIT. It adds 56 tokens to every session and 1,755 once invoked, about $0.0003 per session on Opus 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-08-31.
Other skills, from other repositories
python-backend
Production Python async patterns including asyncio TaskGroup, FastAPI dependency injection and middleware, SQLAlchemy 2.0 async sessions, and database connection pool tuning. Python 3.11+ runtime concerns such as ExceptionGroup, cancellation semantics, and session rollback. Use when building async services, wiring…
python
Use when building FastAPI applications, implementing async endpoints, setting up Pydantic schemas, working with SQLAlchemy, or writing pytest tests for Python backend services.
FastAPI Customer Support Tech Enablement
Comprehensive FastAPI skill for building modern Python web APIs with focus on customer support systems, ticket management, real-time chat, and backend operations.
fastapi-expert
Expert-level FastAPI development for high-performance Python APIs with async support. Use when the user mentions Python, API, async, REST, OpenAPI, or Pydantic, or when the task involves FastAPI Features.
asyncio
Python asyncio - Modern concurrent programming with async/await, event loops, tasks, coroutines, primitives, aiohttp, and FastAPI async patterns.
flask
Flask - Lightweight Python web framework for microservices, REST APIs, and flexible web applications with extensive extension ecosystem.