migrations
Use when creating or reviewing database migrations - Liquibase or Flyway, new tables, columns, indexes, constraints, backfills, or any DDL against Postgres.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Use when creating or reviewing database migrations - Liquibase or Flyway, new tables, columns, indexes, constraints, backfills, or any DDL against Postgres.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Use when reviewing code, a diff, a module, an architecture, or a design/spec document against house standards - including multi-expert panel reviews ("review with a DDD expert and an asset-finance expert"). Also when running a removal-first simplification sweep: "what can we remove", "product simplification review".
Use when executing an implementation plan or building a scoped feature or fix - after scope is clear, before code gets written. Triggers on "implement the plan at PATH", "start slice SP-2b".
Use when investigating any bug, error, crash, stack trace, failing or flaky test, incident, regression, unexpected behavior, or "why is this happening" question - before proposing or applying a fix.
Use when an implementation needs proof against the live running stack: after build completes, before ship, or when asked to verify, e2e-test, smoke-test, or demo that an API, UI, or DB change actually works.
Use when building or styling sportsbook, betting, or casino (iGaming) interfaces: odds displays, betslips, live-event states, suspended markets, casino game grids, or wallet and money surfaces.
Use when writing or reviewing code that posts, holds, voids, reverses, or reconciles money movements - double-entry postings, wallet balances, idempotency keys, FX conversion, or Blnk / pgledger integration.
| name | migrations |
| description | Use when creating or reviewing database migrations - Liquibase or Flyway, new tables, columns, indexes, constraints, backfills, or any DDL against Postgres. |
These defaults apply to service-owned schemas. Third-party and provider-managed schemas keep their own versioned contract.
BIGINT app-generated TSID, with UUIDv7 as a separate public identifier. Do not retrofit upstream package schemas or expose storage keys.NUMERIC(precision, scale) derived from the supported currency or asset contract; common two-decimal fiat may use NUMERIC(20,2), but not when the asset set needs another scale. Time: TIMESTAMPTZ for instants.TEXT + CHECK; use a reference table when values evolve independently. Avoid native Postgres enums when rolling change is required.ENABLE, normally FORCE ROW LEVEL SECURITY, and a policy based on the correctly typed current_setting('app.tenant_id', true) value.<scope>-<NNN>-<description>.sql (Liquibase, established services) / timestamp versions (Flyway, newer services; avoids merge conflicts). Match what the repo already uses. Greenfield (unreleased) repos: edit the existing changeset instead of stacking history.CREATE INDEX CONCURRENTLY in its own changeset with transactions off (runInTransaction:false Liquibase / executeInTransaction=false Flyway); it cannot run inside a transaction block.NOT VALID, then VALIDATE CONSTRAINT.DROP, TRUNCATE, column removal) require explicit user confirmation and a documented rollback story.Prefer a resumable application job for complex or long backfills. A PostgreSQL DO loop with per-batch commits is valid only when the exact runner executes it at top level outside a transaction: Liquibase puts runInTransaction:false on the --changeset line; Flyway uses executeInTransaction=false in script configuration. Irreversible changes have no fake rollback and must state restore or forward-fix steps. Pattern: references/backfill-pattern.md.
Fresh-container run must apply cleanly from scratch; rollback tested where reversible; ledger-table changes also satisfy the ledger skill invariants.