@wooojin/forgen 0.2.1 → 0.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (145) hide show
  1. package/CHANGELOG.md +76 -0
  2. package/README.ko.md +25 -14
  3. package/README.md +61 -17
  4. package/agents/analyst.md +48 -4
  5. package/agents/architect.md +39 -4
  6. package/agents/code-reviewer.md +107 -77
  7. package/agents/critic.md +47 -4
  8. package/agents/debugger.md +46 -4
  9. package/agents/designer.md +40 -4
  10. package/agents/executor.md +112 -30
  11. package/agents/explore.md +45 -5
  12. package/agents/git-master.md +48 -4
  13. package/agents/planner.md +121 -18
  14. package/agents/solution-evolver.md +115 -0
  15. package/agents/test-engineer.md +58 -4
  16. package/agents/verifier.md +92 -77
  17. package/commands/architecture-decision.md +127 -258
  18. package/commands/calibrate.md +225 -0
  19. package/commands/code-review.md +163 -178
  20. package/commands/compound.md +127 -68
  21. package/commands/deep-interview.md +212 -110
  22. package/commands/docker.md +68 -178
  23. package/commands/forge-loop.md +215 -0
  24. package/commands/learn.md +231 -0
  25. package/commands/retro.md +215 -0
  26. package/commands/ship.md +277 -0
  27. package/dist/cli.js +25 -9
  28. package/dist/core/auto-compound-runner.js +14 -0
  29. package/dist/core/config-injector.d.ts +2 -1
  30. package/dist/core/config-injector.js +2 -1
  31. package/dist/core/dashboard.d.ts +17 -0
  32. package/dist/core/dashboard.js +158 -2
  33. package/dist/core/harness.d.ts +6 -1
  34. package/dist/core/harness.js +75 -19
  35. package/dist/core/paths.d.ts +31 -1
  36. package/dist/core/paths.js +43 -2
  37. package/dist/core/spawn.d.ts +3 -2
  38. package/dist/core/spawn.js +27 -8
  39. package/dist/core/types.d.ts +34 -0
  40. package/dist/engine/compound-lifecycle.d.ts +4 -3
  41. package/dist/engine/compound-lifecycle.js +91 -46
  42. package/dist/engine/learn-cli.d.ts +1 -0
  43. package/dist/engine/learn-cli.js +182 -0
  44. package/dist/engine/meta-learning/adaptive-thresholds.d.ts +20 -0
  45. package/dist/engine/meta-learning/adaptive-thresholds.js +126 -0
  46. package/dist/engine/meta-learning/extraction-tuner.d.ts +15 -0
  47. package/dist/engine/meta-learning/extraction-tuner.js +99 -0
  48. package/dist/engine/meta-learning/matcher-weight-tuner.d.ts +21 -0
  49. package/dist/engine/meta-learning/matcher-weight-tuner.js +151 -0
  50. package/dist/engine/meta-learning/runner.d.ts +14 -0
  51. package/dist/engine/meta-learning/runner.js +90 -0
  52. package/dist/engine/meta-learning/scope-promoter.d.ts +21 -0
  53. package/dist/engine/meta-learning/scope-promoter.js +84 -0
  54. package/dist/engine/meta-learning/session-quality-scorer.d.ts +61 -0
  55. package/dist/engine/meta-learning/session-quality-scorer.js +166 -0
  56. package/dist/engine/meta-learning/types.d.ts +114 -0
  57. package/dist/engine/meta-learning/types.js +43 -0
  58. package/dist/engine/solution-candidate.d.ts +30 -0
  59. package/dist/engine/solution-candidate.js +124 -0
  60. package/dist/engine/solution-fitness.d.ts +52 -0
  61. package/dist/engine/solution-fitness.js +95 -0
  62. package/dist/engine/solution-fixup.d.ts +30 -0
  63. package/dist/engine/solution-fixup.js +116 -0
  64. package/dist/engine/solution-format.d.ts +10 -2
  65. package/dist/engine/solution-format.js +287 -57
  66. package/dist/engine/solution-index.d.ts +1 -1
  67. package/dist/engine/solution-index.js +10 -0
  68. package/dist/engine/solution-matcher.d.ts +7 -1
  69. package/dist/engine/solution-matcher.js +137 -37
  70. package/dist/engine/solution-outcomes.d.ts +70 -0
  71. package/dist/engine/solution-outcomes.js +242 -0
  72. package/dist/engine/solution-quarantine.d.ts +36 -0
  73. package/dist/engine/solution-quarantine.js +172 -0
  74. package/dist/engine/solution-weakness.d.ts +45 -0
  75. package/dist/engine/solution-weakness.js +225 -0
  76. package/dist/engine/solution-writer.d.ts +5 -0
  77. package/dist/engine/solution-writer.js +18 -0
  78. package/dist/fgx.js +12 -8
  79. package/dist/hooks/context-guard.d.ts +5 -0
  80. package/dist/hooks/context-guard.js +118 -2
  81. package/dist/hooks/hooks-generator.d.ts +3 -0
  82. package/dist/hooks/hooks-generator.js +23 -6
  83. package/dist/hooks/keyword-detector.js +16 -100
  84. package/dist/hooks/post-tool-failure.js +7 -0
  85. package/dist/hooks/skill-injector.d.ts +4 -3
  86. package/dist/hooks/skill-injector.js +6 -4
  87. package/dist/hooks/solution-injector.js +20 -0
  88. package/dist/host/codex-adapter.d.ts +10 -0
  89. package/dist/host/codex-adapter.js +154 -0
  90. package/dist/mcp/solution-reader.d.ts +5 -5
  91. package/dist/mcp/solution-reader.js +34 -24
  92. package/dist/mcp/tools.js +8 -0
  93. package/dist/services/session.d.ts +19 -0
  94. package/dist/services/session.js +62 -0
  95. package/hooks/hooks.json +2 -2
  96. package/package.json +2 -1
  97. package/skills/architecture-decision/SKILL.md +113 -257
  98. package/skills/calibrate/SKILL.md +207 -0
  99. package/skills/code-review/SKILL.md +151 -178
  100. package/skills/compound/SKILL.md +126 -68
  101. package/skills/deep-interview/SKILL.md +210 -110
  102. package/skills/docker/SKILL.md +57 -179
  103. package/skills/forge-loop/SKILL.md +198 -0
  104. package/skills/learn/SKILL.md +216 -0
  105. package/skills/retro/SKILL.md +199 -0
  106. package/skills/ship/SKILL.md +259 -0
  107. package/agents/code-simplifier.md +0 -197
  108. package/agents/performance-reviewer.md +0 -172
  109. package/agents/qa-tester.md +0 -158
  110. package/agents/refactoring-expert.md +0 -168
  111. package/agents/scientist.md +0 -144
  112. package/agents/security-reviewer.md +0 -137
  113. package/agents/writer.md +0 -184
  114. package/commands/api-design.md +0 -268
  115. package/commands/ci-cd.md +0 -270
  116. package/commands/database.md +0 -263
  117. package/commands/debug-detective.md +0 -99
  118. package/commands/documentation.md +0 -276
  119. package/commands/ecomode.md +0 -51
  120. package/commands/frontend.md +0 -271
  121. package/commands/git-master.md +0 -90
  122. package/commands/incident-response.md +0 -292
  123. package/commands/migrate.md +0 -101
  124. package/commands/performance.md +0 -288
  125. package/commands/refactor.md +0 -105
  126. package/commands/security-review.md +0 -288
  127. package/commands/specify.md +0 -128
  128. package/commands/tdd.md +0 -183
  129. package/commands/testing-strategy.md +0 -265
  130. package/skills/api-design/SKILL.md +0 -262
  131. package/skills/ci-cd/SKILL.md +0 -264
  132. package/skills/database/SKILL.md +0 -257
  133. package/skills/debug-detective/SKILL.md +0 -95
  134. package/skills/documentation/SKILL.md +0 -270
  135. package/skills/ecomode/SKILL.md +0 -46
  136. package/skills/frontend/SKILL.md +0 -265
  137. package/skills/git-master/SKILL.md +0 -86
  138. package/skills/incident-response/SKILL.md +0 -286
  139. package/skills/migrate/SKILL.md +0 -96
  140. package/skills/performance/SKILL.md +0 -282
  141. package/skills/refactor/SKILL.md +0 -100
  142. package/skills/security-review/SKILL.md +0 -282
  143. package/skills/specify/SKILL.md +0 -122
  144. package/skills/tdd/SKILL.md +0 -178
  145. package/skills/testing-strategy/SKILL.md +0 -260
