forgedock 1.0.15 → 1.0.17

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 (71) hide show
  1. package/README.md +82 -60
  2. package/bin/forgedock.mjs +1992 -540
  3. package/bin/github-app-manifest.json.license +2 -0
  4. package/bin/hooks/session-start.mjs +4 -5
  5. package/bin/registry.mjs +20 -0
  6. package/bin/tui.mjs +172 -96
  7. package/commands/adopt.md +433 -0
  8. package/commands/analytics.md +2 -0
  9. package/commands/audit-agents.md +2 -0
  10. package/commands/audit.md +2 -0
  11. package/commands/changelog.md +354 -0
  12. package/commands/cleanup.md +2 -0
  13. package/commands/compat-audit.md +330 -0
  14. package/commands/deploy-info.md +6 -5
  15. package/commands/diagnose.md +483 -0
  16. package/commands/explain.md +349 -0
  17. package/commands/forge-stats.md +2 -0
  18. package/commands/forgedock-init.md +2 -0
  19. package/commands/geo-audit.md +2 -0
  20. package/commands/incident-response.md +2 -0
  21. package/commands/issue.md +2 -0
  22. package/commands/milestone.md +2 -0
  23. package/commands/optimize.md +411 -0
  24. package/commands/orchestrate.md +118 -0
  25. package/commands/pipeline-health.md +60 -1
  26. package/commands/qa-sweep.md +2 -0
  27. package/commands/quality-gate.md +37 -0
  28. package/commands/replay.md +263 -0
  29. package/commands/resume.md +264 -0
  30. package/commands/review-pr-agents.md +5 -1
  31. package/commands/review-pr-staging.md +2 -0
  32. package/commands/review-pr.md +85 -3
  33. package/commands/rollback.md +2 -0
  34. package/commands/scope.md +280 -0
  35. package/commands/security-audit.md +2 -0
  36. package/commands/status.md +262 -0
  37. package/commands/sync-ecosystem.md +2 -0
  38. package/commands/validate.md +2 -0
  39. package/commands/work-on/build/architect.md +128 -18
  40. package/commands/work-on/build/context.md +130 -17
  41. package/commands/work-on/build/implement.md +2 -0
  42. package/commands/work-on/build/validate.md +2 -0
  43. package/commands/work-on/build.md +32 -7
  44. package/commands/work-on/close.md +85 -0
  45. package/commands/work-on/decompose.md +2 -0
  46. package/commands/work-on/investigate.md +30 -3
  47. package/commands/work-on/review.md +13 -1
  48. package/commands/work-on-monolithic.md +2 -0
  49. package/commands/work-on.md +624 -36
  50. package/docs/BRAND.md +51 -0
  51. package/docs/CONFIG.md +94 -0
  52. package/docs/articles/per-repo-adaptive-scripts-token-savings.md +174 -0
  53. package/docs/claude-breakpoints.json +47 -0
  54. package/docs/site/getting-started.md +21 -0
  55. package/package.json +10 -2
  56. package/scripts/classify-lane.sh +145 -0
  57. package/scripts/transition-label.sh +161 -0
  58. package/scripts/validate-pr-target.sh +30 -0
  59. package/templates/devdocs/README.md +72 -0
  60. package/templates/devdocs/agent/using-forgedock.md +3 -0
  61. package/templates/devdocs/agent/using-github.md +3 -0
  62. package/templates/devdocs/index.yaml +162 -0
  63. package/templates/devdocs/project/architecture.md +3 -0
  64. package/templates/devdocs/project/conventions.md +3 -0
  65. package/templates/devdocs/project/custom-instructions.md +3 -0
  66. package/templates/devdocs/project/glossary.md +3 -0
  67. package/templates/devdocs/project/stack.md +3 -0
  68. package/templates/devdocs/templates/commit-convention.md +3 -0
  69. package/templates/devdocs/templates/issue.md +3 -0
  70. package/templates/devdocs/templates/pull-request.md +3 -0
  71. package/templates/devdocs/templates/review-finding.md +3 -0
