@moretea-labs/forge 1.5.0-rc.1 → 1.5.0

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 (259) hide show
  1. package/AGENTS.md +9 -11
  2. package/CHANGELOG.md +19 -0
  3. package/CLAUDE.md +8 -10
  4. package/DESIGN.md +278 -0
  5. package/README.md +70 -90
  6. package/README.zh-CN.md +50 -55
  7. package/SKILL.md +8 -11
  8. package/THIRD_PARTY_NOTICES.md +9 -3
  9. package/assets/branding/README.md +4 -2
  10. package/assets/hooks/lib/workflow-state.sh +19 -18
  11. package/assets/hooks/post-edit-guard.sh +6 -75
  12. package/assets/hooks/prompt-guard.sh +24 -12
  13. package/assets/hooks/session-start-context.sh +17 -17
  14. package/assets/hooks/stop-orchestrator.sh +2 -2
  15. package/assets/partials/04-project-structure.partial.md +6 -6
  16. package/assets/partials/05-workflow.partial.md +6 -6
  17. package/assets/partials/07-footer.partial.md +1 -1
  18. package/assets/partials/08-orchestration.partial.md +2 -2
  19. package/assets/partials-agents/02-operating-mode.partial.md +5 -5
  20. package/assets/partials-agents/03-orchestration.partial.md +3 -3
  21. package/assets/partials-agents/04-task-protocol.partial.md +3 -3
  22. package/assets/partials-agents/08-deep-docs.partial.md +1 -1
  23. package/assets/reference-configs/agentic-development-flow.md +49 -86
  24. package/assets/reference-configs/external-tooling.md +21 -61
  25. package/assets/reference-configs/handoff-protocol.md +25 -20
  26. package/assets/reference-configs/harness-overview.md +8 -8
  27. package/assets/templates/helpers/archive-workflow.sh +0 -1
  28. package/assets/templates/helpers/capture-plan.sh +3 -3
  29. package/assets/templates/helpers/check-task-workflow.sh +2 -2
  30. package/assets/templates/helpers/codex-handoff-resume.sh +5 -5
  31. package/assets/templates/helpers/ensure-task-workflow.sh +37 -35
  32. package/assets/templates/helpers/new-plan.sh +1 -1
  33. package/assets/templates/helpers/plan-to-todo.sh +2 -2
  34. package/assets/templates/helpers/prepare-codex-handoff.sh +2 -2
  35. package/assets/templates/helpers/prepare-handoff.sh +9 -9
  36. package/assets/templates/helpers/refresh-current-status.sh +2 -2
  37. package/assets/templates/helpers/ship-worktrees.sh +1 -1
  38. package/assets/templates/helpers/sprint-backlog.sh +1 -1
  39. package/assets/templates/helpers/verify-sprint.sh +7 -7
  40. package/assets/templates/helpers/workstream-sync.sh +1 -1
  41. package/assets/templates/plan.template.md +1 -1
  42. package/assets/workflow-contract.v1.json +6 -3
  43. package/docs/architecture/current/README.md +10 -9
  44. package/docs/architecture/current/approved-target-architecture.zh-CN.md +2 -2
  45. package/docs/architecture/current/architecture-invariants.md +2 -2
  46. package/docs/architecture/current/automation-and-schedule-engine.md +15 -15
  47. package/docs/architecture/current/codegraph-context-provider.md +2 -2
  48. package/docs/architecture/current/control-plane-authority-inventory.md +12 -0
  49. package/docs/architecture/current/dispatch-and-agent-strategy.md +11 -11
  50. package/docs/architecture/current/entity-model.md +0 -27
  51. package/docs/architecture/current/failure-recovery.md +0 -24
  52. package/docs/architecture/current/governance.md +1 -1
  53. package/docs/architecture/current/implementation-status.md +1 -1
  54. package/docs/architecture/current/legacy-governance.md +58 -0
  55. package/docs/architecture/current/multi-repository-execution.md +1 -1
  56. package/docs/architecture/current/peer-supercontroller-runtime.md +1 -1
  57. package/docs/architecture/current/personal-assistant-plugin-baseline.md +4 -5
  58. package/docs/architecture/current/scheduler-and-resource-claims.md +0 -10
  59. package/docs/architecture/current/target-requirements-traceability.md +2 -2
  60. package/docs/architecture/current/thin-harness-governance-policy.md +1 -1
  61. package/docs/architecture/current/thin-harness-v1.md +9 -11
  62. package/docs/architecture/domains/runtime-harness.md +1 -1
  63. package/docs/forge-autonomous-goal-loop.md +3 -1
  64. package/docs/forge-chatgpt-mcp-setup.md +51 -184
  65. package/docs/images/forge-banner-cn.svg +26 -1
  66. package/docs/images/forge-banner.svg +26 -1
  67. package/docs/operations/features.md +1 -1
  68. package/docs/operations/homebrew.md +3 -3
  69. package/docs/operations/mcp-tool-exposure.md +5 -5
  70. package/docs/operations/platform-support.md +45 -37
  71. package/docs/operations/platform-support.zh-CN.md +40 -38
  72. package/docs/operations/releasing.md +3 -3
  73. package/docs/operations/releasing.zh-CN.md +3 -3
  74. package/docs/operations/troubleshooting.md +11 -6
  75. package/docs/operations/troubleshooting.zh-CN.md +11 -6
  76. package/docs/public-usage-guide.md +28 -21
  77. package/docs/public-usage-guide.zh-CN.md +28 -21
  78. package/docs/tutorials/01-install-and-start.md +56 -35
  79. package/docs/tutorials/01-install-and-start.zh-CN.md +56 -35
  80. package/docs/tutorials/02-connect-chatgpt.md +112 -46
  81. package/docs/tutorials/02-connect-chatgpt.zh-CN.md +113 -45
  82. package/docs/wiki/Architecture.md +1 -1
  83. package/docs/wiki/Installation.md +2 -2
  84. package/docs/wiki/Quick-Start.md +1 -1
  85. package/docs/wiki/Work-Lifecycle.md +1 -1
  86. package/install.ps1 +4 -5
  87. package/install.sh +4 -6
  88. package/package.json +15 -5
  89. package/scripts/archive-workflow.sh +0 -1
  90. package/scripts/benchmark-thin-harness-mcp-e2e.ts +27 -14
  91. package/scripts/build-controller-ui.ts +28 -0
  92. package/scripts/capture-plan.sh +4 -4
  93. package/scripts/check-agent-tooling.sh +12 -1
  94. package/scripts/check-platform-support.mjs +2 -2
  95. package/scripts/check-public-docs.sh +16 -5
  96. package/scripts/check-release-readiness.sh +5 -11
  97. package/scripts/check-runtime-architecture.mjs +14 -22
  98. package/scripts/check-tarball-install-smoke.sh +3 -2
  99. package/scripts/check-task-workflow.sh +2 -2
  100. package/scripts/codex-handoff-resume.sh +5 -5
  101. package/scripts/create-project-dirs.sh +3 -3
  102. package/scripts/ensure-task-workflow.sh +45 -35
  103. package/scripts/init-project.sh +4 -4
  104. package/scripts/install-desktop-operator-registration.ts +2 -2
  105. package/scripts/lib/project-init-lib.sh +46 -44
  106. package/scripts/migrate-project-template.sh +7 -4
  107. package/scripts/new-plan.sh +1 -1
  108. package/scripts/plan-to-todo.sh +2 -2
  109. package/scripts/prepare-codex-handoff.sh +2 -2
  110. package/scripts/prepare-handoff.sh +9 -9
  111. package/scripts/refresh-current-status.sh +2 -2
  112. package/scripts/setup-plugins.sh +3 -3
  113. package/scripts/ship-worktrees.sh +1 -1
  114. package/scripts/sprint-backlog.sh +5 -5
  115. package/scripts/sync-codex-installed-copies.sh +2 -3
  116. package/scripts/verify-sprint.sh +7 -7
  117. package/scripts/workstream-sync.sh +1 -1
  118. package/src/cli/chatgpt-browser/bridge-extension.ts +1 -1
  119. package/src/cli/chatgpt-browser/bridge-provider.ts +29 -0
  120. package/src/cli/chatgpt-browser/file-policy.ts +3 -1
  121. package/src/cli/commands/chatgpt.ts +51 -0
  122. package/src/cli/commands/doctor.ts +1 -1
  123. package/src/cli/commands/init-hook.ts +211 -70
  124. package/src/cli/commands/init.ts +5 -6
  125. package/src/cli/commands/mcp.ts +29 -5
  126. package/src/cli/commands/runtime.ts +60 -8
  127. package/src/cli/commands/setup-profile.ts +441 -0
  128. package/src/cli/controller/check-runner.ts +20 -3
  129. package/src/cli/controller/codex-continuation.ts +4 -7
  130. package/src/cli/controller/context-pack.ts +118 -14
  131. package/src/cli/controller/operational-plan.ts +4 -4
  132. package/src/cli/controller/task-ledger.ts +10 -10
  133. package/src/cli/controller/work-mode.ts +6 -13
  134. package/src/cli/index.ts +14 -35
  135. package/src/cli/local-bridge/connector-freshness.ts +1 -1
  136. package/src/cli/local-bridge/console-automations.ts +160 -0
  137. package/src/cli/local-bridge/dashboard.ts +8 -1303
  138. package/src/cli/local-bridge/facade-api.ts +16 -7
  139. package/src/cli/local-bridge/frontend/src/App.tsx +10 -0
  140. package/src/cli/local-bridge/frontend/src/components/Button.tsx +1 -0
  141. package/src/cli/local-bridge/frontend/src/components/DetailPane.tsx +3 -0
  142. package/src/cli/local-bridge/frontend/src/components/SearchField.tsx +1 -0
  143. package/src/cli/local-bridge/frontend/src/components/SectionHeader.tsx +1 -0
  144. package/src/cli/local-bridge/frontend/src/components/Segmented.tsx +1 -0
  145. package/src/cli/local-bridge/frontend/src/components/StatusText.tsx +3 -0
  146. package/src/cli/local-bridge/frontend/src/design/icons.tsx +11 -0
  147. package/src/cli/local-bridge/frontend/src/design/tokens.css +8 -0
  148. package/src/cli/local-bridge/frontend/src/features/automations/AutomationsView.tsx +3 -0
  149. package/src/cli/local-bridge/frontend/src/features/capabilities/CapabilitiesView.tsx +4 -0
  150. package/src/cli/local-bridge/frontend/src/features/overview/OverviewView.tsx +3 -0
  151. package/src/cli/local-bridge/frontend/src/features/repositories/RepositoriesView.tsx +2 -0
  152. package/src/cli/local-bridge/frontend/src/features/settings/SettingsView.tsx +2 -0
  153. package/src/cli/local-bridge/frontend/src/features/system/SystemView.tsx +2 -0
  154. package/src/cli/local-bridge/frontend/src/features/work/WorkView.tsx +3 -0
  155. package/src/cli/local-bridge/frontend/src/lib/api.ts +23 -0
  156. package/src/cli/local-bridge/frontend/src/lib/format.ts +4 -0
  157. package/src/cli/local-bridge/frontend/src/lib/routes.ts +7 -0
  158. package/src/cli/local-bridge/frontend/src/main.tsx +1 -0
  159. package/src/cli/local-bridge/frontend/src/shell/AppShell.tsx +1 -0
  160. package/src/cli/local-bridge/frontend/src/shell/CommandBar.tsx +2 -0
  161. package/src/cli/local-bridge/frontend/src/shell/Sidebar.tsx +3 -0
  162. package/src/cli/local-bridge/frontend/src/styles.css +12 -0
  163. package/src/cli/local-bridge/frontend/src/types.ts +14 -0
  164. package/src/cli/local-bridge/frontend/src/vite-env.d.ts +1 -0
  165. package/src/cli/local-bridge/frontend/vite.config.ts +27 -0
  166. package/src/cli/local-bridge/server.ts +44 -0
  167. package/src/cli/local-bridge/ui-dist/app.css +1 -0
  168. package/src/cli/local-bridge/ui-dist/app.js +11094 -0
  169. package/src/cli/mcp/instructions.ts +3 -3
  170. package/src/cli/mcp/legacy-tool-service.ts +27 -23
  171. package/src/cli/mcp/multi-repository.ts +2 -0
  172. package/src/cli/mcp/policy.ts +7 -5
  173. package/src/cli/mcp/repository-tools.ts +53 -14
  174. package/src/cli/mcp/server.ts +5 -10
  175. package/src/cli/mcp/setup.ts +211 -275
  176. package/src/cli/mcp/tool-capability-cache.ts +1 -1
  177. package/src/cli/mcp/toolset-names.ts +1 -1
  178. package/src/cli/mcp/toolset.ts +0 -1
  179. package/src/cli/mcp/transports/http.ts +24 -4
  180. package/src/cli/repositories/branch-name-policy.ts +0 -7
  181. package/src/cli/repositories/controller-home.ts +110 -3
  182. package/src/cli/repositories/safe-patch.ts +1 -1
  183. package/src/cli/repositories/selected-path-actions.ts +26 -24
  184. package/src/core/adoption/gitignore-plan.ts +2 -3
  185. package/src/core/adoption/plan.ts +4 -1
  186. package/src/runtime/control-plane/execution/edit-validation-coordinator.ts +556 -0
  187. package/src/runtime/control-plane/execution/work-handle-store.ts +128 -1
  188. package/src/runtime/control-plane/execution/work-validation-reconciler.ts +277 -0
  189. package/src/runtime/control-plane/execution/work-verification-snapshot.ts +169 -0
  190. package/src/runtime/control-plane/facade/capability-registry.ts +0 -10
  191. package/src/runtime/control-plane/facade/handoff-inbox-store.ts +44 -25
  192. package/src/runtime/control-plane/facade/suggested-actions.ts +7 -1
  193. package/src/runtime/control-plane/facade/types.ts +0 -1
  194. package/src/runtime/control-plane/global-scheduler/scheduler.ts +30 -8
  195. package/src/runtime/control-plane/launcher/chatgpt-work-binding-store.ts +114 -0
  196. package/src/runtime/control-plane/launcher/chatgpt-work-continuation.ts +175 -0
  197. package/src/runtime/control-plane/launcher/launch-reservation-store.ts +161 -0
  198. package/src/runtime/control-plane/launcher/provider-mcp-bootstrap.ts +64 -0
  199. package/src/runtime/control-plane/launcher/thin-launcher.ts +117 -24
  200. package/src/runtime/control-plane/routing/route-policy.ts +14 -14
  201. package/src/runtime/control-plane/runtime-cleanup.ts +0 -1
  202. package/src/runtime/evidence/event-ledger.ts +1 -1
  203. package/src/runtime/{workflow/campaigns/workspace.ts → execution/managed-workspace.ts} +41 -43
  204. package/src/runtime/execution/process-runtime/check-facade.ts +6 -0
  205. package/src/runtime/execution/process-runtime/check-result.ts +45 -0
  206. package/src/runtime/execution/process-runtime/check-runner-sidecar.ts +42 -16
  207. package/src/runtime/execution/process-runtime/command-facade.ts +4 -2
  208. package/src/runtime/execution/process-runtime/gc.ts +1 -1
  209. package/src/runtime/execution/process-runtime/index.ts +3 -0
  210. package/src/runtime/execution/process-runtime/interactive-admission.ts +14 -5
  211. package/src/runtime/execution/process-runtime/persisted-check.ts +285 -0
  212. package/src/runtime/execution/process-runtime/resource-claims.ts +30 -0
  213. package/src/runtime/execution/process-runtime/runtime.ts +18 -1
  214. package/src/runtime/execution/process-runtime/store.ts +1 -19
  215. package/src/runtime/execution/process-runtime/types.ts +4 -0
  216. package/src/runtime/execution/thin-harness/execution-router.ts +0 -1
  217. package/src/runtime/execution/thin-harness/fast-executor.ts +1 -1
  218. package/src/runtime/execution/thin-harness/lightweight-lanes.ts +1 -2
  219. package/src/runtime/execution/thin-harness/types.ts +0 -1
  220. package/src/runtime/execution/workers/executor.ts +1 -1
  221. package/src/runtime/gateway/mcp/execution-tools.ts +1 -1
  222. package/src/runtime/gateway/mcp/persisted-check-process.ts +3 -255
  223. package/src/runtime/gateway/mcp/process-tools.ts +16 -3
  224. package/src/runtime/gateway/mcp/resource-policy.ts +0 -9
  225. package/src/runtime/gateway/mcp/router.ts +117 -182
  226. package/src/runtime/gateway/mcp/runtime-tools.ts +331 -409
  227. package/src/runtime/gateway/mcp/work-validation-reconciler.ts +1 -219
  228. package/src/runtime/plugins/browser-adapter.ts +5 -0
  229. package/src/runtime/plugins/desktop-operator-registration.ts +1 -1
  230. package/src/runtime/plugins/store.ts +14 -6
  231. package/src/runtime/plugins/types.ts +1 -1
  232. package/src/runtime/projections/materialized-view.ts +1 -23
  233. package/src/runtime/recovery/maintenance-executor.ts +9 -0
  234. package/src/runtime/resources/ownership.ts +0 -1
  235. package/src/runtime/root/gateway-adapter.ts +2 -0
  236. package/src/runtime/root/mcp-transport.ts +10 -2
  237. package/src/runtime/root/package-runtime-release.ts +161 -0
  238. package/src/runtime/root/package-runtime-service.ts +172 -0
  239. package/src/runtime/root/runtime.ts +2 -1
  240. package/src/runtime/root/scheduler.ts +5 -0
  241. package/src/runtime/root/service.ts +18 -5
  242. package/src/runtime/standalone-recovery/core.ts +65 -16
  243. package/src/runtime/workflow/findings/store.ts +145 -106
  244. package/src/runtime/workflow/findings/types.ts +22 -0
  245. package/src/runtime/workflow/schedules/engine.ts +132 -2
  246. package/src/runtime/workflow/schedules/pending-activation.ts +139 -0
  247. package/src/runtime/workflow/schedules/work-continuation.ts +218 -0
  248. package/docs/CHANGELOG.md +0 -978
  249. package/docs/README.zh-CN.md +0 -58
  250. package/scripts/smoke-chatgpt-supervised-automation.ts +0 -208
  251. package/src/cli/commands/controller.ts +0 -680
  252. package/src/runtime/workflow/campaigns/cleanup.ts +0 -263
  253. package/src/runtime/workflow/campaigns/engine.ts +0 -112
  254. package/src/runtime/workflow/campaigns/normalize.ts +0 -100
  255. package/src/runtime/workflow/campaigns/review.ts +0 -315
  256. package/src/runtime/workflow/campaigns/store.ts +0 -526
  257. package/src/runtime/workflow/campaigns/supervisor.ts +0 -112
  258. package/src/runtime/workflow/campaigns/types.ts +0 -290
  259. /package/src/runtime/{workflow/campaigns → execution}/workspace-agent.ts +0 -0
