@wooojin/forgen 0.4.0 → 0.4.3

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 (187) hide show
  1. package/.claude-plugin/plugin.json +5 -5
  2. package/CHANGELOG.md +194 -15
  3. package/CONTRIBUTING.md +2 -2
  4. package/README.ja.md +74 -9
  5. package/README.ko.md +77 -12
  6. package/README.md +127 -25
  7. package/README.zh.md +43 -9
  8. package/assets/README.md +86 -0
  9. package/assets/architecture.svg +100 -0
  10. package/assets/banner.png +0 -0
  11. package/assets/banner.svg +53 -0
  12. package/assets/demo/01-install.gif +0 -0
  13. package/assets/demo/01-install.tape +54 -0
  14. package/assets/demo/02-compound-learning.gif +0 -0
  15. package/assets/demo/02-compound-learning.tape +50 -0
  16. package/assets/demo/03-forge-personalization.gif +0 -0
  17. package/assets/demo/03-forge-personalization.tape +64 -0
  18. package/assets/demo/before-after.gif +0 -0
  19. package/assets/demo/before-after.tape +98 -0
  20. package/assets/demo-preview.svg +96 -0
  21. package/assets/icon.png +0 -0
  22. package/{hooks → assets/shared}/hook-registry.json +2 -1
  23. package/dist/checks/conclusion-verification-ratio.d.ts +37 -0
  24. package/dist/checks/conclusion-verification-ratio.js +86 -0
  25. package/dist/checks/fact-vs-agreement.d.ts +47 -0
  26. package/dist/checks/fact-vs-agreement.js +92 -0
  27. package/dist/checks/self-score-deflation.d.ts +38 -0
  28. package/dist/checks/self-score-deflation.js +108 -0
  29. package/dist/cli.js +98 -6
  30. package/dist/core/auto-compound-runner.js +137 -49
  31. package/dist/core/behavior-classifier.d.ts +28 -0
  32. package/dist/core/behavior-classifier.js +46 -0
  33. package/dist/core/dashboard.d.ts +7 -0
  34. package/dist/core/dashboard.js +41 -2
  35. package/dist/core/doctor.js +118 -5
  36. package/dist/core/extraction-notice.d.ts +18 -0
  37. package/dist/core/extraction-notice.js +64 -0
  38. package/dist/core/git-stats.d.ts +36 -0
  39. package/dist/core/git-stats.js +79 -0
  40. package/dist/core/harness.d.ts +1 -1
  41. package/dist/core/harness.js +27 -20
  42. package/dist/core/host-detect.d.ts +42 -0
  43. package/dist/core/host-detect.js +68 -0
  44. package/dist/core/init-cli.d.ts +26 -0
  45. package/dist/core/init-cli.js +104 -0
  46. package/dist/core/init.js +17 -0
  47. package/dist/core/inspect-cli.js +1 -2
  48. package/dist/core/installer.js +2 -2
  49. package/dist/core/migrate-cli.d.ts +11 -0
  50. package/dist/core/migrate-cli.js +53 -0
  51. package/dist/core/migrate-evidence-host.d.ts +36 -0
  52. package/dist/core/migrate-evidence-host.js +49 -0
  53. package/dist/core/paths.d.ts +8 -1
  54. package/dist/core/paths.js +11 -2
  55. package/dist/core/recall-cli.d.ts +26 -0
  56. package/dist/core/recall-cli.js +125 -0
  57. package/dist/core/recall-reference-detector.d.ts +43 -0
  58. package/dist/core/recall-reference-detector.js +65 -0
  59. package/dist/core/settings-injector.js +4 -2
  60. package/dist/core/spawn.d.ts +1 -1
  61. package/dist/core/spawn.js +4 -11
  62. package/dist/core/stats-cli.d.ts +21 -0
  63. package/dist/core/stats-cli.js +133 -10
  64. package/dist/core/trust-layer-intent.d.ts +35 -0
  65. package/dist/core/trust-layer-intent.js +30 -0
  66. package/dist/core/types.d.ts +1 -1
  67. package/dist/core/uninstall.js +2 -1
  68. package/dist/engine/compound-cli.js +1 -0
  69. package/dist/engine/compound-export.js +8 -3
  70. package/dist/engine/compound-extractor.js +7 -9
  71. package/dist/engine/learn-cli.js +5 -6
  72. package/dist/engine/lifecycle/bypass-detector.d.ts +6 -1
  73. package/dist/engine/lifecycle/bypass-detector.js +57 -5
  74. package/dist/engine/lifecycle/lifecycle-cli.js +4 -4
  75. package/dist/engine/lifecycle/meta-reclassifier.js +3 -3
  76. package/dist/engine/lifecycle/orchestrator.js +2 -2
  77. package/dist/engine/lifecycle/signals.js +6 -6
  78. package/dist/engine/meta-learning/session-quality-scorer.d.ts +1 -6
  79. package/dist/engine/meta-learning/session-quality-scorer.js +2 -21
  80. package/dist/engine/skill-promoter.js +3 -6
  81. package/dist/fgx.js +2 -1
  82. package/dist/forge/evidence-processor.js +12 -0
  83. package/dist/forge/onboarding.d.ts +3 -2
  84. package/dist/forge/onboarding.js +3 -2
  85. package/dist/hooks/context-guard.js +1 -1
  86. package/dist/hooks/dangerous-patterns.json +3 -3
  87. package/dist/hooks/db-guard.js +21 -5
  88. package/dist/hooks/forge-loop-progress.d.ts +9 -0
  89. package/dist/hooks/forge-loop-progress.js +38 -0
  90. package/dist/hooks/hook-registry.js +1 -1
  91. package/dist/hooks/hooks-generator.d.ts +15 -1
  92. package/dist/hooks/hooks-generator.js +18 -16
  93. package/dist/hooks/intent-classifier.js +1 -1
  94. package/dist/hooks/keyword-detector.js +2 -2
  95. package/dist/hooks/notepad-injector.js +1 -1
  96. package/dist/hooks/permission-handler.js +1 -1
  97. package/dist/hooks/post-tool-failure.js +1 -1
  98. package/dist/hooks/post-tool-use.d.ts +7 -1
  99. package/dist/hooks/post-tool-use.js +50 -23
  100. package/dist/hooks/pre-compact.js +2 -2
  101. package/dist/hooks/pre-tool-use.d.ts +7 -0
  102. package/dist/hooks/pre-tool-use.js +28 -10
  103. package/dist/hooks/rate-limiter.js +3 -3
  104. package/dist/hooks/secret-filter.js +1 -1
  105. package/dist/hooks/session-recovery.js +12 -1
  106. package/dist/hooks/shared/blocking-allowlist.d.ts +28 -0
  107. package/dist/hooks/shared/blocking-allowlist.js +38 -0
  108. package/dist/hooks/shared/command-parser.d.ts +44 -0
  109. package/dist/hooks/shared/command-parser.js +50 -0
  110. package/dist/hooks/shared/forge-loop-state.d.ts +36 -0
  111. package/dist/hooks/shared/forge-loop-state.js +116 -0
  112. package/dist/hooks/shared/hook-response.d.ts +30 -2
  113. package/dist/hooks/shared/hook-response.js +61 -3
  114. package/dist/hooks/skill-injector.js +2 -2
  115. package/dist/hooks/slop-detector.js +2 -2
  116. package/dist/hooks/solution-injector.d.ts +9 -0
  117. package/dist/hooks/solution-injector.js +48 -5
  118. package/dist/hooks/stop-guard.js +152 -13
  119. package/dist/hooks/subagent-tracker.js +1 -1
  120. package/dist/host/capabilities-claude.d.ts +8 -0
  121. package/dist/host/capabilities-claude.js +46 -0
  122. package/dist/host/capabilities-codex.d.ts +11 -0
  123. package/dist/host/capabilities-codex.js +50 -0
  124. package/dist/host/capabilities-registry.d.ts +11 -0
  125. package/dist/host/capabilities-registry.js +30 -0
  126. package/dist/host/codex-adapter.d.ts +8 -5
  127. package/dist/host/codex-adapter.js +10 -82
  128. package/dist/host/codex-output-parser.d.ts +39 -0
  129. package/dist/host/codex-output-parser.js +75 -0
  130. package/dist/host/exec-host.d.ts +54 -0
  131. package/dist/host/exec-host.js +92 -0
  132. package/dist/host/host-runtime.d.ts +37 -0
  133. package/dist/host/host-runtime.js +51 -0
  134. package/dist/host/install-claude.d.ts +35 -0
  135. package/dist/host/install-claude.js +238 -0
  136. package/dist/host/install-codex.d.ts +44 -0
  137. package/dist/host/install-codex.js +276 -0
  138. package/dist/host/install-orchestrator.d.ts +34 -0
  139. package/dist/host/install-orchestrator.js +126 -0
  140. package/dist/host/invoke-agent.d.ts +27 -0
  141. package/dist/host/invoke-agent.js +115 -0
  142. package/dist/host/parity-harness.d.ts +62 -0
  143. package/dist/host/parity-harness.js +283 -0
  144. package/dist/host/projection.d.ts +35 -0
  145. package/dist/host/projection.js +126 -0
  146. package/dist/i18n/index.js +3 -5
  147. package/dist/mcp/server.js +11 -0
  148. package/dist/mcp/tools.js +47 -0
  149. package/dist/services/session.d.ts +6 -3
  150. package/dist/services/session.js +33 -4
  151. package/dist/store/evidence-store.d.ts +1 -0
  152. package/dist/store/evidence-store.js +45 -3
  153. package/dist/store/host-mismatch.d.ts +42 -0
  154. package/dist/store/host-mismatch.js +65 -0
  155. package/dist/store/implicit-feedback-store.d.ts +59 -0
  156. package/dist/store/implicit-feedback-store.js +153 -0
  157. package/dist/store/profile-store.d.ts +29 -0
  158. package/dist/store/profile-store.js +53 -0
  159. package/dist/store/rule-store.js +8 -0
  160. package/dist/store/types.d.ts +13 -0
  161. package/hooks/hooks.json +6 -1
  162. package/package.json +7 -5
  163. package/plugin.json +4 -4
  164. package/scripts/postinstall.js +100 -25
  165. /package/{agents → assets/claude/agents}/analyst.md +0 -0
  166. /package/{agents → assets/claude/agents}/architect.md +0 -0
  167. /package/{agents → assets/claude/agents}/code-reviewer.md +0 -0
  168. /package/{agents → assets/claude/agents}/critic.md +0 -0
  169. /package/{agents → assets/claude/agents}/debugger.md +0 -0
  170. /package/{agents → assets/claude/agents}/designer.md +0 -0
  171. /package/{agents → assets/claude/agents}/executor.md +0 -0
  172. /package/{agents → assets/claude/agents}/explore.md +0 -0
  173. /package/{agents → assets/claude/agents}/git-master.md +0 -0
  174. /package/{agents → assets/claude/agents}/planner.md +0 -0
  175. /package/{agents → assets/claude/agents}/solution-evolver.md +0 -0
  176. /package/{agents → assets/claude/agents}/test-engineer.md +0 -0
  177. /package/{agents → assets/claude/agents}/verifier.md +0 -0
  178. /package/{commands → assets/claude/commands}/architecture-decision.md +0 -0
  179. /package/{commands → assets/claude/commands}/calibrate.md +0 -0
  180. /package/{commands → assets/claude/commands}/code-review.md +0 -0
  181. /package/{commands → assets/claude/commands}/compound.md +0 -0
  182. /package/{commands → assets/claude/commands}/deep-interview.md +0 -0
  183. /package/{commands → assets/claude/commands}/docker.md +0 -0
  184. /package/{commands → assets/claude/commands}/forge-loop.md +0 -0
  185. /package/{commands → assets/claude/commands}/learn.md +0 -0
  186. /package/{commands → assets/claude/commands}/retro.md +0 -0
  187. /package/{commands → assets/claude/commands}/ship.md +0 -0