package/README.md CHANGED
@@ -4,23 +4,23 @@
4
4
 
5
5
  <h1>ForgeDock</h1>
6
6
 
7
- <p><strong>Give Claude Code a memory that survives every session.</strong></p>
7
+ <p><strong>Autonomous software development for Claude Code.</strong></p>
8
8
 
9
- <p>ForgeDock turns GitHub into a persistent knowledge graph for AI agents. Every pipeline stage writes structured annotations to issues and PRs — so the next agent always knows what happened, why the code looks this way, and what to do next.</p>
9
+ <p>ForgeDock turns every bug found, every fix shipped, and every review finding into structured context that makes the next agent smarter. It catches integration bugs that code review can't see — missing route registrations, env vars present in CI but absent in deploy, Docker permission mismatches, sibling code paths left unfixed. Every finding feeds back as a prevention rule for future builds. After thousands of issues on production codebases, the system catches bugs before they reach a testing branch.</p>
10
10
 
11
- <a href="https://www.npmjs.com/package/forgedock"><img src="https://img.shields.io/npm/dm/forgedock?label=npm%20downloads&color=CB3837" alt="npm downloads/month" /></a>
12
- <a href="https://www.npmjs.com/package/forgedock"><img src="https://img.shields.io/npm/v/forgedock?color=CB3837" alt="npm version" /></a>
13
- <a href="https://nodejs.org/"><img src="https://img.shields.io/node/v/forgedock?color=339933" alt="node version" /></a>
14
- <a href="https://docs.anthropic.com/en/docs/claude-code"><img src="https://img.shields.io/badge/Built%20for-Claude%20Code-7C3AED" alt="Claude Code" /></a>
15
- <a href="LICENSE"><img src="https://img.shields.io/badge/License-AGPL--3.0-blue.svg" alt="License: AGPL-3.0" /></a>
16
- <a href="https://github.com/RapierCraftStudios/ForgeDock/pulls"><img src="https://img.shields.io/badge/PRs-welcome-brightgreen.svg" alt="PRs Welcome" /></a>
17
- <a href="https://github.com/sponsors/RapierCraftStudios"><img src="https://img.shields.io/badge/Sponsor-%E2%9D%A4-ea4aaa.svg" alt="Sponsor" /></a>
11
+ <a href="https://www.npmjs.com/package/forgedock"><img src="https://img.shields.io/npm/dm/forgedock?label=npm%20downloads&style=flat-square&color=CB3837" alt="npm downloads/month" /></a>&nbsp;
12
+ <a href="https://www.npmjs.com/package/forgedock"><img src="https://img.shields.io/npm/v/forgedock?style=flat-square&color=CB3837" alt="npm version" /></a>&nbsp;
13
+ <a href="https://nodejs.org/"><img src="https://img.shields.io/node/v/forgedock?style=flat-square&color=339933" alt="node version" /></a>&nbsp;
14
+ <a href="https://docs.anthropic.com/en/docs/claude-code"><img src="https://img.shields.io/badge/Built%20for-Claude%20Code-7C3AED?style=flat-square" alt="Claude Code" /></a>
15
+ <br />
16
+ <a href="LICENSE"><img src="https://img.shields.io/badge/License-AGPL--3.0-blue.svg?style=flat-square" alt="License: AGPL-3.0" /></a>&nbsp;
17
+ <a href="https://github.com/RapierCraftStudios/ForgeDock/pulls"><img src="https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square" alt="PRs Welcome" /></a>
18
18
 
19
19
  <br /><br />
20
20
 
21
- <img src="docs/demo.gif" alt="ForgeDock demo — issue to merged PR in one command" width="900" />
21
+ <img src="docs/demo.gif" alt="ForgeDock demo — parallel orchestration across 15+ issues" width="900" />
22
22
 