package/README.md CHANGED
@@ -1,132 +1,112 @@
1
1
  <a id="english"></a>
2
2
 
3
- <p align="center"><img src="docs/images/forge-banner.svg" alt="Forge — local-first action runtime" width="1280"></p>
4
- <p align="center"><strong>Local-first action runtime for ChatGPT and AI coding assistants.</strong></p>
5
- <p align="center"><a href="#english">English</a> · <a href="#zh-cn">简体中文</a> · <a href="docs/README.md">Docs</a> · <a href="docs/forge-plugin-management.md">Plugins</a> · <a href="https://github.com/moretea-labs/forge/releases">Releases</a></p>
6
- <p align="center"><img alt="CI" src="https://github.com/moretea-labs/forge/actions/workflows/ci.yml/badge.svg"> <img alt="Release" src="https://img.shields.io/github/v/release/moretea-labs/forge?include_prereleases&sort=semver"> <img alt="npm next" src="https://img.shields.io/npm/v/%40moretea-labs%2Fforge?tag=next&label=npm%20next"> <img alt="License" src="https://img.shields.io/github/license/moretea-labs/forge"></p>
3
+ <p align="center"><img src="docs/images/forge-banner.svg" alt="Forge — ChatGPT decides, Forge acts" width="1280"></p>
4
+ <p align="center"><strong>Give ChatGPT real, controlled hands on your computer, code, browser, and services.</strong></p>
5
+ <p align="center"><a href="#english">English</a> · <a href="#zh-cn">简体中文</a> · <a href="docs/README.md">Docs</a> · <a href="docs/operations/features.md">Features</a> · <a href="docs/forge-plugin-management.md">Plugins</a> · <a href="https://github.com/moretea-labs/forge/releases">Releases</a></p>
6
+ <p align="center"><img alt="CI" src="https://github.com/moretea-labs/forge/actions/workflows/ci.yml/badge.svg"> <img alt="Release" src="https://img.shields.io/github/v/release/moretea-labs/forge?include_prereleases&sort=semver"> <img alt="npm latest" src="https://img.shields.io/npm/v/%40moretea-labs%2Fforge?tag=latest&label=npm%20latest"> <img alt="License" src="https://img.shields.io/github/license/moretea-labs/forge"></p>
7
7
 
