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 agentmods add skills/new1direction/korgex/database-migrationsnpx skills add New1Direction/korgex --skill database-migrationsgit clone --depth 1 https://github.com/New1Direction/korgexWrote 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/new1direction/korgex/database-migrations)<a href="https://agentmods.dev/skills/new1direction/korgex/database-migrations"><img src="https://agentmods.dev/badge/skills/new1direction/korgex/database-migrations.svg" alt="Measured on agentmods" 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 | $0.00021 | $0.00364 |
| Opus 5 | $0.00010 | $0.00182 |
| Sonnet 5 | $0.00004 | $0.00073 |
| Haiku 4.5 | $0.00002 | $0.00036 |
Grade A, and why
database-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 3d 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
A schema change touches persistent, shared, irreplaceable data. Slow down: a bad migration can't be "just reverted" once data is lost.
- Migration as code. Use the project's migration tool; never hand-edit production schema. Each migration is small, ordered, version-controlled, and has a tested down/rollback path where possible.
- Additive first (expand/contract). To change something live:
- Expand: add the new column/table (nullable / with a default), deploy code that writes BOTH old and new.
- Backfill existing rows in batches (not one giant locking update).
- Migrate reads to the new shape, verify.
- Contract: only after everything uses the new shape, drop the old. This keeps old and new code working simultaneously → zero downtime, safe rollback.
- Never destructive in one step. Don't drop/rename a column in the same release that stops using it — you can't roll back without data loss.
- Guard the data. Back up (or snapshot) before a risky migration. Test the migration on a copy with realistic volume — lock duration and timeouts bite at scale.
- Make it idempotent + resumable where the tooling allows, so a half-run migration can be safely retried.
Red flag: an irreversible DROP/ALTER shipped together with the code change, or a
backfill that locks a big table in a single statement.
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.
- 3d ago First seen · 30 lines · 21 tokens per session scan A d442c0df3d31
database-migrations is a skill published in the GitHub repository New1Direction/korgex (5 stars, last pushed 2mo ago), licensed MIT. It adds 21 tokens to every session and 364 once invoked, about $0.0001 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
vibe-database
Use this skill to design database schemas, tables, and relationships.
memory-layer
Standalone persistent memory for Pi — smart search, symbol clustering, dedup, auto-recovery, trust scoring. Zero Python dependency.
cache
Cache. Redis, Memcached, Varnish, CDN, cache invalidation, TTL, write-through, cache stampede, thundering herd.
persistence-drift
Governs the on-device Drift/SQLite data layer: package:drift and package:sqlite3 confined to lib/data/ behind DAOs that map rows to immutable value objects (no Drift symbol leaks past the repository), invariants pushed into the schema (STRICT tables, CHECK/FK/partial-UNIQUE indexes), foreignkeys/WAL pragmas…
data-export-and-restore
Enforces user-facing data portability in an offline-first app — backup/restore (exact, machine round-trippable) kept strictly separate from export/report (human, lossy, never a restore source); a versioned envelope carrying formatVersion, schemaVersion, appVersion, exportedAtUtc and a payload checksum so a restore…
run-migration
Runs the forward-only Drift/SQLite schema-migration ritual — the most dangerous deterministic operation in an offline-first app: a bad migration silently destroys on-device rows that exist nowhere else. Enforces the exact ordered sequence: take a pre-migration file snapshot before the database is opened, bump…