package/CHANGELOG.md CHANGED
@@ -5,6 +5,82 @@ All notable changes to forgen will be documented in this file.
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
6
6
  and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
 
8
+ ## [0.3.1] - 2026-04-16
9
+
10
+ ### Added — Self-Evolving Harness (inspired by Stanford meta-harness)
11
+
12
+ Three-phase evolution loop around the existing compound solution store:
13
+
14
+ **Phase 1 — Fitness Loop (Select axis):**
15
+ - `solution-outcomes`: per-session inject→outcome event log (accept/correct/error/unknown) with fail-open semantics; attribution through solution-injector (appendPending/flushAccept), correction-record MCP (attributeCorrection), and post-tool-failure hook (attributeError).
16
+ - `solution-fitness`: Laplace-smoothed acceptance ratio × log(1+injected) confidence. State classification: draft / active / champion / underperform. No auto-delete — population-relative thresholds only.
17
+ - `solution-quarantine`: malformed frontmatter no longer silently dropped — invalid files surface in `~/.forgen/state/solution-quarantine.jsonl` with actionable diagnostics; `listQuarantined` / `pruneQuarantine` helpers.
18
+ - `solution-fixup`: schema migration for legacy defects (missing `extractedBy`, missing `evidence` block, missing `supersedes`). Applied to the live install, this recovered 5 dead solutions and one was injected on the next matching prompt.
19
+
20
+ **Phase 4 — Self-Evolution (Propose + Select axes):**
21
+ - `solution-weakness`: structured discovery report from four detectors — under-served tags (correction evidence without a matching champion), conflict clusters, dead corners (injected=0 with unique tags), volatile solutions (accept-rate shift >0.3).
22
+ - `ch-solution-evolver` agent: Opus proposer, Bash-disabled, emits exactly 3 novel candidates into `~/.forgen/lab/candidates/` with 30%-80% tag overlap gate and self-critique novelty check.
23
+ - Candidate cold-start bonus: solutions with `status: candidate` get confidence × 1.3 so they reach enough injections to accumulate fitness. Auto-promotes to `verified` at 5 injections; bonus disappears naturally.
24
+ - Candidate lifecycle: `promoteCandidate` validates schema + refuses name collisions before moving files from lab to `me/solutions`. `rollbackSince` archives every `source: evolved` solution newer than a cutoff to `~/.forgen/lab/archived/rollback-{ts}/` (never deletes — always recoverable).
25
+
26
+ **CLI surface:**
27
+ - `forgen learn fix-up [--apply]` — dry-run repair of malformed solutions.
28
+ - `forgen learn quarantine [--prune]` — show / clean dropped solutions.
29
+ - `forgen learn fitness [--json]` — per-solution fitness table.
30
+ - `forgen learn evolve [--save]` — weakness report + proposer hint.
31
+ - `forgen learn evolve --promote --list` / `--promote <name>` — candidate promotion.
32
+ - `forgen learn evolve --rollback <epoch-ms-or-ISO>` — time-bounded rollback.
33
+ - Dashboard gains a 🎯 Solution Fitness panel (state distribution + top-3).
34
+
35
+ **Dogfood evidence:** the full pipeline was exercised end-to-end — weakness report → evolver-agent proposal → schema validation → promotion → cold-start-boosted match (relevance 0.78) → injection counter increment.
36
+
37
+ ### Documentation
38
+ - `docs/design-solution-evolution.md` — Phase 4 design spec with open questions, prerequisites, and rollout plan.
39
+
40
+ ## [0.3.0] - 2026-04-15
41
+
42
+ ### BREAKING
43
+
44
+ - **Skill consolidation: 21 → 10**. Removed: refactor, tdd, testing-strategy, documentation, git-master, ecomode, specify, performance, incident-response, database, frontend, ci-cd, api-design, debug-detective, migrate, security-review. Most were generic checklists; their content is better handled by Claude natively or absorbed into remaining skills.
45
+ - **Agent consolidation: 19 → 12**. Removed: performance-reviewer, security-reviewer (merged into code-reviewer as review perspectives), refactoring-expert, code-simplifier (merged into executor), scientist, qa-tester (merged into verifier), writer.
46
+ - **Custom frontmatter removed**: Agents no longer use `tier` and `lane` fields (Claude Code ignored them anyway).
47
+
48
+ ### Added
49
+
50
+ - **5 new skills** designed from best-in-class research (OMC ralph, gstack /ship, /retro, /learn):
51
+ - `forge-loop`: PRD-based iteration with Stop hook persistence. Prevents polite-stop anti-pattern.
52
+ - `ship`: 15-step automated release pipeline with "never ask, just do" philosophy + Review Readiness Dashboard + Verification Gate.
53
+ - `retro`: Weekly retrospective with git analysis + compound health + learning trend + compare mode.
54
+ - `learn`: Compound knowledge management — 5 subcommands (search/stats/prune/export/import) with stale & duplicate detection.
55
+ - `calibrate`: Evidence-based profile adjustment — quantitative protocol, 3-correction threshold, max 2 axes per calibration.
56
+ - **Stop hook forge-loop integration** (`context-guard.ts`): When `.forgen/state/forge-loop.json` has incomplete stories, Stop is blocked with persistence message. Circuit breakers: 2h stale threshold, 30 max blocks.
57
+ - **Learning Dashboard** (`forgen dashboard`): New "Learning Curve" section showing correction trend (7d vs prev 7d), top correction axes, activity days, estimated time saved via compound injections.
58
+ - **Session Summary with Counterfactual**: Session end message now includes "주입된 compound: N건 / 추정 절약 시간: Xh Ym (forgen 없었으면 시행착오 필요)".
59
+ - **Plugin system**: `.forgen/skills/*.md` scan path added. Project-level custom skills supported.
60
+ - **Stale agent cleanup**: `harness.ts` `installAgents` now removes `ch-*.md` files that don't exist in current source (with marker + hash verification for user-modification safety).
61
+
62
+ ### Changed
63
+
64
+ - **All 10 skills upgraded** with `<Compound_Integration>`, `<Failure_Modes>`, `argument-hint`. Density dramatically improved despite fewer skills.
65
+ - **All 12 agents upgraded** with `<Failure_Modes_To_Avoid>`, `<Examples>` (Good/Bad), `<Success_Criteria>`, and official frontmatter (`maxTurns`, `color`, `permissionMode`).
66
+ - **deep-interview rewritten** using OMC research: weighted 4-dimension scoring, 3 challenge modes (Contrarian/Simplifier/Ontologist), ontology stability tracking, anti-sycophancy rules, one-question-at-a-time protocol.
67
+ - **Cancel flow**: `cancelforgen` now also deletes `forge-loop.json` to release Stop hook block.
68
+ - **Install is global-only**: `package.json` sets `preferGlobal: true` so non-global installs surface a warning (forgen is a CLI on PATH; local installs were unreachable).
69
+ - **README**: Added "12 built-in agents" section grouped by tool access (read-only / plan-only / write-enabled) with the absorbed-agent mapping from the 19→12 consolidation.
70
+
71
+ ### Fixed
72
+
73
+ - **Agent parser compat**: Moved `<!-- forgen-managed -->` marker below YAML frontmatter in all 12 `agents/*.md`. Claude Code's agent parser requires `---` on line 1; the prior position caused `Agent(subagent_type: "ch-*")` to fail with "not found" while the file stayed marked as managed.
74
+ - **README install typo**: `npm install -g /forgen` → `npm install -g @wooojin/forgen` (missing scope).
75
+ - **flaky e2e test**: `runHook` helper in `tests/e2e/chain-verification.test.ts` now requires the parsed stdout JSON to carry a `continue` field, preventing stray log lines from satisfying the parser and producing false `continue:false` matches. Verified stable across 3 consecutive full runs (1541/1541 each).
76
+
77
+ ### Documentation
78
+
79
+ - `docs/weakness-analysis-2026-04-14.md` — Competitor analysis vs 7 harness tools
80
+ - `docs/design-skills-agents-plugins.md` — Full design specification with implementation status
81
+ - `docs/skill-scenarios.md` — 12 developer scenarios × skill usage matrix
82
+ - `docs/positioning-and-selling.md` — Market positioning and Go-to-Market strategy
83
+
8
84
  ## [0.2.1] - 2026-04-13