8
- Forge gives ChatGPT a bounded, auditable way to work with **real local repositories, processes, plugins, and recovery state**. It keeps durable execution facts outside the chat, uses the lightest valid path for small work, and preserves explicit safety boundaries for remote, destructive, secret, and outside-workspace effects.
8
+ **Forge has no internal AI brain.** One external controller owns semantic decisions; Forge provides the controlled execution, state, permissions, and recovery layer. ChatGPT is the recommended controller, but you can choose Codex, Claude, or another MCP client instead, and you may configure several controller entries while keeping one primary controller at a time.
9
9
 
10
- ## Why Forge
10
+ With ChatGPT as the controller, Forge does **not** require a separate OpenAI API key or a second per-token model budget. Your existing ChatGPT plan/session limits still apply. Codex and Claude are not Forge dependencies unless you explicitly choose or configure them.
11
11
 
12
- | Need | Forge behavior |
13
- | --- | --- |
14
- | Work on real code | Stable `repoId + checkoutId` identity binds every repository operation to the intended checkout. |
15
- | Keep small tasks fast | Direct-first execution avoids Plan/Issue/Agent/worktree overhead when the change is already understood. |
16
- | Run long work once | Process Runtime owns build/test/process lifecycle; status, wait, logs, and cancel attach to the same process. |
17
- | Work concurrently | Independent repositories run in parallel; worktrees are introduced only when isolation is actually needed. |
18
- | Trust the result | Focused checks, diffs, receipts, evidence, immutable runtime releases, and Recovery make outcomes reviewable. |
19
- | Extend safely | Typed external providers install through Forge's pinned catalog and reuse the same authorization/evidence path. |
12
+ ## What Forge gives ChatGPT
20
13
 
21
- ## Quick start
14
+ | Capability | What that means for you |
15
+ | --- | --- |
16
+ | **Your local computer** | Authorize a folder, then let ChatGPT list/read/write/copy/move files, create directories, open documents or Finder, run bounded commands, inspect processes, and manage verified macOS LaunchAgents. |
17
+ | **Real software work** | Inspect and edit repositories, run tests/builds, use Git and worktrees, keep long commands attached, verify results, commit, and clean temporary work. |
18
+ | **Browser + desktop** | Navigate, inspect, click, fill, screenshot, transfer files, and hand off when human interaction is required; Chrome/Vivaldi native attach and macOS desktop actions are supported where available. |
19
+ | **Apple workflows** | Build and inspect iOS projects, work with simulators/devices, and use App Store Connect for apps, builds, TestFlight, review state, and Xcode Cloud workflows. |
20
+ | **Your services** | Typed plugins for GitHub, Gmail, Google Calendar, Google Tasks, Resend, plus independently released Forge providers. |
21
+ | **Automation + recovery** | Long commands stay attached instead of being restarted; scheduled/recurring work can persist outside chat and hand control back to ChatGPT when reasoning is needed. Repository identity, checks, approvals, and recovery facts survive outside the conversation. |
22
22
 
23
- Requirements: Git, Node.js 20.10+, npm, and a writable home directory. Bun 1.0+ is recommended for source development and the full test suite.
23
+ ### Ask for outcomes, not tools
24
24
 
25
- ```bash
26
- npm install -g @moretea-labs/forge@next
27
- forge --version
28
- forge setup open --target both
29
- forge setup next # repeat until ready
30
- forge setup close
31
- forge doctor
25
+ ```text
26
+ “Clean up these generated files, run the project checks, commit the fix, and remove the worktree.”
27
+ “Read this authorized folder, reorganize the documents, and open the result in Finder.”
28
+ “Open the web app, test this flow in Chrome, capture evidence, then fix the UI regression.”
29
+ “Summarize today’s inbox, archive obvious promotions, and prepare the important replies.”
30
+ “Check the latest TestFlight build and tell me what blocks release.”
32
31
  ```
33
32
 
34
- Connect ChatGPT with [Tutorial 2](docs/tutorials/02-connect-chatgpt.md), then adopt a repository:
33
+ Forge deliberately keeps the tool mechanics below the conversation. You describe the goal to your chosen external controller; that controller decides, while Forge enforces scope, persistence, execution policy, and evidence. Forge never invents an internal agent just because Codex or Claude happens to be installed.
35
34
 
36
- ```bash
37
- forge adopt --repo /path/to/your-project --dry-run
38
- forge adopt --repo /path/to/your-project
39
- forge repo list --json
40
- ```
35
+ ## Start in minutes
41
36
 
42
- For source development, follow [Install and start](docs/tutorials/01-install-and-start.md) or install the reviewed checkout directly:
37
+ Base install: **Node.js 20.10+, npm (or Bun), and a writable home directory**. Git is only required when you enable repository/software-work features; Codex and Claude are optional.
43
38
 
44
39
  ```bash
