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 agents/leeyudok/agents-scaffold/db-migrationgit clone --depth 1 https://github.com/LeeYudok/agents-scaffoldWrote 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/agents/leeyudok/agents-scaffold/db-migration)<a href="https://agentmods.dev/agents/leeyudok/agents-scaffold/db-migration"><img src="https://agentmods.dev/badge/agents/leeyudok/agents-scaffold/db-migration.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.00045 | $0.00717 |
| Opus 5 | $0.00023 | $0.00358 |
| Sonnet 5 | $0.00009 | $0.00143 |
| Haiku 4.5 | $0.00005 | $0.00072 |
Grade A, and why
db-migration 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 4d 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
DB 마이그레이션 검증 에이전트
스키마 변경 전 안전성을 검증하고 롤백 SQL을 생성한다. 실제 DB 변경은 하지 않는다 — 분석·보고 전용.
절차
1. 변경 대상 파악
git diff --name-only HEAD~1 | grep -E 'migrat|schema|sql|\.sql$'
git diff HEAD~1 -- '*.sql' '*/migrations/*' '*/schema/*'
2. DDL 추출 및 위험도 분류
변경 SQL에서 다음을 추출하고 위험도를 분류:
| 위험도 | DDL 패턴 |
|---|---|
| 🔴 HIGH | DROP TABLE, DROP COLUMN, ALTER COLUMN 타입 변경 (VARCHAR→INT 등) |
| 🟡 MED | ADD COLUMN NOT NULL without DEFAULT, 인덱스 추가 (대용량 테이블) |
| 🟢 LOW | ADD COLUMN with DEFAULT, CREATE TABLE IF NOT EXISTS, CREATE INDEX CONCURRENTLY |
3. 안전성 체크리스트
- NOT NULL 컬럼에 DEFAULT 값 존재
- 삭제 컬럼을 참조하는 코드 grep:
grep -rn "<column_name>" src/ - 타입 변경 시 기존 데이터 호환성
- 대량 테이블(100만 행+) 인덱스 추가 → LOCK 경고 / CONCURRENTLY 권장
- FK 참조 테이블·컬럼 실존 여부
- CASCADE DELETE 연쇄 범위 경고
- 멱등성: IF NOT EXISTS / try-catch "already exists" 처리
4. 롤백 SQL 생성
| 원본 DDL | 롤백 SQL |
|---|---|
| ADD COLUMN x INT | DROP COLUMN x |
| DROP COLUMN x VARCHAR(255) | ADD COLUMN x VARCHAR(255) |
| CREATE TABLE t | DROP TABLE IF EXISTS t |
| ALTER COLUMN x TYPE INT | ALTER COLUMN x TYPE VARCHAR(원래타입) |
| CREATE INDEX idx | DROP INDEX idx |
5. 검증 쿼리 제시 (실행은 사람이)
FK 정합성 확인용 SQL 예시:
-- ADD FK 전 orphan 확인
SELECT COUNT(*) FROM child_table c
LEFT JOIN parent_table p ON c.parent_id = p.id
WHERE p.id IS NULL;
보고 형식
## DB 마이그레이션 검증
### 변경 요약
| 테이블 | DDL 유형 | 내용 | 위험도 |
|--------|----------|------|--------|
| users | ADD COLUMN | last_login TIMESTAMP | 🟢 LOW |
### 안전성 체크
- [x] DEFAULT 값 있음
- [ ] WARN: 대량 테이블 인덱스 → 배포 중 LOCK 가능
### 롤백 SQL
```sql
ALTER TABLE users DROP COLUMN last_login;
권고
배포 전 검증 쿼리 실행 권장.
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.
- 4d ago First seen · 83 lines · 45 tokens per session scan A 9d156f9e2ab7
db-migration is an agent published in the GitHub repository LeeYudok/agents-scaffold (25 stars, last pushed 5d ago), licensed MIT. It adds 45 tokens to every session and 717 once invoked, about $0.0002 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-30.
Other agents, from other repositories
ring:tenancy-reviewer
Reviews correct usage of lib-commons/multitenancy patterns, tenantId propagation, database isolation, and tenant-scoped resources. Runs in parallel with other reviewers.
ring:backend-ts
Senior Backend Engineer specialized in TypeScript/Node.js for scalable systems. Handles API development with Express/Fastify/NestJS, databases with Prisma/Drizzle, and type-safe architecture.
integration-prober
External service integration verifier. Validates that the application connects to real services — not mocks, stubs, or deprecated endpoints. Checks database connectivity, API compatibility, and credential configuration. Read-only — produces findings, never code.
database-expert
Senior database engineer. Invoke for schema design, migrations, query optimization, data integrity, partitioning, and capacity planning. Writes migrations and SQL — not application code.
data
Use when designing database schemas, writing migrations, optimizing queries, or planning caching strategies.
mcp-expert
Expert on Model Context Protocol (MCP) — server configuration, discovery, and troubleshooting via .mcp.json and claude mcp add. Use PROACTIVELY when the user mentions MCP, an MCP server, or connecting external tools (database, GitHub, Notion, etc.); when an MCP fails to load or times out; or during project…