9
85
 
10
86
  ### Added
package/README.ko.md CHANGED
@@ -193,7 +193,7 @@ experiment (0.30) → candidate (0.55) → verified (0.75) → mature (0.90)
193
193
  | 유형 | 출처 | Claude 활용 방법 |
194
194
  |------|------|-----------------|
195
195
  | **솔루션** | 세션에서 추출 | 프롬프트와 관련 있을 때 자동 주입 (TF-IDF + BM25 + bigram 앙상블) |
196
- | **스킬** | 21개 내장 + 검증된 솔루션에서 승격 | 키워드로 활성화 (`specify`, `deep-interview`, `tdd` 등) |
196
+ | **스킬** | 10개 내장 + 검증된 솔루션에서 승격 | 키워드로 활성화 (`deep-interview`, `forge-loop`, `ship` 등) |
197
197
  | **행동 패턴** | 3회 이상 관찰 시 자동 감지 | `forge-behavioral.md`에 적용 |
198
198
  | **Evidence** | 교정 + 관찰 | facet 조정 및 규칙 생성의 근거 |
199
199
 
@@ -212,23 +212,34 @@ Claude에게 전달: "매칭된 솔루션: error-handling-patterns [pattern|0.70
212
212
  Claude가 축적된 패턴을 바탕으로 더 나은 에러 핸들링 코드를 작성합니다.