45
- git clone https://github.com/moretea-labs/forge.git && cd forge
46
- npm ci --ignore-scripts --no-audit --no-fund
47
- npm install -g . --omit=optional --no-audit --no-fund
48
- ```
49
-
50
- ## How ChatGPT uses Forge
51
-
52
- The normal ChatGPT connector exposes a bounded **19-tool MCP surface**. Five preferred facades—`rh_status`, `rh_access`, `rh_inbox`, `rh_context`, and `rh_work`—cover most orchestration; repository, source/patch, check, Process, plugin-dispatch, and result tools complete the default surface.
53
-
54
- ```text
55
- Small task → inspect → relevant context → Direct Edit → focused check → commit
56
- Long task → resolve identity → durable work only if needed → Process/worktree → verify → integrate → clean
40
+ npm install -g @moretea-labs/forge
41
+ forge setup
42
+ # Recommended path; then follow one Next action at a time:
43
+ forge setup configure --controller chatgpt --tunnel auto
44
+ forge setup next
57
45
  ```
58
46
 
59
- <p align="center"><img src="docs/images/forge-controller-flow.svg" alt="Forge canonical runtime flow" width="980"></p>
60
-
61
- Ask for the outcome, not the tool: “fix this failing test and commit”, “compare these repositories in parallel”, or “run the build and keep using the same Process”.
62
-
63
- ## Official providers
47
+ Setup persists progress and guides the selected path through the user-level Package Runtime, remote connectivity, controller registration, and connection verification. For ChatGPT, prefer **OpenAI Secure MCP Tunnel** when your organization supports it; Cloudflare Tunnel, Tailscale Funnel, an existing HTTPS `/mcp` URL, or deferred remote access remain alternatives. Local Codex/Claude controllers do not need a tunnel.
64
48
 
65
- | Provider | Purpose | Install |
66
- | --- | --- | --- |
67
- | [Forge Desktop Operator](https://github.com/moretea-labs/forge-desktop-operator) | Native macOS desktop automation | `forge plugin install desktop_operator` |
68
- | [Forge Design](https://github.com/moretea-labs/forge-design) | Repository-native design workspace and `design.md` provider | `forge plugin install design` |
69
- | [Personal Knowledge Assistant](https://github.com/moretea-labs/personal-knowledge-assistant) | Local-first personal knowledge retrieval, memory, and safe writes | `forge plugin install personal_knowledge` |
49
+ Then follow [Install and start](docs/tutorials/01-install-and-start.md) and [Connect ChatGPT](docs/tutorials/02-connect-chatgpt.md). A repository is optional during initial setup; add one later with `forge adopt --repo /path/to/your-project`.
70
50
 
71
- See [Plugin Management](docs/forge-plugin-management.md) for trust, distribution, update, and transport boundaries. Investment Decision System remains an independent product rather than a Forge plugin.
51
+ For a reviewed source checkout: `git clone https://github.com/moretea-labs/forge.git && cd forge && npm ci --ignore-scripts --no-audit --no-fund && npm install -g . --omit=optional --no-audit --no-fund`.
72
52
 
73
- ## Safety model
53
+ ## Built in, and extensible
74
54
 
75
- Forge distinguishes observation, normal local changes, remote effects, destructive actions, outside-workspace access, and secrets. Full Access reduces repetitive approval for ordinary local work; it does **not** weaken destructive, remote, or secret boundaries. See [Security Model](docs/wiki/Security-Model.md) and [SECURITY.md](SECURITY.md).
55
+ Forge ships typed local/browser/desktop/iOS/GitHub/Gmail/Calendar/Tasks/App Store Connect/Resend capabilities. The public provider catalog currently includes **Forge Desktop Operator**, **Forge Design**, and **Personal Knowledge Assistant**; install with `forge plugin catalog` / `forge plugin install <id>`. See [Features](docs/operations/features.md) and [Plugin Management](docs/forge-plugin-management.md).
76
56
 
77
- ## Documentation
57
+ ## Controlled by design
78
58
 
79
- - **Start:** [Documentation hub](docs/README.md) · [Wiki](docs/wiki/Home.md) · [Quick Start](docs/wiki/Quick-Start.md) · [Public usage guide](docs/public-usage-guide.md)
80
- - **Understand:** [Core Concepts](docs/wiki/Core-Concepts.md) · [Architecture](docs/wiki/Architecture.md) · [Work Lifecycle](docs/wiki/Work-Lifecycle.md)
81
- - **Operate:** [Operations](docs/wiki/Operations.md) · [Troubleshooting](docs/operations/troubleshooting.md) · [Platform support](docs/operations/platform-support.md)
82
- - **Maintain:** [Contributing](CONTRIBUTING.md) · [Release process](docs/operations/releasing.md) · [Changelog](CHANGELOG.md) · [Support](SUPPORT.md)
59
+ Local read/write grants are explicit and expiring; remote or destructive effects are distinguished from ordinary local work; high-impact actions require stronger confirmation. Full Access reduces repetitive prompts for normal work without removing the hard boundaries around secrets, destructive actions, and outside-workspace access. See [Security](SECURITY.md) and the [Security Model](docs/wiki/Security-Model.md).
83
60
 
84
- **Current release candidate:** `1.5.0-rc.1` on the npm `next` channel. Stable releases use `latest`. Forge is MIT licensed; see [LICENSE](LICENSE), [NOTICE](NOTICE), and [THIRD_PARTY_NOTICES.md](THIRD_PARTY_NOTICES.md).
61
+ **Docs:** [Wiki](docs/wiki/Home.md) · [Support](SUPPORT.md) · [Contributing](CONTRIBUTING.md) · [Changelog](CHANGELOG.md). Current stable release: `1.5.0`; stable installs use npm `latest`.
85
62
 
86
63
  ---
87
64
  <a id="zh-cn"></a>
88
65
 
89
- <p align="center"><img src="docs/images/forge-banner-cn.svg" alt="Forge——本地优先的行动运行时" width="1280"></p>
90
- <p align="center"><strong>面向 ChatGPT 与 AI 编程助手的本地优先行动运行时。</strong></p>
91
- <p align="center"><a href="#english">English</a> · <a href="#zh-cn">简体中文</a> · <a href="docs/README.zh-CN.md">中文文档</a> · <a href="docs/forge-plugin-management.md">插件</a> · <a href="https://github.com/moretea-labs/forge/releases">版本</a></p>
66
+ <p align="center"><img src="docs/images/forge-banner-cn.svg" alt="Forge——ChatGPT 决策,Forge 执行" width="1280"></p>
67
+ <p align="center"><strong>让 ChatGPT 真正、安全地操作你的电脑、代码、浏览器和外部服务。</strong></p>
68
+ <p align="center"><a href="#english">English</a> · <a href="#zh-cn">简体中文</a> · <a href="docs/README.zh-CN.md">中文文档</a> · <a href="docs/operations/features.zh-CN.md">功能</a> · <a href="docs/forge-plugin-management.md">插件</a></p>
92
69
 
93
- Forge 让 ChatGPT 在**真实本地仓库、进程、插件与恢复状态**上执行有边界、可审查的工作。小任务默认走最短路径;长任务复用同一个 Process;远程、破坏性、密钥和工作区外访问继续保持明确安全边界。
70
+ **Forge 自己没有 AI 大脑。** 语义判断始终由一个外部主控负责,Forge 负责受控执行、持久状态、权限和恢复。推荐 ChatGPT,也可以明确选择 Codex、Claude 或其他 MCP 客户端;可以预配置多个入口,但同一时刻只有一个主控负责决策。
94
71
 
95
- ## 核心能力
72
+ 选择 ChatGPT 时**不要求再配置一份 OpenAI API Key,也不需要额外准备一套按 token 计费的模型预算**;仍受你的 ChatGPT 套餐和会话限制。Codex、Claude 没被选中时就不是 Forge 的依赖。
96
73
 
97
- - **Direct-first**:范围明确的小修改不因调查自动创建 Plan、Issue、Agent 或 worktree。
98
- - **真实并发**:不同仓库可并行;需要隔离时再建立 worktree;同一 checkout 保持单写者。
99
- - **可恢复执行**:build/test 只启动一次,后续 status/wait/log/cancel 连接同一个 Process。
100
- - **明确身份**:`repoId + checkoutId` 防止一个会话误操作另一个 checkout。
101
- - **可验证结果**:diff、focused check、receipt、evidence、不可变 Runtime release 与 Recovery 都可追溯。
102
- - **类型化插件**:官方 Provider 从固定版本目录安装,并复用 Forge 的授权、资源声明与证据链。
74
+ ## Forge 能让 ChatGPT 做什么
103
75
 
104
- ## 快速开始
76
+ | 能力 | 用户真正得到什么 |
77
+ | --- | --- |
78
+ | **操作本机** | 授权一个目录后,可列出/读取/写入/复制/移动文件,创建目录,打开文档或 Finder,执行受控命令,查看进程并管理经过身份校验的 macOS LaunchAgent。 |
79
+ | **完成真实开发任务** | 读取和修改仓库、运行测试/构建、操作 Git/worktree、持续跟踪长命令、验证结果、提交并清理临时工作区。 |
80
+ | **浏览器与桌面** | 页面导航、读取、点击、填写、截图、文件传输;需要人工时再 handoff;可使用 Chrome/Vivaldi 原生 attach 与 macOS 桌面能力。 |
81
+ | **Apple 工作流** | iOS 构建、模拟器/设备,以及 App Store Connect 的版本、构建、TestFlight、审核状态和 Xcode Cloud。 |
82
+ | **连接你的服务** | GitHub、Gmail、Google Calendar、Google Tasks、Resend,以及独立发布的 Forge Provider。 |
83
+ | **自动化与可恢复执行** | 长命令不会因为聊天继续而重跑;定时/周期工作可以持久化,在需要判断时再交回 ChatGPT。仓库身份、检查、授权与恢复状态也不只存在于聊天上下文里。 |
105
84
 
106
- ```bash
107
- npm install -g @moretea-labs/forge@next
108
- forge setup open --target both
109
- forge setup next # 重复直到 ready
110
- forge setup close
111
- forge doctor
85
+ ```text
86
+ “把这个 bug 修好,跑完测试,提交,然后把临时 worktree 清掉。”
87
+ “读取我授权的这个目录,整理文件,并在 Finder 里打开结果。”
88
+ “在 Chrome 里把这个流程走一遍,截图核对,然后修 UI。”
89
+ “汇总今天邮件,把明显广告归档,重要邮件整理给我。”
90
+ “看最新 TestFlight 构建,告诉我离发布还差什么。”
112
91
  ```
113
92
 
114
- 接入仓库:
93
+ ## 快速开始
94
+
95
+ 基础安装只需要 **Node.js 20.10+、npm(或 Bun)和可写用户目录**。Git 只在启用仓库/软件开发能力时需要;Codex、Claude 都是可选项。
115
96
 
116
97
  ```bash
