@bastani/atomic 0.9.20-alpha.4 → 0.9.20-alpha.6
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/CHANGELOG.md +60 -0
- package/README.md +37 -0
- package/dist/builtin/intercom/CHANGELOG.md +16 -0
- package/dist/builtin/intercom/broker/broker.ts +110 -39
- package/dist/builtin/intercom/broker/client.ts +8 -1
- package/dist/builtin/intercom/index.bundle.mjs +61 -2
- package/dist/builtin/intercom/live-route-refusal.ts +69 -0
- package/dist/builtin/intercom/package.json +2 -2
- package/dist/builtin/intercom/recoverable-disconnect.ts +16 -4
- package/dist/builtin/intercom/skills/intercom/SKILL.md +43 -12
- package/dist/builtin/intercom/types.ts +3 -1
- package/dist/builtin/mcp/package.json +2 -2
- package/dist/builtin/subagents/CHANGELOG.md +18 -0
- package/dist/builtin/subagents/README.md +2 -0
- package/dist/builtin/subagents/agents/code-simplifier.md +1 -1
- package/dist/builtin/subagents/agents/codebase-analyzer.md +1 -1
- package/dist/builtin/subagents/agents/codebase-online-researcher.md +3 -3
- package/dist/builtin/subagents/agents/debugger.md +7 -5
- package/dist/builtin/subagents/agents/worker.md +4 -2
- package/dist/builtin/subagents/package.json +3 -3
- package/dist/builtin/subagents/skills/agent-browser/SKILL.md +56 -0
- package/dist/builtin/subagents/skills/cua-driver/BROWSER.md +494 -0
- package/dist/builtin/subagents/skills/cua-driver/EMBEDDING.md +578 -0
- package/dist/builtin/subagents/skills/cua-driver/LINUX.md +364 -0
- package/dist/builtin/subagents/skills/cua-driver/MACOS.md +509 -0
- package/dist/builtin/subagents/skills/cua-driver/README.md +113 -0
- package/dist/builtin/subagents/skills/cua-driver/RECORDING.md +162 -0
- package/dist/builtin/subagents/skills/cua-driver/SKILL.md +1105 -0
- package/dist/builtin/subagents/skills/cua-driver/WINDOWS.md +866 -0
- package/dist/builtin/subagents/skills/subagent/SKILL.md +32 -8
- package/dist/builtin/subagents/src/extension/index.bundle.mjs +7 -4
- package/dist/builtin/web-access/package.json +2 -2
- package/dist/builtin/workflows/CHANGELOG.md +43 -0
- package/dist/builtin/workflows/README.md +4 -2
- package/dist/builtin/workflows/builtin/adversarial-verification.js +3 -3
- package/dist/builtin/workflows/builtin/{chunk-1dydq7w3.js → chunk-2hzrv5y8.js} +202 -45
- package/dist/builtin/workflows/builtin/{chunk-n4yxrsm9.js → chunk-3tx8ry44.js} +3 -2
- package/dist/builtin/workflows/builtin/{chunk-n8g2da69.js → chunk-5724b0cf.js} +1 -1
- package/dist/builtin/workflows/builtin/{chunk-scgprmdj.js → chunk-7n51c5gh.js} +1 -1
- package/dist/builtin/workflows/builtin/{chunk-9y0f90rd.js → chunk-9z3ztr2a.js} +1 -1
- package/dist/builtin/workflows/builtin/{chunk-vt9zgr9d.js → chunk-deq63d9p.js} +4 -4
- package/dist/builtin/workflows/builtin/{chunk-k18g9me8.js → chunk-dxjxtgmp.js} +1 -1
- package/dist/builtin/workflows/builtin/{chunk-kf5xpbkz.js → chunk-ffdrv23t.js} +1 -1
- package/dist/builtin/workflows/builtin/{chunk-119kxb28.js → chunk-hmt5w62g.js} +72 -45
- package/dist/builtin/workflows/builtin/{chunk-hnbbb5r0.js → chunk-jngsbbpm.js} +4 -4
- package/dist/builtin/workflows/builtin/{chunk-d1xqh1rd.js → chunk-njmf5ze7.js} +1 -1
- package/dist/builtin/workflows/builtin/{chunk-sn5mchnx.js → chunk-vn0wb31x.js} +1 -1
- package/dist/builtin/workflows/builtin/classify-and-act.js +3 -3
- package/dist/builtin/workflows/builtin/fan-out-and-synthesize.js +3 -3
- package/dist/builtin/workflows/builtin/generate-and-filter.js +3 -3
- package/dist/builtin/workflows/builtin/goal.js +4 -4
- package/dist/builtin/workflows/builtin/index.d.ts +1 -1
- package/dist/builtin/workflows/builtin/index.js +12 -12
- package/dist/builtin/workflows/builtin/loop-until-done.js +3 -3
- package/dist/builtin/workflows/builtin/open-claude-design.d.ts +1 -1
- package/dist/builtin/workflows/builtin/open-claude-design.js +3 -3
- package/dist/builtin/workflows/builtin/ralph.js +4 -4
- package/dist/builtin/workflows/builtin/steering-context.js +1 -1
- package/dist/builtin/workflows/builtin/tournament.js +3 -3
- package/dist/builtin/workflows/package.json +2 -2
- package/dist/builtin/workflows/skills/impeccable/SKILL.md +18 -11
- package/dist/builtin/workflows/skills/impeccable/reference/adapt.md +1 -1
- package/dist/builtin/workflows/skills/impeccable/reference/adapt.native.md +1 -1
- package/dist/builtin/workflows/skills/impeccable/reference/animate.md +1 -1
- package/dist/builtin/workflows/skills/impeccable/reference/audit.md +5 -5
- package/dist/builtin/workflows/skills/impeccable/reference/audit.native.md +6 -6
- package/dist/builtin/workflows/skills/impeccable/reference/bolder.md +2 -2
- package/dist/builtin/workflows/skills/impeccable/reference/clarify.md +1 -1
- package/dist/builtin/workflows/skills/impeccable/reference/colorize.md +1 -1
- package/dist/builtin/workflows/skills/impeccable/reference/craft-floor.md +0 -6
- package/dist/builtin/workflows/skills/impeccable/reference/critique.md +19 -41
- package/dist/builtin/workflows/skills/impeccable/reference/degraded/asset-producer.md +11 -65
- package/dist/builtin/workflows/skills/impeccable/reference/degraded/documenter.md +3 -3
- package/dist/builtin/workflows/skills/impeccable/reference/degraded/finish-reviewer.md +4 -4
- package/dist/builtin/workflows/skills/impeccable/reference/degraded/manual-edit-applier.md +1 -1
- package/dist/builtin/workflows/skills/impeccable/reference/delight.md +1 -1
- package/dist/builtin/workflows/skills/impeccable/reference/distill.md +2 -2
- package/dist/builtin/workflows/skills/impeccable/reference/doctor.md +4 -4
- package/dist/builtin/workflows/skills/impeccable/reference/document.md +4 -4
- package/dist/builtin/workflows/skills/impeccable/reference/extract.md +1 -1
- package/dist/builtin/workflows/skills/impeccable/reference/harden.md +1 -1
- package/dist/builtin/workflows/skills/impeccable/reference/hooks.md +21 -21
- package/dist/builtin/workflows/skills/impeccable/reference/init.md +8 -8
- package/dist/builtin/workflows/skills/impeccable/reference/layout.md +2 -2
- package/dist/builtin/workflows/skills/impeccable/reference/live-setup.md +10 -8
- package/dist/builtin/workflows/skills/impeccable/reference/live.md +39 -38
- package/dist/builtin/workflows/skills/impeccable/reference/new-work.md +48 -21
- package/dist/builtin/workflows/skills/impeccable/reference/onboard.md +1 -1
- package/dist/builtin/workflows/skills/impeccable/reference/optimize.md +1 -1
- package/dist/builtin/workflows/skills/impeccable/reference/overdrive.md +1 -1
- package/dist/builtin/workflows/skills/impeccable/reference/polish.md +11 -3
- package/dist/builtin/workflows/skills/impeccable/reference/quieter.md +2 -2
- package/dist/builtin/workflows/skills/impeccable/reference/routing.md +13 -7
- package/dist/builtin/workflows/skills/impeccable/reference/typeset.md +2 -2
- package/dist/builtin/workflows/skills/impeccable/reference/visualize.md +13 -19
- package/dist/builtin/workflows/skills/impeccable/scripts/VERSION +1 -0
- package/dist/builtin/workflows/skills/impeccable/scripts/data/font-index-failures.json +121 -0
- package/dist/builtin/workflows/skills/impeccable/scripts/data/font-index.json +1 -0
- package/dist/builtin/workflows/skills/impeccable/scripts/impeccable +212 -0
- package/dist/builtin/workflows/skills/impeccable/scripts/impeccable.cmd +218 -0
- package/dist/builtin/workflows/skills/impeccable/scripts/live-browser-dom.js +21 -0
- package/dist/builtin/workflows/skills/impeccable/scripts/live-browser-ignores.js +242 -0
- package/dist/builtin/workflows/skills/impeccable/scripts/live-browser-session.js +25 -4
- package/dist/builtin/workflows/skills/impeccable/scripts/live-browser.js +666 -197
- package/dist/builtin/workflows/skills/research-codebase/SKILL.md +1 -1
- package/dist/builtin/workflows/src/extension/index.bundle.mjs +352 -117
- package/dist/builtin/workflows/src/index.js +1403 -1218
- package/dist/cli/args.d.ts.map +1 -1
- package/dist/cli/args.js +15 -4
- package/dist/cli/args.js.map +1 -1
- package/dist/cli/file-processor.d.ts +1 -1
- package/dist/cli/file-processor.d.ts.map +1 -1
- package/dist/cli/file-processor.js.map +1 -1
- package/dist/core/agent-session-auto-compaction.d.ts.map +1 -1
- package/dist/core/agent-session-auto-compaction.js +40 -12
- package/dist/core/agent-session-auto-compaction.js.map +1 -1
- package/dist/core/agent-session-bash.d.ts.map +1 -1
- package/dist/core/agent-session-bash.js +9 -8
- package/dist/core/agent-session-bash.js.map +1 -1
- package/dist/core/agent-session-boundaries.d.ts +68 -0
- package/dist/core/agent-session-boundaries.d.ts.map +1 -0
- package/dist/core/agent-session-boundaries.js +334 -0
- package/dist/core/agent-session-boundaries.js.map +1 -0
- package/dist/core/agent-session-compaction.js +1 -1
- package/dist/core/agent-session-compaction.js.map +1 -1
- package/dist/core/agent-session-events.d.ts.map +1 -1
- package/dist/core/agent-session-events.js +27 -13
- package/dist/core/agent-session-events.js.map +1 -1
- package/dist/core/agent-session-export.d.ts.map +1 -1
- package/dist/core/agent-session-export.js +16 -20
- package/dist/core/agent-session-export.js.map +1 -1
- package/dist/core/agent-session-message-queue.d.ts.map +1 -1
- package/dist/core/agent-session-message-queue.js +3 -2
- package/dist/core/agent-session-message-queue.js.map +1 -1
- package/dist/core/agent-session-methods.d.ts +30 -4
- package/dist/core/agent-session-methods.d.ts.map +1 -1
- package/dist/core/agent-session-methods.js.map +1 -1
- package/dist/core/agent-session-persistent-custom-messages.d.ts.map +1 -1
- package/dist/core/agent-session-persistent-custom-messages.js +2 -1
- package/dist/core/agent-session-persistent-custom-messages.js.map +1 -1
- package/dist/core/agent-session-prompt.d.ts.map +1 -1
- package/dist/core/agent-session-prompt.js +93 -25
- package/dist/core/agent-session-prompt.js.map +1 -1
- package/dist/core/agent-session-retry.d.ts.map +1 -1
- package/dist/core/agent-session-retry.js +4 -9
- package/dist/core/agent-session-retry.js.map +1 -1
- package/dist/core/agent-session-runtime.js +1 -1
- package/dist/core/agent-session-runtime.js.map +1 -1
- package/dist/core/agent-session-tool-hooks.d.ts.map +1 -1
- package/dist/core/agent-session-tool-hooks.js +15 -5
- package/dist/core/agent-session-tool-hooks.js.map +1 -1
- package/dist/core/agent-session-tree.d.ts.map +1 -1
- package/dist/core/agent-session-tree.js +2 -3
- package/dist/core/agent-session-tree.js.map +1 -1
- package/dist/core/agent-session-types.d.ts +6 -0
- package/dist/core/agent-session-types.d.ts.map +1 -1
- package/dist/core/agent-session-types.js.map +1 -1
- package/dist/core/agent-session.d.ts +15 -2
- package/dist/core/agent-session.d.ts.map +1 -1
- package/dist/core/agent-session.js +17 -1
- package/dist/core/agent-session.js.map +1 -1
- package/dist/core/compaction/branch-summarization.d.ts.map +1 -1
- package/dist/core/compaction/branch-summarization.js +1 -0
- package/dist/core/compaction/branch-summarization.js.map +1 -1
- package/dist/core/compaction/compaction-boundary.d.ts.map +1 -1
- package/dist/core/compaction/compaction-boundary.js +11 -6
- package/dist/core/compaction/compaction-boundary.js.map +1 -1
- package/dist/core/compaction/compaction.d.ts +3 -1
- package/dist/core/compaction/compaction.d.ts.map +1 -1
- package/dist/core/compaction/compaction.js +37 -0
- package/dist/core/compaction/compaction.js.map +1 -1
- package/dist/core/crash-log.d.ts +6 -0
- package/dist/core/crash-log.d.ts.map +1 -0
- package/dist/core/crash-log.js +69 -0
- package/dist/core/crash-log.js.map +1 -0
- package/dist/core/execution-model-router.d.ts +3 -0
- package/dist/core/execution-model-router.d.ts.map +1 -1
- package/dist/core/execution-model-router.js +45 -16
- package/dist/core/execution-model-router.js.map +1 -1
- package/dist/core/export-html/template-js/tree-filter-render.js +6 -1
- package/dist/core/export-html/template.js +6 -1
- package/dist/core/extensions/agent-events.d.ts +69 -3
- package/dist/core/extensions/agent-events.d.ts.map +1 -1
- package/dist/core/extensions/agent-events.js.map +1 -1
- package/dist/core/extensions/api-types.d.ts +5 -3
- package/dist/core/extensions/api-types.d.ts.map +1 -1
- package/dist/core/extensions/api-types.js.map +1 -1
- package/dist/core/extensions/event-results.d.ts +3 -0
- package/dist/core/extensions/event-results.d.ts.map +1 -1
- package/dist/core/extensions/event-results.js.map +1 -1
- package/dist/core/extensions/event-types.d.ts +2 -2
- package/dist/core/extensions/event-types.d.ts.map +1 -1
- package/dist/core/extensions/event-types.js.map +1 -1
- package/dist/core/extensions/index.d.ts +1 -1
- package/dist/core/extensions/index.d.ts.map +1 -1
- package/dist/core/extensions/index.js.map +1 -1
- package/dist/core/extensions/provider-types.d.ts +2 -0
- package/dist/core/extensions/provider-types.d.ts.map +1 -1
- package/dist/core/extensions/provider-types.js.map +1 -1
- package/dist/core/extensions/runner-events.d.ts +16 -2
- package/dist/core/extensions/runner-events.d.ts.map +1 -1
- package/dist/core/extensions/runner-events.js +98 -5
- package/dist/core/extensions/runner-events.js.map +1 -1
- package/dist/core/extensions/runner.d.ts +3 -2
- package/dist/core/extensions/runner.d.ts.map +1 -1
- package/dist/core/extensions/runner.js +4 -1
- package/dist/core/extensions/runner.js.map +1 -1
- package/dist/core/index.d.ts +1 -1
- package/dist/core/index.d.ts.map +1 -1
- package/dist/core/index.js.map +1 -1
- package/dist/core/messages.d.ts +10 -0
- package/dist/core/messages.d.ts.map +1 -1
- package/dist/core/messages.js +57 -0
- package/dist/core/messages.js.map +1 -1
- package/dist/core/model-config.d.ts +52 -0
- package/dist/core/model-config.d.ts.map +1 -1
- package/dist/core/model-config.js +16 -0
- package/dist/core/model-config.js.map +1 -1
- package/dist/core/model-resolver-defaults.d.ts.map +1 -1
- package/dist/core/model-resolver-defaults.js +2 -1
- package/dist/core/model-resolver-defaults.js.map +1 -1
- package/dist/core/model-routing-task.d.ts +1 -1
- package/dist/core/model-routing-task.d.ts.map +1 -1
- package/dist/core/model-routing-task.js +4 -3
- package/dist/core/model-routing-task.js.map +1 -1
- package/dist/core/prompt-templates-async.d.ts +2 -2
- package/dist/core/prompt-templates-async.d.ts.map +1 -1
- package/dist/core/prompt-templates-async.js +57 -29
- package/dist/core/prompt-templates-async.js.map +1 -1
- package/dist/core/prompt-templates.d.ts +6 -1
- package/dist/core/prompt-templates.d.ts.map +1 -1
- package/dist/core/prompt-templates.js +61 -35
- package/dist/core/prompt-templates.js.map +1 -1
- package/dist/core/provider-composer-internal.d.ts +1 -0
- package/dist/core/provider-composer-internal.d.ts.map +1 -1
- package/dist/core/provider-composer-internal.js +19 -0
- package/dist/core/provider-composer-internal.js.map +1 -1
- package/dist/core/resource-loader-assets.d.ts.map +1 -1
- package/dist/core/resource-loader-assets.js +6 -6
- package/dist/core/resource-loader-assets.js.map +1 -1
- package/dist/core/sdk.js +3 -2
- package/dist/core/sdk.js.map +1 -1
- package/dist/core/session-manager-core.d.ts +10 -3
- package/dist/core/session-manager-core.d.ts.map +1 -1
- package/dist/core/session-manager-core.js +65 -7
- package/dist/core/session-manager-core.js.map +1 -1
- package/dist/core/session-manager-entries.d.ts +4 -1
- package/dist/core/session-manager-entries.d.ts.map +1 -1
- package/dist/core/session-manager-entries.js +8 -0
- package/dist/core/session-manager-entries.js.map +1 -1
- package/dist/core/session-manager-history.d.ts +16 -1
- package/dist/core/session-manager-history.d.ts.map +1 -1
- package/dist/core/session-manager-history.js +105 -42
- package/dist/core/session-manager-history.js.map +1 -1
- package/dist/core/session-manager-types.d.ts +30 -3
- package/dist/core/session-manager-types.d.ts.map +1 -1
- package/dist/core/session-manager-types.js.map +1 -1
- package/dist/core/session-manager.d.ts +2 -2
- package/dist/core/session-manager.d.ts.map +1 -1
- package/dist/core/session-manager.js +1 -1
- package/dist/core/session-manager.js.map +1 -1
- package/dist/core/structured-output/index.d.ts +0 -1
- package/dist/core/structured-output/index.d.ts.map +1 -1
- package/dist/core/structured-output/index.js +3 -15
- package/dist/core/structured-output/index.js.map +1 -1
- package/dist/core/structured-output/jev-client.d.ts +4 -8
- package/dist/core/structured-output/jev-client.d.ts.map +1 -1
- package/dist/core/structured-output/jev-client.js +36 -32
- package/dist/core/structured-output/jev-client.js.map +1 -1
- package/dist/core/structured-output/jev.d.ts.map +1 -1
- package/dist/core/structured-output/jev.js +4 -12
- package/dist/core/structured-output/jev.js.map +1 -1
- package/dist/core/structured-output/types.d.ts +0 -2
- package/dist/core/structured-output/types.d.ts.map +1 -1
- package/dist/core/structured-output/types.js.map +1 -1
- package/dist/core/system-prompt.d.ts.map +1 -1
- package/dist/core/system-prompt.js +2 -1
- package/dist/core/system-prompt.js.map +1 -1
- package/dist/core/tools/read.d.ts +4 -0
- package/dist/core/tools/read.d.ts.map +1 -1
- package/dist/core/tools/read.js +5 -1
- package/dist/core/tools/read.js.map +1 -1
- package/dist/index-extensions.d.ts +1 -1
- package/dist/index-extensions.d.ts.map +1 -1
- package/dist/index-extensions.js.map +1 -1
- package/dist/index.d.ts +3 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -3
- package/dist/index.js.map +1 -1
- package/dist/main-app-mode.d.ts +1 -1
- package/dist/main-app-mode.d.ts.map +1 -1
- package/dist/main-app-mode.js +3 -2
- package/dist/main-app-mode.js.map +1 -1
- package/dist/main.d.ts.map +1 -1
- package/dist/main.js +1 -1
- package/dist/main.js.map +1 -1
- package/dist/modes/interactive/components/chat-message-renderer.d.ts.map +1 -1
- package/dist/modes/interactive/components/chat-message-renderer.js +4 -0
- package/dist/modes/interactive/components/chat-message-renderer.js.map +1 -1
- package/dist/modes/interactive/components/tree-selector-content.d.ts.map +1 -1
- package/dist/modes/interactive/components/tree-selector-content.js +6 -0
- package/dist/modes/interactive/components/tree-selector-content.js.map +1 -1
- package/dist/modes/interactive/components/tree-selector-model.d.ts.map +1 -1
- package/dist/modes/interactive/components/tree-selector-model.js +1 -0
- package/dist/modes/interactive/components/tree-selector-model.js.map +1 -1
- package/dist/modes/interactive/interactive-agent-events.js +17 -1
- package/dist/modes/interactive/interactive-agent-events.js.map +1 -1
- package/dist/modes/interactive/interactive-mode-helpers.d.ts +1 -0
- package/dist/modes/interactive/interactive-mode-helpers.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-mode-helpers.js +16 -0
- package/dist/modes/interactive/interactive-mode-helpers.js.map +1 -1
- package/dist/modes/interactive/interactive-mode-surface.d.ts +1 -0
- package/dist/modes/interactive/interactive-mode-surface.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-mode-surface.js.map +1 -1
- package/dist/modes/interactive/interactive-process-lifecycle.js +13 -1
- package/dist/modes/interactive/interactive-process-lifecycle.js.map +1 -1
- package/dist/modes/interactive/interactive-session-runtime.js +5 -1
- package/dist/modes/interactive/interactive-session-runtime.js.map +1 -1
- package/dist/utils/mime.js +1 -1
- package/dist/utils/mime.js.map +1 -1
- package/dist/utils/tool-result-images.d.ts +3 -1
- package/dist/utils/tool-result-images.d.ts.map +1 -1
- package/dist/utils/tool-result-images.js +4 -1
- package/dist/utils/tool-result-images.js.map +1 -1
- package/docs/compaction.md +5 -1
- package/docs/computer-use.md +123 -73
- package/docs/extensions/events.md +75 -7
- package/docs/extensions.md +6 -2
- package/docs/getting-started/first-session.md +3 -2
- package/docs/getting-started/installation.md +6 -2
- package/docs/intercom/operations.md +13 -1
- package/docs/intercom.md +7 -2
- package/docs/models/evals.md +68 -82
- package/docs/models/model-selection.md +11 -7
- package/docs/models/reference.md +30 -2
- package/docs/packages.md +2 -0
- package/docs/prompt-templates.md +1 -0
- package/docs/providers.md +8 -2
- package/docs/quickstart.md +1 -1
- package/docs/sdk/reference.md +1 -2
- package/docs/sdk/structured-decisions.md +10 -9
- package/docs/sdk.md +13 -2
- package/docs/session-format.md +17 -2
- package/docs/settings.md +1 -1
- package/docs/skills.md +3 -1
- package/docs/subagents/reference.md +6 -6
- package/docs/subagents.md +8 -2
- package/docs/usage.md +2 -0
- package/docs/windows.md +1 -1
- package/docs/workflows/api-reference.md +5 -4
- package/docs/workflows/authoring.md +191 -0
- package/docs/workflows/builtins.md +2 -2
- package/docs/workflows/operations.md +10 -4
- package/docs/workflows/reliable-design.md +12 -1
- package/docs/workflows/verification.md +27 -14
- package/npm-shrinkwrap.json +69 -69
- package/package.json +8 -8
- package/dist/builtin/subagents/skills/playwright-cli/SKILL.md +0 -420
- package/dist/builtin/subagents/skills/playwright-cli/references/element-attributes.md +0 -23
- package/dist/builtin/subagents/skills/playwright-cli/references/playwright-tests.md +0 -39
- package/dist/builtin/subagents/skills/playwright-cli/references/request-mocking.md +0 -87
- package/dist/builtin/subagents/skills/playwright-cli/references/running-code.md +0 -241
- package/dist/builtin/subagents/skills/playwright-cli/references/session-management.md +0 -225
- package/dist/builtin/subagents/skills/playwright-cli/references/storage-state.md +0 -275
- package/dist/builtin/subagents/skills/playwright-cli/references/test-generation.md +0 -433
- package/dist/builtin/subagents/skills/playwright-cli/references/tracing.md +0 -139
- package/dist/builtin/subagents/skills/playwright-cli/references/video-recording.md +0 -143
- package/dist/builtin/workflows/skills/impeccable/agents/impeccable_asset_producer.toml +0 -94
- package/dist/builtin/workflows/skills/impeccable/agents/impeccable_documenter.toml +0 -27
- package/dist/builtin/workflows/skills/impeccable/agents/impeccable_finish_reviewer.toml +0 -41
- package/dist/builtin/workflows/skills/impeccable/agents/impeccable_manual_edit_applier.toml +0 -95
- package/dist/builtin/workflows/skills/impeccable/agents/openai.yaml +0 -4
- package/dist/builtin/workflows/skills/impeccable/scripts/concept-seed.mjs +0 -695
- package/dist/builtin/workflows/skills/impeccable/scripts/context-signals.mjs +0 -325
- package/dist/builtin/workflows/skills/impeccable/scripts/context.mjs +0 -1503
- package/dist/builtin/workflows/skills/impeccable/scripts/critique-storage.mjs +0 -222
- package/dist/builtin/workflows/skills/impeccable/scripts/detect-csp.mjs +0 -198
- package/dist/builtin/workflows/skills/impeccable/scripts/detect.mjs +0 -21
- package/dist/builtin/workflows/skills/impeccable/scripts/detector/browser/injected/index.mjs +0 -2073
- package/dist/builtin/workflows/skills/impeccable/scripts/detector/cli/main.mjs +0 -432
- package/dist/builtin/workflows/skills/impeccable/scripts/detector/design-system.mjs +0 -1121
- package/dist/builtin/workflows/skills/impeccable/scripts/detector/detect-antipatterns-browser.js +0 -8746
- package/dist/builtin/workflows/skills/impeccable/scripts/detector/detect-antipatterns.mjs +0 -51
- package/dist/builtin/workflows/skills/impeccable/scripts/detector/engines/browser/detect-url.mjs +0 -376
- package/dist/builtin/workflows/skills/impeccable/scripts/detector/engines/regex/detect-text.mjs +0 -1168
- package/dist/builtin/workflows/skills/impeccable/scripts/detector/engines/static-html/css-cascade.mjs +0 -1192
- package/dist/builtin/workflows/skills/impeccable/scripts/detector/engines/static-html/detect-html.mjs +0 -290
- package/dist/builtin/workflows/skills/impeccable/scripts/detector/engines/visual/screenshot-contrast.mjs +0 -189
- package/dist/builtin/workflows/skills/impeccable/scripts/detector/findings.mjs +0 -18
- package/dist/builtin/workflows/skills/impeccable/scripts/detector/node/file-system.mjs +0 -213
- package/dist/builtin/workflows/skills/impeccable/scripts/detector/profile/profiler.mjs +0 -166
- package/dist/builtin/workflows/skills/impeccable/scripts/detector/registry/antipatterns.mjs +0 -617
- package/dist/builtin/workflows/skills/impeccable/scripts/detector/rules/checks.mjs +0 -5534
- package/dist/builtin/workflows/skills/impeccable/scripts/detector/shared/color.mjs +0 -588
- package/dist/builtin/workflows/skills/impeccable/scripts/detector/shared/constants.mjs +0 -112
- package/dist/builtin/workflows/skills/impeccable/scripts/detector/shared/fonts.mjs +0 -30
- package/dist/builtin/workflows/skills/impeccable/scripts/detector/shared/inline-ignores.mjs +0 -148
- package/dist/builtin/workflows/skills/impeccable/scripts/detector/shared/page.mjs +0 -35
- package/dist/builtin/workflows/skills/impeccable/scripts/doctor.mjs +0 -338
- package/dist/builtin/workflows/skills/impeccable/scripts/embed-prompt.mjs +0 -270
- package/dist/builtin/workflows/skills/impeccable/scripts/generate-image.mjs +0 -277
- package/dist/builtin/workflows/skills/impeccable/scripts/hook-admin.mjs +0 -783
- package/dist/builtin/workflows/skills/impeccable/scripts/hook-lib.mjs +0 -2305
- package/dist/builtin/workflows/skills/impeccable/scripts/hook.mjs +0 -78
- package/dist/builtin/workflows/skills/impeccable/scripts/lib/artifact-schema.mjs +0 -93
- package/dist/builtin/workflows/skills/impeccable/scripts/lib/composition-catalog.mjs +0 -200
- package/dist/builtin/workflows/skills/impeccable/scripts/lib/concept-catalog.mjs +0 -395
- package/dist/builtin/workflows/skills/impeccable/scripts/lib/design-parser.mjs +0 -925
- package/dist/builtin/workflows/skills/impeccable/scripts/lib/impeccable-config.mjs +0 -640
- package/dist/builtin/workflows/skills/impeccable/scripts/lib/impeccable-paths.mjs +0 -137
- package/dist/builtin/workflows/skills/impeccable/scripts/lib/is-generated.mjs +0 -72
- package/dist/builtin/workflows/skills/impeccable/scripts/lib/open-system-browser.mjs +0 -57
- package/dist/builtin/workflows/skills/impeccable/scripts/lib/provider.mjs +0 -5
- package/dist/builtin/workflows/skills/impeccable/scripts/lib/roll-selection.mjs +0 -369
- package/dist/builtin/workflows/skills/impeccable/scripts/lib/staleness-deep.mjs +0 -483
- package/dist/builtin/workflows/skills/impeccable/scripts/lib/staleness-notice.mjs +0 -169
- package/dist/builtin/workflows/skills/impeccable/scripts/lib/staleness.mjs +0 -528
- package/dist/builtin/workflows/skills/impeccable/scripts/lib/surface-briefs.mjs +0 -151
- package/dist/builtin/workflows/skills/impeccable/scripts/lib/target-args.mjs +0 -42
- package/dist/builtin/workflows/skills/impeccable/scripts/lib/target-slug.mjs +0 -33
- package/dist/builtin/workflows/skills/impeccable/scripts/lib/template-extensions.mjs +0 -146
- package/dist/builtin/workflows/skills/impeccable/scripts/live/accept-css.mjs +0 -617
- package/dist/builtin/workflows/skills/impeccable/scripts/live/accept-verify.mjs +0 -71
- package/dist/builtin/workflows/skills/impeccable/scripts/live/browser-script-parts.mjs +0 -77
- package/dist/builtin/workflows/skills/impeccable/scripts/live/completion.mjs +0 -28
- package/dist/builtin/workflows/skills/impeccable/scripts/live/event-validation.mjs +0 -199
- package/dist/builtin/workflows/skills/impeccable/scripts/live/frameworks/astro.mjs +0 -47
- package/dist/builtin/workflows/skills/impeccable/scripts/live/frameworks/detect-utils.mjs +0 -157
- package/dist/builtin/workflows/skills/impeccable/scripts/live/frameworks/index.mjs +0 -143
- package/dist/builtin/workflows/skills/impeccable/scripts/live/frameworks/journal.mjs +0 -205
- package/dist/builtin/workflows/skills/impeccable/scripts/live/frameworks/nextjs.mjs +0 -49
- package/dist/builtin/workflows/skills/impeccable/scripts/live/frameworks/nuxt.mjs +0 -170
- package/dist/builtin/workflows/skills/impeccable/scripts/live/frameworks/script-src.mjs +0 -26
- package/dist/builtin/workflows/skills/impeccable/scripts/live/frameworks/static-html.mjs +0 -26
- package/dist/builtin/workflows/skills/impeccable/scripts/live/frameworks/sveltekit.mjs +0 -71
- package/dist/builtin/workflows/skills/impeccable/scripts/live/frameworks/tag-strategy.mjs +0 -247
- package/dist/builtin/workflows/skills/impeccable/scripts/live/frameworks/tanstack-start.mjs +0 -70
- package/dist/builtin/workflows/skills/impeccable/scripts/live/frameworks/vite-generic.mjs +0 -42
- package/dist/builtin/workflows/skills/impeccable/scripts/live/generation-preflight.mjs +0 -149
- package/dist/builtin/workflows/skills/impeccable/scripts/live/insert-ui.mjs +0 -458
- package/dist/builtin/workflows/skills/impeccable/scripts/live/instructions.mjs +0 -169
- package/dist/builtin/workflows/skills/impeccable/scripts/live/manual-apply.mjs +0 -939
- package/dist/builtin/workflows/skills/impeccable/scripts/live/manual-edit-routes.mjs +0 -357
- package/dist/builtin/workflows/skills/impeccable/scripts/live/manual-edits-buffer.mjs +0 -152
- package/dist/builtin/workflows/skills/impeccable/scripts/live/poll-lanes.mjs +0 -14
- package/dist/builtin/workflows/skills/impeccable/scripts/live/roots.mjs +0 -670
- package/dist/builtin/workflows/skills/impeccable/scripts/live/session-store.mjs +0 -563
- package/dist/builtin/workflows/skills/impeccable/scripts/live/source-lock.mjs +0 -105
- package/dist/builtin/workflows/skills/impeccable/scripts/live/source-search.mjs +0 -105
- package/dist/builtin/workflows/skills/impeccable/scripts/live/svelte-ast.mjs +0 -969
- package/dist/builtin/workflows/skills/impeccable/scripts/live/svelte-component.mjs +0 -1401
- package/dist/builtin/workflows/skills/impeccable/scripts/live/sveltekit-adapter.mjs +0 -314
- package/dist/builtin/workflows/skills/impeccable/scripts/live/tanstack-adapter.mjs +0 -280
- package/dist/builtin/workflows/skills/impeccable/scripts/live/ui-surfaces.mjs +0 -75
- package/dist/builtin/workflows/skills/impeccable/scripts/live/vocabulary.mjs +0 -171
- package/dist/builtin/workflows/skills/impeccable/scripts/live-accept.mjs +0 -961
- package/dist/builtin/workflows/skills/impeccable/scripts/live-commit-manual-edits.mjs +0 -1244
- package/dist/builtin/workflows/skills/impeccable/scripts/live-complete.mjs +0 -107
- package/dist/builtin/workflows/skills/impeccable/scripts/live-copy-edit-agent.mjs +0 -800
- package/dist/builtin/workflows/skills/impeccable/scripts/live-discard-manual-edits.mjs +0 -51
- package/dist/builtin/workflows/skills/impeccable/scripts/live-inject.mjs +0 -515
- package/dist/builtin/workflows/skills/impeccable/scripts/live-insert.mjs +0 -292
- package/dist/builtin/workflows/skills/impeccable/scripts/live-manual-edit-evidence.mjs +0 -371
- package/dist/builtin/workflows/skills/impeccable/scripts/live-poll.mjs +0 -427
- package/dist/builtin/workflows/skills/impeccable/scripts/live-resume.mjs +0 -123
- package/dist/builtin/workflows/skills/impeccable/scripts/live-server.mjs +0 -1675
- package/dist/builtin/workflows/skills/impeccable/scripts/live-status.mjs +0 -71
- package/dist/builtin/workflows/skills/impeccable/scripts/live-target.mjs +0 -30
- package/dist/builtin/workflows/skills/impeccable/scripts/live-wrap.mjs +0 -927
- package/dist/builtin/workflows/skills/impeccable/scripts/live.mjs +0 -365
- package/dist/builtin/workflows/skills/impeccable/scripts/palette.mjs +0 -628
- package/dist/builtin/workflows/skills/impeccable/scripts/pin.mjs +0 -224
- package/dist/builtin/workflows/skills/impeccable/scripts/serve-question.mjs +0 -1540
- package/dist/builtin/workflows/skills/impeccable/scripts/surface-brief.mjs +0 -74
|
@@ -72,10 +72,10 @@ Builtin agents load at the lowest priority. Project agents override user agents,
|
|
|
72
72
|
| `codebase-pattern-finder` | Find similar implementations or conventions | read, search, find, ls, intercom | Read-only. Returns code snippets with `file:line` references. |
|
|
73
73
|
| `codebase-research-locator` | Discover prior `research/` and `specs/` docs | read, search, find, ls, intercom | Read-only. Sorts by date, tiers by recency, flags supersession. |
|
|
74
74
|
| `codebase-research-analyzer` | Extract decisions and constraints from prior docs | read, search, find, ls, todo, intercom | Read-only. Filters aggressively for what still applies today. |
|
|
75
|
-
| `codebase-online-researcher` | Web research with authoritative sources | read, search, find, ls, bash, web_search, fetch_content, get_search_content, todo, intercom | Has the `
|
|
75
|
+
| `codebase-online-researcher` | Web research with authoritative sources | read, search, find, ls, bash, web_search, fetch_content, get_search_content, todo, intercom | Has the `agent-browser` skill. Returns cited findings. |
|
|
76
76
|
| `code-simplifier` | Clean up recently changed code without changing behavior | read, edit, write, search, find, ls, bash, todo, intercom | **Writer.** Scopes to recently modified code by default; preserves all observable behavior. |
|
|
77
|
-
| `debugger` | Reproduce, diagnose, and fix failing behavior | read, edit, write, search, find, ls, bash, web_search, fetch_content, get_search_content, intercom, contact_supervisor, todo | **Writer.** Has the `tdd`, `
|
|
78
|
-
| `worker` | Implement normal tasks and approved orchestrator handoffs | read, edit, write, search, find, ls, bash, web_search, fetch_content, get_search_content, intercom, contact_supervisor, todo | **Writer.** Has the `tdd`, `
|
|
77
|
+
| `debugger` | Reproduce, diagnose, and fix failing behavior | read, edit, write, search, find, ls, bash, web_search, fetch_content, get_search_content, intercom, contact_supervisor, todo | **Writer.** Has the `tdd`, `agent-browser`, and `tmux` skills. Can coordinate with the parent; inspect-only mode requires an explicit instruction. |
|
|
78
|
+
| `worker` | Implement normal tasks and approved orchestrator handoffs | read, edit, write, search, find, ls, bash, web_search, fetch_content, get_search_content, intercom, contact_supervisor, todo | **Writer.** Has the `tdd`, `agent-browser`, and `tmux` skills. Defaults to forked context; escalates unapproved decisions instead of guessing. |
|
|
79
79
|
|
|
80
80
|
Each builtin defaults to `model: "auto"`, with no pinned fallback chain. The router selects a model and effort before launch. Inspect effective configuration with `subagent({ action: "get", agent: "debugger" })`. Normal execution fallback remains subject to routing constraints and does not change the main-chat model. Override per run with a concrete model:
|
|
81
81
|
|
|
@@ -86,7 +86,7 @@ subagent({ agent: "codebase-analyzer", task: "Trace the auth flow", model: "anth
|
|
|
86
86
|
|
|
87
87
|
For persistent tweaks, edit `subagents.agentOverrides` in user or project settings. User overrides apply everywhere. Project overrides apply only in that repo and win over user overrides.
|
|
88
88
|
|
|
89
|
-
Every builtin agent declares `intercom` for live coordination; `debugger` and `worker` also declare `contact_supervisor`. Parent tool restrictions and disabled Intercom still apply. Custom agents can coordinate when they declare `intercom` or when the runtime bridge supplies `contact_supervisor`; see [Subagent + Intercom Coordination](#subagent--intercom-coordination).
|
|
89
|
+
Every builtin agent declares `intercom` for live coordination with the supervisor and with same-group peers; `debugger` and `worker` also declare `contact_supervisor`. Parent tool restrictions and disabled Intercom still apply. Custom agents can coordinate when they declare `intercom` or when the runtime bridge supplies `contact_supervisor`; see [Subagent + Intercom Coordination](#subagent--intercom-coordination).
|
|
90
90
|
|
|
91
91
|
## Prompting specialist subagents
|
|
92
92
|
|
|
@@ -102,7 +102,7 @@ A strong subagent prompt usually includes:
|
|
|
102
102
|
- **Output**: the expected summary shape, artifact path, or finding format.
|
|
103
103
|
- **Stop rules**: when to stop after enough evidence, and when not to keep searching.
|
|
104
104
|
|
|
105
|
-
Avoid carrying over old prompt habits that over-specify every step. Use `must`, `always`, and `never` for real invariants; for judgment calls, give decision rules. For example, tell `codebase-analyzer` to trace the staged diff directly and report only evidence-backed findings, rather than prescribing every file or command. Tell `codebase-online-researcher` the retrieval budget: start with broad targeted searches, fetch the strongest sources via `fetch_content`, fall back to `
|
|
105
|
+
Avoid carrying over old prompt habits that over-specify every step. Use `must`, `always`, and `never` for real invariants; for judgment calls, give decision rules. For example, tell `codebase-analyzer` to trace the staged diff directly and report only evidence-backed findings, rather than prescribing every file or command. Tell `codebase-online-researcher` the retrieval budget: start with broad targeted searches, fetch the strongest sources via `fetch_content`, fall back to `agent-browser` only when JS execution is required, and stop when the question is answered.
|
|
106
106
|
|
|
107
107
|
For implementation handoffs to `debugger` or `code-simplifier`, name the approved scope and success criteria more clearly than the process. Good prompts say what to change, what not to change, where the evidence lives, how to validate, and when to escalate. They should not ask the child to create another subagent plan or continue the parent conversation.
|
|
108
108
|
|
|
@@ -287,7 +287,7 @@ subagent({
|
|
|
287
287
|
|
|
288
288
|
Atomic subagents work without intercom. When Atomic's bundled intercom companion or upstream `pi-intercom` is installed and enabled, the bridge can give eligible child agents a private coordination tool back to the parent session without connecting either session automatically. If a child may need live coordination, invoke `intercom({ action: "status" })` in the parent before launching it; the child connects when it first invokes `contact_supervisor` or `intercom`.
|
|
289
289
|
|
|
290
|
-
All builtin specialists can coordinate through `intercom
|
|
290
|
+
All builtin specialists can coordinate through `intercom`, both upward to the supervisor and sideways to peers in the same Intercom group. `debugger` and `worker` also declare `contact_supervisor`; use it for supervisor requests when the bridge supplies it. Explicit parent tool allowlists, exclusions, `noTools`, and disabled builtins are never bypassed to restore coordination.
|
|
291
291
|
|
|
292
292
|
Custom agents that do have the bridge tool can ask the parent for a decision:
|
|
293
293
|
|
|
@@ -315,7 +315,29 @@ Message conventions:
|
|
|
315
315
|
- `reason: "progress_update"` is non-blocking and should stay concise.
|
|
316
316
|
- Child-side routine completion handoffs are not expected. With the intercom bridge active, parent-side subagents send grouped completion results through the intercom companion: one grouped message per foreground parent run and one per detached child completion. Acknowledged delivery returns a compact receipt with artifact/session paths; if unacknowledged, the normal full output is preserved.
|
|
317
317
|
|
|
318
|
-
|
|
318
|
+
For supervisor requests, prefer `contact_supervisor`; use generic `intercom` toward the supervisor only when the bridge instructions provide the target and `contact_supervisor` is unavailable. For peers, discover targets with `intercom({ action: "list" })`. Never invent a target.
|
|
319
|
+
|
|
320
|
+
### Peer coordination
|
|
321
|
+
|
|
322
|
+
Coordination is not only vertical. Children launched in the same parallel set, or in the same explicit `group`, share one Intercom group, and workflow stages share their invocation group. Any of them can run `intercom({ action: "list" })`, see live siblings, and `send` or `ask` them directly. `contact_supervisor` is reserved for the supervisor; everything peer-to-peer goes through ordinary `intercom`.
|
|
323
|
+
|
|
324
|
+
Use peer messaging when a sibling is the better source than the supervisor:
|
|
325
|
+
|
|
326
|
+
- **Debate**: a reviewer challenges another reviewer's blocking finding with concrete evidence; each still returns its own verdict (see the constructive-quorum pattern in `/skill:intercom`).
|
|
327
|
+
- **Connect**: a locator hands file paths and line ranges straight to the analyzer working the same question instead of round-tripping through the parent.
|
|
328
|
+
- **Learn**: a worker asks the sibling that already reproduced the bug for the exact command and environment rather than rediscovering it.
|
|
329
|
+
- **Coordinate**: parallel writers claim ownership of shared files, serialize expensive suites or builds, and announce when a shared step is done.
|
|
330
|
+
|
|
331
|
+
```typescript
|
|
332
|
+
// In a child: find who else is in the group, then talk to them
|
|
333
|
+
intercom({ action: "list" })
|
|
334
|
+
intercom({ action: "send", to: "worker-2", message: "I own src/api/*; leave those files to me and take src/cli/*." })
|
|
335
|
+
intercom({ action: "ask", to: "reviewer-1", message: "You flagged the retry loop as unbounded. I read a max of 5 attempts at client.ts:88 — what did you see?" })
|
|
336
|
+
```
|
|
337
|
+
|
|
338
|
+
Peer asks and one blocking supervisor request may wait concurrently in the same child; a peer reply returns to the asking child with its context intact. Mutual asks work as long as both sides process inbound work. Keep exchanges bounded and evidence-driven, do not defer to a peer's conclusion without inspecting the evidence, and still return your own complete result. Peer messages do not replace the supervisor for scope, product, or architecture decisions.
|
|
339
|
+
|
|
340
|
+
To enable this from the parent, launch related work as one parallel set (or an explicit `group`) and say in each task prompt who the peers are and what they should exchange; children do not coordinate spontaneously without that instruction. Use `group: true` to give one parallel set its own private group, or a named group to let later launches join the same conversation.
|
|
319
341
|
|
|
320
342
|
If intercom messages do not show up, check the bridge from the intercom side with `intercom({ action: "status" })`.
|
|
321
343
|
|
|
@@ -441,10 +463,12 @@ Give subagents specific tasks rather than vague mandates.
|
|
|
441
463
|
- "X is broken — make it pass" → `debugger`
|
|
442
464
|
- "X works but it's ugly — clean it up" → `code-simplifier`
|
|
443
465
|
|
|
444
|
-
### Escalate decisions upward
|
|
466
|
+
### Escalate decisions upward, coordinate sideways
|
|
445
467
|
|
|
446
468
|
All builtin specialists can use Intercom when permitted by the parent. Use `contact_supervisor` for parent decisions when the active bridge supplies it. Resolve known scope, product, and architecture questions before launching any writer. If the parent realizes mid-run that the scope is wrong, steer a reachable child or kill it.
|
|
447
469
|
|
|
470
|
+
When several children work related angles, tell them to use ordinary `intercom` with each other for findings, ownership, and challenges so the parent is not the bottleneck for information that a sibling already holds. See [Peer coordination](#peer-coordination).
|
|
471
|
+
|
|
448
472
|
### Intervene only on clear control signals
|
|
449
473
|
|
|
450
474
|
Use subagent control proactively when a delegated run emits `needs_attention`, or when a human asks you to regain control. Do not kill just because a child has briefly produced no output. Silence can be normal during long tool calls, test runs, or model reasoning.
|
|
@@ -8187,12 +8187,14 @@ var DEFAULT_INTERCOM_TARGET_PREFIX = "subagent-chat";
|
|
|
8187
8187
|
var INTERCOM_BRIDGE_MARKER = "Intercom orchestration channel:";
|
|
8188
8188
|
var DEFAULT_INTERCOM_BRIDGE_TEMPLATE = `The inherited thread is reference-only. Do not continue that conversation or send questions, status updates, or completion handoffs to the supervisor in normal assistant text.
|
|
8189
8189
|
|
|
8190
|
-
Use contact_supervisor
|
|
8190
|
+
Use contact_supervisor for the supervisor. It resolves the supervisor session "{orchestratorTarget}" and run metadata automatically.
|
|
8191
8191
|
- Need a decision, blocked, approval, or product/API/scope ambiguity: contact_supervisor({ reason: "need_decision", message: "<question>" })
|
|
8192
8192
|
- In parallel runs, blocking requests wait here and the supervisor's correlated reply lets this same child continue; siblings keep running. Do not request a replacement launch. A single-child claimed decision/interview instead ends with a dynamic [TASK_CONTEXT] fresh-child handoff; follow the actual tool result.
|
|
8193
8193
|
- Do not ask for clarification when the only conflict is review-only/no-edit versus progress-writing or artifact-writing instructions. Review-only/no-edit wins; leave files unchanged and mention the conflict in your final result only if it matters.
|
|
8194
8194
|
- Meaningful progress or unexpected discoveries that change the plan: contact_supervisor({ reason: "progress_update", message: "UPDATE: <summary>" })
|
|
8195
|
-
-
|
|
8195
|
+
- Toward the supervisor, generic intercom is the fallback only when contact_supervisor is unavailable: intercom({ action: "ask", to: "{orchestratorTarget}", message: "<question>" })
|
|
8196
|
+
|
|
8197
|
+
Use ordinary intercom for peers. Sibling agents launched with you, and workflow stages in your invocation, share your Intercom group; intercom({ action: "list" }) shows who is live. Send or ask them directly to share findings and file locations, divide ownership of files or expensive steps, challenge a conclusion with evidence, or learn what a sibling already verified, instead of routing that through the supervisor. Peer asks and one blocking supervisor request may wait at the same time; keep exchanges bounded, decide on evidence rather than deference, and still return your own complete result. Scope, product, and architecture decisions remain supervisor decisions. Do not invent targets.
|
|
8196
8198
|
|
|
8197
8199
|
Do not use contact_supervisor or intercom for routine completion handoffs. If no coordination is needed, return a focused task result.`;
|
|
8198
8200
|
function resolveIntercomSessionTarget(sessionName, sessionId) {
|
|
@@ -17324,7 +17326,7 @@ function parseSubagentNotifyContent(content) {
|
|
|
17324
17326
|
// dist/builtin/subagents/src/extension/prompt-guidance.ts
|
|
17325
17327
|
var DEFAULT_PROMPT_GUIDANCE = [
|
|
17326
17328
|
`**Subagent orchestration**: Use subagents for focused specialist work inside workflows or as bounded delegation when a workflow would be unnecessary overhead.
|
|
17327
|
-
- When workflow is available, call workflow route with the actual request, relevant message text/document excerpts, and explicit constraints in state, not file paths in place of content. If it returns none, continue inline. Otherwise use its input contract to prepare inputs, then call workflow run with the registered workflow ID. Ask only for genuinely missing information.
|
|
17329
|
+
- When workflow is available, call workflow route with the actual request, relevant message text/document excerpts, and explicit constraints in state, not file paths in place of content. Pass the user's own words; the router judges whether a workflow fits and whether the user asked for inline or workflow execution, so do not pass your own routing preference. If it returns none, continue inline. Otherwise use its input contract to prepare inputs, then call workflow run with the registered workflow ID. Ask only for genuinely missing information.
|
|
17328
17330
|
- Honor the user's task-scoped execution preferences without hidden/nested workflows or pressure to reapprove. Preserve appropriate testing, review and evidence inline, and unrelated safety and authorization constraints.
|
|
17329
17331
|
- On a switch from an active workflow to inline, notify the controlling session to safely hold/stop the affected run, reconcile completed work and in-flight side effects, then continue inline without duplicate execution. Do not claim completed work was undone.
|
|
17330
17332
|
- Use a single subagent for a focused specialty or parallel tasks for independent work. Keep substantial-overlap tasks together rather than duplicating investigation across agents.
|
|
@@ -17335,7 +17337,8 @@ var DEFAULT_PROMPT_GUIDANCE = [
|
|
|
17335
17337
|
- Use the debugger subagent for actual failures that need reproduction, root-cause diagnosis, and a validated fix; additional debugger or research delegates are optional when they add a distinct useful angle.
|
|
17336
17338
|
- Let each named agent use its declared model and fallback policy: omit the explicit model argument unless the user requests an exact model or a documented task requirement needs one, and record the reason for any override before launch. Do not choose an ad hoc model merely for diversity.
|
|
17337
17339
|
- If an agent has no declared model or fallback policy, consult packages/coding-agent/docs/models/model-selection.md for general role and effort guidance and packages/coding-agent/docs/models/evals.md for factual per-evaluation benchmark records, then use workflow({ action: "models" }) when available to inspect the configured catalog. Pin only a returned fullId and only append a thinking level listed for that entry. If the catalog tool is unavailable, the catalog is empty, or no catalog model matches the documented evidence and role constraints, leave the child unpinned and state the limitation rather than inventing a model. Do not inspect credentials or infer why a model is absent.
|
|
17338
|
-
- Workflow stages automatically receive their invocation-scoped Intercom group, and delegated children inherit the launching session's group across single, parallel, and follow-up work. Do not create or propagate group identifiers for ordinary workflow-stage delegation; use an explicit group only for an intentional topology override. Keep contact_supervisor available for cross-group escalation
|
|
17340
|
+
- Workflow stages automatically receive their invocation-scoped Intercom group, and delegated children inherit the launching session's group across single, parallel, and follow-up work. Do not create or propagate group identifiers for ordinary workflow-stage delegation; use an explicit group only for an intentional topology override. Keep contact_supervisor available for cross-group escalation.
|
|
17341
|
+
- Coordination is not only vertical. Same-group children and sibling workflow stages can discover each other with intercom list and send/ask each other directly to debate findings with evidence, hand off file locations and reproductions, claim ownership of shared files or expensive steps, and learn what a sibling already verified, instead of routing everything through the supervisor. contact_supervisor stays reserved for supervisor decisions. Children do not coordinate spontaneously: when parallel work is related, name the peers and the expected exchange in each task prompt, keep the exchange bounded, and require each child to return its own result.`
|
|
17339
17342
|
];
|
|
17340
17343
|
|
|
17341
17344
|
// dist/builtin/subagents/src/extension/schemas.ts
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bastani/web-access",
|
|
3
|
-
"version": "0.9.20-alpha.
|
|
3
|
+
"version": "0.9.20-alpha.6",
|
|
4
4
|
"private": true,
|
|
5
5
|
"description": "Atomic extension for web search, URL fetching, GitHub repo cloning, PDF/video extraction. Fork of: https://github.com/nicobailon/pi-web-access",
|
|
6
6
|
"contributors": [
|
|
@@ -31,7 +31,7 @@
|
|
|
31
31
|
},
|
|
32
32
|
"peerDependencies": {
|
|
33
33
|
"@bastani/atomic": "*",
|
|
34
|
-
"@earendil-works/pi-tui": "^0.
|
|
34
|
+
"@earendil-works/pi-tui": "^0.87.0"
|
|
35
35
|
},
|
|
36
36
|
"peerDependenciesMeta": {
|
|
37
37
|
"@bastani/atomic": {
|
|
@@ -6,6 +6,49 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
|
|
6
6
|
|
|
7
7
|
## [Unreleased]
|
|
8
8
|
|
|
9
|
+
## [0.9.20-alpha.6] - 2026-09-22
|
|
10
|
+
|
|
11
|
+
### Changed
|
|
12
|
+
|
|
13
|
+
- Goal and Ralph end-to-end verification guidance and the workflow-authoring guidance now direct desktop, simulator, and emulator verification to Cua Driver: builtin stages load the bundled `cua-driver` skill and drive the exact window with `cua-driver call <tool>` under `CUA_DRIVER_RS_TELEMETRY_ENABLED=false`, save `get_window_state` JSON and `screenshot_out_file` images as evidence, and report a missing permission, session, or refused install as `blocked`/`needs_human` with exact remediation; custom workflows run code-owned scenarios with the `@trycua/cua-driver` SDK inside `ctx.tool` with `timeoutMs` and `signal`, after a preflight `ctx.tool` that exits `blocked` on missing permissions. The OpenAI CUA sample-app reference was removed ([#3181](https://github.com/bastani-inc/atomic/issues/3181)).
|
|
14
|
+
|
|
15
|
+
### Fixed
|
|
16
|
+
|
|
17
|
+
- Docker fallback Postgres is no longer treated as ready when the published port accepts TCP during `initdb`. Atomic waits for a PostgreSQL query using the endpoint, credentials and TLS settings DBOS will use, retries transient startup resets and refusals (including a connection that terminates while the container is still starting), and shuts down a failed DBOS executor before continuing with the in-memory backend. Invalid readiness ports now fail before connecting rather than leaving a delayed process-crashing error.
|
|
18
|
+
- Failed DBOS executor cleanup no longer permits a second launch or an in-memory fallback with unconfirmed executor ownership; startup reports the initialization and cleanup errors instead.
|
|
19
|
+
- New Docker fallback containers now publish on the configured `PGPORT`, matching the readiness probe and DBOS connection instead of always binding host port 5432.
|
|
20
|
+
- A schema-backed workflow stage whose prompt resolves without any assistant message is no longer recorded as a successful model attempt and pushed into `structured_output` correction prompts. The empty completion is now classified as a transient provider failure at the execution layer: it is retried on the same model using the configured `settings.retry` budget, then advances to the next configured fallback, and its attempt record carries `Model turn ended without an assistant message after the prompt (empty completion)` instead of the structured-output contract error. Genuine cancellation during such a turn stops both the retries and the fallback chain, and corrective prompts remain reserved for turns that actually answered without calling the tool ([#3164](https://github.com/bastani-inc/atomic/issues/3164)).
|
|
21
|
+
|
|
22
|
+
## [0.9.20-alpha.5] - 2026-09-20
|
|
23
|
+
|
|
24
|
+
### Breaking Changes
|
|
25
|
+
|
|
26
|
+
- Workflow route `state` no longer accepts `executionPreference`, and unknown state fields are rejected before inference. The router now asks an independent question about the user's stated execution preference, judged from the user's own words in `state.task`, `state.conversation` and `state.constraints`: an explicit inline request yields `none` even when a workflow matches, and an explicit workflow request bypasses the lifecycle-benefit gate without inventing an unregistered workflow. The calling assistant passes evidence only, so it can no longer pre-decide the route.
|
|
27
|
+
|
|
28
|
+
- The `open-claude-design` workflow output `playwright_cli_status` is now `agent_browser_status`: the initial deterministic setup step probes for and installs the `agent-browser` CLI (`npm install -g agent-browser` + `agent-browser install`) instead of `playwright-cli`. Consumers reading `playwright_cli_status` must switch to the new field name.
|
|
29
|
+
|
|
30
|
+
### Changed
|
|
31
|
+
|
|
32
|
+
- `/workflow connect <run>` no longer prints a `Connected to <run-id>. h hide · ctrl+x leave graph …` notice into the chat; the graph overlay already shows its own key hints, and the picker path never printed one.
|
|
33
|
+
|
|
34
|
+
- Builtin workflow prompts (`open-claude-design`, `ralph`, goal orchestration, verification guidance, and workflow authoring guidance) now direct browser verification and evidence capture to the `agent-browser` skill and CLI instead of `playwright-cli`, including `agent-browser record start`/`record stop` for QA proof videos.
|
|
35
|
+
|
|
36
|
+
- Synchronized the bundled `impeccable` skill from upstream `skill-v4.1.1` (`5a149f3fdb1b5793f10567233b1dcab98fc305fd`, `.agents` distribution) to `skill-v4.3.1` (`cd12f8660e2dde57b9615c8a6b8ea674101f9cfc`, `.pi` distribution, engine 0.1.5). Every command now runs through the launcher at `scripts/impeccable` (`impeccable.cmd` on Windows), which executes a self-contained engine binary beside it or downloads the pinned release for the current platform into `~/.impeccable/bin/<version>/` and verifies it against the published SHA-256 before the first run; Node is no longer required, and `IMPECCABLE_BIN` selects a preinstalled engine where network access is unavailable. The launchers default `IMPECCABLE_NO_TELEMETRY` and `IMPECCABLE_NO_UPDATE_CHECK` on, keeping the concept-roll ping and the `npx impeccable update` prompt off for a skill that ships with each Atomic release, and the retained live-browser helpers keep their CSPRNG session-id hardening and removed-editor stripping.
|
|
37
|
+
|
|
38
|
+
- The `open-claude-design` live review loop drives the bundled Impeccable launcher's `live-poll` verb instead of the removed `live-poll.mjs` script, running `impeccable.cmd` through the platform shell on Windows.
|
|
39
|
+
|
|
40
|
+
- Workflow authoring guidance now describes stages in one invocation as peers: a live stage can `intercom list` its siblings and `send`/`ask` them directly, queue `send` to a known pending sibling, and `ask` a completed sibling that retains a valid conversation, with prompts expected to name the peers, bound the exchange, and keep each stage's structured result its own.
|
|
41
|
+
|
|
42
|
+
### Fixed
|
|
43
|
+
|
|
44
|
+
- An abandoned, owner-less embedded Postgres setup-lock directory (`~/.atomic/postgres/v<major>.setup-lock`, for example a legacy empty-directory lock or a crash remnant) now expires once it is older than the stale threshold, so Atomic recovers embedded provisioning instead of waiting ~30 s for a nonexistent owner and falling back to the non-durable in-memory backend. A freshly created empty directory, a future-dated one, and a live heartbeat owner remain protected ([#3135](https://github.com/bastani-inc/atomic/issues/3135)).
|
|
45
|
+
|
|
46
|
+
- An embedded Postgres setup-lock creator that is suspended between creating the lock directory and writing its owner marker can no longer end up holding a lease alongside a contender that expired and replaced the empty directory in the meantime. The creator now confirms its marker is the directory's only entry after writing it, and backs off as a lost race otherwise, so two Atomic processes cannot initialize or start the same data directory concurrently.
|
|
47
|
+
|
|
48
|
+
### Removed
|
|
49
|
+
|
|
50
|
+
- The bundled Impeccable skill no longer ships its Node `scripts/*.mjs` helpers, `scripts/detector/`, `scripts/live/`, `scripts/lib/`, or the Codex-only `agents/` definitions; upstream 4.3.1 moved that logic into the engine binary and the `.pi` distribution carries no Codex agent files.
|
|
51
|
+
|
|
9
52
|
## [0.9.20-alpha.4] - 2026-09-20
|
|
10
53
|
|
|
11
54
|
### Breaking Changes
|
|
@@ -455,6 +455,8 @@ When an item configures both `schema` and `output`, its successful `structured_o
|
|
|
455
455
|
|
|
456
456
|
Send material updates through Intercom to every affected workflow stage, including stages that have not started. Join `workflow:<rootRunId>` and use `intercom list` to see live, pending, and possible future targets, then send to `workflow:<rootRunId>/<segment>[/<segment>...]`; segments may be stage names, run ids, or globs (`*` matches one segment, `**` any depth). Name and pattern sends remain sticky for every future match until root termination. When shared scope or acceptance criteria change, broadcast one authoritative update to `workflow:<rootRunId>/**` (or a narrower pattern) rather than enumerating stages; live matches receive it immediately and future matches receive it before their first model turn. A valid target outside the known set queues with a `notInKnownSet` warning and settles undeliverable at terminal only if never delivered. Use `ask` only once the target is live and can reply. Workflow `answer` handles pending human-input prompts, and workflow `resume` handles paused run control.
|
|
457
457
|
|
|
458
|
+
Stages are also peers of one another. Every stage in an invocation shares the `workflow:<rootRunId>` group with its siblings and with the subagents they delegate, so a live stage can `intercom list` the others and `send`/`ask` them directly to debate a finding with evidence, hand off paths and reproductions, claim shared files or an expensive step, or learn what a sibling already verified. A `send` to a known pending sibling queues until it starts; an `ask` to a completed sibling that retains a valid conversation reopens it for a post-mortem turn. Named subgroups isolate their members from sibling subgroups. Stages do not coordinate spontaneously: when parallel stages should exchange evidence, the prompt names the peers or how to discover them, bounds the exchange, and requires each stage to return its own result. See [peer coordination between stages](../coding-agent/docs/workflows/reliable-design.md#peer-coordination-between-stages).
|
|
459
|
+
|
|
458
460
|
### Model fallbacks
|
|
459
461
|
|
|
460
462
|
Stages and high-level task helpers can retry transient provider/model failures with an ordered `fallbackModels` list. The primary `model` is tried first, then each fallback, and finally the current Atomic-selected model when available. Fallbacks are only used for retryable model/provider failures such as rate limits, quota/usage-limit exhaustion (provider messages such as `The usage limit has been reached` and codes such as `usage_limit_reached`/`insufficient_quota` classify as retryable rate-limit failures so the chain advances to a candidate with remaining headroom), auth/provider outages, unavailable models, network timeouts, context-window overflows that Atomic's auto-compaction cannot resolve on the current model, and 5xx errors — ordinary tool, shell, validation, cancellation, and workflow-code failures are not retried.
|
|
@@ -858,7 +860,7 @@ The live session is unbounded: accepted variants and steered edits are written i
|
|
|
858
860
|
|
|
859
861
|
The session starts at `user-feedback-N-start`; durable `live-poll-N-M` and `live-reply-N-M` tool nodes own polling and acknowledgements, while `live-generate-*`, `live-steer-*`, `live-manual_edit_apply-*`, and `live-variant_mount_failed-*` mint model stages. Replies pass the event id before the status. Successful `variant_mounted` events are journal-only; `accept`, `discard`, and `prefetch` mint no model stage, and `timeout` is absorbed in the poll node. Nonzero helper exits fail the run rather than looking like timeouts. No `<artifact_dir>/feedback/` directory or per-session record is written.
|
|
860
862
|
|
|
861
|
-
Impeccable 4.
|
|
863
|
+
The poll and reply nodes run the bundled Impeccable 4.3.1 launcher (`skills/impeccable/scripts/impeccable`, or `impeccable.cmd` on Windows) with the `live-poll` verb; the launcher runs the engine binary beside it or downloads and checksum-verifies the pinned engine release on first use, so a machine without network access needs `IMPECCABLE_BIN` pointed at a preinstalled engine. Live sessions persist the selected app root for every helper and support SvelteKit, Nuxt, TanStack Start, Astro, Next.js, Vite, and static HTML injection.
|
|
862
864
|
|
|
863
865
|
Research context moves between stages as artifact files, not inline prompt payloads: the project design context is written to `<artifact_dir>/design-context.md` and the curated references brief to `<artifact_dir>/references.md`; `reference-discovery`, `generate-1`, and `exporter` read the required files via `reads`.
|
|
864
866
|
|
|
@@ -871,7 +873,7 @@ Research context moves between stages as artifact files, not inline prompt paylo
|
|
|
871
873
|
| `prompt` | `text` | ✓ | — | Design brief or description. |
|
|
872
874
|
| `discover_references` | `boolean` | — | `true` | Discover current gallery references with browser tooling; set false to skip. |
|
|
873
875
|
|
|
874
|
-
Child workflow outputs: `output_type`, `design_system`, `artifact`, `handoff`, `import_context`, `run_id`, `artifact_dir`, `preview_path`, `preview_file_url`, `spec_path`, `spec_file_url`, and `
|
|
876
|
+
Child workflow outputs: `output_type`, `design_system`, `artifact`, `handoff`, `import_context`, `run_id`, `artifact_dir`, `preview_path`, `preview_file_url`, `spec_path`, `spec_file_url`, and `agent_browser_status`. `open-claude-design` has no `result` output; it exposes only the declared fields listed here.
|
|
875
877
|
|
|
876
878
|
---
|
|
877
879
|
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import {
|
|
2
2
|
adversarial_verification_default
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-dxjxtgmp.js";
|
|
4
4
|
import"./chunk-2377r57g.js";
|
|
5
5
|
import"./chunk-n1910xc4.js";
|
|
6
|
-
import"./chunk-
|
|
7
|
-
import"./chunk-
|
|
6
|
+
import"./chunk-5724b0cf.js";
|
|
7
|
+
import"./chunk-3tx8ry44.js";
|
|
8
8
|
export {
|
|
9
9
|
adversarial_verification_default as default
|
|
10
10
|
};
|
|
@@ -5125,6 +5125,36 @@ function getDbosProcessOwner() {
|
|
|
5125
5125
|
// dist/builtin/workflows/src/durable/dbos-sdk-handle.ts
|
|
5126
5126
|
var ATOMIC_EXECUTOR_ID = `atomic-${process.pid.toString(36)}-${crypto.randomUUID().slice(0, 8)}`;
|
|
5127
5127
|
|
|
5128
|
+
// ../../node_modules/pg/esm/index.mjs
|
|
5129
|
+
var import_lib = __toESM(require_lib2(), 1);
|
|
5130
|
+
var Client = import_lib.default.Client;
|
|
5131
|
+
var Pool = import_lib.default.Pool;
|
|
5132
|
+
var Connection = import_lib.default.Connection;
|
|
5133
|
+
var types = import_lib.default.types;
|
|
5134
|
+
var Query = import_lib.default.Query;
|
|
5135
|
+
var DatabaseError = import_lib.default.DatabaseError;
|
|
5136
|
+
var escapeIdentifier = import_lib.default.escapeIdentifier;
|
|
5137
|
+
var escapeLiteral = import_lib.default.escapeLiteral;
|
|
5138
|
+
var Result = import_lib.default.Result;
|
|
5139
|
+
var TypeOverrides = import_lib.default.TypeOverrides;
|
|
5140
|
+
var defaults = import_lib.default.defaults;
|
|
5141
|
+
|
|
5142
|
+
// dist/builtin/workflows/src/durable/dbos-default-postgres-url.ts
|
|
5143
|
+
function defaultPostgresUrl(database, host = process.env.PGHOST || "localhost", port = process.env.PGPORT || "5432") {
|
|
5144
|
+
const url = new URL("postgresql://localhost");
|
|
5145
|
+
url.pathname = `/${database}`;
|
|
5146
|
+
if (host.startsWith("/") || host.includes(":"))
|
|
5147
|
+
url.searchParams.set("host", host);
|
|
5148
|
+
else
|
|
5149
|
+
url.hostname = host;
|
|
5150
|
+
url.port = port;
|
|
5151
|
+
url.username = encodeURIComponent(process.env.PGUSER || "postgres");
|
|
5152
|
+
url.password = encodeURIComponent(process.env.PGPASSWORD || "dbos");
|
|
5153
|
+
url.searchParams.set("connect_timeout", process.env.PGCONNECT_TIMEOUT || "10");
|
|
5154
|
+
url.searchParams.set("sslmode", process.env.PGSSLMODE || (host === "localhost" ? "disable" : "allow"));
|
|
5155
|
+
return url.toString();
|
|
5156
|
+
}
|
|
5157
|
+
|
|
5128
5158
|
// dist/builtin/workflows/src/durable/dbos-embedded-postgres.ts
|
|
5129
5159
|
import {
|
|
5130
5160
|
chmodSync,
|
|
@@ -5844,20 +5874,6 @@ import { createServer } from "node:net";
|
|
|
5844
5874
|
import { endianness } from "node:os";
|
|
5845
5875
|
import { join as join3 } from "node:path";
|
|
5846
5876
|
|
|
5847
|
-
// ../../node_modules/pg/esm/index.mjs
|
|
5848
|
-
var import_lib = __toESM(require_lib2(), 1);
|
|
5849
|
-
var Client = import_lib.default.Client;
|
|
5850
|
-
var Pool = import_lib.default.Pool;
|
|
5851
|
-
var Connection = import_lib.default.Connection;
|
|
5852
|
-
var types = import_lib.default.types;
|
|
5853
|
-
var Query = import_lib.default.Query;
|
|
5854
|
-
var DatabaseError = import_lib.default.DatabaseError;
|
|
5855
|
-
var escapeIdentifier = import_lib.default.escapeIdentifier;
|
|
5856
|
-
var escapeLiteral = import_lib.default.escapeLiteral;
|
|
5857
|
-
var Result = import_lib.default.Result;
|
|
5858
|
-
var TypeOverrides = import_lib.default.TypeOverrides;
|
|
5859
|
-
var defaults = import_lib.default.defaults;
|
|
5860
|
-
|
|
5861
5877
|
// dist/builtin/workflows/src/durable/dbos-postgres-ownership.ts
|
|
5862
5878
|
import { randomUUID } from "node:crypto";
|
|
5863
5879
|
import {
|
|
@@ -6674,7 +6690,7 @@ async function withSetupLock(lockDir, fn, options = {}) {
|
|
|
6674
6690
|
const isProcessAlive = options.isProcessAlive ?? processIsAlive2;
|
|
6675
6691
|
let lease;
|
|
6676
6692
|
for (let attempt = 0;attempt < attempts; attempt += 1) {
|
|
6677
|
-
lease = acquireSetupLock(lockDir, clock(), staleMs, isProcessAlive);
|
|
6693
|
+
lease = acquireSetupLock(lockDir, clock(), staleMs, isProcessAlive, options.beforeOwnerMarkerWrite);
|
|
6678
6694
|
if (lease !== undefined)
|
|
6679
6695
|
break;
|
|
6680
6696
|
if (attempt === attempts - 1) {
|
|
@@ -6696,29 +6712,15 @@ async function withSetupLock(lockDir, fn, options = {}) {
|
|
|
6696
6712
|
releaseSetupLock(lease);
|
|
6697
6713
|
}
|
|
6698
6714
|
}
|
|
6699
|
-
function acquireSetupLock(lockDir, now, staleMs, isProcessAlive) {
|
|
6715
|
+
function acquireSetupLock(lockDir, now, staleMs, isProcessAlive, beforeOwnerMarkerWrite) {
|
|
6700
6716
|
const abandonedOwnerTokens = new Set;
|
|
6701
6717
|
for (let attempt = 0;attempt < 2; attempt += 1) {
|
|
6702
6718
|
const token = `${process.pid}-${crypto.randomUUID()}`;
|
|
6703
|
-
|
|
6704
|
-
|
|
6705
|
-
|
|
6706
|
-
|
|
6707
|
-
|
|
6708
|
-
flag: "wx",
|
|
6709
|
-
mode: 384
|
|
6710
|
-
});
|
|
6711
|
-
return { lockDir, markerPath, token, ownerPid: process.pid, abandonedOwnerTokens };
|
|
6712
|
-
} catch (error) {
|
|
6713
|
-
try {
|
|
6714
|
-
rmdirSync(lockDir);
|
|
6715
|
-
} catch {}
|
|
6716
|
-
throw error;
|
|
6717
|
-
}
|
|
6718
|
-
} catch (error) {
|
|
6719
|
-
const code = error instanceof Error && "code" in error ? error.code : undefined;
|
|
6720
|
-
if (code !== "EEXIST")
|
|
6721
|
-
throw error;
|
|
6719
|
+
if (createSetupLockDirectory(lockDir)) {
|
|
6720
|
+
beforeOwnerMarkerWrite?.(lockDir);
|
|
6721
|
+
const lease = claimCreatedSetupLock(lockDir, token, now, abandonedOwnerTokens);
|
|
6722
|
+
if (lease !== undefined)
|
|
6723
|
+
return lease;
|
|
6722
6724
|
}
|
|
6723
6725
|
const observation = observeSetupLock(lockDir);
|
|
6724
6726
|
if (observation === undefined || !setupLockIsStale(observation, now, staleMs, isProcessAlive))
|
|
@@ -6731,6 +6733,52 @@ function acquireSetupLock(lockDir, now, staleMs, isProcessAlive) {
|
|
|
6731
6733
|
}
|
|
6732
6734
|
return;
|
|
6733
6735
|
}
|
|
6736
|
+
function createSetupLockDirectory(lockDir) {
|
|
6737
|
+
try {
|
|
6738
|
+
mkdirSync2(lockDir);
|
|
6739
|
+
return true;
|
|
6740
|
+
} catch (error) {
|
|
6741
|
+
if (errorCode(error) === "EEXIST")
|
|
6742
|
+
return false;
|
|
6743
|
+
throw error;
|
|
6744
|
+
}
|
|
6745
|
+
}
|
|
6746
|
+
function claimCreatedSetupLock(lockDir, token, now, abandonedOwnerTokens) {
|
|
6747
|
+
const markerName = `.owner-${token}`;
|
|
6748
|
+
const markerPath = join4(lockDir, markerName);
|
|
6749
|
+
try {
|
|
6750
|
+
writeFileSync2(markerPath, serializeLockOwner({ token, pid: process.pid, heartbeatMonotonicMs: now.monotonicMs }), {
|
|
6751
|
+
flag: "wx",
|
|
6752
|
+
mode: 384
|
|
6753
|
+
});
|
|
6754
|
+
} catch (error) {
|
|
6755
|
+
try {
|
|
6756
|
+
rmdirSync(lockDir);
|
|
6757
|
+
} catch {}
|
|
6758
|
+
if (errorCode(error) === "ENOENT")
|
|
6759
|
+
return;
|
|
6760
|
+
throw error;
|
|
6761
|
+
}
|
|
6762
|
+
if (createdSetupLockHoldsOnly(lockDir, markerName)) {
|
|
6763
|
+
return { lockDir, markerPath, token, ownerPid: process.pid, abandonedOwnerTokens };
|
|
6764
|
+
}
|
|
6765
|
+
rmSync2(markerPath, { force: true });
|
|
6766
|
+
try {
|
|
6767
|
+
rmdirSync(lockDir);
|
|
6768
|
+
} catch {}
|
|
6769
|
+
return;
|
|
6770
|
+
}
|
|
6771
|
+
function createdSetupLockHoldsOnly(lockDir, markerName) {
|
|
6772
|
+
try {
|
|
6773
|
+
const entries = readdirSync2(lockDir);
|
|
6774
|
+
return entries.length === 1 && entries[0] === markerName;
|
|
6775
|
+
} catch {
|
|
6776
|
+
return false;
|
|
6777
|
+
}
|
|
6778
|
+
}
|
|
6779
|
+
function errorCode(error) {
|
|
6780
|
+
return error instanceof Error && "code" in error && typeof error.code === "string" ? error.code : undefined;
|
|
6781
|
+
}
|
|
6734
6782
|
function refreshSetupLockLease(lease, now, beforeReplace) {
|
|
6735
6783
|
if (!ownsSetupLock(lease))
|
|
6736
6784
|
return false;
|
|
@@ -6851,9 +6899,15 @@ function setupLockIsStale(observation, now, staleMs, isProcessAlive) {
|
|
|
6851
6899
|
return false;
|
|
6852
6900
|
}
|
|
6853
6901
|
}
|
|
6854
|
-
if (
|
|
6855
|
-
return observation.
|
|
6856
|
-
|
|
6902
|
+
if (observation.hasUnexpectedState) {
|
|
6903
|
+
return now.wallTimeMs < observation.latestMtimeMs || now.wallTimeMs - observation.latestMtimeMs > staleMs;
|
|
6904
|
+
}
|
|
6905
|
+
if (observation.owners.length > 0)
|
|
6906
|
+
return true;
|
|
6907
|
+
return emptySetupLockIsAbandoned(observation, now, staleMs);
|
|
6908
|
+
}
|
|
6909
|
+
function emptySetupLockIsAbandoned(observation, now, staleMs) {
|
|
6910
|
+
return Number.isFinite(observation.latestMtimeMs) && now.wallTimeMs - observation.latestMtimeMs > staleMs;
|
|
6857
6911
|
}
|
|
6858
6912
|
function serializeLockOwner(owner) {
|
|
6859
6913
|
const serialized = JSON.stringify(owner);
|
|
@@ -6915,6 +6969,16 @@ var DOCKER_CONTAINER = "dbos-db";
|
|
|
6915
6969
|
var DOCKER_IMAGE = "pgvector/pgvector:pg16";
|
|
6916
6970
|
var DOCKER_READY_ATTEMPTS = 60;
|
|
6917
6971
|
var DOCKER_READY_DELAY_MS = 500;
|
|
6972
|
+
var DOCKER_READY_QUERY_TIMEOUT_MS = 1000;
|
|
6973
|
+
var TRANSIENT_STARTUP_CODES = new Set([
|
|
6974
|
+
"ECONNREFUSED",
|
|
6975
|
+
"ECONNRESET",
|
|
6976
|
+
"ETIMEDOUT",
|
|
6977
|
+
"EPIPE",
|
|
6978
|
+
"57P01",
|
|
6979
|
+
"57P02",
|
|
6980
|
+
"57P03"
|
|
6981
|
+
]);
|
|
6918
6982
|
var resolution;
|
|
6919
6983
|
var resolvedProvider;
|
|
6920
6984
|
var embeddedProvider = ensureEmbeddedDbosPostgres;
|
|
@@ -7004,6 +7068,103 @@ function shutdownResolvedLocalDbos() {
|
|
|
7004
7068
|
});
|
|
7005
7069
|
return embeddedShutdown;
|
|
7006
7070
|
}
|
|
7071
|
+
function postgresReadinessPort(value) {
|
|
7072
|
+
const port = Number(value);
|
|
7073
|
+
const validFormat = typeof value !== "string" || /^\d+$/.test(value);
|
|
7074
|
+
const validPort = Number.isInteger(port) && port >= 1 && port <= 65535;
|
|
7075
|
+
if (!validFormat || !validPort)
|
|
7076
|
+
throw new Error("PostgreSQL readiness port (PGPORT) must be an integer between 1 and 65535.");
|
|
7077
|
+
return port;
|
|
7078
|
+
}
|
|
7079
|
+
function dockerFallbackEndpoint() {
|
|
7080
|
+
return {
|
|
7081
|
+
host: process.env.PGHOST || "localhost",
|
|
7082
|
+
port: postgresReadinessPort(process.env.PGPORT || "5432"),
|
|
7083
|
+
user: process.env.PGUSER || "postgres",
|
|
7084
|
+
password: process.env.PGPASSWORD || "dbos"
|
|
7085
|
+
};
|
|
7086
|
+
}
|
|
7087
|
+
async function waitForPostgresProtocolReadiness(options) {
|
|
7088
|
+
postgresReadinessPort(options.port);
|
|
7089
|
+
const attempts = options.attempts ?? DOCKER_READY_ATTEMPTS;
|
|
7090
|
+
const delayMs = options.delayMs ?? DOCKER_READY_DELAY_MS;
|
|
7091
|
+
const wait = options.wait ?? delay;
|
|
7092
|
+
const isReady = options.isReady ?? dockerPostgresQueryReady;
|
|
7093
|
+
const deadline = performance.now() + attempts * delayMs;
|
|
7094
|
+
for (let attempt = 0;attempt < attempts && performance.now() < deadline; attempt += 1) {
|
|
7095
|
+
try {
|
|
7096
|
+
if (await isReady(options.host, options.port))
|
|
7097
|
+
return;
|
|
7098
|
+
} catch (error) {
|
|
7099
|
+
if (!isTransientStartupError(readStartupFailure(error)))
|
|
7100
|
+
throw error;
|
|
7101
|
+
}
|
|
7102
|
+
if (attempt + 1 < attempts && performance.now() < deadline)
|
|
7103
|
+
await wait(delayMs);
|
|
7104
|
+
}
|
|
7105
|
+
throw new Error(`The DBOS Postgres container started but did not become ready within ${attempts * delayMs / 1000} seconds.`);
|
|
7106
|
+
}
|
|
7107
|
+
function readStartupFailure(value) {
|
|
7108
|
+
if (!(value instanceof Error))
|
|
7109
|
+
return { message: String(value) };
|
|
7110
|
+
const cause = value.cause;
|
|
7111
|
+
return {
|
|
7112
|
+
message: value.message,
|
|
7113
|
+
code: "code" in value && typeof value.code === "string" ? value.code : undefined,
|
|
7114
|
+
cause: cause === undefined ? undefined : cause instanceof Error ? cause : String(cause),
|
|
7115
|
+
source: value
|
|
7116
|
+
};
|
|
7117
|
+
}
|
|
7118
|
+
function isTransientStartupError(error) {
|
|
7119
|
+
const seen = new Set;
|
|
7120
|
+
let current = error;
|
|
7121
|
+
while (current !== undefined) {
|
|
7122
|
+
const { code, message, source, cause } = current;
|
|
7123
|
+
if (typeof code === "string" && TRANSIENT_STARTUP_CODES.has(code))
|
|
7124
|
+
return true;
|
|
7125
|
+
if (typeof code === "string" && /^[0-9A-Z]{5}$/.test(code))
|
|
7126
|
+
return false;
|
|
7127
|
+
if (/\b(?:ECONNRESET|ECONNREFUSED|ETIMEDOUT|EPIPE)\b|^connection (?:refused|terminated(?: unexpectedly| due to connection timeout)?)(?:\s|$)|^connect(?:ion)? (?:timeout|timed out)(?:\s|$)|^timeout (?:expired|exceeded when trying to connect)$/i.test(message))
|
|
7128
|
+
return true;
|
|
7129
|
+
if (source === undefined || seen.has(source))
|
|
7130
|
+
return false;
|
|
7131
|
+
seen.add(source);
|
|
7132
|
+
current = cause === undefined ? undefined : readStartupFailure(cause);
|
|
7133
|
+
}
|
|
7134
|
+
return false;
|
|
7135
|
+
}
|
|
7136
|
+
async function dockerPostgresQueryReady(host, port) {
|
|
7137
|
+
const client = new Client({
|
|
7138
|
+
connectionString: defaultPostgresUrl("postgres", host, String(port)),
|
|
7139
|
+
connectionTimeoutMillis: DOCKER_READY_QUERY_TIMEOUT_MS,
|
|
7140
|
+
query_timeout: DOCKER_READY_QUERY_TIMEOUT_MS,
|
|
7141
|
+
statement_timeout: DOCKER_READY_QUERY_TIMEOUT_MS
|
|
7142
|
+
});
|
|
7143
|
+
client.on("error", () => {});
|
|
7144
|
+
let timer;
|
|
7145
|
+
try {
|
|
7146
|
+
await Promise.race([
|
|
7147
|
+
(async () => {
|
|
7148
|
+
await client.connect();
|
|
7149
|
+
await client.query("SELECT 1");
|
|
7150
|
+
})(),
|
|
7151
|
+
new Promise((_, reject) => {
|
|
7152
|
+
timer = setTimeout(() => reject(new Error("timeout expired")), DOCKER_READY_QUERY_TIMEOUT_MS);
|
|
7153
|
+
})
|
|
7154
|
+
]);
|
|
7155
|
+
return true;
|
|
7156
|
+
} catch (error) {
|
|
7157
|
+
if (isTransientStartupError(readStartupFailure(error)))
|
|
7158
|
+
return false;
|
|
7159
|
+
throw error;
|
|
7160
|
+
} finally {
|
|
7161
|
+
if (timer !== undefined)
|
|
7162
|
+
clearTimeout(timer);
|
|
7163
|
+
client.end().catch(() => {
|
|
7164
|
+
return;
|
|
7165
|
+
});
|
|
7166
|
+
}
|
|
7167
|
+
}
|
|
7007
7168
|
async function resolve() {
|
|
7008
7169
|
const explicit = process.env.DBOS_SYSTEM_DATABASE_URL?.trim();
|
|
7009
7170
|
if (explicit)
|
|
@@ -7029,6 +7190,7 @@ async function resolve() {
|
|
|
7029
7190
|
}
|
|
7030
7191
|
}
|
|
7031
7192
|
async function ensureDockerDbosPostgres() {
|
|
7193
|
+
const endpoint = dockerFallbackEndpoint();
|
|
7032
7194
|
const docker = await runLocalCommand("docker", ["version", "--format", "{{.Server.Version}}"]).catch(() => {
|
|
7033
7195
|
return;
|
|
7034
7196
|
});
|
|
@@ -7051,18 +7213,13 @@ async function ensureDockerDbosPostgres() {
|
|
|
7051
7213
|
"-e",
|
|
7052
7214
|
"PGDATA=/var/lib/postgresql/data",
|
|
7053
7215
|
"-p",
|
|
7054
|
-
|
|
7216
|
+
`127.0.0.1:${endpoint.port}:5432`,
|
|
7055
7217
|
"-v",
|
|
7056
7218
|
"dbos-db-data:/var/lib/postgresql/data",
|
|
7057
7219
|
DOCKER_IMAGE
|
|
7058
7220
|
]);
|
|
7059
7221
|
}
|
|
7060
|
-
|
|
7061
|
-
if (await tcpReachable("127.0.0.1", 5432))
|
|
7062
|
-
return;
|
|
7063
|
-
await delay(DOCKER_READY_DELAY_MS);
|
|
7064
|
-
}
|
|
7065
|
-
throw new Error("The DBOS Postgres container started but did not become ready within 30 seconds.");
|
|
7222
|
+
await waitForPostgresProtocolReadiness({ host: endpoint.host, port: endpoint.port });
|
|
7066
7223
|
}
|
|
7067
7224
|
async function requireDockerSuccess(action, args) {
|
|
7068
7225
|
const result = await runLocalCommand("docker", args);
|
|
@@ -63,9 +63,9 @@ var WORKER_PREFLIGHT_CONTRACT = [
|
|
|
63
63
|
`);
|
|
64
64
|
var E2E_VERIFICATION_GUIDANCE = [
|
|
65
65
|
"Verify correctness end-to-end whenever practical for user-visible behavior; an executable scenario is stronger proof than code inspection, unit tests, or stage summaries alone.",
|
|
66
|
-
'For web or frontend flows, including frontend changes whose correctness depends on backend/API behavior, use the
|
|
66
|
+
'For web or frontend flows, including frontend changes whose correctness depends on backend/API behavior, use the agent-browser skill or delegate with `skill: "agent-browser"`; capture snapshot, screenshot, DOM, or network evidence suited to the objective. Prefer agent-browser for what its skill covers (websites and web apps in Chrome/Chromium, Electron desktop apps, Slack, cloud browsers); use Cua Driver for anything else, including iOS simulators, Android emulators, OS dialogs, and non-Chromium browsers, and whenever agent-browser hits a limitation.',
|
|
67
67
|
"For TUI/terminal automation/testing, prefer the herdr skill on macOS, Linux and Windows. Install Herdr if missing when network access and permissions permit; fall back to the tmux skill or native Windows psmux if installation or use is not possible. Preserve the pinned herdr skill's explicit-request and HERDR_ENV=1 requirements; never control a focused session from outside Herdr. Check installed help: psmux uses tmux-style commands, while herdr has its own CLI, not interchangeable flags. Exercise the actual interactive flow and retain pane/text or terminal recording evidence.",
|
|
68
|
-
"For desktop and accessible simulator/emulator windows, use
|
|
68
|
+
"For desktop and accessible simulator/emulator windows, use Cua Driver: when a model chooses the next action, as in this stage, use the `cua-driver` CLI; when workflow TypeScript code owns the sequence and the postcondition, the @trycua/cua-driver TypeScript SDK inside `ctx.tool` is the face instead. Here, load the cua-driver skill and drive the exact window with one-shot `cua-driver call <tool>` commands, following the skill's snapshot -> act -> fresh snapshot -> verify loop. Before the first action, ensure the executable (`cua-driver --version`; if missing, one bounded attempt with upstream's one-line installer, reporting its side effects; never `cua-driver skills install`), telemetry off (run every command with CUA_DRIVER_RS_TELEMETRY_ENABLED=false, and `cua-driver telemetry disable` once after an executable install), and readiness (`cua-driver status`, `cua-driver doctor`, `cua-driver call list_apps`; on macOS also `cua-driver permissions status`, starting a stopped daemon with `open -n -g -a CuaDriver --args serve`) with bounded attempts per docs/computer-use.md. Save each `get_window_state` JSON result and `screenshot_out_file` image to the artifacts directory as evidence. Report a missing macOS Accessibility or Screen Recording grant, a non-interactive Windows session, no graphical Linux session, or a refused/failed install as the stage's blocked/needs_human finding with the exact fix (for macOS: `cua-driver permissions grant`, then toggle CuaDriver on under System Settings -> Privacy & Security -> Accessibility and Screen & System Audio Recording, then relaunch the daemon; for an install: the exact installer command), and re-run the readiness check on resume. Use a dedicated desktop/session and controlled fixtures, inspect snapshots for other windows, and stop before destructive actions. Do not automate an arbitrary physical iPhone without an accessible simulator/emulator/mirroring or native automation setup, or label browser recordings as terminal/iOS proof.",
|
|
69
69
|
"Choose tools from observed environment capabilities. Prefer installed/cached tools; install missing tools, runtimes or plugins when online access and permissions permit. Known offline/restricted installation is sufficient evidence not to attempt prohibited downloads; otherwise check capabilities or make one bounded setup attempt. Do not loop on blocked downloads, require production credentials, or take unsafe actions.",
|
|
70
70
|
"When execution or installation is unavailable, continue available authoritative repository checks and retain useful local evidence. Report the constraint or attempted command with observed output, what could not run, and the narrower validation performed. For non-UI tasks, use relevant executable checks rather than manufacturing a UI scenario. An unavailable optional mechanism is not itself failed implementation or permission to relax required project checks."
|
|
71
71
|
].join(`
|
|
@@ -79,6 +79,7 @@ var CODE_QUALITY_VERIFICATION_GUIDANCE = [
|
|
|
79
79
|
`);
|
|
80
80
|
var MEDIA_PUBLICATION_GUIDANCE = [
|
|
81
81
|
"Detect the repository provider and authorized PR/MR/issue/comment target before publishing media. Inspect and redact screenshots/video for secrets, personal information and unrelated windows; tie evidence to the verified commit and scenario. Local evidence collection does not authorize uploads.",
|
|
82
|
+
"When creating the PR/MR, gather the image and video evidence the verification stages produced and attach it to the PR body when the provider supports uploads: cua-driver `screenshot_out_file` before/after PNGs from `get_window_state`, agent-browser `screenshot` PNGs and `record` recordings, and any QA proof video. Reference each file in the body next to the scenario it proves (a before/after pair per verified postcondition, one recording per interaction) and keep the window-state JSON as a local artifact the body cites by name. On supported GitHub, pass them at creation: gh pr create --body-file <body.md> --attach 'before.png#State before the action' --attach 'after.png#State after the action' --attach flow.webm; use gh pr edit/comment --attach for evidence produced later.",
|
|
82
83
|
"On GitHub, check gh --version and the chosen command's --help. GitHub CLI >=2.99.0 supports repeatable --attach on gh issue create/edit/comment and gh pr create/edit/comment. Use native attachments when supported, for example gh pr comment <number> --repo <owner/repo> --body-file <body.md> --attach <proof.mp4>. Attach each file once. Body-local path references are rewritten to hosted URLs; otherwise attachments append in flag order. Image path#alt text is supported; video alt text is not. A standalone  paragraph becomes an embedded player.",
|
|
83
84
|
"Check current GitHub limits: PNG/JPEG/GIF/WebP/SVG images and MP4/MOV/WebM videos; images/GIFs up to 10 MB, video 10 MB on Free or 100 MB paid. Native attachment upload requires repository write access and supported OAuth/classic PAT auth; GitHub Enterprise Server is unsupported in this release. See https://docs.github.com/en/github-cli/github-cli/attaching-files-with-github-cli.",
|
|
84
85
|
"Read back the returned PR/issue/comment and confirm usable GitHub-hosted links before claiming attachment success. Unsupported CLI versions, hosts, providers, auth or sizes require a truthful fallback: retain the local artifact and explain authorized manual attachment or supported provider options. Never claim file:// links are uploaded evidence, expose secrets, or upload automatically to unrelated third-party hosts."
|