@bastani/atomic 0.10.9 → 0.10.10-alpha.1
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 +57 -0
- package/README.md +211 -155
- package/dist/_shared/dist-KOELCESV.js +2 -2
- package/dist/_shared/fork-row-index-UAUAQRD5.js +2 -2
- package/dist/_shared/lib-4PES5P4V.js +2 -2
- package/dist/_shared/mode-interactive-sdk-7KXUFI2F.js +27 -12
- package/dist/_shared/mode-interactive-sdk-7KXUFI2F.js.map +1 -1
- package/dist/_shared/mode-rpc-sdk-IOPGDYR4.js +47 -7
- package/dist/_shared/mode-rpc-sdk-IOPGDYR4.js.map +1 -1
- package/dist/_shared/mode-shared-2QJSCUM6.js +48 -19
- package/dist/_shared/mode-shared-2QJSCUM6.js.map +1 -1
- package/dist/_shared/{p1a-prewarm-UQY3X2UK.js → p1a-prewarm-XIU57JHF.js} +5 -5
- package/dist/_shared/{p1a-prewarm-UQY3X2UK.js.map → p1a-prewarm-XIU57JHF.js.map} +1 -1
- package/dist/_shared/p2-shell-main-B2WIALFD.js +30 -25
- package/dist/_shared/p2-shell-main-B2WIALFD.js.map +1 -1
- package/dist/_shared/runtime-O4KCSG4C.js +5 -5
- package/dist/_shared/{sdk-OSBEPR3Q.js → sdk-RRLVN7ER.js} +15 -9
- package/dist/_shared/sdk-RRLVN7ER.js.map +1 -0
- package/dist/_shared/session-data-AHTU7IS6.js +2 -2
- package/dist/_shared/session-manager-list-2BLEEZVG.js +1 -1
- package/dist/_shared/settings-startup-8-DNZ2RIHM.js +4 -1
- package/dist/_shared/settings-startup-8-DNZ2RIHM.js.map +1 -1
- package/dist/_shared/{startup-0-0-TYUFUOJZ.js → startup-0-0-4VG2G44V.js} +427 -33
- package/dist/_shared/startup-0-0-4VG2G44V.js.map +1 -0
- package/dist/_shared/{startup-0-1-W2G2UY7R.js → startup-0-1-XTIL65D4.js} +18 -11
- package/dist/_shared/startup-0-1-XTIL65D4.js.map +1 -0
- package/dist/_shared/{startup-0-2-UXBUEOXW.js → startup-0-2-27OWFHV6.js} +145 -58
- package/dist/_shared/startup-0-2-27OWFHV6.js.map +1 -0
- package/dist/_shared/startup-0-3-T4DVFYWX.js +15 -25
- package/dist/_shared/startup-0-3-T4DVFYWX.js.map +1 -1
- package/dist/_shared/{startup-0-4-HN5EB4K7.js → startup-0-4-ZMJV547D.js} +81 -12
- package/dist/_shared/startup-0-4-ZMJV547D.js.map +1 -0
- package/dist/_shared/startup-0-5-FD2P735I.js +90 -50
- package/dist/_shared/startup-0-5-FD2P735I.js.map +1 -1
- package/dist/_shared/startup-10-0-TDQNBDDL.js +5 -5
- package/dist/_shared/startup-12-0-55AAXBJZ.js +13 -7
- package/dist/_shared/startup-12-0-55AAXBJZ.js.map +1 -1
- package/dist/_shared/startup-14-0-MLX36RBG.js +4 -4
- package/dist/_shared/startup-15-0-YUKGAC63.js +4 -4
- package/dist/_shared/startup-15-1-4S7FLMNG.js +88 -28
- package/dist/_shared/startup-15-1-4S7FLMNG.js.map +1 -1
- package/dist/_shared/startup-8-0-34CBHPZH.js +5 -5
- package/dist/_shared/startup-8-1-4KANEHRA.js +61 -17
- package/dist/_shared/startup-8-1-4KANEHRA.js.map +1 -1
- package/dist/_shared/storage-command-7MGXLJGZ.js +4 -4
- package/dist/_shared/task-unsaved-answer-VJ2KTB4V.js +2 -2
- package/dist/_shared/tree-outline-MUEPK5B7.js +2 -2
- package/dist/builtin/intercom/CHANGELOG.md +6 -0
- package/dist/builtin/intercom/README.md +85 -114
- package/dist/builtin/intercom/broker/broker.bundle.mjs +3 -3
- package/dist/builtin/intercom/broker/presence-handler.ts +1 -1
- package/dist/builtin/intercom/group.ts +7 -3
- package/dist/builtin/intercom/index.bundle.mjs +1 -1
- package/dist/builtin/intercom/package.json +1 -1
- package/dist/builtin/mcp/README.md +37 -27
- package/dist/builtin/mcp/index.bundle.mjs +1 -1
- package/dist/builtin/mcp/package.json +1 -1
- package/dist/builtin/subagents/CHANGELOG.md +8 -0
- package/dist/builtin/subagents/README.md +71 -138
- package/dist/builtin/subagents/package.json +1 -1
- package/dist/builtin/subagents/src/extension/index.bundle.mjs +213 -74
- package/dist/builtin/web-access/CHANGELOG.md +9 -0
- package/dist/builtin/web-access/README.md +60 -87
- package/dist/builtin/web-access/index.bundle.mjs +387 -351
- package/dist/builtin/web-access/package.json +1 -1
- package/dist/cli/args.js +2 -2
- package/dist/cli/auth-cli.code.js +4 -4
- package/dist/cli/auth-cli.impl.js +3 -3
- package/dist/cli/auth-cli.js +3 -3
- package/dist/cli/blueprint-command.code.js +2 -2
- package/dist/cli/blueprint-command.impl.js +3 -3
- package/dist/cli/blueprint-command.js +3 -3
- package/dist/cli/intercom-command.code.js +3 -3
- package/dist/cli/intercom-command.impl.js +3 -3
- package/dist/cli/intercom-command.js +3 -3
- package/dist/cli/list-models.code.js +3 -3
- package/dist/cli/list-models.impl.js +3 -3
- package/dist/cli/list-models.js +3 -3
- package/dist/cli/session-picker.code.js +2 -2
- package/dist/cli/session-picker.impl.js +3 -3
- package/dist/cli/session-picker.js +3 -3
- package/dist/cli/startup-ui.code.js +2 -2
- package/dist/cli/startup-ui.impl.js +3 -3
- package/dist/cli/startup-ui.js +3 -3
- package/dist/cli/storage-command.impl.js +3 -3
- package/dist/cli/storage-command.js +3 -3
- package/dist/cli/storage-search-session.code.js +2 -2
- package/dist/cli/storage-search-session.impl.js +3 -3
- package/dist/cli/storage-search-session.js +3 -3
- package/dist/cli/team-command.code.js +2 -2
- package/dist/cli/team-command.impl.js +3 -3
- package/dist/cli/team-command.js +3 -3
- package/dist/cli.js +2 -2
- package/dist/core/agent-session-methods.d.ts +4 -1
- package/dist/core/agent-session-methods.js.map +1 -1
- package/dist/core/agent-session.d.ts +3 -0
- package/dist/core/compaction/compactor.d.ts +20 -14
- package/dist/core/compaction/errors.d.ts +120 -0
- package/dist/core/compaction/index.d.ts +1 -0
- package/dist/core/compaction/model-resolver.d.ts +2 -2
- package/dist/core/debug.impl.js +3 -3
- package/dist/core/debug.js +3 -3
- package/dist/core/export-html/card-projection.impl.js +3 -3
- package/dist/core/export-html/card-projection.js +3 -3
- package/dist/core/export-html/index.code.js +2 -2
- package/dist/core/export-html/index.impl.js +3 -3
- package/dist/core/export-html/index.js +3 -3
- package/dist/core/export-html/json-spans.impl.js +3 -3
- package/dist/core/export-html/json-spans.js +3 -3
- package/dist/core/export-html/oversized-render-inputs.impl.js +3 -3
- package/dist/core/export-html/oversized-render-inputs.js +3 -3
- package/dist/core/export-html/tool-renderer.code.js +1 -1
- package/dist/core/export-html/tool-renderer.impl.js +3 -3
- package/dist/core/export-html/tool-renderer.js +3 -3
- package/dist/core/extensions/api-types.d.ts +1 -1
- package/dist/core/extensions/api-types.js.map +1 -1
- package/dist/core/extensions/index.d.ts +1 -1
- package/dist/core/extensions/jiti-loader.impl.js +3 -3
- package/dist/core/extensions/jiti-loader.js +3 -3
- package/dist/core/extensions/jiti-static-loader.impl.js +3 -3
- package/dist/core/extensions/jiti-static-loader.js +3 -3
- package/dist/core/extensions/loader-host-modules.code.js +1 -1
- package/dist/core/extensions/loader-host-modules.impl.js +3 -3
- package/dist/core/extensions/loader-host-modules.js +3 -3
- package/dist/core/extensions/loader-virtual-modules.js +1 -1
- package/dist/core/extensions/provider-types.d.ts +18 -6
- package/dist/core/extensions/provider-types.js.map +1 -1
- package/dist/core/extensions/runner-context.js +1 -1
- package/dist/core/intercom-broker-control-host.code.js +1 -1
- package/dist/core/intercom-broker-control-host.impl.js +3 -3
- package/dist/core/intercom-broker-control-host.js +3 -3
- package/dist/core/intercom-broker-control.code.js +3 -3
- package/dist/core/intercom-broker-control.impl.js +3 -3
- package/dist/core/intercom-broker-control.js +3 -3
- package/dist/core/model-config.d.ts +40 -0
- package/dist/core/model-registry.js +1 -1
- package/dist/core/model-resolver-scope.d.ts +4 -4
- package/dist/core/model-runtime.d.ts +1 -1
- package/dist/core/package-manager-storage-adapters.impl.js +3 -3
- package/dist/core/package-manager-storage-adapters.js +3 -3
- package/dist/core/provider-composer-internal.d.ts +11 -2
- package/dist/core/sdk.code.js +3 -3
- package/dist/core/sdk.impl.js +3 -3
- package/dist/core/sdk.js +3 -3
- package/dist/core/session-manager-core.js +5 -5
- package/dist/core/session-manager-list.impl.js +3 -3
- package/dist/core/session-manager-list.js +3 -3
- package/dist/core/session-manager.code.js +1 -1
- package/dist/core/session-manager.impl.js +3 -3
- package/dist/core/session-manager.js +3 -3
- package/dist/core/session-storage.impl.js +3 -3
- package/dist/core/session-storage.js +3 -3
- package/dist/core/settings-manager-basic-accessors.d.ts +6 -2
- package/dist/core/storage/index.js +2 -2
- package/dist/core/storage/node-sqlite-thread.js +2 -2
- package/dist/core/storage/node-sqlite.js +2 -2
- package/dist/core/storage/offline-snapshot-file.impl.js +3 -3
- package/dist/core/storage/offline-snapshot-file.js +3 -3
- package/dist/core/storage/provider.js +2 -2
- package/dist/core/storage/selection.js +2 -2
- package/dist/core/storage/session/branch-fork-source.code.js +2 -2
- package/dist/core/storage/session/branch-fork-source.impl.js +3 -3
- package/dist/core/storage/session/branch-fork-source.js +3 -3
- package/dist/core/storage/session/card-view.impl.js +3 -3
- package/dist/core/storage/session/card-view.js +3 -3
- package/dist/core/storage/session/child-reader.code.js +3 -3
- package/dist/core/storage/session/child-reader.impl.js +3 -3
- package/dist/core/storage/session/child-reader.js +3 -3
- package/dist/core/storage/session/chunked-resume-projection.impl.js +3 -3
- package/dist/core/storage/session/chunked-resume-projection.js +3 -3
- package/dist/core/storage/session/expanded-child-details.code.js +2 -2
- package/dist/core/storage/session/expanded-child-details.impl.js +3 -3
- package/dist/core/storage/session/expanded-child-details.js +3 -3
- package/dist/core/storage/session/fork-row-bytes.impl.js +3 -3
- package/dist/core/storage/session/fork-row-bytes.js +3 -3
- package/dist/core/storage/session/fork-row-index.impl.js +3 -3
- package/dist/core/storage/session/fork-row-index.js +3 -3
- package/dist/core/storage/session/fork-staging.code.js +2 -2
- package/dist/core/storage/session/fork-staging.impl.js +3 -3
- package/dist/core/storage/session/fork-staging.js +3 -3
- package/dist/core/storage/session/fork-window.code.js +3 -3
- package/dist/core/storage/session/fork-window.impl.js +3 -3
- package/dist/core/storage/session/fork-window.js +3 -3
- package/dist/core/storage/session/history-pages.impl.js +3 -3
- package/dist/core/storage/session/history-pages.js +3 -3
- package/dist/core/storage/session/jsonl-entry-projection.impl.js +3 -3
- package/dist/core/storage/session/jsonl-entry-projection.js +3 -3
- package/dist/core/storage/session/jsonl-session-store.impl.js +3 -3
- package/dist/core/storage/session/jsonl-session-store.js +3 -3
- package/dist/core/storage/session/memory-session-store.impl.js +3 -3
- package/dist/core/storage/session/memory-session-store.js +3 -3
- package/dist/core/storage/session/pinned-branch-resume.code.js +3 -3
- package/dist/core/storage/session/pinned-branch-resume.impl.js +3 -3
- package/dist/core/storage/session/pinned-branch-resume.js +3 -3
- package/dist/core/storage/session/released-history-files.code.js +3 -3
- package/dist/core/storage/session/released-history-files.impl.js +3 -3
- package/dist/core/storage/session/released-history-files.js +3 -3
- package/dist/core/storage/session/resident-fork-rows.impl.js +3 -3
- package/dist/core/storage/session/resident-fork-rows.js +3 -3
- package/dist/core/storage/session/session-resume.impl.js +3 -3
- package/dist/core/storage/session/session-resume.js +3 -3
- package/dist/core/storage/session/snapshot-cut.impl.js +3 -3
- package/dist/core/storage/session/snapshot-cut.js +3 -3
- package/dist/core/storage/session/snapshot-history.code.js +3 -3
- package/dist/core/storage/session/snapshot-history.impl.js +3 -3
- package/dist/core/storage/session/snapshot-history.js +3 -3
- package/dist/core/storage/session/sql-session-store.code.js +1 -1
- package/dist/core/storage/session/sql-session-store.impl.js +3 -3
- package/dist/core/storage/session/sql-session-store.js +3 -3
- package/dist/core/storage/session/tree-outline.impl.js +3 -3
- package/dist/core/storage/session/tree-outline.js +3 -3
- package/dist/core/storage/session/tree-presentation.impl.js +3 -3
- package/dist/core/storage/session/tree-presentation.js +3 -3
- package/dist/core/storage/storage-status.impl.js +3 -3
- package/dist/core/storage/storage-status.js +3 -3
- package/dist/core/storage/team.impl.js +3 -3
- package/dist/core/storage/team.js +3 -3
- package/dist/core/structured-output/index.code.js +1 -1
- package/dist/core/structured-output/index.impl.js +3 -3
- package/dist/core/structured-output/index.js +3 -3
- package/dist/core/tasks/task-completion-entry.impl.js +3 -3
- package/dist/core/tasks/task-completion-entry.js +3 -3
- package/dist/core/tasks/task-file-history.code.js +3 -3
- package/dist/core/tasks/task-file-history.impl.js +3 -3
- package/dist/core/tasks/task-file-history.js +3 -3
- package/dist/core/tasks/task-reference-archive.code.js +4 -4
- package/dist/core/tasks/task-reference-archive.js +3 -3
- package/dist/core/tasks/task-reference-identity.code.js +1 -1
- package/dist/core/tasks/task-reference-identity.js +3 -3
- package/dist/core/tasks/task-reference-stream.impl.js +3 -3
- package/dist/core/tasks/task-reference-stream.js +3 -3
- package/dist/core/tasks/task-unsaved-answer.impl.js +3 -3
- package/dist/core/tasks/task-unsaved-answer.js +3 -3
- package/dist/core/tasks/task-view-source.impl.js +3 -3
- package/dist/core/tasks/task-view-source.js +3 -3
- package/dist/core/tools/read-url.code.js +2 -2
- package/dist/core/tools/read-url.impl.js +3 -3
- package/dist/core/tools/read-url.js +3 -3
- package/dist/core/worktree-snapshot/blob-store.js +2 -2
- package/dist/core/worktree-snapshot/errors.code.js +3 -3
- package/dist/core/worktree-snapshot/errors.impl.js +3 -3
- package/dist/core/worktree-snapshot/errors.js +3 -3
- package/dist/core/worktree-snapshot/session-index-reset.impl.js +3 -3
- package/dist/core/worktree-snapshot/session-index-reset.js +3 -3
- package/dist/extensions/codemode/execute.code.js +1 -1
- package/dist/extensions/codemode/execute.impl.js +3 -3
- package/dist/extensions/codemode/execute.js +3 -3
- package/dist/extensions/codemode/renderer.code.js +2 -2
- package/dist/extensions/codemode/renderer.impl.js +3 -3
- package/dist/extensions/codemode/renderer.js +3 -3
- package/dist/extensions/mcp/cli.code.js +2 -2
- package/dist/extensions/mcp/cli.impl.js +3 -3
- package/dist/extensions/mcp/cli.js +3 -3
- package/dist/extensions/mcp/cli.lazy.code.js +2 -2
- package/dist/extensions/mcp/cli.lazy.impl.js +3 -3
- package/dist/extensions/mcp/cli.lazy.js +3 -3
- package/dist/extensions/mcp/runtime.code.js +1 -1
- package/dist/extensions/mcp/runtime.impl.js +3 -3
- package/dist/extensions/mcp/runtime.js +3 -3
- package/dist/index-extensions.d.ts +1 -1
- package/dist/index.d.ts +8 -1
- package/dist/index.js +7 -7
- package/dist/main-first-time-setup.code.js +2 -2
- package/dist/main-first-time-setup.impl.js +3 -3
- package/dist/main-first-time-setup.js +3 -3
- package/dist/modes/interactive/components/settings-selector-types.d.ts +1 -0
- package/dist/modes/interactive/components/settings-selector-types.js.map +1 -1
- package/dist/modes/interactive/components/stored-tree-view.code.js +2 -2
- package/dist/modes/interactive/components/stored-tree-view.impl.js +3 -3
- package/dist/modes/interactive/components/stored-tree-view.js +3 -3
- package/dist/modes/interactive/components/user-message-selector-archive.impl.js +3 -3
- package/dist/modes/interactive/components/user-message-selector-archive.js +3 -3
- package/dist/modes/interactive/theme/color-utils.d.ts +5 -5
- package/dist/modes/interactive/theme/theme-loading.d.ts +1 -0
- package/dist/modes/interactive-engine/engine-prewarm.js +1 -1
- package/dist/modes/interactive-engine/remote-model-catalog.d.ts +1 -0
- package/dist/modes/print-mode.js +1 -1
- package/dist/modes/rpc/rpc-client-api.d.ts +6 -0
- package/dist/modes/rpc/rpc-types.d.ts +29 -2
- package/dist/package-manager-cli.code.js +5 -5
- package/dist/package-manager-cli.impl.js +3 -3
- package/dist/package-manager-cli.js +3 -3
- package/dist/rpc-entry.js +1 -1
- package/dist/startup-files.json +1 -1
- package/dist/startup-stages/5.js +1 -1
- package/dist/startup-stages/7.js +1 -1
- package/dist/startup-stages/8.js +1 -2
- package/dist/startup-stages/9.js +2 -1
- package/dist/utils/native-module.d.ts +44 -0
- package/dist/utils/startup-database-spare.code.js +3 -3
- package/dist/utils/startup-database-spare.impl.js +3 -3
- package/dist/utils/startup-database-spare.js +3 -3
- package/dist/utils/tools-manager.code.js +1 -1
- package/dist/utils/tools-manager.impl.js +3 -3
- package/dist/utils/tools-manager.js +3 -3
- package/docs/background-tasks.md +235 -243
- package/docs/build.md +12 -11
- package/docs/codemode.md +60 -51
- package/docs/compaction/reference.md +61 -24
- package/docs/compaction.md +117 -65
- package/docs/computer-use.md +179 -146
- package/docs/containerization.md +79 -33
- package/docs/custom-provider/api-reference.md +148 -11
- package/docs/custom-provider/oauth.md +44 -27
- package/docs/custom-provider/override.md +14 -7
- package/docs/custom-provider/registration.md +75 -65
- package/docs/custom-provider/streaming.md +42 -19
- package/docs/custom-provider.md +25 -61
- package/docs/development.md +47 -43
- package/docs/docs.json +33 -33
- package/docs/environment-variables.md +83 -57
- package/docs/extensions/api-reference.md +323 -734
- package/docs/extensions/authoring.md +186 -269
- package/docs/extensions/events.md +308 -375
- package/docs/extensions/examples.md +122 -74
- package/docs/extensions/ui.md +217 -197
- package/docs/extensions.md +152 -259
- package/docs/getting-started/authentication.md +27 -14
- package/docs/getting-started/first-session.md +25 -26
- package/docs/getting-started/installation.md +62 -84
- package/docs/getting-started/project-instructions.md +39 -14
- package/docs/guides/configuration.md +42 -20
- package/docs/guides/intercom.md +17 -13
- package/docs/guides/non-interactive.md +29 -16
- package/docs/guides/orchestration.md +16 -10
- package/docs/guides/resume-on-any-machine.md +54 -49
- package/docs/guides/subagents.md +22 -14
- package/docs/guides/team-setup.md +37 -26
- package/docs/guides.md +22 -21
- package/docs/herdr.md +21 -16
- package/docs/index.md +16 -17
- package/docs/intercom/operations.md +68 -66
- package/docs/intercom/reference.md +196 -191
- package/docs/intercom.md +103 -92
- package/docs/json.md +71 -71
- package/docs/keybindings.md +63 -50
- package/docs/libraries/agent-core.md +49 -8
- package/docs/libraries/ai.md +21 -12
- package/docs/libraries/codemode.md +28 -6
- package/docs/libraries/schema.md +7 -7
- package/docs/libraries/telemetry.md +7 -7
- package/docs/libraries/tui.md +74 -94
- package/docs/libraries.md +5 -5
- package/docs/llama-cpp.md +38 -33
- package/docs/mcp-servers.md +96 -90
- package/docs/models/reference.md +46 -33
- package/docs/models-configuration.md +12 -6
- package/docs/models.md +93 -88
- package/docs/orchestration/migrating-workflows.md +21 -19
- package/docs/orchestration/patterns.md +35 -20
- package/docs/orchestration.md +22 -21
- package/docs/packages/authoring.md +28 -19
- package/docs/packages/reference.md +75 -16
- package/docs/packages.md +31 -33
- package/docs/programmatic.md +22 -21
- package/docs/prompt-templates.md +63 -41
- package/docs/providers/reference.md +35 -19
- package/docs/providers.md +61 -71
- package/docs/quickstart.md +32 -46
- package/docs/reference/cli.md +249 -252
- package/docs/reference.md +23 -20
- package/docs/rpc/examples.md +74 -17
- package/docs/rpc/extension-ui.md +79 -62
- package/docs/rpc/protocol.md +816 -358
- package/docs/rpc.md +75 -151
- package/docs/sdk/reference.md +175 -45
- package/docs/sdk/structured-decisions.md +92 -62
- package/docs/sdk/web-server.md +79 -46
- package/docs/sdk.md +237 -195
- package/docs/security.md +106 -43
- package/docs/session-format.md +96 -59
- package/docs/sessions.md +149 -113
- package/docs/settings.md +289 -204
- package/docs/shell-aliases.md +15 -6
- package/docs/skills/authoring.md +17 -9
- package/docs/skills/reference.md +23 -21
- package/docs/skills.md +104 -97
- package/docs/storage.md +140 -242
- package/docs/subagents/authoring.md +147 -16
- package/docs/subagents/reference.md +100 -30
- package/docs/subagents.md +220 -252
- package/docs/terminal-setup.md +97 -69
- package/docs/termux.md +51 -85
- package/docs/themes/reference.md +51 -37
- package/docs/themes.md +49 -54
- package/docs/tmux.md +38 -21
- package/docs/tools.md +198 -147
- package/docs/tui/reference.md +64 -32
- package/docs/tui.md +38 -66
- package/docs/usage.md +76 -78
- package/docs/verification.md +25 -25
- package/docs/web-access.md +72 -55
- package/docs/windows.md +53 -58
- package/docs/worktree-snapshots.md +62 -65
- package/package.json +8 -8
- package/schemas/models.schema.json +51 -0
- package/dist/_shared/sdk-OSBEPR3Q.js.map +0 -1
- package/dist/_shared/startup-0-0-TYUFUOJZ.js.map +0 -1
- package/dist/_shared/startup-0-1-W2G2UY7R.js.map +0 -1
- package/dist/_shared/startup-0-2-UXBUEOXW.js.map +0 -1
- package/dist/_shared/startup-0-4-HN5EB4K7.js.map +0 -1
|
@@ -3,10 +3,10 @@ import { existsSync, readFileSync } from "node:fs";
|
|
|
3
3
|
import { join, resolve } from "node:path";
|
|
4
4
|
import { pathToFileURL } from "node:url";
|
|
5
5
|
import { APP_NAME } from "./p0-cli-BB45ZQY6.js";
|
|
6
|
-
import { getBuiltinPackageLocations, openAdapterSelectionDatabase } from "./startup-0-0-
|
|
6
|
+
import { getBuiltinPackageLocations, openAdapterSelectionDatabase } from "./startup-0-0-4VG2G44V.js";
|
|
7
7
|
import { SettingsManager, adoptInlineSnapshotBlobs, collectStorageStatus, describeStorageError as describeStorageError$1, describeStorageSelection, effectiveSharedSelection, inlineSnapshotBlobs, joinSharedDatabase, projectTrust, resolveSessionStore, selectSessionStorageWithSettings, sessionSnapshotBlobs } from "./startup-8-1-4KANEHRA.js";
|
|
8
8
|
import { mkdir } from "node:fs/promises";
|
|
9
|
-
import { SESSIONS_TRANSFER_DIRECTORY, StorageImportIncompleteError, StorageTransferError, assertSessionBlobStore, inlineToolOutput, isStorageImportIncompleteError, isStorageTransferError, readTransferDirectory, storeSessionBlobs, takeInlineToolOutput, transferFile, writeLinesAtomically } from "./startup-0-1-
|
|
9
|
+
import { SESSIONS_TRANSFER_DIRECTORY, StorageImportIncompleteError, StorageTransferError, assertSessionBlobStore, inlineToolOutput, isStorageImportIncompleteError, isStorageTransferError, readTransferDirectory, storeSessionBlobs, takeInlineToolOutput, transferFile, writeLinesAtomically } from "./startup-0-1-XTIL65D4.js";
|
|
10
10
|
import { SessionConflictError, SessionExistsError } from "../core/storage/session/errors.js";
|
|
11
11
|
import { JsonlSessionStore, isCurrentSessionHeader } from "./startup-8-0-34CBHPZH.js";
|
|
12
12
|
import "./settings-startup-4QCVCI53.js";
|
|
@@ -1012,7 +1012,7 @@ function __atomicOnDemandFailed(error, feature) {
|
|
|
1012
1012
|
return (async () => {
|
|
1013
1013
|
const root = new URL("../", import.meta.url);
|
|
1014
1014
|
const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
|
|
1015
|
-
const key = `${root.href}#0.10.
|
|
1015
|
+
const key = `${root.href}#0.10.10-alpha.1`;
|
|
1016
1016
|
let release = releases.get(key);
|
|
1017
1017
|
if (release === undefined) {
|
|
1018
1018
|
const current = (async () => {
|
|
@@ -1040,7 +1040,7 @@ function __atomicOnDemandFailed(error, feature) {
|
|
|
1040
1040
|
} catch {
|
|
1041
1041
|
// No installation to read, as in a bundle of the package: the release the process runs decides.
|
|
1042
1042
|
}
|
|
1043
|
-
const updatedTo = typeof installed === "string" && installed !== "0.10.
|
|
1043
|
+
const updatedTo = typeof installed === "string" && installed !== "0.10.10-alpha.1" ? installed : running !== undefined && running.version !== "0.10.10-alpha.1" ? "0.10.10-alpha.1" : undefined;
|
|
1044
1044
|
if (updatedTo === undefined) throw error;
|
|
1045
1045
|
const application = typeof running?.name === "string" ? running.name : "atomic";
|
|
1046
1046
|
const restart = new Error(`${application} was updated to ${updatedTo} while this session was running; restart it to keep using ${feature}.`, {
|
|
@@ -31,7 +31,7 @@ function __atomicOnDemandFailed(error, feature) {
|
|
|
31
31
|
return (async () => {
|
|
32
32
|
const root = new URL("../", import.meta.url);
|
|
33
33
|
const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
|
|
34
|
-
const key = `${root.href}#0.10.
|
|
34
|
+
const key = `${root.href}#0.10.10-alpha.1`;
|
|
35
35
|
let release = releases.get(key);
|
|
36
36
|
if (release === undefined) {
|
|
37
37
|
const current = (async () => {
|
|
@@ -59,7 +59,7 @@ function __atomicOnDemandFailed(error, feature) {
|
|
|
59
59
|
} catch {
|
|
60
60
|
// No installation to read, as in a bundle of the package: the release the process runs decides.
|
|
61
61
|
}
|
|
62
|
-
const updatedTo = typeof installed === "string" && installed !== "0.10.
|
|
62
|
+
const updatedTo = typeof installed === "string" && installed !== "0.10.10-alpha.1" ? installed : running !== undefined && running.version !== "0.10.10-alpha.1" ? "0.10.10-alpha.1" : undefined;
|
|
63
63
|
if (updatedTo === undefined) throw error;
|
|
64
64
|
const application = typeof running?.name === "string" ? running.name : "atomic";
|
|
65
65
|
const restart = new Error(`${application} was updated to ${updatedTo} while this session was running; restart it to keep using ${feature}.`, {
|
|
@@ -88,7 +88,7 @@ function __atomicOnDemandFailed(error, feature) {
|
|
|
88
88
|
return (async () => {
|
|
89
89
|
const root = new URL("../", import.meta.url);
|
|
90
90
|
const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
|
|
91
|
-
const key = `${root.href}#0.10.
|
|
91
|
+
const key = `${root.href}#0.10.10-alpha.1`;
|
|
92
92
|
let release = releases.get(key);
|
|
93
93
|
if (release === undefined) {
|
|
94
94
|
const current = (async () => {
|
|
@@ -116,7 +116,7 @@ function __atomicOnDemandFailed(error, feature) {
|
|
|
116
116
|
} catch {
|
|
117
117
|
// No installation to read, as in a bundle of the package: the release the process runs decides.
|
|
118
118
|
}
|
|
119
|
-
const updatedTo = typeof installed === "string" && installed !== "0.10.
|
|
119
|
+
const updatedTo = typeof installed === "string" && installed !== "0.10.10-alpha.1" ? installed : running !== undefined && running.version !== "0.10.10-alpha.1" ? "0.10.10-alpha.1" : undefined;
|
|
120
120
|
if (updatedTo === undefined) throw error;
|
|
121
121
|
const application = typeof running?.name === "string" ? running.name : "atomic";
|
|
122
122
|
const restart = new Error(`${application} was updated to ${updatedTo} while this session was running; restart it to keep using ${feature}.`, {
|
|
@@ -4,6 +4,12 @@ All notable changes to Atomic's Intercom extension, `@bastani/intercom`, are doc
|
|
|
4
4
|
|
|
5
5
|
## [Unreleased]
|
|
6
6
|
|
|
7
|
+
## [0.10.10-alpha.1] - 2026-11-24
|
|
8
|
+
|
|
9
|
+
### Fixed
|
|
10
|
+
|
|
11
|
+
- Targeted `intercom({ action: "leave", group })` on a session's last membership now falls back to the session's resolved registration group (such as `project:<owner>/<repo>` under multi-node routing) instead of silently moving the session into `"default"` ([#6552](https://github.com/bastani-inc/atomic/pull/6552)).
|
|
12
|
+
|
|
7
13
|
## [0.10.6] - 2026-11-23
|
|
8
14
|
|
|
9
15
|
### Changed
|
|
@@ -8,15 +8,17 @@ See the [Intercom guide](https://docs.bastani.ai/intercom), [Intercom operations
|
|
|
8
8
|
|
|
9
9
|
When you run multiple Atomic sessions at the same time, such as one researching and another implementing, Intercom lets you coordinate them without copying text between terminals:
|
|
10
10
|
|
|
11
|
-
- **User-driven orchestration
|
|
12
|
-
- **Agent collaboration
|
|
13
|
-
- **Subagent escalation
|
|
11
|
+
- **User-driven orchestration:** Press `Alt+M` or run `/intercom` to pick a session and send context or instructions.
|
|
12
|
+
- **Agent collaboration:** Agents can list live peers, send notifications, ask questions, and exchange file or code attachments.
|
|
13
|
+
- **Subagent escalation:** Delegated subagents launched with supervisor coordination automatically receive a `contact_supervisor` tool scoped to their parent session. Regular sessions see only the `intercom` tool.
|
|
14
14
|
|
|
15
15
|
## Setup
|
|
16
16
|
|
|
17
17
|
Atomic bundles `@bastani/intercom` with `@bastani/atomic`. No separate installation is required.
|
|
18
18
|
|
|
19
|
-
At startup, the extension registers the `intercom` tool, `/intercom` command, `Alt+M` shortcut, and bundled `intercom` skill (`/skill:intercom`). An interactive session connects to the local broker in the background
|
|
19
|
+
At startup, the extension registers the `intercom` tool, `/intercom` command, `Alt+M` shortcut, and bundled `intercom` skill (`/skill:intercom`). An interactive session connects to the local broker in the background 3 seconds after startup so other sessions in its group can list and message it right away. Print (`-p`), JSON, RPC, and SDK sessions connect on first use, or when they launch a subagent with Intercom. Interactive sessions also wait for first use when `intercom` is excluded from the session's tools, or when startup join is disabled (`joinAtStartup: false` in config, or `ATOMIC_INTERCOM_JOIN_AT_STARTUP=0` or `false`; legacy alias `PI_INTERCOM_JOIN_AT_STARTUP`). Setting `ATOMIC_INTERCOM_JOIN_AT_STARTUP=1` or `true` forces startup join even when config sets `joinAtStartup` to `false`.
|
|
20
|
+
|
|
21
|
+
A subagent launched with Intercom connects as soon as its session starts so sessions in its group can list and message it immediately. Its group matches the launching session's group unless the launch specifies `group`.
|
|
20
22
|
|
|
21
23
|
You can add this snippet to your project's `AGENTS.md` to guide when agents should coordinate across sessions:
|
|
22
24
|
|
|
@@ -30,7 +32,7 @@ Principle: use `send` for notifications and `ask` when you need an answer. `ask`
|
|
|
30
32
|
</intercom>
|
|
31
33
|
```
|
|
32
34
|
|
|
33
|
-
The session list, `Alt+M` picker, and group counts include connected agent sessions only.
|
|
35
|
+
The session list, `Alt+M` picker, and group counts include connected agent sessions only. An agent executing a tool or waiting for user input stays visible and messageable.
|
|
34
36
|
|
|
35
37
|
Unnamed sessions keep a runtime alias such as `subagent-chat-1a2b3c4d-1111-4222-8333-123456789abc` for name lookup. Session listings omit that generated alias and lead with the copyable full session ID while keeping user-chosen names as metadata.
|
|
36
38
|
|
|
@@ -58,7 +60,7 @@ intercom({ action: "join", group: "api-review" })
|
|
|
58
60
|
// Discover all active groups and see which ones you belong to
|
|
59
61
|
intercom({ action: "groups" })
|
|
60
62
|
|
|
61
|
-
// Leave one membership, or omit group to reset to your
|
|
63
|
+
// Leave one membership, or omit group to reset to your resolved home group
|
|
62
64
|
intercom({ action: "leave", group: "api-review" })
|
|
63
65
|
|
|
64
66
|
// Send a message to a named session
|
|
@@ -84,15 +86,17 @@ intercom({ action: "status" })
|
|
|
84
86
|
|
|
85
87
|
// Send with attachments (file, snippet, or context)
|
|
86
88
|
intercom({
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
89
|
+
action: "send",
|
|
90
|
+
to: "worker",
|
|
91
|
+
message: "Here is the fix:",
|
|
92
|
+
attachments: [
|
|
93
|
+
{
|
|
94
|
+
type: "snippet",
|
|
95
|
+
name: "auth.ts",
|
|
96
|
+
language: "typescript",
|
|
97
|
+
content: "function validate(user: User) { ... }",
|
|
98
|
+
},
|
|
99
|
+
],
|
|
96
100
|
})
|
|
97
101
|
```
|
|
98
102
|
|
|
@@ -101,7 +105,7 @@ intercom({
|
|
|
101
105
|
Incoming messages appear inline in chat with the sender's details and a reply hint:
|
|
102
106
|
|
|
103
107
|
```text
|
|
104
|
-
|
|
108
|
+
**📨 From research** (~/projects/api)
|
|
105
109
|
|
|
106
110
|
To reply, use the intercom tool: intercom({ action: "reply", message: "..." })
|
|
107
111
|
|
|
@@ -109,7 +113,7 @@ Found the issue. UserService.validate() does not check for null input.
|
|
|
109
113
|
See auth.ts:142-156.
|
|
110
114
|
```
|
|
111
115
|
|
|
112
|
-
The reply hint is enabled by default and points to `intercom({ action: "reply", ... })
|
|
116
|
+
The reply hint is enabled by default and points to `intercom({ action: "reply", ... })` so recipients do not have to reconstruct raw sender or message IDs. Idle recipients start a new turn immediately. How a busy recipient handles an incoming message depends on `delivery` (default `"steer"`, which arrives after current tool calls finish without cancelling work). Attachment contents are included in the agent-visible body, and messages are saved in Atomic session history.
|
|
113
117
|
|
|
114
118
|
Recipients save each message to their session before the sender receives `delivered`. If a recipient closes or crashes before showing a saved message, reopening that session recovers the message in arrival order.
|
|
115
119
|
|
|
@@ -123,7 +127,7 @@ For `send` and `ask`, the `delivery` parameter controls how a busy recipient han
|
|
|
123
127
|
|
|
124
128
|
A single-target `send` or `ask` to a subagent that completed or failed queues the message and has its launching session resume it. A message to a paused or quit subagent waits without expiring until its launching session continues it. Queued messages survive broker restarts in `ended-child-queue.sqlite`, or in the shared database when multi-node routing is active. Permanently cancelled children reject new messages.
|
|
125
129
|
|
|
126
|
-
For delegated children, queued messages and
|
|
130
|
+
For delegated children, queued messages and completion notices stay ordered per child, and each child's completion notice is delivered once.
|
|
127
131
|
|
|
128
132
|
## Planner-worker coordination
|
|
129
133
|
|
|
@@ -139,20 +143,20 @@ Confirm both sessions appear in `intercom({ action: "list" })`, then coordinate:
|
|
|
139
143
|
```typescript
|
|
140
144
|
// Planner delegates with send
|
|
141
145
|
intercom({
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
146
|
+
action: "send",
|
|
147
|
+
to: "worker",
|
|
148
|
+
message: "Task-3: Add retry logic to src/api/client.ts and src/api/types.ts. Ask if anything is unclear.",
|
|
145
149
|
})
|
|
146
150
|
|
|
147
151
|
// Worker asks for clarification and keeps working if the answer is not immediate
|
|
148
152
|
intercom({
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
153
|
+
action: "ask",
|
|
154
|
+
to: "planner",
|
|
155
|
+
message: "Should retry apply to all endpoints or only idempotent ones? What max retry count and backoff should I use?",
|
|
152
156
|
})
|
|
153
157
|
```
|
|
154
158
|
|
|
155
|
-
If the planner replies within the wait budget, the reply returns inline as the tool result. Otherwise the ask stays pending with no expiry and the answer arrives later as a message starting `"Reply to your ask <id> from planner"`.
|
|
159
|
+
If the planner replies within the wait budget, the reply returns inline as the tool result. Otherwise the ask stays pending with no expiry, and the answer arrives later as a message starting `"Reply to your ask <id> from planner"`.
|
|
156
160
|
|
|
157
161
|
To coordinate two chat sessions privately without changing startup settings, have both call `intercom({ action: "join", group: "api-review" })`. Joining adds a membership without changing the session ID or removing existing memberships. Joined memberships survive broker reconnects and Atomic restarts; groups you leave are not rejoined. Sending to a session that is live only in another group fails with `<name> is live in group <group>; join it to send`.
|
|
158
162
|
|
|
@@ -177,44 +181,45 @@ To coordinate two chat sessions privately without changing startup settings, hav
|
|
|
177
181
|
|
|
178
182
|
## Subagent escalation with `contact_supervisor`
|
|
179
183
|
|
|
180
|
-
When
|
|
184
|
+
When a subagent is launched with supervisor coordination, it receives the `contact_supervisor` tool alongside `intercom`. Regular sessions never see `contact_supervisor`.
|
|
181
185
|
|
|
182
|
-
|
|
186
|
+
In interactive and standard sessions, blocking `contact_supervisor` requests wait inside the requesting child and continue that same child once the supervisor replies. Active and queued siblings keep running with their original identities and worktrees. In custom SDK sessions without background task support, a blocking request ends the child with a `[TASK_CONTEXT]` handoff.
|
|
183
187
|
|
|
184
188
|
| Reason | Behavior | Use when |
|
|
185
189
|
| --- | --- | --- |
|
|
186
|
-
| `need_decision` | Waits for a correlated reply in the same child (or returns a `[TASK_CONTEXT]` handoff
|
|
187
|
-
| `interview_request` | Waits for structured JSON answers in the same child (or returns a `[TASK_CONTEXT]` handoff
|
|
190
|
+
| `need_decision` | Requires `message`. Waits for a correlated reply in the same child (or returns a `[TASK_CONTEXT]` handoff in custom SDK sessions without background task support). | The child is blocked or faces an unapproved product, API, or scope decision. |
|
|
191
|
+
| `interview_request` | Waits for structured JSON answers in the same child (or returns a `[TASK_CONTEXT]` handoff in custom SDK sessions without background task support). | The child needs multiple machine-readable answers in one exchange. |
|
|
188
192
|
| `progress_update` | Sends a non-blocking update and returns at delivery. | A discovery changes the plan or merits an explicit update. |
|
|
189
193
|
|
|
190
194
|
Do not use `contact_supervisor` for routine completion handoffs. Return the child's normal final result instead.
|
|
191
195
|
|
|
192
|
-
Cross-group supervisor delivery
|
|
196
|
+
Cross-group supervisor delivery is restricted strictly to the parent-child pair. Ordinary `send` calls stay group-isolated, and replies cross back only when `replyTo` matches a recorded supervisor message in the reverse direction.
|
|
193
197
|
|
|
194
198
|
```typescript
|
|
195
199
|
// Blocked subagent asks for a decision
|
|
196
200
|
contact_supervisor({
|
|
197
|
-
|
|
198
|
-
|
|
201
|
+
reason: "need_decision",
|
|
202
|
+
message:
|
|
203
|
+
"The auth service returns 403 instead of 401 for expired tokens. Should I treat 403 as a re-auth trigger or a hard failure?",
|
|
199
204
|
})
|
|
200
205
|
|
|
201
206
|
// Structured supervisor interview
|
|
202
207
|
contact_supervisor({
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
208
|
+
reason: "interview_request",
|
|
209
|
+
message: "Please answer these questions before I continue the migration.",
|
|
210
|
+
interview: {
|
|
211
|
+
title: "API migration choices",
|
|
212
|
+
questions: [
|
|
213
|
+
{ id: "api", type: "single", question: "Which API should I target?", options: ["Stable API", "Experimental API"] },
|
|
214
|
+
{ id: "constraints", type: "text", question: "What constraints should I preserve?" },
|
|
215
|
+
],
|
|
216
|
+
},
|
|
212
217
|
})
|
|
213
218
|
|
|
214
219
|
// Non-blocking progress update
|
|
215
220
|
contact_supervisor({
|
|
216
|
-
|
|
217
|
-
|
|
221
|
+
reason: "progress_update",
|
|
222
|
+
message: "The bug is in the retry wrapper rather than the API client.",
|
|
218
223
|
})
|
|
219
224
|
```
|
|
220
225
|
|
|
@@ -223,12 +228,13 @@ contact_supervisor({
|
|
|
223
228
|
The supervisor sees the child identity, run metadata, and question:
|
|
224
229
|
|
|
225
230
|
```text
|
|
226
|
-
|
|
231
|
+
**📨 From subagent-worker-78f659a3-1**
|
|
227
232
|
|
|
228
233
|
Subagent needs a supervisor decision.
|
|
229
234
|
Run: 78f659a3
|
|
230
235
|
Agent: worker
|
|
231
236
|
Child index: 0
|
|
237
|
+
Child intercom target: subagent-worker-78f659a3-1
|
|
232
238
|
|
|
233
239
|
Which API should I use?
|
|
234
240
|
```
|
|
@@ -265,12 +271,12 @@ When the reply matches valid question IDs and options, the child tool result inc
|
|
|
265
271
|
|
|
266
272
|
### `contact_supervisor`
|
|
267
273
|
|
|
268
|
-
Registered only in subagent sessions
|
|
274
|
+
Registered only in subagent sessions launched with supervisor coordination.
|
|
269
275
|
|
|
270
276
|
| Parameter | Type | Description |
|
|
271
277
|
| --- | --- | --- |
|
|
272
278
|
| `reason` | string | `"need_decision"`, `"interview_request"`, or `"progress_update"`. |
|
|
273
|
-
| `message` | string | Decision request, optional interview note, or progress update. |
|
|
279
|
+
| `message` | string | Decision request (required for `need_decision`), optional interview note, or progress update. |
|
|
274
280
|
| `interview` | object | Required for `interview_request`: `{ title?, description?, questions: [...] }`. |
|
|
275
281
|
|
|
276
282
|
### Actions
|
|
@@ -278,7 +284,7 @@ Registered only in subagent sessions admitted with supervisor coordination.
|
|
|
278
284
|
- **`list`** returns the current session and every active session sharing at least one membership. Pass `group` for a read-only view of one group.
|
|
279
285
|
- **`groups`** lists every group represented by a connected session with connected counts and membership markers.
|
|
280
286
|
- **`join`** adds a trimmed named membership and creates that group if empty. `default` is shared; `true` and `auto` are reserved for subagent auto-groups.
|
|
281
|
-
- **`leave`** removes the specified `group`, or resets memberships to
|
|
287
|
+
- **`leave`** removes the specified `group`, or resets memberships to your resolved home group when `group` is omitted. Leaving your last remaining group also returns you to your resolved home group (such as `project:<owner>/<repo>` under multi-node routing, or `default` otherwise).
|
|
282
288
|
- **`send`** delivers a message to one target or every live match of a pattern within your groups. A session-name glob matching multiple sessions requires `broadcast: true`; without it, nothing is sent and the error lists all matches.
|
|
283
289
|
- **`ask`** sends a question to one exact target, waits according to `wait`, and keeps the ask open until answered or cancelled. Up to `maxPendingAsks` (default 6) calls may wait concurrently; further asks still deliver and receive replies as messages.
|
|
284
290
|
- **`reply`** answers the active incoming message or single pending inbound ask, or an explicit `to` / `replyTo` thread.
|
|
@@ -286,11 +292,9 @@ Registered only in subagent sessions admitted with supervisor coordination.
|
|
|
286
292
|
- **`cancel`** cancels one of your outbound asks by `askId` (any later reply appears once, marked late), or closes an inbound ask sent to you by `replyTo` without notifying its sender.
|
|
287
293
|
- **`status`** reports connection status, session ID, memberships, visible session count, and the `Multi-node routing:` state (including live peer brokers in shared storage).
|
|
288
294
|
|
|
289
|
-
Target lookup accepts an exact full Intercom session ID, an exact case-insensitive session name, a unique 8-hex UUID prefix, or a connected session's Atomic session ID when unambiguous.
|
|
290
|
-
|
|
291
|
-
A session outside your groups whose message reached you (such as through a host reach policy or supervisor exchange) can be answered directly without joining a group, up to 3 messages within 30 minutes of its latest message. Pattern sends never use this return path.
|
|
295
|
+
Target lookup accepts an exact full Intercom session ID, an exact case-insensitive session name, a unique 8-hex UUID prefix, or a connected session's Atomic session ID when unambiguous.
|
|
292
296
|
|
|
293
|
-
|
|
297
|
+
A session outside your groups whose message reached you (such as through a supervisor exchange) can be answered directly without joining a group, up to 3 messages within 30 minutes of its latest message. Pattern sends never use this return path.
|
|
294
298
|
|
|
295
299
|
Only one blocking `contact_supervisor` request can wait at a time per child. One supervisor wait can coexist with peer asks, while a second concurrent supervisor wait fails with `Already waiting for a supervisor reply`.
|
|
296
300
|
|
|
@@ -317,32 +321,30 @@ Create `~/.atomic/agent/intercom/config.json`. When that file is absent and neit
|
|
|
317
321
|
|
|
318
322
|
```json
|
|
319
323
|
{
|
|
320
|
-
"brokerCommand": "npx",
|
|
321
|
-
"brokerArgs": ["--no-install", "tsx"],
|
|
322
|
-
"brokerStartupTimeoutMs": 30000,
|
|
323
324
|
"confirmSend": false,
|
|
325
|
+
"group": "api-review",
|
|
326
|
+
"joinAtStartup": true,
|
|
324
327
|
"maxPendingAsks": 6,
|
|
325
328
|
"replyHint": true,
|
|
326
|
-
"joinAtStartup": true,
|
|
327
329
|
"status": "researching"
|
|
328
330
|
}
|
|
329
331
|
```
|
|
330
332
|
|
|
331
|
-
The default `npx --no-install tsx` pair is a compatibility sentinel. Intercom recognizes it and spawns the broker with the current Atomic runtime (`process.execPath`) without resolving `npx`, `tsx`, or `bun` on `PATH`. Installed builds run `broker/broker.bundle.mjs`, Node source checkouts run `broker/broker.ts` through Atomic's bundled `jiti` loader, Bun source checkouts run with the active Bun binary, and standalone Atomic binaries re-enter the launcher internally.
|
|
332
|
-
|
|
333
333
|
| Setting | Default | Description |
|
|
334
334
|
| --- | --- | --- |
|
|
335
|
-
| `brokerCommand` | `"npx"` | Broker spawn command. The default sentinel uses the active Atomic runtime internally. |
|
|
336
|
-
| `brokerArgs` | `["--no-install", "tsx"]` | Arguments passed to `brokerCommand` before the broker script path. |
|
|
337
|
-
| `brokerStartupTimeoutMs` | `30000` | Maximum milliseconds a session waits for a newly spawned broker to answer on its socket (minimum `1000`). Raise this if slow source-checkout starts time out. |
|
|
338
335
|
| `confirmSend` | `false` | Prompt for interactive confirmation before non-reply sends. |
|
|
336
|
+
| `group` | none | Optional default home group. `ATOMIC_INTERCOM_GROUP` (or legacy `PI_INTERCOM_GROUP`) overrides it. |
|
|
337
|
+
| `joinAtStartup` | `true` | Connect interactive sessions in the background 3 seconds after startup. `ATOMIC_INTERCOM_JOIN_AT_STARTUP=0` or `false` disables startup join; `1` or `true` forces it on (legacy `PI_INTERCOM_JOIN_AT_STARTUP`). |
|
|
339
338
|
| `maxPendingAsks` | `6` | Maximum concurrent waiting asks per session (minimum `1`). |
|
|
340
339
|
| `replyHint` | `true` | Include the `intercom({ action: "reply", ... })` hint in incoming messages. |
|
|
341
340
|
| `status` | none | Optional status suffix appended after automatic lifecycle states (`idle`, `thinking`, `tool:<name>`). |
|
|
342
|
-
| `
|
|
343
|
-
| `
|
|
341
|
+
| `brokerStartupTimeoutMs` | `30000` | Maximum milliseconds a session waits for a newly spawned broker to answer on its socket (minimum `1000`). Raise this if slow source-checkout starts time out. |
|
|
342
|
+
| `brokerCommand` | `"npx"` | Advanced override for the broker spawn command. By default Atomic spawns the broker with its own runtime without invoking `npx` or `tsx` from `PATH`. |
|
|
343
|
+
| `brokerArgs` | `["--no-install", "tsx"]` | Arguments passed to a custom `brokerCommand` before the broker script path. |
|
|
344
344
|
|
|
345
|
-
Custom broker
|
|
345
|
+
### Custom broker runtime
|
|
346
|
+
|
|
347
|
+
To launch the broker explicitly with a custom runtime such as Bun from `PATH`, override `brokerCommand` and `brokerArgs`:
|
|
346
348
|
|
|
347
349
|
```json
|
|
348
350
|
{
|
|
@@ -377,67 +379,36 @@ graph TB
|
|
|
377
379
|
B2 <-->|Local Socket/Pipe| B3
|
|
378
380
|
```
|
|
379
381
|
|
|
380
|
-
The broker is a standalone process that manages session registration and message routing over length-prefixed JSON frames
|
|
382
|
+
The broker is a standalone process that manages session registration and message routing over length-prefixed JSON frames on a Unix domain socket (macOS and Linux) or named pipe (Windows). When shared storage is configured through `@bastani/atomic-storage-libsql` or `@bastani/atomic-storage-postgres`, brokers also enable multi-node routing so sessions on different machines can list and message each other, and ungrouped sessions default to their repository's `project:<owner>/<repo>` group instead of `default`.
|
|
381
383
|
|
|
382
384
|
### Broker lifecycle and recovery
|
|
383
385
|
|
|
384
|
-
- **Auto-spawn and idle exit
|
|
385
|
-
- **Reconnects
|
|
386
|
-
- **Watchdog
|
|
387
|
-
- **Internal delivery retries
|
|
388
|
-
- **Durable delivery
|
|
389
|
-
- **
|
|
390
|
-
- **Session teardown safety.** Async startup, reconnect, overlay, and relay tasks become no-ops if the session shuts down or reloads before they settle.
|
|
386
|
+
- **Auto-spawn and idle exit:** The broker starts automatically when needed and exits after 5 seconds with no registered sessions. A spawn lock prevents duplicate brokers when multiple sessions connect concurrently.
|
|
387
|
+
- **Reconnects:** Clients reconnect automatically with bounded backoff (1s, 2s, 5s, 10s, then 30s) if the broker restarts or retires.
|
|
388
|
+
- **Watchdog:** A broker-owned watchdog probes its local request path independently and exits after roughly one minute without a valid response so clients spawn a healthy replacement.
|
|
389
|
+
- **Internal delivery retries:** Each `send`, `ask`, or `reply` call retries recoverable disconnects internally up to 3 times (after 1, 2, and 5 seconds) with the same operation identity within an 11-minute deadline. If recovery cannot confirm the outcome, the tool returns an error with `outcome: "unknown"` so callers check with the recipient instead of duplicating automatically.
|
|
390
|
+
- **Durable delivery deduplication:** Accepted operations are recorded for 12 minutes in `delivered-messages.sqlite` as keyed SHA-256 HMAC digests paired with `delivered-messages.key` (never plaintext bodies or attachments). On POSIX, the Intercom directory is `0700` and database and key files are `0600`. Storage is capped at 1,000 client identity slots, 10,000 live records, and 64 MiB; once a cap is reached, new requests return an error instead of evicting existing delivery records.
|
|
391
|
+
- **Session teardown safety:** Async startup, reconnect, overlay, and relay tasks stop safely if the session shuts down or reloads before they finish.
|
|
391
392
|
|
|
392
393
|
### Runtime files
|
|
393
394
|
|
|
394
395
|
Runtime files live in `~/.atomic/agent/intercom/`. Setting `ATOMIC_CODING_AGENT_DIR` (or legacy `PI_CODING_AGENT_DIR` when unset) relocates this directory.
|
|
395
396
|
|
|
396
|
-
- `broker.sock` holds the Unix domain socket on macOS and Linux (Windows uses a named pipe). If the path exceeds the Unix socket
|
|
397
|
-
- `broker.
|
|
398
|
-
- `broker.
|
|
399
|
-
- `
|
|
400
|
-
- `
|
|
401
|
-
- `
|
|
402
|
-
- `broker.log` captures broker stderr, capped internally at 8 KiB by `broker/bounded-stderr-install.ts`.
|
|
403
|
-
- `broker.log.previous` keeps the bounded tail of the previous nonempty broker log.
|
|
404
|
-
- `broker-watchdog.log` records the latest watchdog termination.
|
|
405
|
-
- `delivered-messages.sqlite` and `delivered-messages.key` store durable delivery deduplication digests and their owner-only HMAC key.
|
|
406
|
-
- `away-asks.sqlite` stores open asks and replies held for away sessions, and, with multi-node routing, the sessions a broker moved back to their earlier Intercom ID until they register again (at most about 7 days).
|
|
407
|
-
- `ended-child-queue.sqlite` stores queued messages waiting to resume or reach finished and paused subagents across broker restarts.
|
|
397
|
+
- `broker.sock` holds the Unix domain socket on macOS and Linux (Windows uses a named pipe). If the path exceeds the platform Unix socket limit (107 bytes on Linux, 103 bytes on macOS), the broker creates an owner-only `atomic-intercom-<uid>/<digest>.sock` socket under `$XDG_RUNTIME_DIR` or the system temp directory and records its path in `broker.sock.path`.
|
|
398
|
+
- `broker.pid`, `broker.starting`, `broker.spawn.lock`, and `broker.sock.replace.lock` coordinate broker startup and lock ownership.
|
|
399
|
+
- `broker.log` (capped at 8 KiB), `broker.log.previous`, and `broker-watchdog.log` store diagnostic logs.
|
|
400
|
+
- `delivered-messages.sqlite` and `delivered-messages.key` store delivery deduplication digests and their owner-only HMAC key.
|
|
401
|
+
- `away-asks.sqlite` stores open asks and replies held for away sessions (retained up to about 7 days).
|
|
402
|
+
- `ended-child-queue.sqlite` stores queued messages waiting to reach finished and paused subagents across broker restarts.
|
|
408
403
|
- `config.json` stores user configuration.
|
|
409
404
|
|
|
410
|
-
##
|
|
405
|
+
## Limitations
|
|
411
406
|
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
├── index-heavy.ts # Runtime wiring and session lifecycle
|
|
417
|
-
├── intercom-tool.ts # intercom tool implementation
|
|
418
|
-
├── contact-supervisor-tool.ts # Subagent-only contact_supervisor tool
|
|
419
|
-
├── config.ts # Config loading and validation
|
|
420
|
-
├── types.ts # Protocol and session types
|
|
421
|
-
├── broker/
|
|
422
|
-
│ ├── broker.ts # Broker process entry point
|
|
423
|
-
│ ├── client.ts # IntercomClient socket client
|
|
424
|
-
│ ├── framing.ts # Length-prefixed JSON framing
|
|
425
|
-
│ ├── paths.ts # Platform socket, pipe, and state paths
|
|
426
|
-
│ ├── spawn.ts # Auto-spawn and lock coordination
|
|
427
|
-
│ ├── multinode-router.ts # Cross-machine routing over shared storage
|
|
428
|
-
│ └── watchdog.ts # Broker liveness watchdog
|
|
429
|
-
├── ui/
|
|
430
|
-
│ ├── session-list.ts # Session picker overlay
|
|
431
|
-
│ ├── compose.ts # Message composition overlay
|
|
432
|
-
│ └── inline-message.ts # Inline received message renderer
|
|
433
|
-
└── skills/
|
|
434
|
-
└── intercom/
|
|
435
|
-
└── SKILL.md # Bundled /skill:intercom guide
|
|
436
|
-
```
|
|
407
|
+
- **Local IPC by default:** Without shared storage, Intercom connects sessions on the same machine only. Cross-machine messaging requires configuring a shared storage adapter (`@bastani/atomic-storage-libsql` or `@bastani/atomic-storage-postgres`).
|
|
408
|
+
- **No separate transcript file:** Messages are stored in Atomic session history rather than a dedicated Intercom inbox file.
|
|
409
|
+
- **No attachments UI:** The `intercom` tool supports `file`, `snippet`, and `context` attachments, while the `Alt+M` compose overlay sends plain text only.
|
|
410
|
+
- **Connected sessions only:** `intercom list` shows sessions currently registered with the broker, not disconnected or offline Atomic processes.
|
|
437
411
|
|
|
438
|
-
##
|
|
412
|
+
## License
|
|
439
413
|
|
|
440
|
-
|
|
441
|
-
- **No separate transcript file.** Messages are stored in Atomic session history rather than a dedicated Intercom inbox file.
|
|
442
|
-
- **No attachments UI.** The `intercom` tool supports `file`, `snippet`, and `context` attachments, while the `Alt+M` compose overlay sends plain text only.
|
|
443
|
-
- **Connected sessions only.** `intercom list` shows sessions currently registered with the broker, not disconnected or offline Atomic processes.
|
|
414
|
+
MIT. See [LICENSE](LICENSE).
|
|
@@ -62,10 +62,10 @@ function addGroup(groups, value) {
|
|
|
62
62
|
next.add(validateRuntimeGroup(value));
|
|
63
63
|
return next;
|
|
64
64
|
}
|
|
65
|
-
function removeGroup(groups, value) {
|
|
65
|
+
function removeGroup(groups, value, fallback) {
|
|
66
66
|
const next = normalizeGroups(groups);
|
|
67
67
|
next.delete(normalizeGroup(value));
|
|
68
|
-
return normalizeGroups(
|
|
68
|
+
return next.size > 0 ? next : normalizeGroups(undefined, fallback);
|
|
69
69
|
}
|
|
70
70
|
function hasGroup(groups, value) {
|
|
71
71
|
return normalizeGroups(groups).has(normalizeGroup(value));
|
|
@@ -15869,7 +15869,7 @@ function handleBrokerPresence(socket, clientMessage, currentId, sessions, write,
|
|
|
15869
15869
|
if (typeof clientMessage.group !== "string")
|
|
15870
15870
|
return void fail("Invalid presence group");
|
|
15871
15871
|
const group = validateRuntimeGroup(clientMessage.group);
|
|
15872
|
-
nextGroups = removeGroup(previousGroups, group);
|
|
15872
|
+
nextGroups = removeGroup(previousGroups, group, session.registrationGroup);
|
|
15873
15873
|
if (legacyGroup === group)
|
|
15874
15874
|
legacyGroup = undefined;
|
|
15875
15875
|
}
|
|
@@ -127,7 +127,7 @@ export function handleBrokerPresence(
|
|
|
127
127
|
} else {
|
|
128
128
|
if (typeof clientMessage.group !== "string") return void fail("Invalid presence group");
|
|
129
129
|
const group = validateRuntimeGroup(clientMessage.group);
|
|
130
|
-
nextGroups = removeGroup(previousGroups, group);
|
|
130
|
+
nextGroups = removeGroup(previousGroups, group, session.registrationGroup);
|
|
131
131
|
if (legacyGroup === group) legacyGroup = undefined;
|
|
132
132
|
}
|
|
133
133
|
} else {
|
|
@@ -74,11 +74,15 @@ export function addGroup(groups: GroupMemberships, value: unknown): Set<string>
|
|
|
74
74
|
return next;
|
|
75
75
|
}
|
|
76
76
|
|
|
77
|
-
/** Remove one normalized group while retaining default membership when none remain. */
|
|
78
|
-
export function removeGroup(
|
|
77
|
+
/** Remove one normalized group while retaining the fallback (or default) membership when none remain. */
|
|
78
|
+
export function removeGroup(
|
|
79
|
+
groups: GroupMemberships,
|
|
80
|
+
value?: string | null,
|
|
81
|
+
fallback?: string | null,
|
|
82
|
+
): Set<string> {
|
|
79
83
|
const next = normalizeGroups(groups);
|
|
80
84
|
next.delete(normalizeGroup(value));
|
|
81
|
-
return normalizeGroups(
|
|
85
|
+
return next.size > 0 ? next : normalizeGroups(undefined, fallback);
|
|
82
86
|
}
|
|
83
87
|
|
|
84
88
|
/** Test a normalized group membership. */
|
|
@@ -7,7 +7,7 @@ import * as __atomicHostImport1 from "@bastani/atomic-ai";
|
|
|
7
7
|
if (!(name in namespace)) missing.push(`The requested module '${specifier}' does not provide an export named '${name}'`);
|
|
8
8
|
if (missing.length > 0) {
|
|
9
9
|
const application = typeof __atomicHostImport0.APP_NAME === "string" ? __atomicHostImport0.APP_NAME : "atomic";
|
|
10
|
-
if (__atomicHostImport0.VERSION !== "0.10.
|
|
10
|
+
if (__atomicHostImport0.VERSION !== "0.10.10-alpha.1") missing.unshift(application + " was updated to 0.10.10-alpha.1 while this session was running; restart it to keep using the intercom extension.");
|
|
11
11
|
throw new Error(missing.join("\n"));
|
|
12
12
|
}
|
|
13
13
|
}
|