117
- forge adopt --repo /path/to/your-project --dry-run
118
- forge adopt --repo /path/to/your-project
119
- forge repo list --json
98
+ npm install -g @moretea-labs/forge
99
+ forge setup
100
+ forge setup configure --controller chatgpt --tunnel auto
101
+ forge setup next # 按每次显示的 Next 动作继续
120
102
  ```
121
103
 
122
- 普通 ChatGPT Connector 默认收敛为 **19 个 MCP 工具**,其中 `rh_status`、`rh_access`、`rh_inbox`、`rh_context`、`rh_work` 五个 facade 覆盖主要编排。正常使用时直接描述目标,不需要自己挑工具。
123
-
124
- ## 官方 Provider
104
+ 远程主控的 setup 会继续引导 Package Runtime、远程连接、主控配置和连接验证;ChatGPT 在组织支持时优先 **OpenAI Secure MCP Tunnel**,也可选 Cloudflare Tunnel、Tailscale Funnel、已有 HTTPS `/mcp`,或暂缓远程连接。本地 Codex/Claude 主控不需要 tunnel,也不会配置未选择的 CLI。
125
105
 
126
- `forge plugin catalog` 可查看当前目录;官方 Provider 包括 [Forge Desktop Operator](https://github.com/moretea-labs/forge-desktop-operator)、[Forge Design](https://github.com/moretea-labs/forge-design) 与 [Personal Knowledge Assistant](https://github.com/moretea-labs/personal-knowledge-assistant)。详见[插件管理](docs/forge-plugin-management.md)。
106
+ 继续阅读[安装与启动](docs/tutorials/01-install-and-start.zh-CN.md)和[连接 ChatGPT](docs/tutorials/02-connect-chatgpt.zh-CN.md)。仓库不是首次 setup 的前置条件,需要开发能力时再运行 `forge adopt --repo /path/to/your-project`。源码安装:`git clone https://github.com/moretea-labs/forge.git && cd forge && npm ci --ignore-scripts --no-audit --no-fund && npm install -g . --omit=optional --no-audit --no-fund`。
127
107
 
128
- ## 文档与维护
108
+ Forge 内置本机、Browser、Desktop、iOS、GitHub、Gmail、Calendar、Tasks、App Store Connect、Resend 等类型化能力;公开 Provider 目录还有 **Forge Desktop Operator / Forge Design / Personal Knowledge Assistant**。详见[功能清单](docs/operations/features.zh-CN.md)与[插件管理](docs/forge-plugin-management.md)。
129
109
 
130
- [中文文档中心](docs/README.zh-CN.md) · [安装教程](docs/tutorials/01-install-and-start.zh-CN.md) · [公开使用指南](docs/public-usage-guide.zh-CN.md) · [架构](docs/wiki/Architecture.md) · [故障排查](docs/operations/troubleshooting.zh-CN.md) · [贡献](CONTRIBUTING.md) · [安全](SECURITY.md)
110
+ 安全上,普通本地修改、远程影响、破坏性操作、密钥和工作区外访问是不同边界;Full Access 不会取消高风险确认。详见[安全说明](SECURITY.md)和[安全模型](docs/wiki/Security-Model.md)。
131
111
 
132
- **当前候选版本:** `1.5.0-rc.1`,npm 使用 `next`;稳定版使用 `latest`。项目采用 [MIT License](LICENSE)。
112
+ **文档:** [Wiki](docs/wiki/Home.md) · [支持](SUPPORT.md) · [贡献](CONTRIBUTING.md) · [更新日志](CHANGELOG.md)。当前稳定版为 `1.5.0`,稳定安装使用 npm `latest`。
package/README.zh-CN.md CHANGED
@@ -1,45 +1,62 @@
1
1
  # Forge
2
2
 
3
- <p align="center"><img src="docs/images/forge-banner-cn.svg" alt="Forge——本地优先的行动运行时" width="1280"></p>
4
- <p align="center"><strong>面向 ChatGPT 与 AI 编程助手的本地优先行动运行时。</strong></p>
5
- <p align="center"><a href="README.md#english">English</a> · <a href="README.md#zh-cn">仓库首页中文</a> · <a href="docs/README.zh-CN.md">中文文档</a> · <a href="https://github.com/moretea-labs/forge/releases">版本发布</a></p>
6
- <p align="center"><img alt="CI" src="https://github.com/moretea-labs/forge/actions/workflows/ci.yml/badge.svg"> <img alt="Release" src="https://img.shields.io/github/v/release/moretea-labs/forge?include_prereleases&sort=semver"> <img alt="npm next" src="https://img.shields.io/npm/v/%40moretea-labs%2Fforge?tag=next&label=npm%20next"> <img alt="License" src="https://img.shields.io/github/license/moretea-labs/forge"></p>
3
+ <p align="center"><img src="docs/images/forge-banner-cn.svg" alt="Forge——ChatGPT 决策,Forge 执行" width="1280"></p>
4
+ <p align="center"><strong>让 ChatGPT 真正、安全地操作你的电脑、代码、浏览器和外部服务。</strong></p>
5
+ <p align="center"><a href="https://github.com/moretea-labs/forge#english">English</a> · <a href="https://github.com/moretea-labs/forge#zh-cn">仓库首页中文</a> · <a href="docs/README.zh-CN.md">中文文档</a> · <a href="docs/operations/features.zh-CN.md">功能清单</a> · <a href="https://github.com/moretea-labs/forge/releases">版本发布</a></p>
6
+ <p align="center"><img alt="CI" src="https://github.com/moretea-labs/forge/actions/workflows/ci.yml/badge.svg"> <img alt="Release" src="https://img.shields.io/github/v/release/moretea-labs/forge?include_prereleases&sort=semver"> <img alt="npm latest" src="https://img.shields.io/npm/v/%40moretea-labs%2Fforge?tag=latest&label=npm%20latest"> <img alt="License" src="https://img.shields.io/github/license/moretea-labs/forge"></p>
7
7
 
8
- Forge 让 ChatGPT 在**真实本地仓库、进程、插件和恢复状态**上执行有边界、可审查的工作。它把 Git、Process、检查和发布证据保存在聊天之外,小任务走最短路径,长任务复用同一个执行生命周期。
8
+ **Forge 自己没有 AI 大脑。** 每次语义决策都由一个外部主控负责,Forge 负责执行、持久状态、权限和恢复。默认推荐 ChatGPT,也可以明确选择 Codex、Claude 或其他 MCP 客户端;可以配置多个控制入口,但同一时刻只有一个主控拥有语义控制权。
9
9
 
10
- ## 为什么使用 Forge
10
+ 选择 ChatGPT 时**不要求单独配置 OpenAI API Key,也不需要额外准备一套按 token 计费的模型预算**;仍受你的 ChatGPT 套餐和会话限制。没有选择 Codex/Claude,就不会把它们当成安装或就绪依赖。
11
11
 
12
- | 需求 | Forge 的处理方式 |
12
+ ## 为什么这和普通 Coding Agent 不一样
13
+
14
+ - **外部主控就是大脑**:推荐把 ChatGPT 对话作为主工作台;也可明确让 Codex、Claude 或其他 MCP 客户端担任主控,Forge 本身不参与语义决策。
15
+ - **不只会写代码**:同一个对话可以处理目录文件、命令、浏览器、桌面、邮件、日历、GitHub、iOS 与 App Store Connect。
16
+ - **真实执行状态在聊天之外**:长命令、检查、仓库身份、授权和恢复状态可以继续接上;定时/周期任务也可以持久化,在需要判断时再交回 ChatGPT。
17
+ - **没选就不依赖**:Codex/Claude 不会因为安装在机器上就进入 Forge readiness;只有你明确配置它们为主控或外部执行入口时才检查。
18
+ - **权限不是全有或全无**:本机目录授权可过期;远程、破坏性、密钥和工作区外访问有独立边界。
19
+
20
+ ## 你可以直接这样说
21
+
22
+ ```text
23
+ “把这个 bug 修好,跑完测试,提交,然后把临时 worktree 清掉。”
24
+ “读取我授权的这个目录,整理文件,并在 Finder 里打开结果。”
25
+ “在 Chrome 里把这个流程走一遍,截图核对,然后修 UI。”
26
+ “汇总今天邮件,把明显广告归档,重要邮件整理给我。”
27
+ “看最新 TestFlight 构建,告诉我离发布还差什么。”
28
+ ```
29
+
30
+ ## 现在能做什么
31
+
32
+ | 领域 | 典型能力 |
13
33
  | --- | --- |