23
- <p><em>One command. Issue to merged PR — investigated, built, reviewed, and shipped.</em></p>
23
+ <p><em>15+ issues orchestrated in parallel — investigated, built, reviewed, and shipped autonomously.</em></p>
24
24
 
25
25
  </div>
26
26
 
@@ -30,9 +30,21 @@
30
30
 
31
31
  AI coding agents forget everything between sessions. They re-investigate the same bugs, miss context from past PRs, and make mistakes that were already caught and fixed last week. There's no institutional memory.
32
32
 
33
- ForgeDock fixes this by using **GitHub itself** as the memory layer. Every pipeline stage writes structured `FORGE:` annotations to issues and PRs. Every downstream agent reads them. When a new session starts — even after compaction — the agent queries GitHub and picks up exactly where the last one left off.
33
+ ForgeDock fixes this by using **GitHub itself** as the memory layer. Every pipeline stage writes structured `FORGE:` annotations to issues and PRs. Every downstream agent reads them. When a new session starts — even after Claude's context resets — the agent queries GitHub and picks up exactly where the last one left off.
34
+
35
+ ---
36
+
37
+ ## How Is This Different
38
+
39
+ ForgeDock is **not another AI coding agent.** It's a set of prompt-engineered command specs (`.md` files) that run inside Claude Code. No new runtime, no separate process, no vendor lock-in beyond what you already use.
34
40
 
35
- **The result:** agents that follow structured data instead of guessing.
41
+ | | ForgeDock | Plain Claude Code | Cursor / Windsurf | Devin / Sweep |
42
+ |---|---|---|---|---|
43
+ | Memory across sessions | Structured annotations on GitHub | CLAUDE.md + manual notes | Per-project context | Proprietary cloud state |
44
+ | Autonomous pipeline | Full lifecycle: investigate → merge | Manual, step by step | Autocomplete + chat | Autonomous but opaque |
45
+ | Review quality | 9 domain-specialist agents | You review everything | Basic suggestions | Varies |
46
+ | Infrastructure needed | None — just `npx forgedock` | None | IDE-specific | Cloud service |
47
+ | Codebase visibility | Everything stays on GitHub | Local | Local + cloud sync | Cloud-only |
36
48
 
37
49
  ---
38
50
 
@@ -41,27 +53,59 @@ ForgeDock fixes this by using **GitHub itself** as the memory layer. Every pipel
41
53
  | Capability | How it works |
42
54
  |---|---|
43
55
  | **Full-lifecycle automation** | `/work-on #42` — investigates the issue, architects a fix, builds it, runs quality gates, opens a PR, and reviews it. You click merge. |
44
- | **Persistent agent memory** | Structured `FORGE:` annotations on GitHub issues/PRs survive compaction and session boundaries. Agents never start blind. |
56
+ | **Persistent agent memory** | Structured `FORGE:` annotations on GitHub issues/PRs survive context resets and session boundaries. Agents never start blind. |
45
57
  | **9 specialist review agents** | Security, billing, database, concurrency, auth, frontend, API, performance, infrastructure — every PR gets domain-expert review. |
46
58
  | **Cross-issue knowledge graph** | Agent fixing issue #43 reads the investigation from #42 and applies the known pattern — no re-investigation. |
47
- | **Self-improving pipeline** | False positive rate dropped from 44% to under 10% through automated feedback loops. |
59
+ | **Self-improving pipeline** | Review agents learn from past findings — recurring patterns automatically become new quality gate checks. |
48
60
  | **Parallel orchestration** | `/orchestrate` decomposes milestones into waves and runs `/work-on` on each in parallel. |
49
61
 