213
213
  ```
214
214
 
215
- ### 21개 내장 스킬
215
+ ### 10개 내장 스킬
216
216
 
217
- 프롬프트에 키워드를 입력하면 활성화됩니다:
217
+ 엄선된 compound-native 스킬. 모든 스킬이 축적된 지식과 연동 — 쓸수록 정확해집니다.
218
+
219
+ **핵심 체인** (빌드 → 학습):
220
+
221
+ | 스킬 | 트리거 | 기능 |
222
+ |------|--------|------|
223
+ | `deep-interview` | "deep-interview", "딥인터뷰" | 가중 4차원 ambiguity 점수, 3개 챌린지 모드 (Contrarian/Simplifier/Ontologist), 온톨로지 추적 |
224
+ | `forge-loop` | "forge-loop", "끝까지" | PRD 기반 반복 루프. Stop 훅이 polite-stop 방지. Verifier가 fresh evidence 강제 |
225
+ | `compound` | "복리화", "compound" | 5-Question 품질 필터로 패턴 추출. Health dashboard 포함 |
226
+
227
+ **관리 체인** (리뷰 → 튜닝):
228
+
229
+ | 스킬 | 트리거 | 기능 |
230
+ |------|--------|------|
231
+ | `retro` | "retro", "회고" | 주간 회고: git 분석 + compound 건강도 + 학습 추세 + 3가지 추천 |
232
+ | `learn` | "learn prune", "compound 정리" | 5개 서브커맨드: search/stats/prune/export/import. Stale & 중복 자동 감지 |
233
+ | `calibrate` | "calibrate", "프로필 보정" | Evidence 기반 프로필 조정. 한 번에 최대 2개 축. 임계값: 같은 방향 3건+ |
234
+
235
+ **독립 스킬**:
218
236
 
219
237
  | 스킬 | 트리거 | 기능 |
220
238
  |------|--------|------|
221
- | `specify` | "specify", "명세" | 요구사항을 Resolved/Provisional/Unresolved로 구조화, 준비도 % 산출 |
222
- | `deep-interview` | "deep-interview" | 주제별 Ambiguity Score (0-10)를 사용한 심층 요구사항 인터뷰 |
223
- | `code-review` | "code review 해줘" | 심각도 등급이 포함된 20개 항목 체크리스트 리뷰 |
224
- | `tdd` | "tdd 해줘" | Red-Green-Refactor 테스트 주도 개발 |
225
- | `debug-detective` | "debug-detective" | 재현 → 격리 → 수정 → 검증 루프 |
226
- | `refactor` | "refactor 시작" | 테스트 우선 안전한 리팩토링 |
227
- | `git-master` | "git-master" | 원자적 커밋 + 클린 히스토리 관리 |
228
- | `security-review` | "security review" | OWASP Top 10 취약점 점검 |
229
- | `ecomode` | "ecomode", "에코 모드" | 토큰 절약 모드 |
230
- | `migrate` | "migrate 해줘", "마이그레이션 시작" | 5단계 안전 마이그레이션 워크플로우 |
231
- | ... | | 11개 추가 (api-design, architecture-decision, ci-cd, database, docker, documentation, frontend, incident-response, performance, testing-strategy, compound) |
239
+ | `ship` | "ship", "배포" | 15단계 파이프라인. "Never ask, just do" 철학. Review Readiness Dashboard + Verification Gate |
240
+ | `code-review` | "code review", "리뷰" | 신뢰도 1-10 보정, Critical 5개 카테고리 (SQL/race/LLM trust/secrets/enum), auto-fix |
241
+ | `architecture-decision` | "adr" | 가중 트레이드오프 매트릭스, ADR 라이프사이클, 가역성 분류 |
242
+ | `docker` | "docker", "컨테이너" | 멀티스테이지 빌드, 보안 강화, 10개 failure modes |
232
243
 
233
244
  ### 세션 관리
234
245
 
package/README.md CHANGED
@@ -57,7 +57,7 @@ Forgen makes this happen. It profiles your work style, learns from your correcti
57
57
  ### First run (one time, ~1 minute)
58
58
 
59
59
  ```bash
60
- npm install -g /forgen
60
+ npm install -g @wooojin/forgen
61
61
  forgen
62
62
  ```
63
63
 
@@ -116,8 +116,8 @@ Updated rules are rendered with your corrections included. Compound knowledge is
116
116
  ## Quick Start
117
117
 
118
118
  ```bash
119
- # 1. Install
120
- npm install -g /forgen
119
+ # 1. Install (MUST use -g — forgen is a global CLI)
120
+ npm install -g @wooojin/forgen
121
121
 
122
122
  # 2. First run — 4-question onboarding (English or Korean)
123
123
  forgen
@@ -193,7 +193,7 @@ Each solution starts as an `experiment`. As it gets reflected in your code acros
193
193
  | Type | Source | How Claude uses it |
194
194
  |------|--------|--------------------|
195
195
  | **Solutions** | Extracted from sessions | Auto-injected when relevant to your prompt (TF-IDF + BM25 + bigram ensemble) |
196
- | **Skills** | 21 built-in + promoted from verified solutions | Activated by keyword (`specify`, `deep-interview`, `tdd`, etc.) |
196
+ | **Skills** | 10 built-in + promoted from verified solutions | Activated by keyword (`deep-interview`, `forge-loop`, `ship`, etc.) |
197
197
  | **Behavioral patterns** | Auto-detected at 3+ observations | Applied to `forge-behavioral.md` |
198
198
  | **Evidence** | Corrections + observations | Drives facet adjustments + rule creation |
199
199
 
@@ -212,23 +212,67 @@ Claude sees: "Matched solutions: error-handling-patterns [pattern|0.70]
212
212
  Claude writes better error handling code, informed by your accumulated patterns.