14
- | 操作真实代码 | 使用稳定的 `repoId + checkoutId` 绑定目标仓库和 checkout。 |
15
- | 小任务不要重流程 | Direct-first;仅调查不会自动创建 Plan、Issue、Agent 或 worktree。 |
16
- | 长命令不要重复跑 | Process Runtime 只启动一次,后续 status/wait/log/cancel 连接同一个 Process。 |
17
- | 多仓库并发工作 | 不同仓库可并行;真正需要隔离时才建立 worktree。 |
18
- | 结果能够复核 | diff、focused check、receipt、evidence、不可变 Runtime release 与 Recovery 都可追溯。 |
19
- | 安全扩展能力 | 官方 Provider 从固定版本目录安装,复用 Forge 的授权、资源声明和证据链。 |
34
+ | **本机文件与命令** | 授权目录后列出/读取/写入/复制/移动文件、创建目录、打开文件/Finder、typed command、校验过的项目脚本、系统与进程诊断、macOS LaunchAgent 管理。 |
35
+ | **软件开发** | 多仓库读取与修改、Git、patch、测试/构建、长进程、worktree、验证、提交与清理;支持 Direct-first 的快速任务路径。 |
36
+ | **Browser / Desktop** | 页面导航、读取、选择器、点击、填写、截图、文件传输、人工 handoff;Chrome/Vivaldi 原生 attach;macOS Desktop 与可安装的 Desktop Operator。 |
37
+ | **Apple** | iOS 项目/模拟器/设备;App Store Connect 应用、版本、Build、TestFlight、审核信息和 Xcode Cloud workflow。 |
38
+ | **生产力服务** | GitHub Issue/Project、Gmail、Google Calendar、Google Tasks、Resend Email。 |
39
+ | **扩展能力** | 官方目录中的 Forge Design、Personal Knowledge Assistant、Desktop Operator;外部 Provider 仍复用 Forge 的权限和执行边界。 |
40
+
41
+ > 具体能力依赖操作系统、已安装 Provider、账号授权和目标服务配置。Forge 不会因为 README 写了某项能力就绕过平台权限或服务认证。
20
42
 
21
43
  ## 快速开始
22
44
 
23
- 需要 Git、Node.js 20.10+、npm 和可写用户目录。源码开发建议安装 Bun 1.0+。
45
+ 基础安装只需要 **Node.js 20.10+、npm(或 Bun)和可写用户目录**;Git 只在启用仓库/软件开发能力时需要,源码开发建议 Bun 1.0+。
24
46
 
25
47
  ```bash
26
- npm install -g @moretea-labs/forge@next
48
+ npm install -g @moretea-labs/forge
27
49
  forge --version
28
- forge setup open --target both
29
- forge setup next # 重复直到 ready
30
- forge setup close
31
- forge doctor
50
+ forge setup
51
+ forge setup configure --controller chatgpt --tunnel auto
52
+ forge setup next # 按每次显示的 Next 动作继续
32
53
  ```
33
54
 
34
- 接入仓库:
55
+ `forge setup` 会持久化进度。远程主控会继续经过 Package Runtime、远程连接、主控配置和连接验证;ChatGPT 在组织支持时优先 **OpenAI Secure MCP Tunnel**,也可选择 Cloudflare Tunnel、Tailscale Funnel、已有 HTTPS `/mcp` 或暂缓远程连接。本地主控 Codex/Claude 不需要 tunnel。
35
56
 
36
- ```bash
37
- forge adopt --repo /path/to/your-project --dry-run
38
- forge adopt --repo /path/to/your-project
39
- forge repo list --json
40
- ```
57
+ 接着阅读:[安装与启动](docs/tutorials/01-install-and-start.zh-CN.md) · [连接 ChatGPT](docs/tutorials/02-connect-chatgpt.zh-CN.md) · [第一个仓库任务](docs/tutorials/03-first-repository-task.zh-CN.md)。仓库不是首次 setup 的前置条件;需要时再 `forge adopt --repo /path/to/your-project`。
41
58
 
42
- 接下来按[连接 ChatGPT](docs/tutorials/02-connect-chatgpt.zh-CN.md)和[完成第一个仓库任务](docs/tutorials/03-first-repository-task.zh-CN.md)继续。源码开发可使用:
59
+ 从源码安装已审查 checkout:
43
60
 
44
61
  ```bash
45
62
  git clone https://github.com/moretea-labs/forge.git && cd forge
@@ -47,38 +64,16 @@ npm ci --ignore-scripts --no-audit --no-fund
47
64
  npm install -g . --omit=optional --no-audit --no-fund
48
65
  ```
49
66
 
