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.
git clone --depth 1 https://github.com/iloveitaly/llm-ide-rulesWrote 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/rules/iloveitaly/llm-ide-rules/alembic-migrations)<a href="https://agentmods.dev/rules/iloveitaly/llm-ide-rules/alembic-migrations"><img src="https://agentmods.dev/badge/rules/iloveitaly/llm-ide-rules/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/rules/iloveitaly/llm-ide-rules/alembic-migrations"><img src="https://agentmods.dev/badge/rules/iloveitaly/llm-ide-rules/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.00000 | $0.00375 |
| Opus 5 | $0.00000 | $0.00187 |
| Sonnet 5 | $0.00000 | $0.00075 |
| Haiku 4.5 | $0.00000 | $0.00038 |
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.
What it actually says
Alembic Migrations
Default Content for New Non-Nullable Columns
To add a non-nullable column and set a specific value for all existing rows without a persistent server default:
# 1. Add the column as nullable (no default needed):
op.add_column(
"distribution",
sa.Column(
"default_campaign_ending_date", sa.DateTime(timezone=True), nullable=True
),
)
# 2. Update existing rows with your desired value (e.g., a specific datetime)
op.execute(
"UPDATE distribution SET default_campaign_ending_date = %s", [datetime.utcnow()]
)
# 3. Alter the column to non-nullable:
op.alter_column("distribution", "default_campaign_ending_date", nullable=False)
Record Backfill Operations
For migrations that include data mutation, and not only schema modifications, use this pattern to setup a session:
from alembic import op
from sqlmodel import Session
from activemodel.session_manager import global_session
from app import log
def run_migration_helper():
pass
def upgrade() -> None:
session = Session(bind=op.get_bind())
with global_session(session):
run_migration_helper()
flip_point_coordinates()
backfill_screening_host_data()
# flush before running any other operations, otherwise not all changes will persist to the transaction
session.flush()
However, if you don't need the business logic attached to the models, you can execute a query using op.execute:
op.execute(
TheModel.__table__.update().values({"a_field": "a_value"}) # type: ignore
)
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 · 63 lines · 0 tokens per session scan A 1a44cf2a6d0d
alembic-migrations is a cursor rule published in the GitHub repository iloveitaly/llm-ide-rules (13 stars, last pushed yesterday), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 375 tokens. 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-30.
Other cursor rules, from other repositories
ai-kb
Use shared AI KB rules and context.
ponytail
Ponytail, lazy senior dev mode. Always pick the simplest solution that works.
angular-20
This rule provides comprehensive best practices and coding standards for Angular development, focusing on modern TypeScript, standalone components, signals, and performance optimizations.
dev-standard
Apache Superset development standards and guidelines for Cursor IDE.
cli-error-handling
CLI command error handling patterns.
prefer-assertions-over-defensive-checks
Prefer assertions over defensive checks when data is guaranteed to be valid.