@bastani/atomic 0.10.9 → 0.10.10-alpha.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +83 -0
- package/README.md +226 -163
- 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} +150 -62
- 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 +87 -116
- 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 +61 -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 +74 -141
- 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 +61 -88
- 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 +238 -243
- package/docs/build.md +21 -15
- package/docs/changelog.mdx +1 -1
- package/docs/codemode.md +68 -51
- package/docs/compaction/reference.md +65 -26
- package/docs/compaction.md +118 -66
- package/docs/computer-use.md +179 -146
- package/docs/containerization.md +87 -33
- package/docs/custom-provider/api-reference.md +152 -13
- package/docs/custom-provider/oauth.md +45 -28
- package/docs/custom-provider/override.md +14 -7
- package/docs/custom-provider/registration.md +77 -67
- package/docs/custom-provider/streaming.md +42 -19
- package/docs/custom-provider.md +26 -62
- package/docs/development.md +81 -42
- package/docs/docs.json +54 -38
- package/docs/environment-variables.md +92 -64
- package/docs/extensions/api-reference.md +326 -735
- 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 +189 -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 +62 -20
- package/docs/guides/intercom.md +20 -12
- package/docs/guides/non-interactive.md +31 -16
- package/docs/guides/orchestration.md +17 -9
- package/docs/guides/resume-on-any-machine.md +63 -52
- package/docs/guides/subagents.md +26 -14
- package/docs/guides/team-setup.md +49 -27
- package/docs/guides.md +30 -23
- package/docs/herdr.md +22 -17
- package/docs/index.md +24 -17
- package/docs/intercom/operations.md +90 -66
- package/docs/intercom/reference.md +219 -192
- package/docs/intercom.md +111 -92
- package/docs/json.md +73 -71
- package/docs/keybindings.md +74 -48
- package/docs/libraries/agent-core.md +52 -9
- package/docs/libraries/ai.md +90 -63
- package/docs/libraries/codemode.md +31 -8
- package/docs/libraries/schema.md +12 -9
- package/docs/libraries/storage-libsql.md +92 -0
- package/docs/libraries/storage-postgres.md +119 -0
- package/docs/libraries/telemetry.md +42 -9
- package/docs/libraries/tui.md +74 -94
- package/docs/libraries.md +25 -8
- package/docs/llama-cpp.md +38 -33
- package/docs/mcp-servers.md +140 -88
- package/docs/models/reference.md +53 -36
- package/docs/models-configuration.md +19 -13
- package/docs/models.md +102 -87
- package/docs/orchestration/migrating-workflows.md +22 -20
- package/docs/orchestration/patterns.md +36 -21
- package/docs/orchestration.md +24 -21
- package/docs/packages/authoring.md +29 -18
- package/docs/packages/reference.md +77 -16
- package/docs/packages.md +34 -34
- package/docs/programmatic.md +28 -21
- package/docs/prompt-templates.md +65 -41
- package/docs/providers/reference.md +36 -20
- package/docs/providers.md +78 -76
- package/docs/quickstart.md +42 -54
- package/docs/reference/cli.md +256 -254
- package/docs/reference.md +30 -23
- package/docs/rpc/examples.md +121 -17
- package/docs/rpc/extension-ui.md +86 -63
- package/docs/rpc/protocol.md +817 -358
- package/docs/rpc.md +78 -152
- package/docs/sdk/reference.md +309 -73
- package/docs/sdk/storage.md +614 -0
- package/docs/sdk/structured-decisions.md +168 -65
- package/docs/sdk/web-server.md +80 -46
- package/docs/sdk.md +168 -215
- package/docs/security.md +117 -44
- package/docs/session-format.md +127 -76
- package/docs/sessions.md +155 -113
- package/docs/settings.md +293 -205
- 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 +148 -97
- package/docs/storage.md +172 -260
- package/docs/subagents/authoring.md +148 -15
- package/docs/subagents/reference.md +105 -29
- package/docs/subagents.md +247 -250
- package/docs/terminal-setup.md +97 -69
- package/docs/termux.md +51 -85
- package/docs/themes/reference.md +51 -37
- package/docs/themes.md +52 -55
- package/docs/tmux.md +38 -21
- package/docs/tools.md +209 -147
- package/docs/tui/reference.md +64 -32
- package/docs/tui.md +38 -66
- package/docs/usage.md +94 -86
- package/docs/verification.md +25 -25
- package/docs/web-access.md +106 -54
- package/docs/windows.md +55 -57
- package/docs/worktree-snapshots.md +82 -74
- package/examples/sdk/11-sessions.ts +4 -4
- package/package.json +8 -8
- package/schemas/models.schema.json +58 -7
- 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
package/docs/web-access.md
CHANGED
|
@@ -1,24 +1,32 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: "Web access"
|
|
3
|
-
|
|
3
|
+
sidebarTitle: "Web access"
|
|
4
|
+
description: "Search the web, fetch webpages, PDFs, GitHub repos, and videos, query public repos with DeepWiki, and configure ~/.atomic/web-search.json."
|
|
4
5
|
---
|
|
5
6
|
|
|
6
|
-
|
|
7
|
+
Atomic bundles four web-access tools: `web_search` for searching the web, `fetch_content` for reading pages and media, `get_search_content` for retrieving full stored results, and `code_search` for querying public GitHub repositories. Both `web_search` and `code_search` work out of the box with no API key setup.
|
|
7
8
|
|
|
8
|
-
|
|
9
|
+
## Quick start
|
|
10
|
+
|
|
11
|
+
- **Zero-config defaults.** Ask Atomic to search the web (`web_search` uses keyless Exa by default), read a URL or PDF (`fetch_content`), or query a public GitHub repository (`code_search` via DeepWiki).
|
|
12
|
+
- **Optional API keys.** Set `EXA_API_KEY`, `PERPLEXITY_API_KEY`, or `GEMINI_API_KEY`, or store camelCase keys in `~/.atomic/web-search.json` to raise limits or pick a specific provider.
|
|
13
|
+
- **Interactive commands.** Run `/websearch <query>` to search directly, `/curator on` to review results in your browser before the agent sees them, or `/search` to inspect stored session results.
|
|
9
14
|
|
|
10
15
|
## Searching with `web_search`
|
|
11
16
|
|
|
12
|
-
Pass `query` for a single
|
|
17
|
+
Pass `query` for a single search, or `queries` (an array of 2 to 4 varied angles) for broader research. If both `query` and `queries` are supplied, `queries` wins and `query` is ignored. Multiple queries run sequentially (with a 60-second timeout per query on Exa and Gemini API).
|
|
18
|
+
|
|
19
|
+
Optional parameters are `numResults` (default `5`, max `20`), `includeContent` (boolean; fetches full page text in the background), `recencyFilter` (`"day"`, `"week"`, `"month"`, or `"year"`), `domainFilter` (array of domains; prefix with `-` to exclude; on Perplexity, entries that are not valid domains are ignored), and `provider` (`"auto"`, `"exa"`, `"perplexity"`, or `"gemini"`).
|
|
13
20
|
|
|
14
|
-
With `provider: "auto"` (the default), Atomic
|
|
21
|
+
With `provider: "auto"` (the default), Atomic tries providers in this order:
|
|
15
22
|
|
|
16
|
-
1. **Exa.**
|
|
17
|
-
2. **Perplexity.** Used when a key is set.
|
|
18
|
-
3. **Gemini API.** Used when a key is set.
|
|
19
|
-
4. **Gemini Web.**
|
|
23
|
+
1. **Exa.** Uses your Exa API key when configured, or falls back to Exa's free keyless MCP endpoint (`mcp.exa.ai`). Atomic tracks monthly Exa usage locally in `~/.atomic/exa-usage.json`, warning at 800 requests and stopping at 1,000 requests per month. When `provider: "exa"` is explicitly selected with an API key, errors fail directly; keyless Exa falls back to Perplexity or Gemini on failure.
|
|
24
|
+
2. **Perplexity.** Used when a key is set. Client-side rate limiting caps requests at 10 per 60 seconds.
|
|
25
|
+
3. **Gemini API.** Used when a key is set (`GEMINI_API_KEY` or `geminiApiKey` in `web-search.json`).
|
|
26
|
+
4. **Gemini Web.** Reads cookies from a signed-in browser. Disabled by default; enable it with `"allowBrowserCookies": true` in `~/.atomic/web-search.json` or `ATOMIC_ALLOW_BROWSER_COOKIES=1` (the environment variable must be the exact string `1`; `true` does not enable it).
|
|
27
|
+
- **Supported platforms and browsers:** On **macOS**, Atomic checks Helium, Chrome, and Arc (in that order). On **Linux**, Atomic checks Chromium and Chrome (in that order). **Windows is not supported.** Edge, Brave, Vivaldi, and Opera are not checked on any OS. The default profile directory is `"Default"` (override with `chromeProfile`).
|
|
20
28
|
|
|
21
|
-
Environment variables
|
|
29
|
+
Environment variables override fields in `~/.atomic/web-search.json`. Note that JSON config keys use camelCase (`geminiApiKey`, not `GEMINI_API_KEY`):
|
|
22
30
|
|
|
23
31
|
| Provider | Environment variable | `web-search.json` field |
|
|
24
32
|
| --- | --- | --- |
|
|
@@ -29,17 +37,18 @@ Environment variables take precedence over keys in `~/.atomic/web-search.json`:
|
|
|
29
37
|
```json
|
|
30
38
|
{
|
|
31
39
|
"exaApiKey": "your-key",
|
|
40
|
+
"geminiApiKey": "your-gemini-key",
|
|
32
41
|
"provider": "auto"
|
|
33
42
|
}
|
|
34
43
|
```
|
|
35
44
|
|
|
36
|
-
When no provider can be reached, the error names
|
|
45
|
+
When no provider can be reached, the error names the relevant environment variables, JSON config fields, and cookie opt-in setting.
|
|
37
46
|
|
|
38
47
|
### The search curator
|
|
39
48
|
|
|
40
|
-
By default, `web_search` returns raw results. Run `/curator on` (or set `"workflow": "summary-review"` in `~/.atomic/web-search.json`) to open an interactive browser
|
|
49
|
+
By default, `web_search` returns raw results. Run `/curator on` or `/curator summary-review` (or set `"workflow": "summary-review"` in `~/.atomic/web-search.json`) to open an interactive browser window where you filter results and approve a summary draft before the agent sees them. Run `/curator off` or `/curator none` to return to raw results, or run `/curator` with no argument to toggle between modes. Switching providers inside the curator saves `provider` and updates active search configuration immediately.
|
|
41
50
|
|
|
42
|
-
The curator requires an interactive session with a browser. Subagents and non-interactive runs skip it and return raw results. If the browser cannot open (for example on a headless
|
|
51
|
+
The curator requires an interactive session with a browser. Subagents and non-interactive runs skip it and return raw results. If the browser cannot open (for example on a headless server), `web_search` falls back to raw results with a note pointing to `/curator off`.
|
|
43
52
|
|
|
44
53
|
## Fetching with `fetch_content`
|
|
45
54
|
|
|
@@ -47,13 +56,13 @@ The curator requires an interactive session with a browser. Subagents and non-in
|
|
|
47
56
|
|
|
48
57
|
### Arguments
|
|
49
58
|
|
|
50
|
-
Always pass the lowercase `urls` field as a nonempty array of strings, even for one URL:
|
|
59
|
+
Always pass the lowercase `urls` field as a nonempty array of strings, even for one URL (do not pass a singular `url` field, which belongs to `get_search_content`):
|
|
51
60
|
|
|
52
61
|
```json
|
|
53
62
|
{"urls": ["https://example.com/article"]}
|
|
54
63
|
```
|
|
55
64
|
|
|
56
|
-
For multiple pages (fetched
|
|
65
|
+
For multiple pages (fetched up to 3 at a time):
|
|
57
66
|
|
|
58
67
|
```json
|
|
59
68
|
{"urls": ["https://example.com/one", "https://example.com/two"]}
|
|
@@ -65,25 +74,35 @@ For video analysis, include your question in `prompt`:
|
|
|
65
74
|
{"urls": ["/path/to/recording.mp4"], "prompt": "What error appears on screen?"}
|
|
66
75
|
```
|
|
67
76
|
|
|
68
|
-
Local videos
|
|
69
|
-
|
|
70
|
-
-
|
|
71
|
-
- `
|
|
72
|
-
- `frames`
|
|
77
|
+
- **Local videos.** Accepts absolute paths (including Windows drive and UNC paths), `./` or `../` relative paths, and `file://` URLs for `.mp4`, `.mov`, `.webm`, `.avi`, `.mpeg`, `.mpg`, `.wmv`, `.flv`, `.3gp`, and `.3gpp` files (escape Windows backslashes in JSON, such as `{"urls": ["C:\\Videos\\recording.mp4"], "frames": 1}`). Analysis requires Gemini API or Gemini Web (with browser cookies enabled); `video.maxSizeMB` (`50` by default) is measured in binary MiB.
|
|
78
|
+
- **YouTube videos.** Tries Gemini Web first, then Gemini API, then Perplexity. `/playlist` URLs are not treated as videos. Setting `"youtube": { "enabled": false }` in `~/.atomic/web-search.json` disables both YouTube analysis and YouTube frame extraction.
|
|
79
|
+
- **`prompt` and `model`.** Apply only to YouTube and local video analysis, not webpage extraction.
|
|
80
|
+
- **Frame extraction (`frames` and `timestamp`).** Extract images from YouTube or local videos only (ignored for webpages and other inputs, including in mixed batches). Omit both for text or transcripts. `frames` accepts `1` to `12`; `timestamp` accepts bare seconds (`"85"`), `MM:SS` (`"1:25"`), `H:MM:SS`, or a `start-end` range (`"1:25-2:00"`):
|
|
81
|
+
- `frames` alone samples evenly across the whole video (requires `ffprobe` for local videos).
|
|
82
|
+
- Single `timestamp` alone extracts 1 frame at that time.
|
|
83
|
+
- Single `timestamp` plus `frames` extracts `N` frames at 5-second intervals starting at `timestamp`.
|
|
84
|
+
- Range `timestamp` alone extracts 6 frames across the range.
|
|
85
|
+
- Range `timestamp` plus `frames` extracts up to `N` frames with a 5-second minimum spacing (short ranges may return fewer frames).
|
|
86
|
+
- Requires `ffmpeg` (and `ffprobe` for whole-video sampling of local files), plus `yt-dlp` for YouTube.
|
|
73
87
|
|
|
74
88
|
```json
|
|
75
89
|
{"urls": ["/path/to/recording.mp4"], "timestamp": "1:25-2:00", "frames": 3}
|
|
76
90
|
```
|
|
77
91
|
|
|
78
|
-
|
|
92
|
+
- **GitHub repositories (`forceClone`).** Clones public repositories shallowly unless the repository exceeds `githubClone.maxRepoSizeMB` or targets a full commit SHA URL, in which case Atomic uses the GitHub API unless `forceClone: true` is passed. Skips binary files and common build or dependency directories (`node_modules`, `vendor`, `dist`, `build`, and similar), caps inline files at 100,000 characters, and caps directory listings at 200 entries. The default clone cache clears automatically when you switch sessions.
|
|
79
93
|
|
|
80
|
-
|
|
94
|
+
### Extraction fallbacks, PDFs, and limits
|
|
95
|
+
|
|
96
|
+
- **Inline output and batches.** Single-URL fetches return up to 30,000 characters inline and store the full text for `get_search_content`. Multi-URL batches return titles and character counts inline only; read the full text for each URL with `get_search_content`.
|
|
97
|
+
- **HTTP limits.** Direct fetches run up to 3 concurrently with a 30-second timeout, up to 20 redirects, a 5 MiB limit for HTML and text, and a 20 MiB limit for PDFs. Binary MIME types (`application/octet-stream`, `image/*`, `audio/*`, `video/*`, and `application/zip`) are rejected.
|
|
98
|
+
- **Public webpage fallbacks.** When a direct fetch of a public URL fails or extracts fewer than 500 characters (excluding private-network URLs and URLs with embedded credentials), `fetch_content` forwards the URL to **Jina Reader (`https://r.jina.ai/`)** first, then **Gemini URL Context API**, then **Gemini Web**.
|
|
99
|
+
- **PDF downloads.** Fetching a PDF URL downloads up to 20 MiB, extracts up to 100 pages, **writes the extracted Markdown file into `~/Downloads`**, and returns the saved file path, page count, and character count.
|
|
81
100
|
|
|
82
101
|
### Troubleshooting
|
|
83
102
|
|
|
84
103
|
If argument validation fails, check that:
|
|
85
104
|
|
|
86
|
-
- The field is `urls
|
|
105
|
+
- The field is `urls` (lowercase), not `URLs` or `url`.
|
|
87
106
|
- Its value is a nonempty array of strings.
|
|
88
107
|
- No unrecognized fields are present.
|
|
89
108
|
|
|
@@ -91,15 +110,17 @@ If every URL in a batch fails, the error lists each URL and its cause; partial e
|
|
|
91
110
|
|
|
92
111
|
## Retrieving full results with `get_search_content`
|
|
93
112
|
|
|
94
|
-
When `web_search` or `fetch_content` truncates output or stores background fetches, it returns a `responseId`. Pass that ID
|
|
113
|
+
When `web_search` or `fetch_content` truncates output or stores background fetches, it returns a `responseId`. Pass that ID plus **at least one selector** (`query` or `queryIndex` for a `web_search` response; `url` or `urlIndex` for a `fetch_content` response). Omitting selectors returns an error listing the available queries or URLs.
|
|
114
|
+
|
|
115
|
+
`query` and `url` take precedence over `queryIndex` and `urlIndex` and require exact, case-sensitive matches.
|
|
95
116
|
|
|
96
117
|
| Parameter | Type | Required | Description |
|
|
97
118
|
| --- | --- | --- | --- |
|
|
98
|
-
| `responseId` | string | Yes | ID returned by a previous `web_search` or `fetch_content` call |
|
|
99
|
-
| `query` | string |
|
|
100
|
-
| `queryIndex` | number |
|
|
101
|
-
| `url` | string |
|
|
102
|
-
| `urlIndex` | number |
|
|
119
|
+
| `responseId` | string | Yes | ID returned by a previous `web_search` or `fetch_content` call. |
|
|
120
|
+
| `query` | string | One of `query` / `queryIndex` (for search) | Exact case-sensitive search query to retrieve from a stored `web_search` response. |
|
|
121
|
+
| `queryIndex` | number | One of `query` / `queryIndex` (for search) | Zero-based query index in a stored `web_search` response. |
|
|
122
|
+
| `url` | string | One of `url` / `urlIndex` (for fetch) | Exact case-sensitive URL to retrieve from a stored `fetch_content` response. |
|
|
123
|
+
| `urlIndex` | number | One of `url` / `urlIndex` (for fetch) | Zero-based URL index in a stored `fetch_content` response. |
|
|
103
124
|
|
|
104
125
|
## `code_search`
|
|
105
126
|
|
|
@@ -107,9 +128,9 @@ When `web_search` or `fetch_content` truncates output or stores background fetch
|
|
|
107
128
|
|
|
108
129
|
| Parameter | Type | Required | Description |
|
|
109
130
|
| --- | --- | --- | --- |
|
|
110
|
-
| `repoName` | string | Yes | Public GitHub repository in `owner/repo` format (not a URL) |
|
|
111
|
-
| `query` | string | Yes | Question sent verbatim to DeepWiki |
|
|
112
|
-
| `maxTokens` | integer | No | Best-effort output limit (`1000` to `50000`, default `5000`, about 4
|
|
131
|
+
| `repoName` | string | Yes | Public GitHub repository in `owner/repo` format (not a URL). |
|
|
132
|
+
| `query` | string | Yes | Question sent verbatim to DeepWiki. |
|
|
133
|
+
| `maxTokens` | integer | No | Best-effort output limit (`1000` to `50000`, default `5000`, about 4 characters per token). |
|
|
113
134
|
|
|
114
135
|
Requests have a 60-second deadline. See [`code_search` in Built-in tools](/tools#code_search) for examples and fallback guidance.
|
|
115
136
|
|
|
@@ -117,38 +138,40 @@ Requests have a 60-second deadline. See [`code_search` in Built-in tools](/tools
|
|
|
117
138
|
|
|
118
139
|
| Command | Action |
|
|
119
140
|
| --- | --- |
|
|
120
|
-
| `/curator [on\|off\|none\|summary-review]` |
|
|
121
|
-
| `/websearch [query1, query2, ...]` | Open the interactive search curator directly without an agent round-trip
|
|
122
|
-
| `/search` | Browse, inspect, or delete stored `web_search` and `fetch_content` results from the current session |
|
|
123
|
-
| `/google-account` |
|
|
141
|
+
| `/curator [on\|off\|none\|summary-review]` | Set the search curator workflow and save it to `~/.atomic/web-search.json`. Omitting the argument toggles between `none` and `summary-review`. |
|
|
142
|
+
| `/websearch [query1, query2, ...]` | Open the interactive search curator directly without an agent round-trip. Arguments split on commas into separate queries. Closing or cancelling sends nothing; timing out submits collected results as a summary-review follow-up. |
|
|
143
|
+
| `/search` | Browse, inspect, or delete stored `web_search` and `fetch_content` results from the current session. |
|
|
144
|
+
| `/google-account` | Print the active Google account used for Gemini Web when browser cookie access is enabled, without starting a model turn. |
|
|
124
145
|
|
|
125
146
|
| Shortcut | Config key | Action |
|
|
126
147
|
| --- | --- | --- |
|
|
127
|
-
| `Ctrl+Shift+S` | `shortcuts.curate` | Open the search curator while a search is running |
|
|
128
|
-
| `Ctrl+Shift+W` | `shortcuts.activity` | Toggle the web search activity widget |
|
|
148
|
+
| `Ctrl+Shift+S` | `shortcuts.curate` | Open the search curator while a search is running. |
|
|
149
|
+
| `Ctrl+Shift+W` | `shortcuts.activity` | Toggle the web search activity widget. |
|
|
129
150
|
|
|
130
151
|
Customize shortcuts in `~/.atomic/web-search.json` under `"shortcuts"`. Shortcut changes take effect after restarting Atomic.
|
|
131
152
|
|
|
132
|
-
##
|
|
153
|
+
## Configure `web-search.json`
|
|
133
154
|
|
|
134
|
-
All fields in `~/.atomic/web-search.json` are optional. If `~/.atomic/web-search.json` does not exist, Atomic falls back to
|
|
155
|
+
All fields in `~/.atomic/web-search.json` are optional. If `~/.atomic/web-search.json` does not exist, Atomic falls back to `~/.pi/web-search.json` from older installations without merging the two files; interactive saves always write `~/.atomic/web-search.json`.
|
|
156
|
+
|
|
157
|
+
**Reloading changes.** `workflow` and `curatorTimeoutSeconds` are re-read on every call, and switching providers inside the curator updates active search settings immediately. Manual file edits to API keys, `provider`, `searchModel`, `allowBrowserCookies`, `chromeProfile`, `githubClone`, `youtube`, and `video` take effect after `/reload` or restarting Atomic. Shortcut changes require restarting Atomic.
|
|
135
158
|
|
|
136
159
|
| Field | Type | Default | Description |
|
|
137
160
|
| --- | --- | --- | --- |
|
|
138
|
-
| `provider` | `"auto" \| "exa" \| "perplexity" \| "gemini"` | `"auto"` | Default `web_search` provider
|
|
139
|
-
| `workflow` | `"none" \| "summary-review"` | `"none"` | `"none"` returns raw results; `"summary-review"` opens the browser curator with a summary draft |
|
|
140
|
-
| `curatorTimeoutSeconds` | number (`1` to `600`) | `20` | Curator wait timeout in seconds |
|
|
141
|
-
| `summaryModel` | string | auto | Default `"provider/model"`
|
|
142
|
-
| `searchModel` | string | `"gemini-3-flash-preview"` | Gemini API model used for Gemini search queries |
|
|
143
|
-
| `shortcuts` | `{ curate?: string, activity?: string }` | `{ "curate": "ctrl+shift+s", "activity": "ctrl+shift+w" }` | Keyboard shortcuts for opening the curator and toggling the activity widget |
|
|
144
|
-
| `exaApiKey` | string | unset | Exa API key (overridden by `EXA_API_KEY`) |
|
|
145
|
-
| `perplexityApiKey` | string | unset | Perplexity API key (overridden by `PERPLEXITY_API_KEY`) |
|
|
146
|
-
| `geminiApiKey` | string | unset | Gemini API key (overridden by `GEMINI_API_KEY`) |
|
|
147
|
-
| `allowBrowserCookies` | boolean | `false` | Allow Gemini Web to read cookies from
|
|
148
|
-
| `chromeProfile` | string |
|
|
149
|
-
| `githubClone` | object | see below | GitHub clone settings: `enabled` (`true`), `maxRepoSizeMB` (`350`), `cloneTimeoutSeconds` (`30`), and `clonePath` (
|
|
150
|
-
| `youtube` | object | see below | YouTube
|
|
151
|
-
| `video` | object | see below | Local video
|
|
161
|
+
| `provider` | `"auto" \| "exa" \| "perplexity" \| "gemini"` | `"auto"` | Default `web_search` provider. Switching providers in the curator updates this field immediately. |
|
|
162
|
+
| `workflow` | `"none" \| "summary-review"` | `"none"` | `"none"` returns raw results; `"summary-review"` opens the browser curator with a summary draft. |
|
|
163
|
+
| `curatorTimeoutSeconds` | number (`1` to `600`) | `20` | Curator wait timeout in seconds (floored to an integer; values below `1` fall back to `20`, and values above `600` clamp to `600`). |
|
|
164
|
+
| `summaryModel` | string | auto | Default `"provider/model"` for curator summary drafts (prefers `anthropic/claude-haiku-4-5` or `openai-codex/gpt-6.1-sol` when available). |
|
|
165
|
+
| `searchModel` | string | `"gemini-3-flash-preview"` | Gemini API model used for Gemini search queries. |
|
|
166
|
+
| `shortcuts` | `{ curate?: string, activity?: string }` | `{ "curate": "ctrl+shift+s", "activity": "ctrl+shift+w" }` | Keyboard shortcuts for opening the curator and toggling the activity widget. |
|
|
167
|
+
| `exaApiKey` | string | unset | Exa API key (overridden by `EXA_API_KEY`). |
|
|
168
|
+
| `perplexityApiKey` | string | unset | Perplexity API key (overridden by `PERPLEXITY_API_KEY`). |
|
|
169
|
+
| `geminiApiKey` | string | unset | Gemini API key (overridden by `GEMINI_API_KEY`). |
|
|
170
|
+
| `allowBrowserCookies` | boolean | `false` | Allow Gemini Web to read cookies from supported browsers on macOS and Linux (overridden by `ATOMIC_ALLOW_BROWSER_COOKIES=1`). Not supported on Windows. |
|
|
171
|
+
| `chromeProfile` | string | `"Default"` | Browser profile directory name used for Gemini Web cookie lookup. |
|
|
172
|
+
| `githubClone` | object | see below | GitHub clone settings: `enabled` (`true`), `maxRepoSizeMB` (`350`), `cloneTimeoutSeconds` (`30`), and `clonePath` (defaults to an account-private `github-repos` temp folder cleared on session switches). |
|
|
173
|
+
| `youtube` | object | see below | YouTube settings: `enabled` (`true`; setting `false` disables both analysis and frame extraction) and `preferredModel` (`"gemini-3-flash-preview"`). |
|
|
174
|
+
| `video` | object | see below | Local video settings: `enabled` (`true`), `preferredModel` (`"gemini-3-flash-preview"`), and `maxSizeMB` (`50`, measured in binary MiB). |
|
|
152
175
|
|
|
153
176
|
Example configuration:
|
|
154
177
|
|
|
@@ -181,6 +204,35 @@ Example configuration:
|
|
|
181
204
|
}
|
|
182
205
|
```
|
|
183
206
|
|
|
207
|
+
## Enabling and disabling
|
|
208
|
+
|
|
209
|
+
Web access is enabled by default in both the CLI and the SDK.
|
|
210
|
+
|
|
211
|
+
- **CLI.** Remove web-access tools for one run with `--exclude-tools`:
|
|
212
|
+
|
|
213
|
+
```bash
|
|
214
|
+
atomic --exclude-tools web_search,fetch_content,get_search_content,code_search
|
|
215
|
+
```
|
|
216
|
+
|
|
217
|
+
- **SDK.** Disable the bundled `web-access` package completely in `createAgentSession()`:
|
|
218
|
+
|
|
219
|
+
```typescript
|
|
220
|
+
import { createAgentSession } from "@bastani/atomic";
|
|
221
|
+
|
|
222
|
+
const { session } = await createAgentSession({
|
|
223
|
+
builtins: { "web-access": false },
|
|
224
|
+
});
|
|
225
|
+
```
|
|
226
|
+
|
|
227
|
+
See [CLI tool options](/reference/cli#tool-options) and [SDK tools](/sdk/reference#tools).
|
|
228
|
+
|
|
184
229
|
## Helper binary lookup
|
|
185
230
|
|
|
186
231
|
Helper binaries (`gh`, `git`, `ffmpeg`, `ffprobe`, `yt-dlp`, `npm`, browser openers, and OS keychain helpers) are resolved only from absolute directories in `PATH`. The current project directory is searched only when `PATH` explicitly lists it.
|
|
232
|
+
|
|
233
|
+
## Related docs
|
|
234
|
+
|
|
235
|
+
- [Built-in tools](/tools) covers `read` URL fetching, `code_search`, and tool selection.
|
|
236
|
+
- [SDK tools](/sdk/reference#tools) covers `builtins`, `tools`, and `excludedTools`.
|
|
237
|
+
- [CLI reference](/reference/cli) covers `--tools`, `--exclude-tools`, and `--no-tools`.
|
|
238
|
+
- [Environment variables](/environment-variables) lists `EXA_API_KEY`, `PERPLEXITY_API_KEY`, `GEMINI_API_KEY`, and `ATOMIC_ALLOW_BROWSER_COOKIES`.
|
package/docs/windows.md
CHANGED
|
@@ -1,54 +1,48 @@
|
|
|
1
1
|
---
|
|
2
|
-
title: "Windows"
|
|
3
|
-
|
|
2
|
+
title: "Windows setup"
|
|
3
|
+
sidebarTitle: "Windows"
|
|
4
|
+
description: "Install Atomic, configure Bash and PowerShell, pick a terminal, and troubleshoot Windows or WSL."
|
|
4
5
|
---
|
|
5
6
|
|
|
6
|
-
|
|
7
|
+
## Install with PowerShell
|
|
7
8
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
Install the self-contained Windows release archive with Windows PowerShell 5.1 or newer:
|
|
9
|
+
Install the self-contained Windows release archive with Windows PowerShell 5.1 or newer (no Node.js or package manager required):
|
|
11
10
|
|
|
12
11
|
```powershell
|
|
13
12
|
irm https://raw.githubusercontent.com/bastani-inc/atomic/main/install.ps1 | iex
|
|
14
13
|
```
|
|
15
14
|
|
|
16
|
-
|
|
15
|
+
To pin an exact release (`MAJOR.MINOR.PATCH` or `MAJOR.MINOR.PATCH-alpha.REVISION`):
|
|
17
16
|
|
|
18
17
|
```powershell
|
|
19
18
|
& ([scriptblock]::Create((irm https://raw.githubusercontent.com/bastani-inc/atomic/main/install.ps1))) -Ref 0.9.11
|
|
20
19
|
```
|
|
21
20
|
|
|
22
|
-
By default, the installer verifies `SHA256SUMS`, stores versioned payloads under `%LOCALAPPDATA%\atomic`, and
|
|
21
|
+
By default, the installer verifies `SHA256SUMS`, stores versioned payloads under `%LOCALAPPDATA%\atomic`, and creates an ASCII-only `atomic.cmd` launcher plus an `atomic-current` junction in `%LOCALAPPDATA%\atomic\bin`. The relative shim supports Unicode install paths and custom bin directories.
|
|
23
22
|
|
|
24
|
-
Override defaults with `ATOMIC_INSTALL_DIR`, `ATOMIC_BIN_DIR`, `ATOMIC_VERSION
|
|
23
|
+
Override defaults with `ATOMIC_INSTALL_DIR`, `ATOMIC_BIN_DIR` (defaults to `<ATOMIC_INSTALL_DIR>\bin`, so changing `ATOMIC_INSTALL_DIR` moves the default bin directory too), `ATOMIC_VERSION` (`-Ref` takes precedence over `ATOMIC_VERSION`), or optional `GITHUB_TOKEN`/`GH_TOKEN` (used only if release resolution falls back to the GitHub API). See [Release archive](/getting-started/installation#release-archive) for cross-platform archive options and [Package managers](/getting-started/installation#package-managers) if you install with Node.js.
|
|
25
24
|
|
|
26
|
-
###
|
|
25
|
+
### Installer rules and edge cases
|
|
27
26
|
|
|
28
|
-
- **Reruns and
|
|
29
|
-
- **PATH and `PATHEXT`:** The installer adds the bin directory to User PATH and the current PowerShell process, then asks you to open a new terminal when User PATH changed. A custom `ATOMIC_BIN_DIR` containing `;` cannot be one Windows PATH entry, so the installer leaves PATH untouched and prints a direct
|
|
27
|
+
- **Reruns, repair, and locking:** Concurrent installer runs serialize on an exclusive lock file under `ATOMIC_INSTALL_DIR`. When the requested release is already installed and healthy, rerunning skips the download and restores a missing User PATH entry; pass `-Force` or set `ATOMIC_FORCE_INSTALL=1` to reinstall anyway. A missing or mismatched `atomic.cmd` shim or `atomic-current` junction, a `current` junction pointing outside the install root, or a payload missing `app.js` or another startup file triggers a repair install.
|
|
28
|
+
- **PATH and `PATHEXT`:** The installer adds the bin directory to User PATH and the current PowerShell process, then asks you to open a new terminal when User PATH changed. A custom `ATOMIC_BIN_DIR` containing `;` cannot be one Windows PATH entry, so the installer leaves PATH untouched and prints a direct command for `atomic.cmd`. `PATHEXT` must include `.CMD` for bare `atomic` to resolve, or installation stops with an error.
|
|
30
29
|
- **Existing launchers and directories:** A same-stem launcher that `PATHEXT` resolves before `atomic.cmd`, such as a stale `atomic.exe`, stops installation before download until you remove it. An unexpected regular `current` entry under `ATOMIC_INSTALL_DIR`, or regular `atomic-current` entry under `ATOMIC_BIN_DIR`, is reported and left untouched instead of being moved or deleted.
|
|
31
|
-
- **Pinned versions:**
|
|
32
|
-
- **TLS 1.2 on legacy PowerShell 5.1:** Once
|
|
33
|
-
- **Output and cleanup:**
|
|
30
|
+
- **Pinned versions:** `-Ref` is validated against `MAJOR.MINOR.PATCH` or `MAJOR.MINOR.PATCH-alpha.REVISION` and honored literally. If GitHub returns a different release tag, installation stops before download.
|
|
31
|
+
- **TLS 1.2 on legacy PowerShell 5.1:** Once downloaded, the script enables TLS 1.2 for its own GitHub requests and restores your previous protocol setting. Because a downloaded script cannot fix the connection used to fetch itself, enable TLS 1.2 in your shell first if `irm` cannot reach GitHub.
|
|
32
|
+
- **Output, Intercom upgrade, and cleanup:** Setting `NO_COLOR` to any value (even empty) switches installer output to plain text without colors, progress bar, or logo (output is also plain under `CI` or redirected stdout; legacy consoles draw `#`/`-` bars without the logo). After installing, `install.ps1` runs `atomic intercom upgrade` to replace any older running Intercom broker and warns if that step fails ([Updating while Intercom is running](/getting-started/installation#updating-while-intercom-is-running)). The installer removes its `atomic-install-*` staging directory when done and warns if cleanup fails.
|
|
34
33
|
|
|
35
|
-
##
|
|
34
|
+
## Bash and PowerShell discovery
|
|
36
35
|
|
|
37
36
|
Atomic uses Bash for the `bash` tool and checks these locations in order:
|
|
38
37
|
|
|
39
|
-
1. Custom `shellPath` in `~/.atomic/agent/settings.json
|
|
38
|
+
1. Custom `shellPath` in `~/.atomic/agent/settings.json`, trusted project `.atomic/settings.json`, or legacy `~/.pi/agent/settings.json`
|
|
40
39
|
2. Git Bash at `%ProgramFiles%\Git\bin\bash.exe`
|
|
41
40
|
3. Git Bash at `%ProgramFiles(x86)%\Git\bin\bash.exe`
|
|
42
41
|
4. `bash.exe` on `PATH` (Cygwin, MSYS2, or WSL)
|
|
43
42
|
|
|
44
|
-
Windows Store app aliases (such as those in `%LOCALAPPDATA%\Microsoft\WindowsApps`) are accepted wherever Atomic
|
|
45
|
-
|
|
46
|
-
For legacy WSL `bash.exe` from `%SystemRoot%\System32`:
|
|
47
|
-
|
|
48
|
-
- Ownerless `bash` tool calls send commands over stdin to avoid command-line quoting issues.
|
|
49
|
-
- Supervised and background shell tasks reject legacy WSL `bash.exe` with `ContainmentUnavailable`. Run Atomic inside WSL for supervised POSIX shells.
|
|
43
|
+
Windows Store app aliases (such as those in `%LOCALAPPDATA%\Microsoft\WindowsApps`) are accepted wherever Atomic searches for a shell. Atomic checks only absolute directories on `PATH` in order, skips empty and relative `PATH` entries and directories, never searches the current working directory first, and caches missing `PATH` lookups for 30 seconds.
|
|
50
44
|
|
|
51
|
-
For the `bash` tool, [Git for Windows](https://git-scm.com/download/win) is
|
|
45
|
+
For the `bash` tool on native Windows, [Git for Windows](https://git-scm.com/download/win) is recommended. Every `bash` tool call in an Atomic CLI or interactive session rejects legacy WSL `%SystemRoot%\System32\bash.exe` with `ContainmentUnavailable` because Windows cannot isolate legacy WSL child processes reliably. Run Atomic directly inside WSL when you want a WSL POSIX shell. (Only standalone SDK `createBashTool()` calls without background task management fall back to sending commands over stdin on legacy WSL `bash.exe`.)
|
|
52
46
|
|
|
53
47
|
PowerShell discovery checks these locations in order:
|
|
54
48
|
|
|
@@ -57,9 +51,15 @@ PowerShell discovery checks these locations in order:
|
|
|
57
51
|
3. `powershell.exe` on `PATH`
|
|
58
52
|
4. `%SystemRoot%\System32\WindowsPowerShell\v1.0\powershell.exe`
|
|
59
53
|
|
|
60
|
-
|
|
54
|
+
### Native Windows `shellCommandPrefix` caveat
|
|
55
|
+
|
|
56
|
+
On native Windows, Atomic prepends `shellCommandPrefix` to **both** model `bash` tool calls (which run in Bash) and interactive `!` and `!!` commands (which run in PowerShell), while the model `powershell` tool ignores `shellCommandPrefix`.
|
|
57
|
+
|
|
58
|
+
Because Bash and PowerShell use incompatible syntax, putting PowerShell syntax in `shellCommandPrefix` breaks every model `bash` tool call, and putting Bash syntax breaks every `!` and `!!` command. Leave `shellCommandPrefix` unset on native Windows unless you intentionally disable one side (for example, by excluding `bash`). Inside WSL, both `bash` tool calls and `!`/`!!` run in Bash, so Bash syntax works for both. See [Shell aliases](/shell-aliases).
|
|
61
59
|
|
|
62
|
-
|
|
60
|
+
### Set a custom Bash path
|
|
61
|
+
|
|
62
|
+
Set `shellPath` in `~/.atomic/agent/settings.json` or a trusted project's `.atomic/settings.json`:
|
|
63
63
|
|
|
64
64
|
```json
|
|
65
65
|
{
|
|
@@ -67,11 +67,22 @@ Atomic searches only absolute directories on `PATH`, in order, and never searche
|
|
|
67
67
|
}
|
|
68
68
|
```
|
|
69
69
|
|
|
70
|
-
|
|
70
|
+
If `shellPath` is a bare executable name (with no `/`, `\`, or `:`), Atomic searches absolute `PATH` directories. Otherwise Atomic checks the path literally. If the configured `shellPath` does not exist, Atomic stops with `Custom shell path not found: ...` instead of falling back to Git Bash.
|
|
71
|
+
|
|
72
|
+
POSIX-style paths copied from Git Bash, MSYS2, Cygwin, or WSL work anywhere Atomic resolves a file path. Atomic translates `/c/...`, `/cygdrive/c/...`, and `/mnt/c/...` (case-insensitive single drive letter) into `C:\...`, while leaving UNC/double-slash paths (`//...`) and paths already containing `\` untouched.
|
|
73
|
+
|
|
74
|
+
## PowerShell tool
|
|
75
|
+
|
|
76
|
+
On native Windows, Atomic enables the `powershell` tool by default whenever `pwsh.exe` or `powershell.exe` is found in the discovery order above, and omits it if neither is installed. This tool is Windows-only and is not enabled on Linux or macOS even if `pwsh` is installed.
|
|
77
|
+
|
|
78
|
+
- **Execution flags and encoding:** Atomic launches PowerShell with `-NoProfile -NonInteractive -ExecutionPolicy Bypass` (using `-EncodedCommand` with UTF-16LE base64 in interactive and CLI sessions, or `-Command` in standalone SDK calls), sets UTF-8 console output, and wraps Windows PowerShell 5.1 (`powershell.exe`) calls so script errors exit with code `1`.
|
|
79
|
+
- **Environment and PTY control:** Both `ATOMIC_*` and legacy `PI_*` session environment variables are available inside PowerShell calls ([Environment variables](/environment-variables)). Setting `ATOMIC_NO_PTY=1` (legacy `PI_NO_PTY=1`, where `ATOMIC_NO_PTY=0` overrides `PI_NO_PTY=1`) disables PTY allocation for both `powershell` and `bash` tool calls.
|
|
80
|
+
- **Tool lists and output:** Add `powershell` to `defaultTools` in [Tool settings](/settings#tools) if you define a custom built-in tool allowlist. To disable all shell execution on native Windows, exclude both `bash` and `powershell` (`--exclude-tools bash,powershell`; see [No built-in sandbox](/security#no-built-in-sandbox)). PowerShell calls render with a `PS>` prompt, and truncated output spills to an `atomic-powershell-*` temporary file separate from Bash spill files.
|
|
81
|
+
- **SDK exports:** `@bastani/atomic` exports `createPowerShellTool()`, `createPowerShellToolDefinition()`, `createLocalPowerShellOperations()`, their public types, and `getPowerShellConfig()` ([PowerShell tool behavior](/sdk/reference#powershell-tool-behavior)). Factory-created tools expose the `ATOMIC_*` and legacy `PI_*` session snapshot by default; pass `exposeSessionEnvironment: false` to opt out.
|
|
71
82
|
|
|
72
83
|
## Choose a terminal
|
|
73
84
|
|
|
74
|
-
Windows terminals run Atomic through a console host (conhost). Terminals
|
|
85
|
+
Windows terminals run Atomic through a console host (`conhost`). Terminals using the older built-in Windows `conhost` have rendering and input bugs that affect Atomic. Use [Windows Terminal](https://aka.ms/terminal), which ships a current `conhost` (see [Windows Terminal setup](/terminal-setup#windows-terminal) for WSL and SSH `Shift+Enter` configuration). For terminal multiplexers and Windows desktop or terminal automation with psmux and UI Automation, see [Herdr](/herdr) and [Computer use](/computer-use#windows).
|
|
75
86
|
|
|
76
87
|
| Terminal | Conhost | Status |
|
|
77
88
|
| --- | --- | --- |
|
|
@@ -83,7 +94,7 @@ Windows terminals run Atomic through a console host (conhost). Terminals that re
|
|
|
83
94
|
|
|
84
95
|
## Windows and WSL keybindings
|
|
85
96
|
|
|
86
|
-
Atomic adjusts several default shortcuts on native Windows and WSL to avoid terminal conflicts
|
|
97
|
+
Atomic adjusts several default shortcuts on native Windows and WSL to avoid terminal conflicts. WSL keybindings activate automatically on Linux whenever `WSL_DISTRO_NAME` or `WSL_INTEROP` is set.
|
|
87
98
|
|
|
88
99
|
| Action | Native Windows | WSL |
|
|
89
100
|
| --- | --- | --- |
|
|
@@ -95,47 +106,34 @@ Atomic adjusts several default shortcuts on native Windows and WSL to avoid term
|
|
|
95
106
|
| Paste image or clipboard text | `Alt+V` or `Ctrl+V` | `Alt+V` or `Ctrl+V` |
|
|
96
107
|
| Jump to previous / next prompt | `Ctrl+Up` / `Ctrl+Down` | `Ctrl+Up` / `Ctrl+Down` |
|
|
97
108
|
|
|
98
|
-
On native Windows
|
|
99
|
-
|
|
100
|
-
## Interactive startup
|
|
101
|
-
|
|
102
|
-
On eligible interactive starts, Atomic opens the prompt editor immediately so you can start typing right away, and your text is kept while the session finishes loading. See [Startup typing](/usage#startup-typing) for which keys apply immediately and which wait in order.
|
|
109
|
+
On native Windows outside VS Code's integrated terminal, pressing the unmodified secondary mouse button pastes clipboard text into the focused input. See [Keybindings](/keybindings) for the complete shortcut reference.
|
|
103
110
|
|
|
104
|
-
|
|
111
|
+
## Startup, shutdown, and process cleanup
|
|
105
112
|
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
- **Graceful shutdown:** Quitting Atomic gives the interactive engine up to 5 seconds to run `session_shutdown` handlers.
|
|
113
|
+
- **Early startup typing:** On eligible interactive starts, Atomic opens the prompt editor right away so you can start typing while the session finishes loading. Submitting early shows the working indicator, and pressing `Escape` cancels a queued submission. If resource loading fails before a prompt sends, Atomic restores your draft without sending a model request; run `/reload` to retry. See [Startup typing](/usage#startup-typing).
|
|
114
|
+
- **Graceful shutdown:** Quitting Atomic gives the session up to 5 seconds to run `session_shutdown` handlers.
|
|
109
115
|
- **Console close and Windows sign-out:** Closing the console window (exit code `0xC000013A`) and signing out, restarting, or shutting down Windows also run `session_shutdown` handlers with `fromSignal: true` for up to about 4 seconds before Windows terminates the process.
|
|
110
|
-
- **Shell process-tree cleanup:**
|
|
111
|
-
|
|
112
|
-
## Headless skill commands
|
|
116
|
+
- **Shell process-tree cleanup:** Interactive and CLI `bash` and `powershell` tool calls are contained automatically by the session. Interactive `!` commands and standalone SDK `bash` or `powershell` calls start in their own Windows Job object, so pressing `Escape`, hitting a timeout, or aborting stops the shell and its child processes. Because Git Bash starts child processes with `CREATE_BREAKAWAY_FROM_JOB`, processes left running after `bash` exits cannot be stopped by that job. Set `ATOMIC_HOST_SPAWN=child-process` to disable native Job-object containment for `!` commands, helper processes, and standalone SDK tool calls and fall back to Node's `child_process` ([Environment variables](/environment-variables#diagnostics-and-performance)).
|
|
117
|
+
- **Node.js compile cache:** On Node.js 22.8 and newer, Atomic enables Node's persistent compile cache automatically and warms a cold default cache in a background helper during interactive runs. Set `NODE_COMPILE_CACHE` to use a custom directory (letting Node write it on exit) or `NODE_DISABLE_COMPILE_CACHE=1` to disable it ([Environment variables](/environment-variables#diagnostics-and-performance)).
|
|
113
118
|
|
|
114
|
-
|
|
119
|
+
## Self-update on Windows
|
|
115
120
|
|
|
116
|
-
|
|
121
|
+
Run `atomic update` or `atomic update --self` to update Atomic (add `--force` to reinstall the same version), `atomic update --all` to update Atomic and installed packages, `atomic update --extensions` to update installed packages only, or `atomic update --models` to refresh the model catalog.
|
|
117
122
|
|
|
118
|
-
|
|
123
|
+
For writable global package-manager installs on Windows, Atomic handles loaded native add-ons during self-update so Windows file locks do not block replacement. For custom or wrapped installations, configure `selfUpdateCommand` in global settings or `ATOMIC_SELF_UPDATE_COMMAND` (see [Custom update command](/reference/cli#custom-update-command)).
|
|
119
124
|
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
`atomic update` and `atomic update --self` update Atomic only. Pass `atomic update --all` to update both Atomic and installed packages, or `atomic update --extensions` to update installed packages only.
|
|
123
|
-
|
|
124
|
-
For writable global package-manager installs on Windows, Atomic handles loaded native add-ons during self-update so Windows file locks do not block replacement.
|
|
125
|
-
|
|
126
|
-
If Atomic cannot safely self-update an installation, it exits with an explanation naming the detected executable path when available and tells you to update through the package manager, wrapper, source checkout, or release artifact that installed it. Release archive installs are not updated by `atomic update`; rerun `install.ps1` instead. Standalone Bun binaries point you to the latest [Atomic releases](https://github.com/bastani-inc/atomic/releases/latest).
|
|
127
|
-
|
|
128
|
-
## PowerShell tool
|
|
125
|
+
If you upgrade an npm install from 0.10.4 or earlier while an older Intercom broker is running, `npm install -g @bastani/atomic` can fail with `EBUSY` because earlier brokers locked files inside the npm install directory. Close running Atomic sessions and wait 5 seconds (or run `atomic intercom restart`), then rerun the install. From 0.10.5 onward, the broker runs outside the install directory ([Updating while Intercom is running](/getting-started/installation#updating-while-intercom-is-running)).
|
|
129
126
|
|
|
130
|
-
|
|
127
|
+
If Atomic cannot safely self-update an installation, it exits with an explanation naming the detected executable path when available and tells you how to update. Release archive installs are not updated by `atomic update`; rerun `install.ps1` instead. Standalone Bun binaries point you to the latest [Atomic releases](https://github.com/bastani-inc/atomic/releases/latest).
|
|
131
128
|
|
|
132
|
-
|
|
129
|
+
## Headless skills and file watchers
|
|
133
130
|
|
|
134
|
-
|
|
131
|
+
- **Headless skill commands:** Skills such as `/skill:skill-creator` run evaluation queries in a hidden Windows console that cannot answer interactive credential prompts. Configure an API key, an environment variable, or a credential command that reads a cached token without prompting.
|
|
132
|
+
- **File watcher polling:** When a Windows path cannot be watched reliably with native filesystem events, Atomic falls back to polling: every 1,000 ms for custom theme files and Git HEAD, and every 250 ms for Git reftable lists. Theme reloads and Git status updates may arrive after that short interval.
|
|
135
133
|
|
|
136
134
|
## Known issues
|
|
137
135
|
|
|
138
|
-
These issues come from older versions of Windows conhost
|
|
136
|
+
These issues come from older versions of Windows `conhost`:
|
|
139
137
|
|
|
140
138
|
| Issue | Affects | Remedy |
|
|
141
139
|
| --- | --- | --- |
|