50
- ## ChatGPT 如何使用 Forge
51
-
52
- 普通 ChatGPT Connector 默认是 **19 个 MCP 工具**。五个主要 facade——`rh_status`、`rh_access`、`rh_inbox`、`rh_context`、`rh_work`——覆盖日常编排,其余默认工具负责仓库、源码/补丁、check、Process、插件分发和结果读取。
53
-
54
- ```text
55
- 小任务 → 状态/上下文 → Direct Edit → focused check → commit
56
- 长任务 → 确定身份 → 确有需要才建 durable work → Process/worktree → verify → integrate → clean
57
- ```
58
-
59
- <p align="center"><img src="docs/images/forge-controller-flow.svg" alt="Forge Canonical Runtime 流程" width="980"></p>
60
-
61
- 正常使用时直接描述目标即可,不需要自己挑工具。
62
-
63
- ## 官方 Provider
64
-
65
- | Provider | 用途 | 安装 |
66
- | --- | --- | --- |
67
- | [Forge Desktop Operator](https://github.com/moretea-labs/forge-desktop-operator) | macOS 原生桌面操作 | `forge plugin install desktop_operator` |
68
- | [Forge Design](https://github.com/moretea-labs/forge-design) | 仓库原生设计工作区和 `design.md` | `forge plugin install design` |
69
- | [Personal Knowledge Assistant](https://github.com/moretea-labs/personal-knowledge-assistant) | 本地优先个人知识检索、记忆与安全写入 | `forge plugin install personal_knowledge` |
67
+ ## 插件与能力
70
68
 
71
- Forge 不扫描用户本机 sibling 仓库,也不允许模型临时提供任意 executable。完整边界见[插件管理](docs/forge-plugin-management.md)。Investment Decision System 保持独立产品,不进入 Forge 官方插件目录。
69
+ Forge 内置本机、Browser、Desktop、iOS、GitHub、Gmail、Calendar、Tasks、App Store Connect、Resend 等类型化插件;公开 Provider 目录还提供 **Forge Desktop Operator**、**Forge Design**、**Personal Knowledge Assistant**。运行 `forge plugin catalog` 查看当前固定版本目录,详见[插件管理](docs/forge-plugin-management.md)和[功能清单](docs/operations/features.zh-CN.md)。
72
70
 
73
- ## 安全模型
71
+ ## 安全不是宣传词
74
72
 
75
- Forge 区分读取、普通本地修改、远程影响、破坏性操作、工作区外访问和密钥访问。Full Access 只减少普通本地工作的重复授权,不会削弱 destructive、remote 或 secret 边界。详见[安全模型](docs/wiki/Security-Model.md)和 [SECURITY.md](SECURITY.md)。
73
+ Forge 把读取、普通本地写入、远程操作、破坏性操作、工作区外访问和密钥访问分开处理。本机目录采用显式授权;高风险行为需要更强确认。Full Access 只减少普通工作的重复提示,不会取消这些硬边界。详见 [SECURITY.md](SECURITY.md) 和[安全模型](docs/wiki/Security-Model.md)。
76
74
 
77
- ## 文档
75
+ ## 文档与项目
78
76
 
79
- - **开始使用:** [中文文档中心](docs/README.zh-CN.md) · [安装](docs/tutorials/01-install-and-start.zh-CN.md) · [公开使用指南](docs/public-usage-guide.zh-CN.md)
80
- - **理解系统:** [Wiki](docs/wiki/Home.md) · [核心概念](docs/wiki/Core-Concepts.md) · [架构](docs/wiki/Architecture.md) · [工作生命周期](docs/wiki/Work-Lifecycle.md)
81
- - **运维维护:** [故障排查](docs/operations/troubleshooting.zh-CN.md) · [平台支持](docs/operations/platform-support.zh-CN.md) · [发布流程](docs/operations/releasing.zh-CN.md)
82
- - **参与项目:** [贡献](CONTRIBUTING.md) · [安全](SECURITY.md) · [支持](SUPPORT.md) · [版本记录](CHANGELOG.md)
77
+ [中文文档中心](docs/README.zh-CN.md) · [Wiki](docs/wiki/Home.md) · [SUPPORT.md](SUPPORT.md) · [CONTRIBUTING.md](CONTRIBUTING.md) · [CHANGELOG.md](CHANGELOG.md)
83
78
 
84
- **当前候选版本:** `1.5.0-rc.1`,npm 使用 `next`;稳定版本使用 `latest`。项目采用 [MIT License](LICENSE)。
79
+ 当前稳定版本是 `1.5.0`,稳定安装使用 npm `latest`。
package/SKILL.md CHANGED
@@ -36,15 +36,14 @@ Treat ChatGPT as the controller and Forge as its repository execution layer. Cha
36
36
  - Hard runtime boundaries remain for secrets, credentials, Git internals, concurrent write conflicts, out-of-scope writes when a scope is declared, and remote or irreversible side effects.
37
37
  ## Explicit mode directives
38
38
 
39
- Automatic routing remains authoritative when the user does not provide a mode directive. In particular, understood bounded work still defaults to Direct Edit; adding explicit modes must not make ordinary requests Plan-first, Agent-first, Issue-first, or Campaign-first.
39
+ Automatic routing remains authoritative when the user does not provide a mode directive. In particular, understood bounded work still defaults to Direct Edit; adding explicit modes must not make ordinary requests Plan-first, Agent-first, Issue-first.
40
40
 
41
41
  A leading mode directive is an opt-in instruction to ChatGPT's Forge router. It applies only to the current request, is removed from the objective before execution, and never bypasses permissions, Runtime authority, protected-path rules, approvals, or destructive/remote-write confirmation.
42
42
 
43
43
  - `-plan` or `/plan`: force the reviewed planning path. Planning is read-only: inspect repository state and call `controller_context_pack` with `structural_context=required` so CodeGraph symbol/reference/dependency/impact evidence is used when the index is ready; load only relevant architecture/ADR/design/README material, then create or revise the existing PlanContract. Review the PlanContract before approval. Do not start mutation until the reviewed plan is approved and execution is explicitly bound to an approved plan step. If CodeGraph is unavailable or stale, keep the degraded evidence warning visible and use bounded current-source context instead of pretending graph coverage exists.
44
- - `-debug` or `/debug`: force evidence-first debugging. Reproduce or characterize the failure, then prefer `controller_context_pack` with `structural_context=auto` to isolate callers, dependencies, and the smallest causal surface before patching and focused verification. The directive does not force an Agent or Campaign; existing routing still chooses Direct, bounded Work, or an optional worker from the actual scope and risk.
45
- - `-campaign` or `/campaign`: force the durable Campaign topology for the current request. Use Campaign review checkpoints and independent task coordination even when automatic routing would otherwise choose Direct or bounded Work. This is an explicit user override of topology, not a permission override.
44
+ - `-debug` or `/debug`: force evidence-first debugging. Reproduce or characterize the failure, then prefer `controller_context_pack` with `structural_context=auto` to isolate callers, dependencies, and the smallest causal surface before patching and focused verification. The directive does not force an Agent or durable Work; existing routing still chooses Direct, bounded Work, or an optional worker from the actual scope and risk.
46
45
 
47
- A bare directive with no objective should return/explain that mode's working contract and must not mutate repository state. Mode directives are not sticky across turns unless the user repeats them or explicitly asks to continue the same active Plan/Campaign.
46
+ A bare directive with no objective should return/explain that mode's working contract and must not mutate repository state. Mode directives are not sticky across turns unless the user repeats them or explicitly asks to continue the same active Plan/Work.
48
47
 
49
48
  ## When to use
50
49
 
@@ -268,7 +267,7 @@ specific model providers, vector DBs, workflow engines, tracing vendors, or
268
267
  sidecar languages mandatory defaults.
269
268
 
270
269
  Scaffold is not an existing-repo adoption path. If the target already has a
271
- product tree, use `forge init`, `forge migrate`,
270
+ product tree, use `forge adopt`, `forge setup`,
272
271
  `forge upgrade`, or `forge repair` and preserve the existing app
273
272
  shape. `create-project-dirs`, `hooks-init`, and `docs-init` remain internal
274
273
  steps behind public commands, not standalone user-facing scaffold aliases.
@@ -302,12 +301,10 @@ Migration defaults:
302
301
  - move hidden contracts and deep findings into topic-scoped `docs/researches/*.md`
303
302
  - distill repeated corrections into `tasks/lessons.md`
304
303
  - merge missing `external_tooling` defaults into `.ai/harness/policy.json` without overwriting explicit user values
305
- - keep gstack/gbrain/CodeGraph detection advisory-only; do not auto-install, auto-upgrade, auto-sync, or auto-enable MCP
306
- - let `forge init` bootstrap the required global runtime in one pass:
307
- CLI install, forge runtime alias sync, user-level hook adapters, Waza
308
- (`think`, `hunt`, `check`, `health`), Mermaid, brain root persistence, and
309
- CodeGraph CLI/MCP configuration
310
- - treat Waza as Codex-first: `~/.codex/skills` is the Codex runtime source, `~/.agents/skills` is only skills CLI staging/cache, and updates require stage -> copy to Codex -> `cmp` verification
304
+ - keep Waza, gstack, gbrain, Mermaid, and cross-review host skills optional; detect them but never make normal Forge execution depend on them
305
+ - `forge install` bootstraps only Forge-owned runtime and host adapters by default; install third-party host skills only with `--with-external-skills`
306
+ - Forge task routing uses `/direct`, `/plan`, `/debug`, `/review`, `/release`, and `/scale`; optional host skills may refine those workflows when already installed
307
+ - distinguish the bundled CodeGraph read backend used by `rh_context` from an optional global CodeGraph CLI/MCP integration; missing global CLI is not Runtime unready
311
308
 
312
309
  ## Repo-Local Contract
313
310
 
@@ -1,8 +1,8 @@
1
1
  # Third-party notices
2
2
 
3
- This inventory covers the direct runtime and development dependencies declared by `@moretea-labs/forge@1.5.0-rc.1`.
3
+ This inventory covers the direct runtime and development dependencies declared by `@moretea-labs/forge@1.5.0`.
4
4
 
5
- License values come from `package-lock.json` where available. For lock entries without a license field, the declared license was verified from package metadata during release-candidate preparation. This file is informational and does not replace the license text distributed by each dependency.
5
+ License values come from `package-lock.json` where available. For lock entries without a license field, the declared license was verified from package metadata during release preparation. This file is informational and does not replace the license text distributed by each dependency.
6
6
 
7
7
  | Package | Version | Role | Declared license | Source |
8
8
  | --- | --- | --- | --- | --- |
@@ -10,9 +10,15 @@ License values come from `package-lock.json` where available. For lock entries w
10
10
  | `commander` | `14.0.3` | runtime | `MIT` | package metadata |
11
11
  | `express` | `5.2.1` | runtime | `MIT` | package metadata |
12
12
  | `playwright` | `1.61.1` | runtime | `Apache-2.0` | package metadata |
13
+ | `react` | `19.2.8` | runtime | `MIT` | package metadata |
14
+ | `react-dom` | `19.2.8` | runtime | `MIT` | package metadata |
13
15
  | `agent-device` | `0.20.2` | optional runtime (iOS/Android device automation provider) | `MIT` | package-lock.json |
14
16
  | `@colbymchenry/codegraph` | `1.0.1` | development | `MIT` | package-lock.json |
15
17
  | `@types/bun` | `1.3.14` | development | `MIT` | package-lock.json |
16
18
  | `@types/cors` | `2.8.19` | development | `MIT` | package-lock.json |
17
19
  | `@types/express` | `5.0.6` | development | `MIT` | package-lock.json |
18
- | `typescript` | `6.0.3` | development | `Apache-2.0` | package metadata |
20
+ | `@types/react` | `19.2.18` | development | `MIT` | package metadata |
21
+ | `@types/react-dom` | `19.2.4` | development | `MIT` | package metadata |
22
+ | `@vitejs/plugin-react` | `5.2.0` | development | `MIT` | package metadata |
23
+ | `typescript` | `6.0.3` | runtime | `Apache-2.0` | package metadata |
24
+ | `vite` | `7.3.6` | development | `MIT` | package metadata |
@@ -2,9 +2,11 @@
2
2
 
3
3
  These files are the maintained, public-safe, first-party branding assets for **Forge**.
4
4
 
5
- - `docs/images/forge-banner.svg`: English README and social-share banner.
6
- - `docs/images/forge-banner-cn.svg`: Simplified Chinese README and social-share banner.
5
+ - `docs/images/forge-banner.svg`: English product hero / social-share banner — **ChatGPT decides. Forge acts.**
6
+ - `docs/images/forge-banner-cn.svg`: Simplified Chinese product hero / social-share banner — **ChatGPT 决策,Forge 执行。**
7
7
  - `docs/images/forge-controller-flow.svg`: current Forge controller and Runtime architecture diagram.
8
8
  - `forge-controller-flow.mmd`: editable Mermaid source for the architecture diagram.
9
9
 
10
+ The README hero should communicate the product before the architecture: ChatGPT is the controller; Forge is the controlled action layer for local files, commands, code, browser/desktop, Apple workflows, and typed plugins.
11
+
10
12
  Use **Forge** in prose and lowercase `forge` only for commands, package paths, protocol identifiers, state paths, filenames, or code symbols. Do not add previous-product branding, compatibility messaging, third-party logos, trademarks, or stock illustrations.
@@ -91,7 +91,7 @@ workflow_runs_dir() {
91
91
  }
92
92
 
93
93
  workflow_resume_packet_file() {
94
- workflow_repo_relative_path "$(workflow_policy_get '.handoff_resume.resume_packet_file' '.ai/harness/handoff/resume.md')" '.ai/harness/handoff/resume.md' '.ai/harness/'
94
+ workflow_repo_relative_path "$(workflow_policy_get '.session.resume_file' '.ai/harness/session/resume.md')" '.ai/harness/session/resume.md' '.ai/harness/'
95
95
  }
96
96
 
97
97
  workflow_pending_orchestration_file() {
@@ -104,14 +104,14 @@ workflow_ensure_harness_surface() {
104
104
  "$(dirname "$(workflow_context_map_file)")" \
105
105
  "$(dirname "$(workflow_policy_file)")" \
106
106
  "$(dirname "$(workflow_checks_file)")" \
107
- "$(dirname "$(workflow_handoff_file)")" \
107
+ "$(dirname "$(workflow_session_continuation_file)")" \
108
108
  "$(dirname "$(workflow_resume_packet_file)")" \
109
109
  "$(dirname "$(workflow_failure_log_file)")" \
110
110
  "$(dirname "$(workflow_pending_orchestration_file)")" \
111
111
  "$(workflow_runs_dir)"
112
112
 
113
113
  [[ -f "$(workflow_checks_file)" ]] || printf "{}\n" > "$(workflow_checks_file)"
114
- [[ -f "$(workflow_handoff_file)" ]] || printf "# Harness Handoff\n\n> **Reason**: bootstrap\n" > "$(workflow_handoff_file)"
114
+ [[ -f "$(workflow_session_continuation_file)" ]] || printf "# Forge Session Continuation Snapshot\n\n> **Reason**: bootstrap\n" > "$(workflow_session_continuation_file)"
115
115
  [[ -f "$(workflow_resume_packet_file)" ]] || printf "# Codex Resume Packet\n\n> **Reason**: bootstrap\n" > "$(workflow_resume_packet_file)"
116
116
  [[ -f "$(workflow_failure_log_file)" ]] || : > "$(workflow_failure_log_file)"
117
117
  [[ -f "$(workflow_events_file)" ]] || : > "$(workflow_events_file)"
@@ -606,17 +606,17 @@ workflow_next_action() {
606
606
  checks_file="$(workflow_checks_file)"
607
607
 
608
608
  if [[ -z "$review_file" || ! -f "$review_file" ]]; then
609
- printf 'check\t/check\tStage the completed module diff first; then run /check and record a sprint review before finishing this worktree.\n'
609
+ printf 'review\t/review\tStage the completed module diff first; then run /review and record a sprint review before finishing this worktree.\n'
610
610
  return 0
611
611
  fi
612
612
 
613
613
  if ! workflow_review_recommends_pass "$review_file"; then
614
- printf 'check\t/check\tStage the completed module diff first; then run /check until %s records Recommendation: pass.\n' "$review_file"
614
+ printf 'review\t/review\tStage the completed module diff first; then run /review until %s records Recommendation: pass.\n' "$review_file"
615
615
  return 0
616
616
  fi
617
617
 
618
618
  if [[ -z "$contract_file" || ! -f "$contract_file" ]]; then
619
- printf 'check\t/check\tStage the completed module diff first; then regenerate the active sprint contract and run /check.\n'
619
+ printf 'check\t/check\tStage the completed module diff first; then regenerate the active sprint contract and run /review.\n'
620
620
  return 0
621
621
  fi
622
622
 
@@ -629,7 +629,7 @@ workflow_next_action() {
629
629
  fi
630
630
 
631
631
  if [[ ! -f "$checks_file" ]]; then
632
- printf 'check\t/check\tStage the completed module diff first; then run /check and verify-sprint so %s exists.\n' "$checks_file"
632
+ printf 'review\t/review\tStage the completed module diff first; then run /review and verify-sprint so %s exists.\n' "$checks_file"
633
633
  return 0
634
634
  fi
635
635
 
@@ -1111,8 +1111,8 @@ workflow_checks_file() {
1111
1111
  workflow_repo_relative_path "$(workflow_policy_get '.harness.checks_file' '.ai/harness/checks/latest.json')" '.ai/harness/checks/latest.json' '.ai/harness/'
1112
1112
  }
1113
1113
 
1114
- workflow_handoff_file() {
1115
- workflow_repo_relative_path "$(workflow_policy_get '.harness.handoff_file' '.ai/harness/handoff/current.md')" '.ai/harness/handoff/current.md' '.ai/harness/'
1114
+ workflow_session_continuation_file() {
1115
+ workflow_repo_relative_path "$(workflow_policy_get '.session.continuation_file' '.ai/harness/session/continuation.md')" '.ai/harness/session/continuation.md' '.ai/harness/'
1116
1116
  }
1117
1117
 
1118
1118
  # mkdir-based mutual exclusion (macOS ships no flock). Spins ~2s, breaks locks
@@ -1258,7 +1258,7 @@ workflow_write_run_summary() {
1258
1258
  --arg active_review "${active_review:-}" \
1259
1259
  --arg active_notes "${active_notes:-}" \
1260
1260
  --arg checks_file "$(workflow_checks_file)" \
1261
- --arg handoff_file "$(workflow_handoff_file)" \
1261
+ --arg handoff_file "$(workflow_session_continuation_file)" \
1262
1262
  --arg policy_file "$(workflow_policy_file)" \
1263
1263
  --arg context_map_file "$(workflow_context_map_file)" \
1264
1264
  '{
@@ -1278,7 +1278,7 @@ workflow_write_run_summary() {
1278
1278
  fi
1279
1279
 
1280
1280
  cat > "$output_file" <<EOF_RUN
1281
- {"generated_at":"$(workflow_json_escape "$(date '+%Y-%m-%dT%H:%M:%S%z')")","run_id":"$(workflow_json_escape "$run_id")","reason":"$(workflow_json_escape "$reason")","checks_file":"$(workflow_json_escape "$(workflow_checks_file)")","handoff_file":"$(workflow_json_escape "$(workflow_handoff_file)")"}
1281
+ {"generated_at":"$(workflow_json_escape "$(date '+%Y-%m-%dT%H:%M:%S%z')")","run_id":"$(workflow_json_escape "$run_id")","reason":"$(workflow_json_escape "$reason")","checks_file":"$(workflow_json_escape "$(workflow_checks_file)")","handoff_file":"$(workflow_json_escape "$(workflow_session_continuation_file)")"}
1282
1282
  EOF_RUN
1283
1283
  }
1284
1284
 
@@ -1531,16 +1531,17 @@ workflow_contract_allows_path() {
1531
1531
 
1532
1532
  return 1
1533
1533
  }
1534
- workflow_write_handoff() {
1534
+ workflow_write_session_continuation() {
1535
+ # This file is a rebuildable host-session cache. Runtime HandoffItem/rh_inbox owns decisions that require ChatGPT or user judgement.
1535
1536
  local reason="${1:-session-stop}"
1536
- local handoff_file active_plan active_contract active_review active_notes checks_file next_task changed_files diff_stat spec_file source_plan parent_run_id supersedes
1537
+ local continuation_file active_plan active_contract active_review active_notes checks_file next_task changed_files diff_stat spec_file source_plan parent_run_id supersedes
1537
1538
  local next_action next_stage next_command next_message
1538
1539
  local resume_file trace_file recent_commands blockers decisions goal latest_trace_file
1539
1540
  local active_sprint active_sprint_row
1540
1541
  local changed_count untracked_count
1541
1542
 
1542
1543
  workflow_ensure_harness_surface
1543
- handoff_file="$(workflow_handoff_file)"
1544
+ continuation_file="$(workflow_session_continuation_file)"
1544
1545
  checks_file="$(workflow_checks_file)"
1545
1546
  resume_file="$(workflow_resume_packet_file)"
1546
1547
  spec_file="docs/spec.md"
@@ -1637,7 +1638,7 @@ workflow_write_handoff() {
1637
1638
  else
1638
1639
  goal="No active plan. Continue from the latest user request and filesystem state."
1639
1640
  fi
1640
- decisions="Use filesystem artifacts as source of truth; treat SQLite/thread state as a rebuildable read model only."
1641
+ decisions="Canonical Runtime control-plane state is authoritative for migrated repositories. This snapshot is a non-authoritative, rebuildable session continuation cache derived from current source artifacts and evidence."
1641
1642
  blockers="(none recorded)"
1642
1643
  if [[ -f "$checks_file" ]] && command -v jq >/dev/null 2>&1; then
1643
1644
  latest_trace_file="$(jq -r '.run_file // empty' "$checks_file" 2>/dev/null || true)"
@@ -1646,8 +1647,8 @@ workflow_write_handoff() {
1646
1647
  fi
1647
1648
  latest_trace_file="${latest_trace_file:-$checks_file}"
1648
1649
 
1649
- cat > "$handoff_file" <<EOF_HANDOFF
1650
- # Harness Handoff
1650
+ cat > "$continuation_file" <<EOF_HANDOFF
1651
+ # Forge Session Continuation Snapshot
1651
1652
 
1652
1653
  > **Generated**: $(date '+%Y-%m-%d %H:%M:%S')
1653
1654
  > **Reason**: ${reason}
@@ -1695,7 +1696,7 @@ ${recent_commands}
1695
1696
  ## Resume Prompt
1696
1697
 
1697
1698
  - Resume packet: ${resume_file}
1698
- - Start a fresh Codex session and read source artifacts first, then this handoff, before continuing; do not rely on auto-compact.
1699
+ - Start a fresh host session and read the current user input and Canonical Runtime state first. Use this snapshot only as bounded recovery context; do not treat it as lifecycle authority.
1699
1700
 
1700
1701
  ## Source Artifacts
1701
1702