@@ -1,14 +1,14 @@
1
1
  {
2
2
  "$schema": "https://claude.ai/schemas/claude-plugin.json",
3
3
  "name": "forgen",
4
- "version": "0.4.0",
4
+ "version": "0.4.3",
5
5
  "description": "Claude Code harness — the more you use Claude, the better it gets",
6
6
  "author": {
7
7
  "name": "jang-ujin",
8
- "url": "https://github.com/wooo-jin"
8
+ "url": "https://github.com/forgen-team"
9
9
  },
10
- "repository": "https://github.com/wooo-jin/forgen",
11
- "homepage": "https://github.com/wooo-jin/forgen",
10
+ "repository": "https://github.com/forgen-team/forgen",
11
+ "homepage": "https://github.com/forgen-team/forgen",
12
12
  "license": "MIT",
13
13
  "keywords": [
14
14
  "claude-code",
@@ -17,7 +17,7 @@
17
17
  "forge"
18
18
  ],
19
19
  "skills": "./skills/",
20
- "agents": "agents/",
20
+ "agents": "assets/claude/agents/",
21
21
  "statusLine": {
22
22
  "type": "command",
23
23
  "command": "forgen me"
package/CHANGELOG.md CHANGED
@@ -5,6 +5,185 @@ 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.4.3] — 2026-04-30 — Self-correcting hotfix + testbed prep (alpha)
9
+
10
+ forgen-eval introspect testbed (이번 릴리즈에 포함된 자기 측정 시스템) 가
11
+ release-blocker 두 결함을 자가 진단 + fix 까지 한 사이클에 검증한 릴리즈.
12
+ 큰 v0.5.0 testbed-proof 셀링은 실 PASS gate 통과 후로 미루고, 본 릴리즈는
13
+ *hotfix + testbed scaffolding alpha* 로 정직하게 박음.
14
+
15
+ ### Hotfix (forgen body)
16
+
17
+ **TEST-6 — bypass-detector false-positive fix** (`fix`)
18
+ - `src/engine/lifecycle/bypass-detector.ts`: Korean stop list (실행/사용/선언/수행/처리/작성/호출/적용 + 변형) + parens-heuristic 정밀화
19
+ - 기존 root cause: Korean regex `(\S+)\s*(?:말라|금지|하지\s*마|쓰지\s*마)` 가 정책 텍스트 "rm -rf 실행하지 마라" 에서 "실행" 만 추출 → 모든 코드의 "실행" 단어가 false positive (RC5/E9).
20
+ - Parens-heuristic: `(rm -rf, DROP, force-push)` 같은 *예시 목록*은 토큰 추출하되, file path (`tests/e2e/docker/run-test.sh`) 와 exclusion notes (`프로덕션 코드 맥락 한정, 테스트 파일 내 vi.mock 은 제외`) 는 skip.
21
+ - 자기증거: 16일 사용 데이터에서 strict φ 65.66% 의 84% 가 이 단일 버그 (3 L1 rules: no-rm-rf-unconfirmed, e2e-before-done, no-mock-as-proof). 향후 0 false positive 박힘.
22
+
23
+ **TEST-1 — fact-vs-agreement Stop hook wiring** (`fix`)
24
+ - `src/hooks/stop-guard.ts`: `checkFactVsAgreement` import + alert-level invocation. `kind: 'correction'` (no block) — 원 design intent ("alert level only — block 은 TEST-2 에서") 준수.
25
+ - 기존 결함: `src/checks/fact-vs-agreement.ts` 코드 존재했으나 어떤 hook 도 호출 안 함 (forgen-eval introspect 가 발견한 wiring gap).
26
+
27
+ ### Repo / infra
28
+
29
+ **GitHub repo migration** (`chore`)
30
+ - `wooo-jin/forgen` → `forgen-team/forgen` 이전 (1 star + 6 issues 자동 마이그레이션, redirect 자동)
31
+ - npm scope `@wooojin/forgen` 그대로 유지 (npm scope ≠ GitHub org 정상 패턴)
32
+ - 11 파일 URL bulk 갱신 (READMEs + plugin.json + CONTRIBUTING + CHANGELOG + SECURITY)
33
+
34
+ **npm workspaces enable** (`chore`)
35
+ - `"workspaces": ["packages/*"]` 추가 — forgen-eval 같은 부속 alpha package 호스팅용
36
+ - 본 forgen 패키지 무게 영향 0 (peerDep 모델, forgen-eval은 별도 publish)
37
+
38
+ ### Testbed scaffolding (alpha — private workspace)
39
+
40
+ **`@wooojin/forgen-eval@0.4.3-alpha.0` (private, not published)** (`feat`)
41
+ - `packages/forgen-eval/` — forgen 효용 검증 testbed scaffolding
42
+ - 7-축 메트릭: γ_slope (Cohen's d + Wilcoxon r), β_likert, δ/ε/ζ rate, φ Wilson-CI master gate, ψ weighted synergy
43
+ - κ (Cohen's + Fleiss') judge agreement
44
+ - 5 arms (vanilla / forgen-only / claude-mem-only via CLI invoke / forgen+mem / gstack)
45
+ - DEV (Sonnet 4.6 + Qwen + Llama Triple) + PUBLIC (Qwen + Llama Dual) judge tracks
46
+ - vitest 22/22 PASS
47
+
48
+ **`forgen-team/forgen-eval-data` 외부 dataset repo** (`feat`)
49
+ - https://github.com/forgen-team/forgen-eval-data — CC-BY-SA-4.0
50
+ - 10 personas (4 academic + 3 github-issue + 3 forgen-user-anonymized, seed-unreviewed)
51
+ - CURATION.md — 외부 PR 정책 (자체 작성 금지, 2-reviewer 강제)
52
+
53
+ **claude-mem coexistence (Plugin model)** (`design`)
54
+ - ADR-004 amendment — orchestration 가설 폐기, Plugin model 확정 (사용자가 둘 다 별도 plugin install)
55
+ - forgen 본체에 claude-mem 의존성 추가 안 함 (AGPL-3.0 회피)
56
+ - spec §10a — 6 사용자 시나리오 → 메트릭 매핑 narrative
57
+
58
+ ### Documentation
59
+
60
+ - `docs/plans/2026-04-28-forgen-testbed-proof-spec.md` — Deep Interview 11라운드 spec
61
+ - `docs/spike/2026-04-28-claude-mem-spike.md` — claude-mem 실측 (AGPL/Plugin model 발견)
62
+ - `docs/adr/ADR-004/005/006-*.md` — coexistence / module / metrics ADRs
63
+ - `docs/release/v0.5.0-checklist.md` — 미래 v0.5.0 게이트 (이 릴리즈는 *준비*)
64
+
65
+ ### 알려진 한계 — 정직 disclosure
66
+
67
+ **φ master gate 미통과 (current 10.53%, target ≤ 5%)** — 이 릴리즈는 *측정 시스템*이지 *PASS 입증*이 아님:
68
+ - TEST-6 fix 적용으로 strict φ 65.66% → 10.53% (84% reduction). 미래 introspect 사이클에서 추가 감소 예상.
69
+ - 남은 5.53pp 는 user-rule scope 영역 (예: `.then` async/await 룰의 사용자 우회). Pattern bug 아님.
70
+ - 진짜 PASS gate (φ ≤ 5%) 통과 시 v0.5.0 출시.
71
+
72
+ **Self-evidence**: forgen 의 자기 검증 시스템 (`packages/forgen-eval/src/runners/introspect.ts`) 이 자기 자신의 패턴 매칭 버그를 6주 만에 정밀하게 짚어내고 fix 까지 검증한 첫 사이클. v0.4.0 trust restoration 미션이 self-correcting harness 로 한 발자국 더.
73
+
74
+ ### 회귀 검증
75
+ - vitest: 2356/2356 (216 files)
76
+ - bypass-detector: 14/14 (3 RC5/E9 regression 신규)
77
+ - forgen-eval: 22/22
78
+ - Docker e2e: 77/77 (`~/.forgen/state/e2e-result.json` round 14)
79
+ - 회귀: 0
80
+
81
+ ## [0.4.2] - 2026-04-27
82
+
83
+ ### v0.4.2 — Trust hotfix + 학습 회로 4축 확장
84
+
85
+ v0.4.1 이 신뢰 회복 릴리스였다면, v0.4.2 는 **외부 진단(trust-hotfix-report)을 측정으로 검증해 5개 W 를 닫고**, 동시에 v0.4.1 자기 분석에서 발견된 **자동 학습이 4축 중 2축에만 닿는 결함(D1)** 과 **검증 레이어 invariant 부재(P1~P4)** 까지 한 사이클에 통합한 릴리스.
86
+
87
+ **M1 — RC6 가드: forge-loop findings 자동 inject** (`feat`)
88
+ - `src/hooks/shared/forge-loop-state.ts` 신규 — readForgeLoopState / renderForgeLoopForSession / renderForgeLoopForPrompt
89
+ - `session-recovery` (SessionStart) + `forge-loop-progress` (UserPromptSubmit) 신규 hook 이 직전 forge-loop findings 또는 진행 중 stories 를 ≤1KB 로 inject
90
+ - 자기증거: head -80 truncation 으로 directly 유실됐던 사례 invariant 박제
91
+ - Stale 24h soft / 7d hard cap, XML escape
92
+
93
+ **D1'' — auto-compound axis_refs 4축 분류 확장** (`feat`)
94
+ - `src/core/behavior-classifier.ts` 신규 — 5분기 (workflow/thinking/preference + **safety/autonomy** 신규)
95
+ - LLM prompt 카테고리 7종으로 확장 ([품질안전], [자율성] 추가)
96
+ - 결과: behavior_observation 자동 추출이 4축 모두에 닿음 (이전 2축 → 4축)
97
+ - 측정 자기증거: behavior 627건 중 quality 7 / autonomy 6 만 explicit_correction 경로로 들어왔던 결함 해결
98
+
99
+ **P2 — false-positive corpus golden test** (`test`)
100
+ - `tests/invariants/no-false-positive-block.test.ts` (FP1~5 + RC5-E9, 8 케이스)
101
+ - `tests/invariants/true-positive-block.test.ts` (E5/E6 정당 block 5 케이스)
102
+ - 신규 detector CI gate — vitest 가 tests/invariants/* 자동 포함
103
+
104
+ **P3' — Blocking ALLOW-LIST 정책 + denyOrObserve helper** (`feat`)
105
+ - `src/hooks/shared/blocking-allowlist.ts` (4개 멤버: stop-guard / pre-tool-use / secret-filter / db-guard)
106
+ - `denyOrObserve(hookName, reason, observer?)` helper — ALLOW-LIST 외 hook 의 deny 시도가 자동 관찰 모드로 강등
107
+ - 점진 마이그레이션 시작점 (기존 hook 들은 별도 PR)
108
+
109
+ **P4 — fix:feat 비율 셀프 가드** (`feat`)
110
+ - `src/core/git-stats.ts` — 최근 30커밋 fix:feat 비율 측정 (fix(test):/fix(docs): 제외)
111
+ - forgen stats 에 "Repo health" 섹션 + forgen doctor 가 30% 초과 시 경고
112
+ - v0.4.2 릴리즈 시점 측정값: **29%** (정상 범위, ⚠ 미발생)
113
+
114
+ **W1 — 한국어 README 설치 명령 오타 fix** (`fix`)
115
+ - `README.ko.md:86, 146` 의 `npm install -g /forgen` → `@wooojin/forgen`
116
+ - `tests/readme-install-contract.test.ts` 4 로케일 일치 invariant
117
+
118
+ **W2 — 온보딩 2/4 문항 계약 통일** (`fix`)
119
+ - `src/cli.ts:164, 469` 도움말 `2-question` → `4-question`
120
+ - `src/forge/onboarding.ts` 주석 4문항 갱신 + spec 경로 정정 (docs/history/)
121
+ - `tests/onboarding-contract.test.ts` — askChoice 호출 수 vs help text 일치
122
+
123
+ **W3 — agent 인벤토리 12↔13 정렬** (`fix`)
124
+ - `README.md:381` "12 built-in agents" → "13" + ch-solution-evolver Plan-only 표 추가
125
+ - `tests/agent-inventory-contract.test.ts` — agents/ 디렉토리 = README + verify-v3.sh 단일 source
126
+
127
+ **W4 — hooks-generator releaseMode 옵션** (`feat`)
128
+ - `generateHooksJson({ releaseMode: true })` 환경 독립 모드 — plugin 감지 + hook-config 비활성화 모두 무시
129
+ - `prepack-hooks.cjs` 가 releaseMode=true 사용 (HOME swap 도 유지하여 double safety)
130
+ - `tests/hooks-generator-release-mode.test.ts` — mock plugin / mock disable 양쪽 검증
131
+
132
+ **W5 — 하드코딩 → HOOK_REGISTRY.length 동적 read** (`refactor`)
133
+ - 3 자리 (plugin-coexistence / harness-e2e / chain-verification) 의 `21` 하드코딩 제거 → 동적 length
134
+ - `tests/contract-single-source.test.ts` 자체 invariant — 향후 하드코딩 추가 시 자동 fail
135
+ - A3 false-positive 가드: hook-timing/cache-lock-integration 의 다른 의미 20 은 건드리지 않음
136
+
137
+ **D2 — autonomy axis confidence 직접 경로** (`fix`)
138
+ - `bumpAxisConfidence(axis, delta)` — explicit_correction 의 axis_hint 가 즉시 confidence bump
139
+ - `evidence-processor.ts` 에서 호출: avoid-this +0.04, 그 외 +0.02
140
+ - 자기증거: autonomy explicit_correction 6건이 score 못 움직였던 결함 해결
141
+ - facet 값은 안 건드리고 confidence 만 — 회귀 위험 최소
142
+
143
+ **자기증거 박제** (`docs`)
144
+ - `docs/issues/D2-autonomy-facet-stuck.md` — D2 root cause 추적
145
+ - `docs/issues/W4-W5-self-evidence.md` — 본 forge-loop 1차에서 W4/W5 antipattern 을 단기 회피로 재생산한 사례 (RC7 후보)
146
+ - compound 4 박제: rc6-meta-amnesia, rc7-diagnostic-self-fix, validator-layer-invariant, interview-axes-disconnect-RETRACTED
147
+
148
+ **회귀**:
149
+ - vitest **2215/2215** (199 files, 신규 13 테스트 파일)
150
+ - Docker e2e **77/77 + ALL CHECKS PASSED** (round 12, mock_detected:false)
151
+ - typecheck 0
152
+
153
+ **Outstanding (별도 PR)**: P3' enforcement 의 기존 hook 마이그레이션, prepack-hooks.cjs 의 HOME swap 단순화
154
+
155
+ ---
156
+
157
+ ## [0.4.1] - 2026-04-24
158
+
159
+ ### v0.4.1 — 하네스가 당신을 담고 간다
160
+
161
+ v0.4.0 이 Trust Layer (Claude 가 "완료"라고 하면 forgen 이 증명하게 한다) 를 세웠다면, v0.4.1 은 **구매자가 첫 block 을 즉시 경험**하고 **README 만 봐도 "하네스가 당신을 담고 간다" 는 비전을 이해**하게 만드는 릴리스. 내부적으로는 직전 회차에서 scope-out 했던 측정 갭 3건을 정직하게 재평가 → 실제로 닫았고, 10 시나리오 실 Claude signal 누적으로 검증.
162
+
163
+ **3개 구조적 갭 마감** (`feat`)
164
+ - `recall_referenced` 측정: name literal 단일 매칭 → identifier / 복합 태그 2개 교차 fallback 추가. Claude 가 slug 이름 대신 solution content 만 인용해도 잡힘. 일반 단어 단독은 false-positive 방지 위해 제외.
165
+ - `Rule.lifecycle` 자동 초기화: `saveRule` 이 lifecycle 없으면 `phase='active'` + counters=0 주입. suppressed rule 의 audit trail (누가 언제 왜) 추적 가능.
166
+ - `forgen compound list` 출력: `inj: / ref: / neg:` 컬럼에 "ref 측정은 v0.4.1+ 부터 시작됨" 주석. legacy 데이터 `ref:0` 을 "도움 안 됨" 으로 오독하는 혼란 해소.
167
+
168
+ **README 리프레시** (`docs`)
169
+ - **The harness carries you 섹션 신설**: "대화 → 추출 → 주입 → 반복" cycle + `forgen compound export/import` (개인 철학 번들을 tar.gz 로 이식) 연결. forgen 을 "rule 주입 tool" 로 축소 해석하는 오독 해소.
170
+ - 한국어/일본어/중국어 README 동기화 ("하네스가 당신을 담고 간다" / "ハーネスがあなたを運ぶ" / "这个 harness 装载的是你").
171
+ - **The first block 데모 일반화**: forgen-repo 전용 L1 rule → v0.4.1 내장 `builtin:self-score-inflation` (TEST-2) 기반 일반 시나리오로 교체. 구매자가 rule 작성 없이도 첫 block 을 바로 체감.
172
+ - Commands 섹션에 `forgen recall` / `forgen migrate` / `forgen init` 추가.
173
+ - Cold-start boost 설명: champion/active 솔루션 < 5 이면 `MIN_INJECT_RELEVANCE` 0.3 → 0.2 완화.
174
+
175
+ **natural-accumulation e2e** (`test`)
176
+ - 격리 `FORGEN_HOME` + 실 Claude API 10 시나리오로 "시간이 답" 이던 open signal 4종을 수십 분 내 실증:
177
+ - `recall_referenced` 0 → 2 (33% 참조율)
178
+ - `recommendation_surfaced` 1 → 6 (60% 주입률, cold-start boost 실효 확인)
179
+ - TEST-2 자연 block 0 → 3
180
+ - TEST-3 자연 block 0 → 2
181
+ - hook-errors 0 (전 경로 clean)
182
+
183
+ **회귀**: vitest 2114/2114 (신규 테스트 4건 포함). typecheck 0.
184
+
185
+ ---
186
+
8
187
  ## [0.4.0] - 2026-04-23
9
188
 
10
189
  ### v0.4.0 — The Trust Layer
@@ -434,7 +613,7 @@ Three-phase evolution loop around the existing compound solution store:
434
613
  - **Pack Marketplace** — GitHub-based community pack sharing
435
614
  - `forgen pack publish <name>` — publish verified solutions to GitHub + registry PR
436
615
  - `forgen pack search <query>` — search community registry
437
- - Registry: [wooo-jin/forgen-registry](https://github.com/wooo-jin/forgen-registry)
616
+ - Registry: [forgen-team/forgen-registry](https://github.com/forgen-team/forgen-registry)
438
617
  - **Lab compound events** — 6 new event types (compound-injected, compound-reflected, compound-negative, compound-extracted, compound-promoted, compound-demoted)
439
618
  - 83 new tests (solution-format, prompt-injection-filter, solution-index, compound-lifecycle, compound-extractor)
440
619
 
@@ -605,17 +784,17 @@ Three-phase evolution loop around the existing compound solution store:
605
784
  - Bilingual documentation (EN/KO)
606
785
  - Core CLI commands: `fgx` entrypoint
607
786
 
608
- [Unreleased]: https://github.com/wooo-jin/forgen/compare/v3.0.0...HEAD
609
- [3.0.0]: https://github.com/wooo-jin/forgen/compare/v2.1.0...v3.0.0
610
- [2.1.0]: https://github.com/wooo-jin/forgen/compare/v2.0.0...v2.1.0
611
- [2.0.0]: https://github.com/wooo-jin/forgen/compare/v1.7.0...v2.0.0
612
- [1.7.0]: https://github.com/wooo-jin/forgen/compare/v1.6.3...v1.7.0
613
- [1.6.3]: https://github.com/wooo-jin/forgen/compare/v1.6.2...v1.6.3
614
- [1.6.2]: https://github.com/wooo-jin/forgen/compare/v1.6.1...v1.6.2
615
- [1.6.1]: https://github.com/wooo-jin/forgen/compare/v1.6.0...v1.6.1
616
- [1.6.0]: https://github.com/wooo-jin/forgen/compare/v1.4.0...v1.6.0
617
- [1.4.0]: https://github.com/wooo-jin/forgen/compare/v1.3.0...v1.4.0
618
- [1.3.0]: https://github.com/wooo-jin/forgen/compare/v1.1.0...v1.3.0
619
- [1.1.0]: https://github.com/wooo-jin/forgen/compare/v1.0.1...v1.1.0
620
- [1.0.1]: https://github.com/wooo-jin/forgen/compare/v1.0.0...v1.0.1
621
- [1.0.0]: https://github.com/wooo-jin/forgen/releases/tag/v1.0.0
787
+ [Unreleased]: https://github.com/forgen-team/forgen/compare/v3.0.0...HEAD
788
+ [3.0.0]: https://github.com/forgen-team/forgen/compare/v2.1.0...v3.0.0
789
+ [2.1.0]: https://github.com/forgen-team/forgen/compare/v2.0.0...v2.1.0
790
+ [2.0.0]: https://github.com/forgen-team/forgen/compare/v1.7.0...v2.0.0
791
+ [1.7.0]: https://github.com/forgen-team/forgen/compare/v1.6.3...v1.7.0
792
+ [1.6.3]: https://github.com/forgen-team/forgen/compare/v1.6.2...v1.6.3
793
+ [1.6.2]: https://github.com/forgen-team/forgen/compare/v1.6.1...v1.6.2
794
+ [1.6.1]: https://github.com/forgen-team/forgen/compare/v1.6.0...v1.6.1
795
+ [1.6.0]: https://github.com/forgen-team/forgen/compare/v1.4.0...v1.6.0
796
+ [1.4.0]: https://github.com/forgen-team/forgen/compare/v1.3.0...v1.4.0
797
+ [1.3.0]: https://github.com/forgen-team/forgen/compare/v1.1.0...v1.3.0
798
+ [1.1.0]: https://github.com/forgen-team/forgen/compare/v1.0.1...v1.1.0
799
+ [1.0.1]: https://github.com/forgen-team/forgen/compare/v1.0.0...v1.0.1
800
+ [1.0.0]: https://github.com/forgen-team/forgen/releases/tag/v1.0.0
package/CONTRIBUTING.md CHANGED
@@ -5,7 +5,7 @@ Thank you for your interest in contributing! forgen is a philosophy-driven Claud
5
5
  ## Quick Start
6
6
 
7
7
  ```bash
8
- git clone https://github.com/wooo-jin/forgen.git
8
+ git clone https://github.com/forgen-team/forgen.git
9
9
  cd forgen
10
10
  npm install
11
11
  npm run build
@@ -95,4 +95,4 @@ forgen is built around five principles: `understand-before-act`, `decompose-to-c
95
95
 
96
96
  ## Questions
97
97
 
98
- Open a [GitHub Issue](https://github.com/wooo-jin/forgen/issues) for questions, bug reports, or feature proposals.
98
+ Open a [GitHub Issue](https://github.com/forgen-team/forgen/issues) for questions, bug reports, or feature proposals.
package/README.ja.md CHANGED
@@ -1,5 +1,5 @@
1
1
  <p align="center">
2
- <img src="https://raw.githubusercontent.com/wooo-jin/forgen/main/assets/banner.png" alt="Forgen" width="100%"/>
2
+ <img src="https://raw.githubusercontent.com/forgen-team/forgen/main/assets/banner.png" alt="Forgen" width="100%"/>
3
3
  </p>
4
4
 
5
5
  <p align="center">
@@ -15,6 +15,7 @@
15
15
 
16
16
  <p align="center">
17
17
  <a href="#最初のブロック-30秒">最初のブロック</a> &middot;
18
+ <a href="#ハーネスがあなたを運ぶ">ビジョン</a> &middot;
18
19
  <a href="#クイックスタート">クイックスタート</a> &middot;
19
20
  <a href="#仕組み">仕組み</a> &middot;
20
21
  <a href="#4軸パーソナライゼーション">4軸</a> &middot;
@@ -74,6 +75,31 @@ asciinema play docs/demo/mech-b-block-unblock.cast
74
75
 
75
76
  上記の Trust Layer は柱の1つです。もう1つはパーソナライゼーション — 最初のブロック後に forgen を使い続ける理由です。
76
77
 
78
+ ---
79
+
80
+ ## ハーネスがあなたを運ぶ
81
+
82
+ パーソナライゼーションは表面です。より深いアイデア: **すべてのセッションが痕跡を残し、その痕跡が蓄積されてあなたのように判断するハーネスになります。** 修正、規約、トレードオフの好み — 会話から抽出され、`~/.forgen/me/` に保存され、次のセッションで Claude に再注入されます。
83
+
84
+ ```
85
+ 会話 ──► 抽出: solution / rule / behavior / profile 更新
86
+ ────────────────────────────────────────────
87
+
88
+
89
+ 次のセッション ◄── 注入: UserPromptSubmit コンテキスト + レンダリングされた
90
+ ルール + あなたの基準に合わせた Stop-hook ガード
91
+ ```
92
+
93
+ 数週間経つと、このハーネスは「ルールを強制するツール」ではなく、**あなたが仕事を判断する方法が詰まった持ち運べるバンドル** になります。一行で export:
94
+
95
+ ```bash
96
+ forgen compound export # → forgen-knowledge-YYYY-MM-DD.tar.gz
97
+ # (rules + solutions + behavior — あなたの哲学)
98
+ forgen compound import <path> # 別のマシンで再現
99
+ ```
100
+
101
+ これが北極星: *ノートパソコン上で、あなたのように判断する Claude と、持ち運べる tarball.*
102
+
77
103
  開発者 A は慎重派です。Claude にすべてのテストを実行させ、理由を説明させ、現在のファイル以外を変更する前に必ず確認を求めます。
78
104
 
79
105
  開発者 B はスピード重視です。Claude に前提を置いて判断させ、関連ファイルも直接修正させ、結果を2行で報告させます。
@@ -156,22 +182,61 @@ Claude が `correction-record` MCP ツールを呼び出します。修正は、
156
182
  ## クイックスタート
157
183
 
158
184
  ```bash
159
- # 1. インストール
185
+ # 1. インストール (グローバル CLI なので必ず -g)
160
186
  npm install -g @wooojin/forgen
161
187
 
162
- # 2. 初回実行4問オンボーディング(英語/韓国語選択)
163
- forgen
188
+ # 2. ホスト登録Claude Code / Codex / 両方
189
+ forgen install both # 3択インタラクティブ: claude / codex / both
190
+ # または非対話:
191
+ forgen install claude
192
+ forgen install codex
164
193
 
165
- # 3. 以降毎日
166
- forgen
194
+ # 3. 初回実行 — 4問オンボーディング (英語/韓国語選択)
195
+ forgen # デフォルト: Claude
196
+ forgen --runtime codex # Codex で実行
197
+ forgen config default-host codex # 永続デフォルトホスト設定
167
198
  ```
168
199
 
169
200
  ### 前提条件
170
201
 
171
- - **Node.js** >= 20SQLite セッション検索には >= 22 を推奨)
172
- - **Claude Code** インストール・認証済み(`npm i -g @anthropic-ai/claude-code`)
202
+ - **Node.js** >= 20 (SQLite セッション検索には >= 22 を推奨)
203
+ - **少なくとも 1 つのホスト** インストール・認証済み:
204
+ - **Claude Code** — `npm i -g @anthropic-ai/claude-code`
205
+ - **Codex CLI** — [Codex docs](https://github.com/openai/codex) を参照
206
+ - 両方利用可 — `forgen install both` が両方に hook/MCP を対称登録
207
+
208
+ > **ベンダー依存:** forgen は Claude Code と Codex CLI を対称ラップします (Claude が動作基準、Codex が同等性拡張)。上流 API/CLI の変更が動作に影響する可能性があります。Claude Code 1.0.x / 2.1.x、Codex 0.x でテスト済み。
209
+
210
+ ### 隔離 / CI / Docker での利用
211
+
212
+ forgen のホームはデフォルト `~/.forgen` ですが、プロセス毎に上書き可能:
213
+
214
+ ```bash
215
+ # クリーンな隔離ホーム — 実 ~/.forgen は触らない
216
+ FORGEN_HOME=/tmp/forgen-clean forgen init # starter-pack 15件を自動配置
217
+ FORGEN_HOME=/tmp/forgen-clean forgen stats # 隔離ホームの統計のみ表示
218
+ FORGEN_HOME=/tmp/forgen-clean claude -p "…" # フックが env を継承 → ログ隔離
219
+ ```
220
+
221
+ Claude Code のフックプロセスは親 env を継承するため、`FORGEN_HOME=...` プレ
222
+ フィックス一つで全状態 (rules/solutions/behavior/enforcement) がそのディレ
223
+ クトリに隔離されます。用途:
224
+
225
+ - CI パイプラインで固定シードに対する forgen 検証
226
+ - 実ホーム汚染なしの「新規ユーザー初日体験」再現
227
+ - 1 台のマシンで複数ペルソナ運用
228
+
229
+ **Docker / リモートサーバー (OAuth 制約):** Claude Code は OAuth セッションを
230
+ **OS キーチェーン** (macOS Keychain / libsecret / Windows Credential Manager)
231
+ に保存するため、新規 Linux コンテナで `~/.claude.json` のみマウントしても
232
+ refresh トークンが無く認証できません。コンテナ環境では `ANTHROPIC_API_KEY`
233
+ env を使ってください。ホスト環境 (macOS/Linux ワークステーション) は通常の
234
+ `claude login` フローで動作 — API キー不要。
235
+
236
+ ### マイグレーション
173
237
 
174
- > **ベンダー依存:** forgen Claude Code をラップします。Anthropic API または Claude Code の変更が動作に影響する可能性があります。Claude Code 1.0.x でテスト済みです。
238
+ `forgen migrate implicit-feedback` pre-v0.4.1 ログの `category` フィールド
239
+ バックフィル。冪等 (idempotent) — 複数回実行しても安全。
175
240
 
176
241
  ---
177
242
 
package/README.ko.md CHANGED
@@ -1,5 +1,5 @@
1
1
  <p align="center">
2
- <img src="https://raw.githubusercontent.com/wooo-jin/forgen/main/assets/banner.png" alt="Forgen" width="100%"/>
2
+ <img src="https://raw.githubusercontent.com/forgen-team/forgen/main/assets/banner.png" alt="Forgen" width="100%"/>
3
3
  </p>
4
4
 
5
5
  <p align="center">
@@ -14,6 +14,7 @@
14
14
  </p>
15
15
 
16
16
  <p align="center">
17
+ <a href="#하네스가-당신을-담고-간다">비전</a> &middot;
17
18
  <a href="#forgen를-쓰면-일어나는-일">동작 흐름</a> &middot;
18
19
  <a href="#빠른-시작">빠른 시작</a> &middot;
19
20
  <a href="#동작-방식">동작 방식</a> &middot;
@@ -52,12 +53,37 @@ forgen가 이것을 가능하게 합니다. 작업 스타일을 프로파일링
52
53
 
53
54
  ---
54
55
 
56
+ ## 하네스가 당신을 담고 간다
57
+
58
+ 개인화는 표면입니다. 더 깊은 아이디어: **매 세션이 흔적을 남기고, 그 흔적들이 쌓여 당신처럼 판단하는 하네스가 됩니다.** 교정, 컨벤션, 트레이드오프 선호 — 대화에서 추출되어 `~/.forgen/me/` 에 저장되고, 다음 세션마다 Claude 에 다시 주입됩니다.
59
+
60
+ ```
61
+ 대화 ──► 추출: solution / rule / behavior / profile 업데이트
62
+ ──────────────────────────────────────────────
63
+
64
+
65
+ 다음 세션 ◄── 주입: UserPromptSubmit 컨텍스트 + 렌더된 규칙
66
+ + 당신의 기준에 맞춘 Stop-hook 가드
67
+ ```
68
+
69
+ 몇 주가 지나면 이 하네스는 "규칙을 강제하는 도구"가 아니라 **당신이 일을 판단하는 방식이 담긴 휴대 가능한 번들** 이 됩니다. 한 줄로 export:
70
+
71
+ ```bash
72
+ forgen compound export # → forgen-knowledge-YYYY-MM-DD.tar.gz
73
+ # (rules + solutions + behavior — 당신의 철학)
74
+ forgen compound import <path> # 다른 머신에서 그대로 재연
75
+ ```
76
+
77
+ 그게 북극성입니다: *노트북 위에 있는, 당신처럼 판단하는 Claude, 그리고 들고 다닐 수 있는 tarball.*
78
+
79
+ ---
80
+
55
81
  ## forgen를 쓰면 일어나는 일
56
82
 
57
83
  ### 첫 실행 (1회, 약 1분)
58
84
 
59
85
  ```bash
60
- npm install -g /forgen
86
+ npm install -g @wooojin/forgen
61
87
  forgen
62
88
  ```
63
89
 
@@ -116,22 +142,61 @@ Claude가 `correction-record` MCP 도구를 호출합니다. 교정은 축 분
116
142
  ## 빠른 시작
117
143
 
118
144
  ```bash
119
- # 1. 설치
120
- npm install -g /forgen
121
-
122
- # 2. 실행4문항 온보딩 (영어/한국어 선택)
123
- forgen
124
-
125
- # 3. 이후 매일
126
- forgen
145
+ # 1. 설치 (반드시 -g — forgen 은 글로벌 CLI)
146
+ npm install -g @wooojin/forgen
147
+
148
+ # 2. 호스트 등록Claude Code / Codex / 양쪽
149
+ forgen install both # 3지선다 인터랙티브: claude / codex / both
150
+ # 또는 비대화형:
151
+ forgen install claude
152
+ forgen install codex
153
+
154
+ # 3. 첫 실행 — 4문항 온보딩 (영어/한국어 선택)
155
+ forgen # 기본: Claude
156
+ forgen --runtime codex # Codex 로 실행
157
+ forgen config default-host codex # 영구 기본 호스트 설정
127
158
  ```
128
159
 
129
160
  ### 사전 요구사항
130
161
 
131
162
  - **Node.js** >= 20 (SQLite 세션 검색은 >= 22 권장)
132
- - **Claude Code** 설치 및 인증 (`npm i -g @anthropic-ai/claude-code`)
163
+ - **하나 이상의 호스트** 설치 및 인증:
164
+ - **Claude Code** — `npm i -g @anthropic-ai/claude-code`
165
+ - **Codex CLI** — [Codex docs](https://github.com/openai/codex) 참고
166
+ - 둘 다 사용 가능 — `forgen install both` 가 양쪽에 hook/MCP 를 대칭 등록
167
+
168
+ > **벤더 의존성:** forgen 은 Claude Code 와 Codex CLI 를 대칭 래핑합니다 (Claude 가 동작 기준, Codex 가 동등성 확장). 상위 API/CLI 변경이 동작에 영향을 줄 수 있습니다. Claude Code 1.0.x / 2.1.x, Codex 0.x 에서 테스트됨.
169
+
170
+ ### 격리 / CI / Docker 사용
171
+
172
+ forgen 홈은 기본 `~/.forgen` 이지만 프로세스별 override 가능:
173
+
174
+ ```bash
175
+ # 깨끗한 격리 홈 — 실제 ~/.forgen 은 건드리지 않음
176
+ FORGEN_HOME=/tmp/forgen-clean forgen init # starter-pack 15개 자동 배포
177
+ FORGEN_HOME=/tmp/forgen-clean forgen stats # 격리 홈의 통계만 표시
178
+ FORGEN_HOME=/tmp/forgen-clean claude -p "…" # 훅이 env 상속 → 격리된 로그
179
+ ```
180
+
181
+ Claude Code 훅 프로세스가 부모 env 를 상속하므로 `FORGEN_HOME=...` 프리픽스
182
+ 하나면 모든 상태(rules/solutions/behavior/enforcement)가 해당 디렉터리로 격리.
183
+ 쓰임새:
184
+
185
+ - CI 파이프라인에서 고정 시드로 forgen 검증
186
+ - 실 홈 오염 없이 "신규 사용자 첫날 경험" 재현
187
+ - 한 머신에서 여러 페르소나 운영
188
+
189
+ **Docker / 원격 서버 (OAuth 제약):** Claude Code 는 OAuth 세션을 **OS 키체인**
190
+ (macOS Keychain / libsecret / Windows Credential Manager) 에 저장하므로, 새
191
+ Linux 컨테이너에서 `~/.claude.json` 만 마운트하면 refresh 토큰이 없어서 인증이
192
+ 안 됩니다. 컨테이너 환경에서는 `ANTHROPIC_API_KEY` env 를 사용하세요. 호스트
193
+ 기반 사용(macOS/Linux 워크스테이션) 은 `claude login` 흐름 그대로 동작 — API
194
+ 키 불필요.
195
+
196
+ ### 마이그레이션
133
197
 
134
- > **벤더 의존성:** forgen Claude Code를 래핑합니다. Anthropic API 또는 Claude Code 변경이 동작에 영향을 줄 수 있습니다. Claude Code 1.0.x 기준으로 테스트되었습니다.
198
+ `forgen migrate implicit-feedback` pre-v0.4.1 로그의 `category` 필드 백필.
199
+ 멱등(idempotent) — 여러 번 실행 안전.
135
200
 
136
201
  ---
137
202