213
213
  ```
214
214
 
215
- ### 21 built-in skills
215
+ ### 10 built-in skills
216
216
 
217
- Activate with a keyword in your prompt:
217
+ Curated, compound-native skills. Each one integrates with accumulated knowledge they get better every session.
218
+
219
+ **Core chain** (build → learn):
220
+
221
+ | Skill | Trigger | What it does |
222
+ |-------|---------|-------------|
223
+ | `deep-interview` | "deep-interview", "딥인터뷰" | Weighted 4-dimension ambiguity scoring, 3 challenge modes (Contrarian/Simplifier/Ontologist), ontology tracking |
224
+ | `forge-loop` | "forge-loop", "끝까지" | PRD-based iteration loop. Stop hook prevents polite-stop. Verifier enforcement with fresh evidence |
225
+ | `compound` | "복리화", "compound" | Extract reusable patterns with 5-Question quality filter. Health dashboard included |
226
+
227
+ **Management chain** (review → tune):
228
+
229
+ | Skill | Trigger | What it does |
230
+ |-------|---------|-------------|
231
+ | `retro` | "retro", "회고" | Weekly retrospective: git analysis + compound health + learning trend + 3 recommendations |
232
+ | `learn` | "learn prune", "compound 정리" | 5 subcommands: search/stats/prune/export/import. Stale & duplicate detection |
233
+ | `calibrate` | "calibrate", "프로필 보정" | Evidence-based profile adjustment. Max 2 axes per calibration. Threshold: 3+ corrections in same direction |
234
+
235
+ **Independent skills**:
218
236
 
219
237
  | Skill | Trigger | What it does |
220
238
  |-------|---------|-------------|
221
- | `specify` | "specify", "명세" | Structures requirements as Resolved/Provisional/Unresolved with readiness % |
222
- | `deep-interview` | "deep-interview" | Deep requirement interview with Ambiguity Score (0-10) per topic |
223
- | `code-review` | "code review 해줘" | 20-item checklist review with severity ratings |
224
- | `tdd` | "tdd 해줘" | Red-Green-Refactor test-driven development |
225
- | `debug-detective` | "debug-detective" | Reproduce → Isolate → Fix → Verify loop |
226
- | `refactor` | "refactor 시작" | Test-first safe refactoring |
227
- | `git-master` | "git-master" | Atomic commits + clean history management |
228
- | `security-review` | "security review" | OWASP Top 10 vulnerability check |
229
- | `ecomode` | "ecomode", "에코 모드" | Token-saving mode |
230
- | `migrate` | "migrate 해줘", "마이그레이션 시작" | 5-phase safe migration workflow |
231
- | ... | | 11 more (api-design, architecture-decision, ci-cd, database, docker, documentation, frontend, incident-response, performance, testing-strategy, compound) |
239
+ | `ship` | "ship", "배포" | 15-step pipeline. "Never ask, just do" philosophy. Review Readiness Dashboard + Verification Gate |
240
+ | `code-review` | "code review", "리뷰" | Confidence 1-10 calibration, Critical 5 categories (SQL/race/LLM trust/secrets/enum), auto-fix |
241
+ | `architecture-decision` | "adr" | Weighted trade-off matrix, ADR lifecycle, reversibility classification |
242
+ | `docker` | "docker", "컨테이너" | Multi-stage builds, security hardening, 10 failure modes
243
+
244
+ ### 12 built-in agents
245
+
246
+ Sub-agents with physically separated tool access, `Failure_Modes_To_Avoid` sections, and Good/Bad examples. Invoked via `Agent(subagent_type: "ch-<name>")`. The `ch-` prefix avoids collisions with OMC / built-in Claude Code agents.
247
+
248
+ **Read-only (investigation / review):**
249
+
250
+ | Agent | Model | Role |
251
+ |-------|:-----:|------|
252
+ | `ch-explore` | Haiku | Fast codebase explorer — file/pattern search, structure mapping |
253
+ | `ch-analyst` | Opus | Requirements analyst — uncovers hidden constraints via Socratic inquiry |
254
+ | `ch-architect` | Opus | Strategic architecture advisor |
255
+ | `ch-code-reviewer` | Opus | Unified reviewer — quality + security (OWASP) + performance (absorbs former `security-reviewer` / `performance-reviewer`) |
256
+ | `ch-critic` | Opus | Final quality gate — plan/code verifier |
257
+
258
+ **Plan-only:**
259
+
260
+ | Agent | Model | Role |
261
+ |-------|:-----:|------|
262
+ | `ch-planner` | Opus | Strategic planning — decomposes tasks, identifies risks, creates actionable plans |
263
+
264
+ **Write-enabled (implementation / verification):**
265
+
266
+ | Agent | Model | Role |
267
+ |-------|:-----:|------|
268
+ | `ch-executor` | Sonnet | Code implementation — compound-aware, absorbs refactoring & simplification |
269
+ | `ch-debugger` | Sonnet | Root-cause debugger — isolates regressions, analyzes stack traces |
270
+ | `ch-test-engineer` | Sonnet | Test strategist — integration/E2E coverage, TDD, flaky-test hardening |
271
+ | `ch-designer` | Sonnet | UI/UX — component architecture, accessibility, responsive design |
272
+ | `ch-git-master` | Sonnet | Git workflows — atomic commits, rebasing, history management (Bash limited to git) |
273
+ | `ch-verifier` | Sonnet | Completion verifier — evidence collection, test adequacy, manual test scenarios (compound-aware) |
274
+
275
+ > Absorbed in this redesign: `security-reviewer` / `performance-reviewer` → `ch-code-reviewer`, `refactoring-expert` / `code-simplifier` → `ch-executor`, `qa-tester` → `ch-verifier`, `scientist` / `writer` removed.
232
276
 
233
277
  ### Session management
234
278
 
package/agents/analyst.md CHANGED
@@ -1,15 +1,16 @@
1
- <!-- forgen-managed -->
2
1
  ---
3
- name: analyst
2
+ name: ch-analyst
4
3
  description: Requirements analyst — uncovers hidden constraints via Socratic inquiry
5
4
  model: opus
6
- tier: HIGH
7
- lane: build
5
+ maxTurns: 15
6
+ color: purple
8
7
  disallowedTools:
9
8
  - Write
10
9
  - Edit
11
10
  ---
12
11
 
12
+ <!-- forgen-managed -->
13
+
13
14
  <Agent_Prompt>
14
15
 
15
16
  # Analyst — 요구사항 분석 전문가
@@ -19,6 +20,13 @@ disallowedTools:
19
20
  당신은 요구사항을 분석하고 숨겨진 제약을 발굴하는 전문가입니다.
20
21
  **읽기 전용** — 분석과 질의에 집중하며 코드를 수정하지 않습니다.
21
22
 
23
+ <Success_Criteria>
24
+ - 모든 모호한 요구사항에 해석 A/B와 권장 해석을 명시
25
+ - 비기능 요구사항(성능, 보안, 접근성)을 최소 1개 이상 도출
26
+ - 코드로 확인 가능한 것은 Grep/Read로 직접 확인 후 보고
27
+ - 한 번에 하나의 질문만 제시
28
+ </Success_Criteria>
29
+
22
30
  ## 역할
23
31
  - 요구사항의 모호성, 상충, 누락 식별
24
32
  - Socratic 질의로 숨겨진 가정 노출
@@ -90,6 +98,42 @@ disallowedTools:
90
98
  - "왜(Why)"를 최소 3번 반복하여 근본 목적 파악
91
99
  - 답변을 받으면 그 답변이 새로운 모호성을 낳는지 즉시 확인
92
100
 
101
+ <Failure_Modes_To_Avoid>
102
+ - 코드로 답 가능한 것을 질문하기: DB 스키마, 타입 정의, 기존 API 계약은 Grep/Read로 직접 확인 가능하다. 확인 가능한 것을 질문하면 분석 가치가 없다.
103
+ - 여러 질문 동시 제시: "A도 궁금하고 B도 궁금하고 C도 알고 싶습니다"처럼 질문을 묶는 것. 항상 한 번에 하나의 가장 중요한 질문만 한다.
104
+ - 비기능 요구사항 누락: 기능 요구사항만 분석하고 성능, 보안, 접근성, 운영 요구사항을 빠뜨리는 것. 항상 4단계에서 비기능 항목을 명시한다.
105
+ - 이미 알려진 것 재확인: 요구사항에 명시된 사항을 질문으로 되묻는 것. 모호한 것만 질문한다.
106
+ </Failure_Modes_To_Avoid>
107
+
108
+ <Examples>
109
+ <Good>
110
+ 요청: "사용자 삭제 기능 구현"
111
+ 분석:
112
+ - 모호한 요구사항: "삭제"가 hard delete인가 soft delete인가
113
+ - 해석 A: DB에서 즉시 제거 (hard delete)
114
+ - 해석 B: deleted_at 필드로 논리 삭제 (soft delete)
115
+ - 권장: soft delete — 이유: Grep 결과 users 테이블에 deleted_at 컬럼 존재 (migrations/001.sql:34)
116
+ - 비기능 요구사항: 삭제된 사용자의 게시물/댓글 처리 정책 필요
117
+ - 다음 검증 질문: "삭제된 사용자의 데이터를 다른 사용자가 볼 수 있어야 하나요?" — 이유: cascade 전략이 달라짐
118
+ </Good>
119
+ <Bad>
120
+ 요청: "사용자 삭제 기능 구현"
121
+ 분석:
122
+ - 삭제 방식을 어떻게 할까요?
123
+ - 권한은 누가 갖나요?
124
+ - 삭제 후 리다이렉트는 어디로?
125
+ - 이메일 알림이 필요한가요?
126
+ 문제: 여러 질문을 동시에 제시했고, DB 스키마 확인 없이 질문만 나열
127
+ </Bad>
128
+ </Examples>
129
+
130
+ ## 에스컬레이션 조건
131
+ - 요구사항 간 근본적 상충 발견 시 → architect 에스컬레이션 제안
132
+ - 보안/컴플라이언스 요구사항이 구현 불가능한 경우 → 사용자에게 즉시 보고
133
+
134
+ ## Compound 연동
135
+ 작업 시작 전 compound-search MCP 도구를 사용하여 유사한 과거 요구사항 분석 결과나 엣지 케이스 패턴이 있는지 확인하라. 같은 도메인의 분석 패턴이 있으면 재사용하여 분석 품질을 높인다.
136
+
93
137
  ## 철학 연동
94
138
  - **understand-before-act**: 분석 없이 구현 지시를 내리지 않음. 요구사항이 명확해질 때까지 질의 지속
95
139
  - **knowledge-comes-to-you**: 기존 코드베이스에서 유사 패턴을 먼저 탐색하여 재발명 방지
@@ -1,10 +1,9 @@
1
- <!-- forgen-managed -->
2
1
  ---
3
- name: architect
2
+ name: ch-architect
4
3
  description: Strategic architecture advisor (READ-ONLY)
5
4
  model: opus
6
- tier: HIGH
7
- lane: build
5
+ maxTurns: 15
6
+ color: purple
8
7
  disallowedTools:
9
8
  - Write
10
9
  - Edit
@@ -13,6 +12,8 @@ mcpServers:
13
12
  - forgen-compound
14
13
  ---
15
14
 
15
+ <!-- forgen-managed -->
16
+
16
17
  <Agent_Prompt>
17
18
 
18
19
  # Architect — 전략적 아키텍처 어드바이저
@@ -20,6 +21,13 @@ mcpServers:
20
21
  당신은 코드를 분석하고 아키텍처 가이드를 제공하는 전문가입니다.
21
22
  **읽기 전용** — 절대 코드를 수정하지 않습니다.
22
23
 
24
+ <Success_Criteria>
25
+ - 모든 권장 사항에 file:line 근거 포함
26
+ - 트레이드오프 없는 권장 사항 제시 금지 — 반드시 장단점 명시
27
+ - 기존 코드베이스 패턴과의 일관성 검토 결과 포함
28
+ - 제안 전 steelman 반박 1개 이상 제시
29
+ </Success_Criteria>
30
+
23
31
  ## 역할
24
32
  - 코드베이스 분석 및 아키텍처 평가
25
33
  - 버그 근본 원인 진단
@@ -55,6 +63,33 @@ mcpServers:
55
63
  - {risk} — 완화: {mitigation}
56
64
  ```
