본문으로 건너뛰기
cccskills
무료GitHub에 공개

schema-review

Use when reviewing a migration diff or schema change for scale hazards — indexes, unsafe migrations, unbounded growth, N+1. Triggers on 'review this migration', 'will this scale'.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

설치 방법 보기

포함된 파일(2)

  • SKILL.md3.8 KB
  • evals/triggers.json1.3 KB

SKILL.md(원문)

설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.

schema-review

When to use

  • A migration diff, new migration file, or schema change is under review and the question is scale-shaped: indexes, reversibility, growth, query patterns against the new columns.
  • The user asks "will this scale", "review this migration", "check the schema", or a PR touches migrations/, schema.prisma, or raw .sql migration files.
  • NOT for runtime performance analysis of live traffic (no APM here — route to performance-analysis) and NOT for authoring a new migration from scratch (route to laravel-migration or the stack-native tool, then come back with the diff).

Procedure

  1. Detect the stack surface in the diff: Laravel migrations (database/migrations/*.php), Prisma (schema.prisma + prisma/migrations/**/migration.sql), raw SQL (*.sql). One diff can carry several.

  2. Run the deterministic linter on the touched files plus the query surface that references the changed tables:

    npx tsx node_modules/@event4u/agent-config/src/scripts/lint_persistence.ts -- --dir <path> [--stack eloquent|prisma|raw-sql] --format json
    

    The linter emits gate findings (pattern-detected: F1 N+1, F2 index-parity, F3 unbounded reads, F6 migration-safety, F7 growth-budget, F8 audit-coverage, F9 sync-in-handler, F11 non-durable async) and advice findings (heuristics — never treat as blockers).

  3. Walk the gap table — for every gate finding decide: fix, or waiver with a reason (// no-index: <reason>, // sync-required: <reason>, -- no-retention: <reason>, …). An empty waiver reason is itself a finding.

  4. Check the R-A6/R-A7 invariants by hand where the linter is blind: reversibility of data transformations, retention policy for any new append-only table (the -- retention: <policy> line), backfill plan for new NOT NULL columns on large tables.

  5. Report waiver density neutrally — count waivers per rule; state both readings (informed exceptions vs rule misfit) and let the human decide. Density alone is never a verdict.

Output

The review MUST contain:

  1. Gap table — one row per finding: rule · file:line · finding · proposed action (fix | waiver | accepted), gate findings first, advice findings clearly marked as advice.
  2. Waiver-density line — N waivers across M findings with the two-reading note (informed exceptions vs rule misfit).
  3. A one-line verdict: ready / needs fixes / needs human schema decision — never a bare "looks good" without the table.

Gotcha

  • The linter proves pattern presence, not instance-level correctness — a flagged Http:: call in a controller may be legitimately sync (then it gets a // sync-required: waiver with a reason), and a clean run does not prove the schema scales. Say what was checked, not more.
  • Prisma's @relation fields are indexed implicitly on some connectors and not on others — when the linter reports a missing FK index on a Prisma model, verify the connector before calling it a defect.

Do NOT

  • Do NOT gate a review on advice-tier findings (F4 denormalization, F10 event-decoupling heuristics) — they are review inputs, not blockers.
  • Do NOT strip or rewrite existing waivers — surface stale-looking ones and ask.
  • Do NOT invent index recommendations for columns the query surface never filters or orders by — index parity cuts both ways; unused indexes cost write throughput.

리뷰

아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.

댓글

로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.

아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.

보내면 바로 공개됩니다. 이메일 주소나 전화번호 같은 개인 정보는 쓰지 마세요. URL은 2개까지입니다.

0 / 1,000자

이 양식은 reCAPTCHA로 보호되며 Google 개인정보처리방침 및 서비스 약관이 적용됩니다.

같은 저장소의 스킬

Use when reviewing UI for accessibility — WCAG 2.2 AA, keyboard nav, focus, ARIA, contrast, screen-reader semantics — even on 'is this a11y-OK?' or 'mach das barrierefrei'.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

event4u-app/agent-config122026년 10월 21일 업데이트

Use when defining or auditing the activation event — aha-moment selection, retention correlation, falsifiable definition. Triggers on 'what is our aha moment', 'redefine activation'.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

event4u-app/agent-config122026년 10월 21일 업데이트

Use when capturing an architectural decision — file naming, next ADR number, Status / Context / Decision / Consequences, index regen; fires even without saying 'ADR'.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

event4u-app/agent-config122026년 10월 21일 업데이트

Adversarial critique — devil's advocate, stress-test, honest teardown ('poke holes', 'be brutal', 'was hältst du davon'); explicit request only. Routine code or design review → code-review.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

event4u-app/agent-config122026년 10월 21일 업데이트

Use when reading, creating, or updating agent documentation, module docs, roadmaps, or AGENTS.md. Understands the full .augment/, agents/, and copilot-instructions structure.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

event4u-app/agent-config122026년 10월 21일 업데이트

Use for an adversarial red-team / blue-team / auditor review of an AI agent's CONFIG + behaviour (rules, skills, MCP, hooks, permissions) — attack-chain → defensive-gap list, not a code audit.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

event4u-app/agent-config122026년 10월 21일 업데이트

event4u-app의 스킬 모두 보기

이 스킬의 문제 신고