62
+ > **Cost note:** ForgeDock itself is free and open-source. It orchestrates Claude Code sessions, so you pay your normal Anthropic API usage. A typical `/work-on` run on a straightforward bug uses roughly the same tokens as a 15–20 minute manual Claude Code session.
63
+
64
+ <details>
65
+ <summary><strong>See a real pipeline run</strong></summary>
66
+
67
+ Here's what a real run looks like on [issue #619](https://github.com/RapierCraftStudios/ForgeDock/issues/619) — a performance bug where command specs were burning ~200K tokens in context:
68
+
69
+ ```
70
+ FORGE:INVESTIGATOR → CONFIRMED. All 27 command spec files (848KB) load into
71
+ context at session start via symlinks. ~200K tokens wasted.
72
+
73
+ FORGE:CONTRACT → Replace symlink-based install with stub-file pattern.
74
+ Installer parses frontmatter, writes minimal stubs.
75
+
76
+ FORGE:CONTEXT → Issue #577: install() had overly broad catch{} — fixed to
77
+ check err.code === 'ENOENT'. Issue #587: Windows writes
78
+ regular files, not symlinks — keep both paths working.
79
+
80
+ FORGE:ARCHITECT → 3 new functions in bin/forgedock.mjs: parseFrontmatter(),
81
+ generateStubContent(), updated install() flow.
82
+
83
+ FORGE:BUILDER → Branch feat/stub-install-pattern-619, 1 file changed.
84
+
85
+ FORGE:REVIEW → Auto-merged to staging.
86
+
87
+ FORGE:TRAJECTORY → Full audit trail recorded.
88
+ ```
89
+
90
+ The context phase surfaced two historical bugs (#577, #587) in the same module — preventing the builder from repeating known mistakes. [View the full issue →](https://github.com/RapierCraftStudios/ForgeDock/issues/619)
91
+
92
+ </details>
93
+
50
94
  ---
51
95
 
52
96
  ## Install
53
97
 
54
- **Requirements:** [Node.js 18+](https://nodejs.org/) and [Claude Code](https://docs.anthropic.com/en/docs/claude-code)
98
+ **Requirements:** [Node.js 18+](https://nodejs.org/), [Claude Code](https://docs.anthropic.com/en/docs/claude-code), [GitHub CLI (`gh`)](https://cli.github.com/), and [`yq`](https://github.com/mikefarah/yq) (YAML parser used by pipeline commands to read `forge.yaml`)
55
99
 
56
100
  ```bash
57
- # Install pipeline commands (symlinks into ~/.claude/commands/)
101
+ # Install pipeline commands
58
102
  npx forgedock
59
103
 
60
104
  # Generate config for your repo
61
105
  npx forgedock init
62
106
  ```
63
107
 
64
- That's it. Open Claude Code in your project and run `/work-on #42`.
108
+ This symlinks 25+ pipeline commands into `~/.claude/commands/` and generates a `forge.yaml` config in your project root. That's it — open Claude Code and run `/work-on #42`.
65
109
 
66
110
  <details>
67
111
  <summary><strong>Other install methods & commands</strong></summary>
@@ -111,32 +155,6 @@ Each stage writes a structured annotation (`<!-- FORGE:INVESTIGATOR -->`, `<!--
111
155
 
112
156
  Labels track workflow state (`workflow:investigating`, `workflow:building`, `workflow:in-review`, `workflow:merged`). The pipeline resumes from whatever state GitHub says it's in — restart-safe by design.
113
157
 
114
- <details>
115
- <summary><strong>Example: Full pipeline run</strong></summary>
116
-
117
- Issue #42: *"POST /api/payments returns 500 for free-tier users."*
118
-
119
- ```
120
- FORGE:INVESTIGATOR → Traced bug to commit e8f21a3 (PR #38). Payment validation
121
- assumed all users have a billing profile — free-tier users don't.
122
-
123
- FORGE:CONTEXT → Surfaced 2 historical bugs in the same module:
124
- #29 (nil-check on subscription lookup) and
125
- #34 (billing profile race condition). Known pitfall:
126
- don't skip audit log write on early returns.
127
-
128
- FORGE:ARCHITECT → 2-file fix: nil-check in payment validator,
129
- free-tier guard in the API router.
130
-
131
- FORGE:BUILDER → Branch fix/payment-validation-free-tier-42, 2 files changed.
132
-
133
- FORGE:REVIEW → 4 review agents, 0 findings, auto-merged to staging.
134
- ```
135
-
136
- The context phase caught the audit log pitfall from issue #34 — a completely different bug, months earlier, in the same module. That's institutional memory at work.
137
-
138
- </details>
139
-
140
158
  ---
141
159
 
142
160
  ## Commands
@@ -168,13 +186,7 @@ The context phase caught the audit log pitfall from issue #34 — a completely d
168
186
  npx forgedock uninstall
169
187
  ```
170
188
 
171
- This removes all ForgeDock command symlinks from `~/.claude/commands/`. Your `forge.yaml` config and any `FORGE:` annotations on GitHub issues/PRs are left untouched.
172
-
173
- To also remove the npm cache:
174
- ```bash
175
- npx forgedock uninstall
176
- npm cache clean --force
177
- ```
189
+ Removes all ForgeDock command symlinks from `~/.claude/commands/`. Your `forge.yaml` config and any `FORGE:` annotations on GitHub issues/PRs are left untouched.
178
190
 
179
191
  ---
180
192
 
@@ -188,15 +200,15 @@ npm cache clean --force
188
200
 
189
201
  ---
190
202
 
191
- ## Show Your Support
192
-
193
- Add a badge to your README:
203
+ ## Star History
194
204
 
195
- ```markdown
196
- [![Built with ForgeDock](https://img.shields.io/badge/Built_with-ForgeDock-blue?logo=github)](https://github.com/RapierCraftStudios/ForgeDock)
197
- ```
198
-
199
- [![Built with ForgeDock](https://img.shields.io/badge/Built_with-ForgeDock-blue?logo=github)](https://github.com/RapierCraftStudios/ForgeDock)
205
+ <a href="https://star-history.com/#RapierCraftStudios/ForgeDock&Date">
206
+ <picture>
207
+ <source media="(prefers-color-scheme: dark)" srcset="https://api.star-history.com/svg?repos=RapierCraftStudios/ForgeDock&type=Date&theme=dark" />
208
+ <source media="(prefers-color-scheme: light)" srcset="https://api.star-history.com/svg?repos=RapierCraftStudios/ForgeDock&type=Date" />
209
+ <img alt="Star History Chart" src="https://api.star-history.com/svg?repos=RapierCraftStudios/ForgeDock&type=Date" />
210
+ </picture>
211
+ </a>
200
212
 
201
213
  ---
202
214
 
@@ -206,10 +218,20 @@ PRs welcome. Every change goes through a PR, tested against 3+ scenarios, using
206
218
 
207
219
  ## License
208
220
 
209
- [AGPL-3.0](LICENSE) — free to use, modify, and distribute. If you modify ForgeDock and offer it as a service, you must open-source your modifications under the same license.
221
+ ForgeDock uses a **dual-licensing model**:
222
+
223
+ - **[AGPL-3.0](LICENSE)** — free to use, modify, and distribute for open-source and personal use. If you modify ForgeDock and offer it as a service (including over a network), you must open-source your modifications under AGPL-3.0.
224
+
225
+ - **[Commercial License](COMMERCIAL-LICENSE.md)** — for organizations that need to use ForgeDock in proprietary workflows or products without AGPL-3.0 copyleft obligations. [Contact RapierCraft Studios](mailto:licensing@rapiercraft.studio) to obtain a commercial license.
226
+
227
+ The open-source core remains free under AGPL-3.0. The commercial license is an exception for customers who cannot meet the copyleft requirements.
210
228
 
211
229
  ---
212
230
 
213
231
  <div align="center">
232
+
214
233
  <p>Built by <a href="https://github.com/RapierCraftStudios">RapierCraft Studios</a></p>
234
+
235
+ <a href="https://github.com/sponsors/RapierCraftStudios"><img src="https://img.shields.io/badge/Sponsor-%E2%9D%A4-ea4aaa.svg?style=flat-square" alt="Sponsor" /></a>
236
+
215
237
  </div>