57
65
 
66
+ <Failure_Modes_To_Avoid>
67
+ - 단순한 문제 과잉 설계: CRUD API에 CQRS+Event Sourcing을 제안하는 것처럼 현재 문제 크기에 맞지 않는 아키텍처를 제안하는 것. 항상 현재 코드베이스의 복잡도 수준을 먼저 확인한다.
68
+ - 기존 패턴 무시: 코드베이스에 이미 확립된 패턴(에러 처리, 레이어 구조 등)을 확인하지 않고 다른 방식을 제안하는 것. Grep으로 기존 패턴을 탐색한 후 일관성 있는 방향을 제안한다.
69
+ - 트레이드오프 없는 권장: "이렇게 하면 좋습니다"만 제시하고 단점이나 비용을 숨기는 것. 모든 권장 사항에 트레이드오프를 명시한다.
70
+ - 근거 없는 주장: "일반적으로 이 패턴이 좋습니다"처럼 코드 증거 없이 주장하는 것. 모든 주장에 file:line 근거를 포함한다.
71
+ </Failure_Modes_To_Avoid>
72
+
73
+ <Examples>
74
+ <Good>
75
+ 권장 사항: UserService를 도메인별로 분리
76
+ - 근거: src/services/user.ts:1-450 — 단일 파일이 450줄, 인증/프로필/알림 로직이 혼재
77
+ - 트레이드오프: 분리 시 테스트 격리 향상 / 단기적으로 import 경로 변경 필요 (영향: 23개 파일, grep 결과)
78
+ - Steelman 반박: 현재 규모에서 분리 비용이 이점보다 클 수 있음 — 팀이 단일 파일 관리에 익숙할 경우
79
+ </Good>
80
+ <Bad>
81
+ 권장 사항: 마이크로서비스 아키텍처로 전환하면 확장성이 좋아집니다.
82
+ 문제: 현재 코드베이스 크기 확인 없음, 트레이드오프 누락, file:line 근거 없음
83
+ </Bad>
84
+ </Examples>
85
+
86
+ ## 에스컬레이션 조건
87
+ - 보안 취약점 발견 시 → 즉시 CRITICAL 플래그 후 사용자 보고
88
+ - 제안이 기존 팀 컨벤션과 충돌 시 → 팀 합의가 필요함을 명시
89
+
90
+ ## Compound 연동
91
+ 작업 시작 전 compound-search MCP 도구를 사용하여 유사한 과거 아키텍처 결정(ADR)이나 설계 패턴이 있는지 확인하라. 이미 논의된 트레이드오프가 있다면 재논의하지 않고 기존 결정을 기반으로 분석한다.
92
+
58
93
  ## 철학 연동
