@moretea-labs/forge 1.7.0 → 1.7.2
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.
- package/AGENTS.md +2 -0
- package/CHANGELOG.md +26 -0
- package/CLAUDE.md +2 -0
- package/THIRD_PARTY_NOTICES.md +1 -1
- package/agents/openai.yaml +1 -1
- package/assets/partials-agents/02-operating-mode.partial.md +2 -0
- package/assets/plugin-registry.v1.json +3 -3
- package/assets/skill-version.json +2 -2
- package/assets/templates/helpers/check-architecture-sync.sh +17 -0
- package/assets/templates/helpers/inspect-project-state.ts +8 -6
- package/assets/templates/helpers/migrate-workflow-docs.ts +9 -7
- package/assets/templates/helpers/workflow-contract.ts +5 -1
- package/docs/architecture/CURRENT.md +12 -4
- package/docs/forge-plugin-management.md +1 -1
- package/docs/operations/controller-performance-and-502.md +19 -0
- package/docs/operations/homebrew.md +2 -2
- package/package.json +5 -2
- package/scripts/architecture-event.ts +2 -820
- package/scripts/architecture-queue.sh +2 -645
- package/scripts/archive-architecture-request.sh +2 -242
- package/scripts/archive-workflow.sh +1 -291
- package/scripts/benchmark-work-efficiency.ts +0 -0
- package/scripts/capability-config.ts +2 -392
- package/scripts/capability-resolver.ts +2 -503
- package/scripts/capture-plan.sh +1 -332
- package/scripts/check-agent-tooling.sh +2 -1531
- package/scripts/check-architecture-sync.sh +2 -302
- package/scripts/check-brain-manifest.sh +2 -253
- package/scripts/check-context-files.sh +2 -47
- package/scripts/check-deploy-sql-order.sh +2 -115
- package/scripts/check-runtime-architecture.mjs +243 -16
- package/scripts/check-skill-version.ts +3 -191
- package/scripts/check-source-duplication.mjs +61 -0
- package/scripts/check-stable-baseline.ts +0 -0
- package/scripts/check-task-sync.sh +2 -63
- package/scripts/check-task-workflow.sh +2 -1000
- package/scripts/codex-handoff-resume.sh +2 -267
- package/scripts/context-contract-sync.sh +2 -514
- package/scripts/contract-run.ts +2 -463
- package/scripts/contract-worktree.sh +1 -702
- package/scripts/ensure-task-workflow.sh +1 -1192
- package/scripts/inspect-project-state.ts +4 -279
- package/scripts/lib/project-init-lib.sh +7 -2
- package/scripts/lib/run-forge-helper.sh +19 -0
- package/scripts/lib/run-forge-helper.ts +26 -0
- package/scripts/migrate-project-template.sh +1 -33
- package/scripts/migrate-workflow-docs.ts +4 -412
- package/scripts/new-plan.sh +1 -180
- package/scripts/new-spec.sh +1 -47
- package/scripts/new-sprint.sh +1 -46
- package/scripts/plan-to-todo.sh +1 -771
- package/scripts/prepare-codex-handoff.sh +2 -201
- package/scripts/prepare-handoff.sh +1 -78
- package/scripts/refresh-current-status.sh +2 -467
- package/scripts/run-governed-gate.ts +3 -0
- package/scripts/select-agent-context-blocks.sh +2 -64
- package/scripts/ship-worktrees.sh +1 -531
- package/scripts/sprint-backlog.sh +1 -834
- package/scripts/stage-runtime-release.ts +2 -1
- package/scripts/summarize-failures.sh +2 -123
- package/scripts/switch-plan.sh +1 -150
- package/scripts/sync-brain-docs.sh +2 -379
- package/scripts/sync-generated-authority.mjs +175 -0
- package/scripts/verify-contract.sh +2 -593
- package/scripts/verify-sprint.sh +1 -500
- package/scripts/workflow-contract.ts +4 -201
- package/scripts/workstream-sync.sh +2 -261
- package/src/cli/agent-jobs/executor-health.ts +1 -1
- package/src/cli/commands/plugin.ts +12 -3
- package/src/cli/controller/check-runner.ts +7 -2
- package/src/cli/controller/context-pack.ts +46 -21
- package/src/cli/github/contracts.ts +16 -0
- package/src/cli/github/github.ts +2 -16
- package/src/cli/github/session.ts +2 -1
- package/src/cli/local-bridge/facade-api.ts +37 -47
- package/src/cli/local-bridge/server.ts +2 -2
- package/src/cli/mcp/legacy-tool-service.ts +10 -33
- package/src/cli/mcp/post-finalize-work-attribution.ts +150 -0
- package/src/cli/mcp/repository-tools.ts +125 -101
- package/src/cli/mcp/server.ts +57 -13
- package/src/cli/mcp/tool-contract.ts +14 -0
- package/src/cli/mcp/toolset.ts +2 -2
- package/src/cli/mcp/transports/http.ts +23 -0
- package/src/cli/repositories/command-classifier.ts +2 -2
- package/src/cli/repositories/command-executor.ts +24 -6
- package/src/cli/repositories/repository-snapshot.ts +5 -2
- package/src/cli/repositories/structured-git.ts +57 -3
- package/src/cli/repository/inspector.ts +11 -3
- package/src/runtime/context/generic-lsp-provider.ts +1 -1
- package/src/runtime/context/semantic-navigation-contract.ts +61 -0
- package/src/runtime/context/semantic-navigation.ts +9 -61
- package/src/runtime/control-plane/execution/direct-edit-work-completion.ts +69 -29
- package/src/runtime/control-plane/execution/repository-work-attribution.ts +106 -0
- package/src/runtime/control-plane/execution/retained-work-resume.ts +203 -0
- package/src/runtime/control-plane/execution/work-completion-authority.ts +58 -0
- package/src/runtime/control-plane/execution/work-evidence-policy.ts +200 -0
- package/src/runtime/control-plane/execution/work-execution-support.ts +386 -0
- package/src/runtime/control-plane/execution/work-finalization-service.ts +1913 -0
- package/src/runtime/control-plane/execution/work-handle-authority.ts +150 -0
- package/src/runtime/control-plane/execution/work-handle-store.ts +1 -1
- package/src/runtime/control-plane/execution/work-operation-service.ts +468 -0
- package/src/runtime/control-plane/execution/work-path-scope.ts +37 -0
- package/src/runtime/control-plane/execution/work-preparation-service.ts +479 -0
- package/src/runtime/control-plane/execution/work-process-evidence.ts +129 -0
- package/src/runtime/control-plane/execution/work-task-receipt.ts +4 -43
- package/src/runtime/control-plane/execution/work-terminal-cleanup.ts +13 -3
- package/src/runtime/control-plane/execution/work-verification-context.ts +56 -0
- package/src/runtime/control-plane/execution/work-verification-service.ts +388 -0
- package/src/runtime/control-plane/execution/work-verification-snapshot.ts +5 -1
- package/src/runtime/control-plane/facade/controller-round-relay.ts +164 -37
- package/src/runtime/control-plane/facade/controller-session-store.ts +183 -24
- package/src/runtime/control-plane/facade/goal-workloop-access.ts +15 -1
- package/src/runtime/control-plane/facade/goal-workloop.ts +329 -148
- package/src/runtime/control-plane/facade/index.ts +2 -0
- package/src/runtime/control-plane/facade/plan-contract-store.ts +90 -22
- package/src/runtime/control-plane/facade/repository-work-admission.ts +147 -0
- package/src/runtime/control-plane/facade/requirement-authority.ts +83 -0
- package/src/runtime/control-plane/facade/types.ts +68 -5
- package/src/runtime/control-plane/facade/work-contract-store.ts +3 -209
- package/src/runtime/control-plane/facade/work-state-machine.ts +250 -0
- package/src/runtime/control-plane/global-scheduler/maintenance.ts +14 -7
- package/src/runtime/control-plane/global-scheduler/scheduler.ts +5 -1
- package/src/runtime/control-plane/launcher/chatgpt-work-binding-store.ts +13 -0
- package/src/runtime/control-plane/launcher/chatgpt-work-continuation.ts +15 -6
- package/src/runtime/control-plane/launcher/launch-reservation-store.ts +54 -5
- package/src/runtime/control-plane/launcher/thin-launcher.ts +56 -7
- package/src/runtime/control-plane/persistence/requirement-store.ts +0 -12
- package/src/runtime/control-plane/repo-actor/registry.ts +4 -2
- package/src/runtime/control-plane/routing/route-policy.ts +18 -6
- package/src/runtime/control-plane/routing/workspace-admission.ts +70 -0
- package/src/runtime/evidence/process-check-execution.ts +18 -0
- package/src/runtime/execution/jobs/child-reference.ts +6 -2
- package/src/runtime/execution/process-runtime/check-result.ts +53 -18
- package/src/runtime/execution/process-runtime/check-runner-sidecar.ts +7 -1
- package/src/runtime/execution/process-runtime/command-facade.ts +39 -17
- package/src/runtime/execution/process-runtime/lightweight-managed.ts +20 -3
- package/src/runtime/execution/process-runtime/persisted-check.ts +4 -1
- package/src/runtime/execution/process-runtime/runtime.ts +10 -0
- package/src/runtime/execution/process-runtime/types.ts +2 -12
- package/src/runtime/execution/work-activity.ts +21 -0
- package/src/runtime/execution/workers/executor.ts +18 -13
- package/src/runtime/gateway/mcp/execution-tools.ts +35 -2930
- package/src/runtime/gateway/mcp/legacy-ios-tool-adapter.ts +61 -0
- package/src/runtime/gateway/mcp/router.ts +2 -2
- package/src/runtime/gateway/mcp/runtime-tool-definitions.ts +21 -2
- package/src/runtime/gateway/mcp/runtime-tools.ts +815 -1015
- package/src/runtime/plugins/app-store-connect-adapter.ts +93 -28
- package/src/runtime/plugins/browser-adapter.ts +256 -1083
- package/src/runtime/plugins/browser-handoff-host.ts +2 -25
- package/src/runtime/plugins/browser-handoff.ts +18 -3
- package/src/runtime/plugins/browser-macos-bridge.ts +121 -16
- package/src/runtime/plugins/browser-manifest-surface.ts +603 -0
- package/src/runtime/plugins/browser-native-session-service.ts +222 -0
- package/src/runtime/plugins/browser-runtime-contract.ts +2 -0
- package/src/runtime/plugins/browser-runtime.ts +10 -0
- package/src/runtime/plugins/browser-session-store.ts +121 -0
- package/src/runtime/plugins/browser-session-types.ts +98 -0
- package/src/runtime/plugins/desktop-operator-registration.ts +4 -4
- package/src/runtime/plugins/external-adapter.ts +92 -58
- package/src/runtime/plugins/macos-capability-broker.ts +0 -8
- package/src/runtime/plugins/store.ts +66 -9
- package/src/runtime/plugins/types.ts +3 -1
- package/src/runtime/recovery/maintenance-executor.ts +61 -25
- package/src/runtime/root/package-connector-service.ts +46 -4
- package/src/runtime/root/package-runtime-release.ts +3 -2
- package/src/runtime/root/package-runtime-service.ts +48 -3
- package/src/runtime/root/release-manifest.ts +137 -16
- package/src/runtime/root/release-materialize.ts +109 -35
- package/src/runtime/root/types.ts +10 -0
- package/src/runtime/standalone-recovery/core.ts +425 -194
- package/src/runtime/standalone-recovery/entry.ts +1 -1
- package/src/runtime/standalone-recovery/installer.ts +1 -1
- package/src/runtime/workflow/schedules/engine.ts +113 -87
- package/src/runtime/workflow/schedules/settlement.ts +26 -23
- package/src/runtime/workflow/schedules/store.ts +79 -10
package/AGENTS.md
CHANGED
|
@@ -43,6 +43,8 @@ Treat ChatGPT as the controller and Forge as its repository execution layer. Cha
|
|
|
43
43
|
|
|
44
44
|
## Operating Rules
|
|
45
45
|
|
|
46
|
+
- Default to end-to-end execution and minimize avoidable human intervention. Continue through reversible, policy-allowed setup, implementation, verification, cleanup, and delivery steps without asking the user to babysit the workflow; stop only at a genuinely user-only identity, legal/contract, financial authorization, strong-confirmation, or irreversible decision boundary.
|
|
47
|
+
- For authenticated browser work, preserve the user's existing browser identity: reuse the already-running signed-in Google Chrome via attach-preferred, native-auto, Chrome-only, fail-closed routing. Preserve its cookies, tokens, sessions, and settings; never silently launch or switch to a managed, isolated, Vivaldi, or otherwise unauthenticated browser/profile. Managed or isolated browser modes require an explicit task/action request. If the user Chrome cannot be attached safely, fail closed and surface the concrete blocker instead of creating a replacement login state.
|
|
46
48
|
- After a managed repository change is verified and committed/merged, push the delivered target branch to its configured remote promptly. Do not leave a successfully delivered commit only on local refs unless the user explicitly requested local-only delivery or the push is blocked by safety, permissions, authentication, or branch policy; surface the exact blocker when a push cannot complete.
|
|
47
49
|
- Treat the Google Cloud `forge-cloud` VM experiment as retired infrastructure. Do not restart or reuse that VM for Forge Cloud. Any future remote Forge maintainer must use a separately evaluated host/transport and must demonstrate better latency and reliability than the local Forge path before adoption.
|
|
48
50
|
- Sync `tasks/` whenever substantive repo changes are made.
|
package/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,32 @@ All notable public Forge changes are recorded here. Release entries are tied to
|
|
|
4
4
|
|
|
5
5
|
## Unreleased
|
|
6
6
|
|
|
7
|
+
## 1.7.2 - 2026-08-30
|
|
8
|
+
|
|
9
|
+
### Runtime lifecycle reliability
|
|
10
|
+
|
|
11
|
+
- Restart an already-active Linux/systemd Runtime after immutable package activation so the running process cannot remain fenced behind a newer release-authority revision.
|
|
12
|
+
- Avoid duplicate systemd process-group shutdown signals from the package launcher, allowing controlled Runtime restarts to terminate cleanly.
|
|
13
|
+
|
|
14
|
+
### Work and Controller authority
|
|
15
|
+
|
|
16
|
+
- Promote effect Work to repository-change authority before governed source mutation and add narrowly fenced reconciliation for already-delivered historical effect Work.
|
|
17
|
+
- Preserve authenticated explicit Controller session capability across MCP transport rotation while keeping same-principal conversations isolated.
|
|
18
|
+
- Make the Windows worker-stderr path assertion platform-correct without changing production path behavior.
|
|
19
|
+
|
|
20
|
+
## 1.7.1 - 2026-08-30
|
|
21
|
+
|
|
22
|
+
### Runtime and lifecycle stabilization
|
|
23
|
+
|
|
24
|
+
- Prevent effect-only Work from losing repository source deltas during finalization, and recognize successful trusted Work-bound `git push` Process receipts as remote-effect completion authority.
|
|
25
|
+
- Harden controller continuation and terminalization across MCP/session rollover while keeping unrelated conversations isolated, and add stable Requirement-backed business-goal identity so stale continuation cannot silently revive superseded goals.
|
|
26
|
+
- Add bounded post-deadline external Codex claim settlement plus precise Work checkout-mismatch diagnostics, preserving fail-closed fencing without false launcher timeouts.
|
|
27
|
+
|
|
28
|
+
### Browser and release closure
|
|
29
|
+
|
|
30
|
+
- Converge Browser/desktop automation on the signed Forge Desktop Operator boundary, retain Runtime packaging for the browser handoff host, and close historical capability/permission drift without granting privileged macOS access to Runtime.
|
|
31
|
+
- Re-run the full main, MCP compatibility, package, public-surface, open-source, tarball-install, Runtime Recovery, schedule, and tool-surface release contracts before publication.
|
|
32
|
+
|
|
7
33
|
## 1.7.0 - 2026-08-27
|
|
8
34
|
|
|
9
35
|
### Persistent autonomous control
|
package/CLAUDE.md
CHANGED
|
@@ -43,6 +43,8 @@ Treat ChatGPT as the controller and Forge as its repository execution layer. Cha
|
|
|
43
43
|
|
|
44
44
|
## Operating Rules
|
|
45
45
|
|
|
46
|
+
- Default to end-to-end execution and minimize avoidable human intervention. Continue through reversible, policy-allowed setup, implementation, verification, cleanup, and delivery steps without asking the user to babysit the workflow; stop only at a genuinely user-only identity, legal/contract, financial authorization, strong-confirmation, or irreversible decision boundary.
|
|
47
|
+
- For authenticated browser work, preserve the user's existing browser identity: reuse the already-running signed-in Google Chrome via attach-preferred, native-auto, Chrome-only, fail-closed routing. Preserve its cookies, tokens, sessions, and settings; never silently launch or switch to a managed, isolated, Vivaldi, or otherwise unauthenticated browser/profile. Managed or isolated browser modes require an explicit task/action request. If the user Chrome cannot be attached safely, fail closed and surface the concrete blocker instead of creating a replacement login state.
|
|
46
48
|
- After a managed repository change is verified and committed/merged, push the delivered target branch to its configured remote promptly. Do not leave a successfully delivered commit only on local refs unless the user explicitly requested local-only delivery or the push is blocked by safety, permissions, authentication, or branch policy; surface the exact blocker when a push cannot complete.
|
|
47
49
|
- Treat the Google Cloud `forge-cloud` VM experiment as retired infrastructure. Do not restart or reuse that VM for Forge Cloud. Any future remote Forge maintainer must use a separately evaluated host/transport and must demonstrate better latency and reliability than the local Forge path before adoption.
|
|
48
50
|
- Sync `tasks/` whenever substantive repo changes are made.
|
package/THIRD_PARTY_NOTICES.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Third-party notices
|
|
2
2
|
|
|
3
|
-
This inventory covers the direct runtime and development dependencies declared by `@moretea-labs/forge@1.7.
|
|
3
|
+
This inventory covers the direct runtime and development dependencies declared by `@moretea-labs/forge@1.7.2`.
|
|
4
4
|
|
|
5
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
|
|
package/agents/openai.yaml
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
interface:
|
|
2
2
|
display_name: "forge"
|
|
3
3
|
short_description: "Operate Forge workflows for repository planning, execution, verification, migration, audit, and repair"
|
|
4
|
-
default_prompt: "Use Forge to inspect this repository, choose the smallest appropriate workflow, and carry
|
|
4
|
+
default_prompt: "Use Forge to inspect this repository, choose the smallest appropriate workflow, and carry the requested work through implementation, verification, cleanup, and delivery with bounded evidence while minimizing avoidable human intervention. Continue reversible policy-allowed steps autonomously and stop only at a genuinely user-only identity/legal/financial/strong-confirmation/irreversible boundary. For authenticated browser work, reuse the user's already-running signed-in Google Chrome with attach-preferred, native-auto, Chrome-only, fail-closed routing; preserve its cookies/tokens/sessions/settings and never silently launch or switch to a managed, isolated, Vivaldi, or otherwise unauthenticated profile unless the task explicitly requests that mode. After verified repository delivery, promptly push the committed/merged target branch to its configured remote unless the user explicitly requested local-only delivery or the push is blocked; report any blocker precisely."
|
|
@@ -8,6 +8,8 @@
|
|
|
8
8
|
- Claude runtime expectation: `{{CLAUDE_POLICY}}`.
|
|
9
9
|
- Codex runtime expectation: `{{CODEX_POLICY}}`.
|
|
10
10
|
- Do not implement until the user explicitly asks to implement.
|
|
11
|
+
- Once the user asks to execute, minimize avoidable human intervention: continue reversible, policy-allowed implementation, verification, cleanup, and delivery autonomously, stopping only at a genuinely user-only identity/legal/financial/strong-confirmation/irreversible boundary.
|
|
12
|
+
- For authenticated browser work, reuse the user's already-running signed-in Google Chrome with attach-preferred, native-auto, Chrome-only, fail-closed routing. Preserve cookies, tokens, sessions, and settings; never silently switch to a managed, isolated, Vivaldi, or otherwise unauthenticated profile unless the task explicitly requests that mode.
|
|
11
13
|
- Stable product truth: `docs/spec.md`.
|
|
12
14
|
- Research reports: `docs/researches/`.
|
|
13
15
|
- Deferred-goal ledger: `tasks/todos.md` (active execution stays in the plan's `## Task Breakdown`).
|
|
@@ -4,12 +4,12 @@
|
|
|
4
4
|
{
|
|
5
5
|
"id": "desktop_operator",
|
|
6
6
|
"name": "Forge Desktop Operator",
|
|
7
|
-
"version": "0.2.
|
|
7
|
+
"version": "0.2.3",
|
|
8
8
|
"description": "Native macOS desktop automation provider for Forge.",
|
|
9
9
|
"repository": "https://github.com/moretea-labs/forge-desktop-operator.git",
|
|
10
|
-
"ref": "v0.2.
|
|
10
|
+
"ref": "v0.2.3",
|
|
11
11
|
"installer": "forge-plugin-install.mjs",
|
|
12
|
-
"providerVersion": "0.2.
|
|
12
|
+
"providerVersion": "0.2.3",
|
|
13
13
|
"protocolVersion": "1.0",
|
|
14
14
|
"platforms": [
|
|
15
15
|
"darwin"
|
|
@@ -212,6 +212,23 @@ if ! bash scripts/architecture-queue.sh reindex --check >/dev/null; then
|
|
|
212
212
|
exit 1
|
|
213
213
|
fi
|
|
214
214
|
|
|
215
|
+
if [[ -f "docs/architecture/current/README.md" ]]; then
|
|
216
|
+
if [[ ! -f "docs/architecture/CURRENT.md" ]]; then
|
|
217
|
+
echo "[ArchitectureSync] architecture baseline failed: missing required file docs/architecture/CURRENT.md" >&2
|
|
218
|
+
exit 1
|
|
219
|
+
fi
|
|
220
|
+
|
|
221
|
+
if ! grep -Fq "Runtime Authority" "docs/architecture/CURRENT.md"; then
|
|
222
|
+
echo "[ArchitectureSync] architecture baseline failed: docs/architecture/CURRENT.md must contain: Runtime Authority" >&2
|
|
223
|
+
exit 1
|
|
224
|
+
fi
|
|
225
|
+
|
|
226
|
+
if ! grep -Fq "Not Runtime Authority" "docs/architecture/current/README.md"; then
|
|
227
|
+
echo "[ArchitectureSync] architecture baseline failed: docs/architecture/current/README.md must contain: Not Runtime Authority" >&2
|
|
228
|
+
exit 1
|
|
229
|
+
fi
|
|
230
|
+
fi
|
|
231
|
+
|
|
215
232
|
if [[ "$mode" == "off" ]]; then
|
|
216
233
|
case "$format" in
|
|
217
234
|
json) printf '{"mode":"off","changed_capabilities":0,"blocking":0}\n' ;;
|
|
@@ -270,11 +270,13 @@ function renderText(result: InspectionResult): string {
|
|
|
270
270
|
return lines.join("\n");
|
|
271
271
|
}
|
|
272
272
|
|
|
273
|
-
|
|
274
|
-
const
|
|
273
|
+
if (import.meta.main) {
|
|
274
|
+
const { repo, format } = parseArgs(process.argv.slice(2));
|
|
275
|
+
const result = inspectRepo(repo);
|
|
275
276
|
|
|
276
|
-
if (format === "text") {
|
|
277
|
-
|
|
278
|
-
} else {
|
|
279
|
-
|
|
277
|
+
if (format === "text") {
|
|
278
|
+
console.log(renderText(result));
|
|
279
|
+
} else {
|
|
280
|
+
console.log(JSON.stringify(result, null, 2));
|
|
281
|
+
}
|
|
280
282
|
}
|
|
@@ -403,11 +403,13 @@ function renderText(summary: MigrationSummary): string {
|
|
|
403
403
|
return lines.join("\n");
|
|
404
404
|
}
|
|
405
405
|
|
|
406
|
-
|
|
407
|
-
const
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
406
|
+
if (import.meta.main) {
|
|
407
|
+
const { repo, mode, format } = parseArgs(process.argv.slice(2));
|
|
408
|
+
const summary = migrate(repo, mode);
|
|
409
|
+
|
|
410
|
+
if (format === "json") {
|
|
411
|
+
console.log(JSON.stringify(summary, null, 2));
|
|
412
|
+
} else {
|
|
413
|
+
console.log(renderText(summary));
|
|
414
|
+
}
|
|
413
415
|
}
|
|
@@ -65,6 +65,10 @@ export type WorkflowContract = {
|
|
|
65
65
|
helpers: {
|
|
66
66
|
runtimeDirectory?: string;
|
|
67
67
|
compatibilityDirectory?: string;
|
|
68
|
+
/** Legacy manifest field retained for installed contract compatibility. */
|
|
69
|
+
dir?: string;
|
|
70
|
+
/** Legacy runtime-source discriminator still present in v1 manifests. */
|
|
71
|
+
runtimeSource?: string;
|
|
68
72
|
scripts: string[];
|
|
69
73
|
};
|
|
70
74
|
artifacts: {
|
|
@@ -185,7 +189,7 @@ export function getHelperScripts(contract: WorkflowContract): string[] {
|
|
|
185
189
|
}
|
|
186
190
|
|
|
187
191
|
export function getHelperRuntimeDir(contract: WorkflowContract): string {
|
|
188
|
-
return contract.helpers.dir ?? "scripts";
|
|
192
|
+
return contract.helpers.runtimeDirectory ?? contract.helpers.dir ?? contract.helpers.compatibilityDirectory ?? "scripts";
|
|
189
193
|
}
|
|
190
194
|
|
|
191
195
|
export function getRequiredDirectories(contract: WorkflowContract): string[] {
|
|
@@ -92,6 +92,11 @@ Explicit **Scale** is the opt-in coordination form of this existing model, not a
|
|
|
92
92
|
- Durable Process owns persisted command/check lifecycle only when the selected lane is durable.
|
|
93
93
|
- Runtime release/recovery state owns Forge service availability and immutable release activation; it is separate from ordinary command recovery. The canonical OS service executes an atomic byte-identical mirror of the selected signed Runtime entrypoint from the fixed physical `runtime/service/active-forge-runtime` path, while release resources and identity remain manifest-bound. The stable physical path prevents macOS TCC from treating every immutable release directory as a new responsible-process principal.
|
|
94
94
|
- Historical Issue/Task/Local Job and compatibility projections must not become second mutable authorities.
|
|
95
|
+
- Work lifecycle policy is separated from persistence: `work-state-machine.ts` owns legal phase/dispatch/evidence/completion transitions, while `work-contract-store.ts` owns locked persistence and applies that policy. Work completion projection is centralized in `work-completion-authority.ts`, and Work verification execution/evidence is centralized in `work-verification-service.ts`. Transports may submit requests and encode results but must not reimplement these rules.
|
|
96
|
+
- Work delivery/finalization is also an application service: `work-finalization-service.ts` owns the commit/merge/cleanup/receipt transaction and `work-execution-support.ts` owns shared exact identity/cleanup primitives. MCP `execution-tools.ts` and `rh_work` compatibility glue may prepare arguments or reconcile legacy handles, but they must enter that same finalization authority rather than perform Git delivery themselves.
|
|
97
|
+
- Work preparation/adoption is an application service as well: `work-preparation-service.ts` owns managed-workspace selection, WorkContract admission/reuse, exact successor-HEAD adoption and Controller ownership binding. MCP `execution-tools.ts` only decodes `work_prepare` / repository-bind requests and delegates; it must not recreate workspace admission or WorkHandle/WorkContract preparation transitions.
|
|
98
|
+
- Work command execution and validation live in `work-operation-service.ts`. Both MCP Gateway and Durable Worker call this application service directly; Workers must never dynamic-import MCP transport to obtain Work semantics. The architecture gate also forbids any `runtime/control-plane` source from depending back on `runtime/gateway`.
|
|
99
|
+
- Production Browser session persistence is Controller-home SQLite `BrowserSessionAuthority`. Compatibility JSON may be imported or used only when no Controller authority is available; handoff sidecars return interaction results and never write BrowserSession state directly.
|
|
95
100
|
|
|
96
101
|
## Runtime and MCP boundary
|
|
97
102
|
|
|
@@ -100,7 +105,8 @@ Explicit **Scale** is the opt-in coordination form of this existing model, not a
|
|
|
100
105
|
- The default Controller MCP schema is the stable **19-tool** surface.
|
|
101
106
|
- `core` and `advanced` expose that same stable surface.
|
|
102
107
|
- `toolset=full` is an explicit compatibility profile and may contain historical definitions; current default schema construction must not depend on those legacy definitions.
|
|
103
|
-
- Current schemas/handlers should live with their owning module. Legacy compatibility may delegate but must not independently own current business rules.
|
|
108
|
+
- Current schemas/handlers should live with their owning module. Legacy compatibility may delegate but must not independently own current business rules. Shared transport contracts and tool definitions belong in neutral contract/definition modules so the dependency direction remains transport -> application/domain authority rather than transport implementations importing one another.
|
|
109
|
+
- Work-attributed verification is an application service, not an MCP/Local Bridge implementation detail: all Work verification resolves the Work checkout/check registry, runs through Process Runtime, validates terminal receipt identity, and records Work evidence through the same `work-verification-service.ts`.
|
|
104
110
|
|
|
105
111
|
### Controller facade and handoff boundary
|
|
106
112
|
|
|
@@ -131,15 +137,17 @@ Browser providers are selected by declared capability. Common DOM and typed brow
|
|
|
131
137
|
|
|
132
138
|
Foreground presentation is an explicit effect reserved for capabilities that truly require physical pointer/keyboard input or human handoff. Browser `trusted_input` never silently activates a background tab or converts CSS viewport coordinates into desktop coordinates. If the native broker lacks the required trusted-input capability, Browser fails with a typed capability error; an explicitly requested Desktop Operator foreground/physical action remains a separate authority boundary. Mutating provider actions are complete only when their declared postconditions are verified; transport, Apple Events, Accessibility, socket, or CGEvent success alone is not semantic completion.
|
|
133
139
|
|
|
134
|
-
The public Browser action surface remains compatible across Playwright/CDP/native providers. Current native compatibility may omit optional broker methods such as global tab inventory while preserving exact-ref lifecycle safety. DOM automation through Chrome/Vivaldi Apple Events still requires the browser's JavaScript-from-Apple-Events permission; missing permission fails closed instead of weakening the provider contract.
|
|
140
|
+
The public Browser action surface remains compatible across Playwright/CDP/native providers. Current native compatibility may omit optional broker methods such as global tab inventory while preserving exact-ref lifecycle safety. DOM automation through Chrome/Vivaldi Apple Events still requires the browser's JavaScript-from-Apple-Events permission; missing permission fails closed instead of weakening the provider contract. Browser replay safety is derived from the Browser Runtime transaction contract rather than an adapter-local action allowlist, and native session liveness/reconciliation is centralized outside the plugin composition root. A human-handoff host may persist its own InteractionSession result, but BrowserSession mutation returns to the canonical Runtime authority.
|
|
135
141
|
|
|
136
142
|
## Testing and verification
|
|
137
143
|
|
|
138
144
|
Tests are verification evidence, not an alternate architecture authority.
|
|
139
145
|
|
|
140
|
-
- Development/task gate: typecheck + static architecture + manifest validity + affected tests.
|
|
146
|
+
- Development/task gate: typecheck + static architecture + generated-authority drift + source-duplication classification + controller-UI reproduction + manifest validity + affected tests.
|
|
141
147
|
- Main candidate: task gate + core regression + Runtime smoke.
|
|
142
148
|
- Release candidate: main gate + full regression + release packaging/readiness.
|
|
149
|
+
- Static architecture additionally requires the production `src/**/*.ts` relative-import graph to be acyclic. Neutral contracts may break dependency direction; dynamic imports must not be used merely to conceal a static architecture cycle.
|
|
150
|
+
- Source-duplication governance permits only classified distribution/template projections, guidance aliases, and placeholders; unclassified exact duplicates fail the gate. Generated copies may exist for packaging, but manual implementation duplication is not an accepted source-authoring model.
|
|
143
151
|
- Test governance validates registration, resource classification, selection and execution isolation; it does not impose arbitrary global test-line or resource-count budgets.
|
|
144
152
|
- Prefer a small number of architectural invariants, focused module tests and essential integration/E2E coverage. Delete implementation-coupled or retired-compatibility tests when the underlying obligation is removed.
|
|
145
153
|
|
|
@@ -163,7 +171,7 @@ Research notes, tasks, reviews, archived architecture pages, plans and Git histo
|
|
|
163
171
|
|
|
164
172
|
## Intentionally retained compatibility debt
|
|
165
173
|
|
|
166
|
-
- Explicit `toolset=full` remains a supported legacy compatibility boundary for now.
|
|
174
|
+
- Explicit `toolset=full` remains a supported legacy compatibility boundary for now. Issue/Task/project-board writers are migration-only compatibility and are permanently retired after the SQLite requirement-portfolio cutover marker; they must not become a second current control plane.
|
|
167
175
|
- Some large runtime modules still aggregate multiple responsibilities and should be decomposed only when a clear ownership boundary is available.
|
|
168
176
|
- CodeGraph may be structurally stale between index refreshes; current raw source and changed-file overlays remain authoritative.
|
|
169
177
|
|
|
@@ -10,7 +10,7 @@ forge plugin catalog
|
|
|
10
10
|
|
|
11
11
|
| Plugin ID | Product | Pinned release | Platforms |
|
|
12
12
|
| --- | --- | --- | --- |
|
|
13
|
-
| `desktop_operator` | [Forge Desktop Operator](https://github.com/moretea-labs/forge-desktop-operator) | `v0.2.
|
|
13
|
+
| `desktop_operator` | [Forge Desktop Operator](https://github.com/moretea-labs/forge-desktop-operator) | `v0.2.3` | macOS |
|
|
14
14
|
| `design` | [Forge Design](https://github.com/moretea-labs/forge-design) | `v0.3.0` | macOS, Linux, Windows |
|
|
15
15
|
| `personal_knowledge` | [Personal Knowledge Assistant](https://github.com/moretea-labs/personal-knowledge-assistant) | `v0.2.1` | macOS, Linux, Windows |
|
|
16
16
|
|
|
@@ -120,6 +120,25 @@ Corrected invariants:
|
|
|
120
120
|
reason and restart/failure counters) so incident review can distinguish "Recovery
|
|
121
121
|
never fired" from "Recovery fired and the client observed the bounded outage".
|
|
122
122
|
|
|
123
|
+
## Recurring Connection Failure Ledger
|
|
124
|
+
|
|
125
|
+
Keep these failure signatures distinct. A public `502` identifies the failed
|
|
126
|
+
hop; it does not identify the failed owner or authorize a whole-Runtime
|
|
127
|
+
rollback.
|
|
128
|
+
|
|
129
|
+
| Signature | Verified evidence | Correct recovery owner |
|
|
130
|
+
| --- | --- | --- |
|
|
131
|
+
| Runtime activation/port conflict | `RUNTIME_RELEASE_AUTHORITY_MISMATCH`, port `8767` already in use, or orphaned `mcp serve` | Whole-Runtime Recovery transaction; see the 2026-08-23 incident above. |
|
|
132
|
+
| Connector/release binding drift | Runtime `ready=true`, but Connector loopback/public MCP fails or returns `5xx` | Connector Recovery reconciles the active immutable release, then verifies local ownership and the public endpoint. |
|
|
133
|
+
| Connector launched with a Recovery-role binary | Connector plist starts `forge-recovery-gateway` or `forge-recovery-watchdog`; stderr repeats `RECOVERY_*_ROLE_ONLY` | Repair the Connector with the absolute interpreter recorded by Runtime activation. A Connector launch spec must reject a Recovery-role binary. |
|
|
134
|
+
| Connector outage misclassified as a Runtime outage | Runtime status and local active Gateway are healthy while the Watchdog records `restart_primary_runtime` for a Connector probe failure | Count and restart the Connector under its own bounded budget; do not consume the Runtime restart/rollback budget. |
|
|
135
|
+
|
|
136
|
+
The launch interpreter is part of the Connector's immutable release binding:
|
|
137
|
+
detached activation passes its recorded absolute `nodeExecutable` to candidate
|
|
138
|
+
and rollback Connector installs, and Recovery services retain the same explicit
|
|
139
|
+
interpreter for later binding repair. Regression coverage must exercise a
|
|
140
|
+
failed Connector while the Canonical Runtime remains healthy.
|
|
141
|
+
|
|
123
142
|
## Session Continuation Fails With 404 MCP_TOOL_SURFACE_CHANGED (2026-08-23)
|
|
124
143
|
|
|
125
144
|
Second incident on the same day, different failure mode. After a session is
|
|
@@ -6,8 +6,8 @@ Homebrew is planned as a convenience layer after the first stable npm/GitHub rel
|
|
|
6
6
|
|
|
7
7
|
Do not publish a formula until all of the following are true:
|
|
8
8
|
|
|
9
|
-
- `@moretea-labs/forge@1.7.
|
|
10
|
-
- Git tag and GitHub Release `v1.7.
|
|
9
|
+
- `@moretea-labs/forge@1.7.2` exists on npm;
|
|
10
|
+
- Git tag and GitHub Release `v1.7.2` exist and point to the tested commit;
|
|
11
11
|
- the npm tarball has an immutable checksum;
|
|
12
12
|
- macOS installation and `forge --version` / `forge doctor` tests pass;
|
|
13
13
|
- upgrade and uninstall behavior is documented.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@moretea-labs/forge",
|
|
3
|
-
"version": "1.7.
|
|
3
|
+
"version": "1.7.2",
|
|
4
4
|
"description": "Local-first action assistant for software work with resumable execution, bounded tools, and reviewable evidence",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Moretea Labs contributors",
|
|
@@ -106,6 +106,8 @@
|
|
|
106
106
|
"test:coverage": "bun test --coverage",
|
|
107
107
|
"check:type": "bun x tsc --noEmit",
|
|
108
108
|
"check:runtime-architecture": "node scripts/check-runtime-architecture.mjs",
|
|
109
|
+
"check:generated-authority": "node scripts/sync-generated-authority.mjs --check",
|
|
110
|
+
"check:source-duplication": "node scripts/check-source-duplication.mjs",
|
|
109
111
|
"check:executable-modes": "bun scripts/repair-executable-modes.ts --check",
|
|
110
112
|
"repair:executable-modes": "bun scripts/repair-executable-modes.ts",
|
|
111
113
|
"check:test-governance": "bun scripts/test-governance.ts validate",
|
|
@@ -151,7 +153,8 @@
|
|
|
151
153
|
"test:bun": "bun -e 'console.error(\"[tests] test:bun is deprecated; running explicit test:full\")' && bun run test:full",
|
|
152
154
|
"test:node-smoke": "node --test tests/node/*.test.mjs",
|
|
153
155
|
"check:ci:portable": "FORGE_ALLOW_NODE_ONLY=1 bash scripts/check-ci.sh",
|
|
154
|
-
"dev:controller-ui": "vite --config src/cli/local-bridge/frontend/vite.config.ts"
|
|
156
|
+
"dev:controller-ui": "vite --config src/cli/local-bridge/frontend/vite.config.ts",
|
|
157
|
+
"prepack": "node scripts/sync-generated-authority.mjs --check"
|
|
155
158
|
},
|
|
156
159
|
"devDependencies": {
|
|
157
160
|
"@colbymchenry/codegraph": "1.0.1",
|