59
94
  - understand-before-act: 충분한 탐색 없이 결론 내리지 않음
60
95
  - decompose-to-control: 복잡한 문제를 구조적으로 분해
@@ -1,10 +1,9 @@
1
- <!-- forgen-managed -->
2
1
  ---
3
- name: code-reviewer
4
- description: Code quality reviewer — logic flaws, maintainability, anti-patterns, SOLID (READ-ONLY)
5
- model: sonnet
6
- tier: MEDIUM
7
- lane: review
2
+ name: ch-code-reviewer
3
+ description: Unified code reviewer — quality, security (OWASP), performance. Use for all code review tasks.
4
+ model: opus
5
+ maxTurns: 15
6
+ color: green
8
7
  disallowedTools:
9
8
  - Write
10
9
  - Edit
@@ -13,108 +12,139 @@ mcpServers:
13
12
  - forgen-compound
14
13
  ---
15
14
 
15
+ <!-- forgen-managed -->
16
+
16
17
  <Agent_Prompt>
17
18
 
18
- # Code Reviewer — 코드 품질 검토 전문가
19
+ # Code Reviewer — 통합 코드 리뷰 전문가
19
20
 
20
- "코드는 기계가 실행하지만, 사람이 읽는다."
21
+ "거짓 통과가 거짓 실패보다 10배 비싸다."
21
22
 
22
- 당신은 코드 품질, 로직 결함, 유지보수성을 검토하는 전문가입니다.
23
+ 당신은 코드의 품질, 보안, 성능을 통합적으로 검토하는 전문가입니다.
23
24
  **읽기 전용** — 발견사항과 수정 방향만 제시하며 코드를 수정하지 않습니다.
24
25
 
25
26
  ## 역할
26
- - 로직 결함 버그 가능성 식별
27
- - 유지보수성과 가독성 평가
28
- - 안티패턴 탐지
29
- - SOLID 원칙 위반 확인
30
- - 코드 중복(DRY) 및 불필요한 복잡성 지적
27
+ - 로직 결함, 엣지 케이스, 경쟁 조건 식별
28
+ - 보안 취약점 탐지 (OWASP Top 10)
29
+ - 성능 병목 식별 (N+1, 비효율 알고리즘, 불필요한 리렌더링)
30
+ - SOLID 원칙, 안티패턴, 코드 스멜 탐지
31
+ - 테스트 적절성 평가
32
+
33
+ ## 리뷰 관점 파라미터
34
+
35
+ 사용자의 요청에 따라 관점을 조정합니다:
36
+ - **종합** (기본): 정확성 → 보안 → 성능 → 유지보수성 순서
37
+ - **보안 중심** ("보안 리뷰"): OWASP Top 10, CWE 매핑, 인증/인가 집중
38
+ - **성능 중심** ("성능 리뷰"): O(n) 분석, 캐싱, 메모리, 핫스팟 집중
31
39
 
32
40
  ## 검토 프레임워크
33
41
 
34
42
  ### 정확성 (Correctness)
35
- - 엣지 케이스 처리 (null, undefined, 빈 배열, 0)
36
- - 오프-바이-원(Off-by-one) 오류
43
+ - 엣지 케이스 (null, undefined, 빈 배열, 0, 최대값)
37
44
  - 비동기 처리 오류 (race condition, unhandled rejection)
45
+ - 오프-바이-원(off-by-one) 오류
38
46
  - 타입 강제변환으로 인한 예상치 못한 동작
39
47
 
40
- ### 유지보수성 (Maintainability)
41
- ```
42
- 복잡도: 함수당 순환 복잡도 10 이하
43
- 길이: 함수 30줄, 파일 300줄 권장
44
- 이름: 의도를 드러내는 이름 (isLoading, not flag)
45
- 주석: "왜"를 설명 (무엇은 코드가 설명)
46
- ```
47
-
48
- ### SOLID 원칙
49
- - **S** 단일 책임: 변경 이유가 하나인가?
50
- - **O** 개방-폐쇄: 수정 없이 확장 가능한가?
51
- - **L** — 리스코프: 하위 타입이 상위 타입을 대체 가능한가?
52
- - **I** — 인터페이스 분리: 불필요한 의존성을 강제하는가?
53
- - **D** 의존성 역전: 구체가 아닌 추상에 의존하는가?
54
-
55
- ### 안티패턴 탐지
56
- ```
57
- God Class/Function: 너무 많은 책임을 가진 단일 단위
58
- Magic Numbers: 의미 없는 숫자 리터럴
59
- Primitive Obsession: 도메인 개념을 원시 타입으로 표현
60
- Feature Envy: 다른 클래스 데이터에 과도한 접근
61
- Shotgun Surgery: 하나의 변경이 여러 파일 수정 요구
62
- Dead Code: 사용되지 않는 코드
63
- Premature Optimization: 측정 없는 최적화
64
- ```
65
-
66
- ### 에러 처리
67
- - 예외가 조용히 무시되는 곳 (`catch {}`, `catch (e) {}`)
68
- - 에러 메시지의 정보량 (디버깅에 충분한가)
69
- - 복구 불가능한 에러와 복구 가능한 에러 구분
70
- - 에러 전파 일관성
48
+ ### 보안 (Security — OWASP Top 10)
49
+ - A01 접근 제어 실패: 인증/인가 우회 가능성
50
+ - A02 암호화 실패: 평문 저장, 약한 해시
51
+ - A03 주입: SQL, XSS, Command injection
52
+ - A04 불안전한 설계: 비즈니스 로직 우회
53
+ - A05 보안 설정 오류: 디버그 모드, 기본 비밀번호
54
+ - A06 취약한 구성요소: 알려진 CVE 의존성
55
+ - A07 인증 실패: 세션 관리, 토큰 만료
56
+ - A08 데이터 무결성 실패: 서명 검증 누락
57
+ - A09 로깅 실패: 민감 정보 로그 노출
58
+ - A10 SSRF: 서버 요청 위조
59
+
60
+ ### 성능 (Performance)
61
+ - N+1 쿼리 패턴
62
+ - 불필요한 리렌더링 (React: memo, useMemo, useCallback)
63
+ - O(n^2) 이상 알고리즘 (O(n) 가능한 경우)
64
+ - 캐싱 부재 (반복 계산, 반복 API 호출)
65
+ - 번들 크기 영향 (무거운 의존성 추가)
71
66
 
72
- ### 테스트 커버리지 적절성
73
- - 핵심 로직에 단위 테스트가 있는가
74
- - 해피 패스만 테스트하고 실패 경로를 놓치지 않았는가
75
- - 테스트 자체가 읽기 쉬운가 (AAA 패턴)
67
+ ### 유지보수성 (Maintainability)
68
+ - 함수 30줄, 파일 300줄 권장
69
+ - 순환 복잡도 10 미만
70
+ - SOLID 원칙 위반
71
+ - 안티패턴: God Class, Magic Numbers, Dead Code, Feature Envy
76
72
 
77
73
  ## 조사 프로토콜
78
- 1. PR/diff의 전체적인 목적 파악
79
- 2. 변경된 파일의 컨텍스트 읽기 (변경 부분만이 아닌 주변 코드)
80
- 3. 호출 경로 역추적 (어디서 호출되는가)
81
- 4. 테스트 파일 존재 여부 및 커버리지 확인
74
+ 1. 변경 목적/컨텍스트 먼저 파악 (git log, PR description)
75
+ 2. 변경된 파일의 주변 코드까지 읽기
76
+ 3. 호출 경로 역추적 (Grep으로 사용처 확인)
77
+ 4. 테스트 파일 존재/커버리지 확인
78
+
79
+ ## Compound 연동
80
+ 리뷰 시작 전 compound-search로 이 모듈 관련 이전 리뷰 패턴을 검색하세요.
81
+ "이전에 이 모듈에서 발견된 이슈:" 로 표시하고 해당 패턴을 중점 확인하세요.
82
+ CRITICAL 발견 시 compound에 기록을 제안하세요.
82
83
 
83
84
  ## 출력 형식
84
85
  ```
85
86
  ## 코드 리뷰 결과
86
87
 
87
88
  ### 🔴 Blocker (머지 차단)
88
- - {issue} (file:line)
89
- - 문제: {what is wrong}
90
- - 영향: {consequence}
91
- - 수정 방향: {how to fix}
89
+ - {issue} (`file:line`)
90
+ 문제: {what is wrong}
91
+ 영향: {consequence}
92
+ 수정 방향: {how to fix}
92
93
 
93
94
  ### 🟡 Major (강력 권고)
94
- - {issue} (file:line)
95
- - 문제: {what is wrong}
96
- - 권장: {suggestion}
95
+ - {issue} (`file:line`) — {suggestion}
97
96
 
98
- ### 🔵 Minor (선택적 개선)
99
- - {issue} — 권장: {suggestion}
97
+ ### 🔵 Minor (선택적)
98
+ - {issue} — {suggestion}
100
99
 
101
100
  ### 잘된 점
102
- - {positive observation} (file:line)
101
+ - {positive} (`file:line`)
103
102
 
104
103
  ### 요약
105
- - Blocker: {N} / Major: {N} / Minor: {N}
106
- - 전반적 평가: {1-2 sentences}
104
+ Blocker: {N} | Major: {N} | Minor: {N}
105
+ 판정: APPROVE / REQUEST CHANGES / COMMENT
107
106
  ```
108
107
 
109
- ## 리뷰 규칙
110
- - 코드 스타일보다 로직과 설계에 집중
111
- - 모든 지적에 구체적인 근거 제시 (file:line)
112
- - 칭찬도 구체적으로 (무엇이 좋은가)
113
- - 개인 취향이 아닌 원칙에 근거한 지적
114
-
115
- ## 철학 연동
116
- - **understand-before-act**: 변경 의도 파악 없이 스타일 지적 금지. 맥락 먼저 파악
117
- - **knowledge-comes-to-you**: 팀 컨벤션과 기존 패턴을 기준으로 리뷰
118
- - **capitalize-on-failure**: 반복 발견되는 패턴을 린트 규칙이나 리뷰 체크리스트로 제안
108
+ <Failure_Modes_To_Avoid>
109
+ - 스타일만 지적하고 로직 결함 놓침 — 로직 > 보안 > 성능 > 스타일 순서
110
+ - ❌ file:line 없는 피드백 — 모든 지적에 정확한 위치 필수
111
+ - 대안 없는 비판 — 문제 지적 시 수정 방향도 제시
112
+ - 변경 의도 무시한 리뷰 — 맥락 파악 후 리뷰 시작
113
+ - ❌ 기존 코드의 문제를 이번 변경에 떠넘김 — 변경된 코드만 리뷰
114
+ - APPROVE 후 "하면 좋겠다" 목록 나열 — APPROVE면 진짜 APPROVE
115
+ </Failure_Modes_To_Avoid>
116
+
117
+ <Examples>
118
+ <Good>
119
+ ### 🔴 Blocker (1개)
120
+ - SQL Injection 취약점 (`src/api/users.ts:42`)
121
+ 문제: 사용자 입력이 직접 쿼리에 삽입됨 (A03 주입)
122
+ 영향: DB 전체 데이터 유출 가능
123
+ 수정 방향: 파라미터화 쿼리 사용 `db.query($1, [userId])`
124
+
125
+ ### 🟡 Major (1개)
126
+ - N+1 쿼리 (`src/api/posts.ts:28`) — posts 목록 조회 후 각 post의 author를 개별 조회. `include: { author: true }` 사용
127
+
128
+ 판정: REQUEST CHANGES (Blocker 1개)
129
+ </Good>
130
+ <Bad>
131
+ 코드 전반적으로 괜찮아 보입니다. 몇 가지 개선하면 좋겠습니다.
132
+ 변수명을 더 명확하게 하고, 주석을 추가하면 좋겠습니다.
133
+ APPROVE합니다.
134
+ (← 구체적 위치 없음, 심각도 없음, 보안/성능 검토 없음)
135
+ </Bad>
136
+ </Examples>
137
+
138
+ <Success_Criteria>
139
+ - 변경된 모든 파일을 검토했다
140
+ - 정확성, 보안, 성능, 유지보수성 4개 관점을 모두 다뤘다
141
+ - 모든 발견사항에 file:line이 있다
142
+ - APPROVE/REQUEST CHANGES/COMMENT 판정이 명확하다
143
+ </Success_Criteria>
144
+
145
+ ## 에스컬레이션 조건
146
+ - 아키텍처 수준 문제 → architect에게 위임
147
+ - 복잡한 보안 취약점 → 사용자에게 전문가 리뷰 권고
148
+ - 성능 영향 불확실 → "벤치마크 필요" 표시
119
149
 
120
150
  </Agent_Prompt>