@bastani/atomic 0.9.38-alpha.1 → 0.9.38-alpha.11
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 +141 -0
- package/README.md +8 -6
- package/dist/builtin/intercom/CHANGELOG.md +15 -0
- package/dist/builtin/intercom/broker/broker.ts +6 -4
- package/dist/builtin/intercom/broker/delivered-message-cache.ts +50 -4
- package/dist/builtin/intercom/broker/send-handler.ts +6 -4
- package/dist/builtin/intercom/index.bundle.mjs +89 -40
- package/dist/builtin/intercom/package.json +2 -2
- package/dist/builtin/mcp/package.json +1 -1
- package/dist/builtin/subagents/CHANGELOG.md +12 -0
- package/dist/builtin/subagents/README.md +9 -4
- package/dist/builtin/subagents/package.json +3 -3
- package/dist/builtin/subagents/src/extension/index.bundle.mjs +163 -158
- package/dist/builtin/web-access/CHANGELOG.md +7 -0
- package/dist/builtin/web-access/index.bundle.mjs +53 -15
- package/dist/builtin/web-access/package.json +2 -2
- package/dist/builtin/workflows/CHANGELOG.md +91 -0
- package/dist/builtin/workflows/README.md +5 -10
- package/dist/builtin/workflows/builtin/adversarial-verification.js +2 -2
- package/dist/builtin/workflows/builtin/{chunk-94f8zfz1.js → chunk-454hz1qt.js} +1 -1
- package/dist/builtin/workflows/builtin/{chunk-wf876n16.js → chunk-4bwtzyjq.js} +1 -1
- package/dist/builtin/workflows/builtin/{chunk-kb7s3gx2.js → chunk-5eh0brtd.js} +1 -1
- package/dist/builtin/workflows/builtin/{chunk-nkj4qhj6.js → chunk-85mx6wcf.js} +7 -7
- package/dist/builtin/workflows/builtin/{chunk-3n2bnz64.js → chunk-8kkv04hz.js} +16 -16
- package/dist/builtin/workflows/builtin/chunk-8x61e0s7.js +3148 -0
- package/dist/builtin/workflows/builtin/{chunk-r97ndfvt.js → chunk-bjva9j5k.js} +1 -1
- package/dist/builtin/workflows/builtin/{chunk-a1ar035d.js → chunk-qdd897wm.js} +1 -1
- package/dist/builtin/workflows/builtin/{chunk-gyjck9z8.js → chunk-qjqn389g.js} +1 -1
- package/dist/builtin/workflows/builtin/{chunk-632fxeb8.js → chunk-x0vvjyzg.js} +1 -1
- package/dist/builtin/workflows/builtin/{chunk-ad83gc5p.js → chunk-y45tkftg.js} +11 -18
- package/dist/builtin/workflows/builtin/classify-and-act.js +2 -2
- package/dist/builtin/workflows/builtin/fan-out-and-synthesize.js +2 -2
- package/dist/builtin/workflows/builtin/generate-and-filter.js +2 -2
- package/dist/builtin/workflows/builtin/goal.js +3 -3
- package/dist/builtin/workflows/builtin/index.js +11 -11
- package/dist/builtin/workflows/builtin/loop-until-done.js +2 -2
- package/dist/builtin/workflows/builtin/open-claude-design.js +2 -2
- package/dist/builtin/workflows/builtin/ralph.js +3 -3
- package/dist/builtin/workflows/builtin/tournament.js +2 -2
- package/dist/builtin/workflows/package.json +2 -2
- package/dist/builtin/workflows/src/authoring.d.ts +9 -12
- package/dist/builtin/workflows/src/durable/journal/conformance.d.ts +12 -0
- package/dist/builtin/workflows/src/durable/journal/internal.d.ts +1 -0
- package/dist/builtin/workflows/src/durable/journal/lease-expiry.d.ts +2 -0
- package/dist/builtin/workflows/src/durable/journal/legacy-journal-tables.d.ts +42 -0
- package/dist/builtin/workflows/src/durable/journal/memory-run-journal.d.ts +35 -0
- package/dist/builtin/workflows/src/durable/journal/resolution.d.ts +32 -0
- package/dist/builtin/workflows/src/durable/journal/sql-run-journal.d.ts +48 -0
- package/dist/builtin/workflows/src/durable/journal/sqlite-run-journal.d.ts +7 -0
- package/dist/builtin/workflows/src/durable/journal/types.d.ts +95 -0
- package/dist/builtin/workflows/src/durable/journal/values.d.ts +5 -0
- package/dist/builtin/workflows/src/extension/index.bundle.mjs +29515 -64826
- package/dist/builtin/workflows/src/index.js +10767 -45885
- package/dist/builtin/workflows/src/shared/authoring-contract-stage.d.ts +8 -14
- package/dist/builtin/workflows/src/shared/authoring-contract-ui.d.ts +4 -20
- package/dist/bun/split-loader.js +0 -13
- package/dist/bun/split-loader.js.map +1 -1
- package/dist/cli/args.d.ts +3 -0
- package/dist/cli/args.d.ts.map +1 -1
- package/dist/cli/args.js +35 -5
- package/dist/cli/args.js.map +1 -1
- package/dist/cli/session-picker.d.ts +2 -2
- package/dist/cli/session-picker.d.ts.map +1 -1
- package/dist/cli/session-picker.js +5 -5
- package/dist/cli/session-picker.js.map +1 -1
- package/dist/core/agent-session-auto-compaction.d.ts +1 -1
- package/dist/core/agent-session-auto-compaction.d.ts.map +1 -1
- package/dist/core/agent-session-auto-compaction.js +2 -2
- package/dist/core/agent-session-auto-compaction.js.map +1 -1
- package/dist/core/agent-session-bash.d.ts +2 -3
- package/dist/core/agent-session-bash.d.ts.map +1 -1
- package/dist/core/agent-session-bash.js +18 -10
- package/dist/core/agent-session-bash.js.map +1 -1
- package/dist/core/agent-session-boundaries.d.ts +6 -6
- package/dist/core/agent-session-boundaries.d.ts.map +1 -1
- package/dist/core/agent-session-boundaries.js +22 -22
- package/dist/core/agent-session-boundaries.js.map +1 -1
- package/dist/core/agent-session-compaction.d.ts.map +1 -1
- package/dist/core/agent-session-compaction.js +3 -2
- package/dist/core/agent-session-compaction.js.map +1 -1
- package/dist/core/agent-session-custom-message-commit.d.ts.map +1 -1
- package/dist/core/agent-session-custom-message-commit.js +10 -12
- package/dist/core/agent-session-custom-message-commit.js.map +1 -1
- package/dist/core/agent-session-events.d.ts.map +1 -1
- package/dist/core/agent-session-events.js +26 -14
- package/dist/core/agent-session-events.js.map +1 -1
- package/dist/core/agent-session-export.js +1 -1
- package/dist/core/agent-session-export.js.map +1 -1
- package/dist/core/agent-session-extension-bindings.d.ts +2 -2
- package/dist/core/agent-session-extension-bindings.d.ts.map +1 -1
- package/dist/core/agent-session-extension-bindings.js +79 -59
- package/dist/core/agent-session-extension-bindings.js.map +1 -1
- package/dist/core/agent-session-message-queue.d.ts +2 -2
- package/dist/core/agent-session-message-queue.d.ts.map +1 -1
- package/dist/core/agent-session-message-queue.js +17 -8
- package/dist/core/agent-session-message-queue.js.map +1 -1
- package/dist/core/agent-session-methods.d.ts +15 -15
- package/dist/core/agent-session-methods.d.ts.map +1 -1
- package/dist/core/agent-session-methods.js.map +1 -1
- package/dist/core/agent-session-models.d.ts +2 -2
- package/dist/core/agent-session-models.d.ts.map +1 -1
- package/dist/core/agent-session-models.js +59 -42
- package/dist/core/agent-session-models.js.map +1 -1
- package/dist/core/agent-session-persistent-custom-messages.d.ts +4 -4
- package/dist/core/agent-session-persistent-custom-messages.d.ts.map +1 -1
- package/dist/core/agent-session-persistent-custom-messages.js +16 -17
- package/dist/core/agent-session-persistent-custom-messages.js.map +1 -1
- package/dist/core/agent-session-prompt.d.ts.map +1 -1
- package/dist/core/agent-session-prompt.js +63 -23
- package/dist/core/agent-session-prompt.js.map +1 -1
- package/dist/core/agent-session-retry.d.ts.map +1 -1
- package/dist/core/agent-session-retry.js +17 -15
- package/dist/core/agent-session-retry.js.map +1 -1
- package/dist/core/agent-session-runtime.d.ts +7 -8
- package/dist/core/agent-session-runtime.d.ts.map +1 -1
- package/dist/core/agent-session-runtime.js +88 -100
- package/dist/core/agent-session-runtime.js.map +1 -1
- package/dist/core/agent-session-services.d.ts +1 -1
- package/dist/core/agent-session-services.d.ts.map +1 -1
- package/dist/core/agent-session-services.js +2 -2
- package/dist/core/agent-session-services.js.map +1 -1
- package/dist/core/agent-session-summary.js +1 -1
- package/dist/core/agent-session-summary.js.map +1 -1
- package/dist/core/agent-session-tree.d.ts +1 -1
- package/dist/core/agent-session-tree.d.ts.map +1 -1
- package/dist/core/agent-session-tree.js +8 -7
- package/dist/core/agent-session-tree.js.map +1 -1
- package/dist/core/agent-session-types.d.ts +2 -0
- package/dist/core/agent-session-types.d.ts.map +1 -1
- package/dist/core/agent-session-types.js.map +1 -1
- package/dist/core/auth-storage-backends.d.ts +2 -0
- package/dist/core/auth-storage-backends.d.ts.map +1 -1
- package/dist/core/auth-storage-backends.js +12 -0
- package/dist/core/auth-storage-backends.js.map +1 -1
- package/dist/core/auth-storage.d.ts +5 -0
- package/dist/core/auth-storage.d.ts.map +1 -1
- package/dist/core/auth-storage.js +46 -12
- package/dist/core/auth-storage.js.map +1 -1
- package/dist/core/cache-warmer.js +1 -1
- package/dist/core/cache-warmer.js.map +1 -1
- package/dist/core/compaction/branch-summarization.d.ts +3 -5
- package/dist/core/compaction/branch-summarization.d.ts.map +1 -1
- package/dist/core/compaction/branch-summarization.js +6 -10
- package/dist/core/compaction/branch-summarization.js.map +1 -1
- package/dist/core/compaction/compaction-runner.d.ts +1 -0
- package/dist/core/compaction/compaction-runner.d.ts.map +1 -1
- package/dist/core/compaction/compaction-runner.js +4 -1
- package/dist/core/compaction/compaction-runner.js.map +1 -1
- package/dist/core/compaction/pi-summary-fallback.d.ts +2 -1
- package/dist/core/compaction/pi-summary-fallback.d.ts.map +1 -1
- package/dist/core/compaction/pi-summary-fallback.js +6 -8
- package/dist/core/compaction/pi-summary-fallback.js.map +1 -1
- package/dist/core/compaction/utils.d.ts +2 -1
- package/dist/core/compaction/utils.d.ts.map +1 -1
- package/dist/core/compaction/utils.js +32 -7
- package/dist/core/compaction/utils.js.map +1 -1
- package/dist/core/export-html/index.js +1 -1
- package/dist/core/export-html/index.js.map +1 -1
- package/dist/core/export-html/template-js/entries-navigation.js +1 -1
- package/dist/core/export-html/template.js +1 -1
- package/dist/core/extensions/api-types.d.ts +12 -12
- package/dist/core/extensions/api-types.d.ts.map +1 -1
- package/dist/core/extensions/api-types.js.map +1 -1
- package/dist/core/extensions/context-types.d.ts +4 -2
- package/dist/core/extensions/context-types.d.ts.map +1 -1
- package/dist/core/extensions/context-types.js.map +1 -1
- package/dist/core/extensions/extension-work.d.ts +1 -0
- package/dist/core/extensions/extension-work.d.ts.map +1 -1
- package/dist/core/extensions/extension-work.js +5 -1
- package/dist/core/extensions/extension-work.js.map +1 -1
- package/dist/core/extensions/index.d.ts +1 -1
- package/dist/core/extensions/index.d.ts.map +1 -1
- package/dist/core/extensions/index.js +1 -1
- package/dist/core/extensions/index.js.map +1 -1
- package/dist/core/extensions/loader-api.d.ts.map +1 -1
- package/dist/core/extensions/loader-api.js +40 -42
- package/dist/core/extensions/loader-api.js.map +1 -1
- package/dist/core/extensions/loader-host-modules.d.ts +1 -1
- package/dist/core/extensions/loader-host-modules.d.ts.map +1 -1
- package/dist/core/extensions/loader-host-modules.js +6 -2
- package/dist/core/extensions/loader-host-modules.js.map +1 -1
- package/dist/core/extensions/loader-rollback.d.ts.map +1 -1
- package/dist/core/extensions/loader-rollback.js +1 -0
- package/dist/core/extensions/loader-rollback.js.map +1 -1
- package/dist/core/extensions/loader-virtual-modules.d.ts.map +1 -1
- package/dist/core/extensions/loader-virtual-modules.js +1 -0
- package/dist/core/extensions/loader-virtual-modules.js.map +1 -1
- package/dist/core/extensions/runner-context.d.ts +1 -0
- package/dist/core/extensions/runner-context.d.ts.map +1 -1
- package/dist/core/extensions/runner-context.js +10 -3
- package/dist/core/extensions/runner-context.js.map +1 -1
- package/dist/core/extensions/runner-handlers.d.ts +1 -1
- package/dist/core/extensions/runner-handlers.d.ts.map +1 -1
- package/dist/core/extensions/runner-handlers.js.map +1 -1
- package/dist/core/extensions/runner.d.ts +5 -2
- package/dist/core/extensions/runner.d.ts.map +1 -1
- package/dist/core/extensions/runner.js +28 -12
- package/dist/core/extensions/runner.js.map +1 -1
- package/dist/core/extensions/runtime-types.d.ts +7 -7
- package/dist/core/extensions/runtime-types.d.ts.map +1 -1
- package/dist/core/extensions/runtime-types.js.map +1 -1
- package/dist/core/extensions/session-events.d.ts +5 -5
- package/dist/core/extensions/session-events.d.ts.map +1 -1
- package/dist/core/extensions/session-events.js.map +1 -1
- package/dist/core/extensions/workflow-events.d.ts +2 -0
- package/dist/core/extensions/workflow-events.d.ts.map +1 -1
- package/dist/core/extensions/workflow-events.js.map +1 -1
- package/dist/core/extensions/workflow-run-control.d.ts +3 -3
- package/dist/core/extensions/workflow-run-control.d.ts.map +1 -1
- package/dist/core/extensions/workflow-run-control.js +4 -4
- package/dist/core/extensions/workflow-run-control.js.map +1 -1
- package/dist/core/fast-model-routing.d.ts.map +1 -1
- package/dist/core/fast-model-routing.js +1 -0
- package/dist/core/fast-model-routing.js.map +1 -1
- package/dist/core/intercom-runtime-group.js +1 -1
- package/dist/core/intercom-runtime-group.js.map +1 -1
- package/dist/core/model-config.d.ts +765 -0
- package/dist/core/model-config.d.ts.map +1 -1
- package/dist/core/model-config.js +46 -24
- package/dist/core/model-config.js.map +1 -1
- package/dist/core/model-resolver-defaults.js +5 -5
- package/dist/core/model-resolver-defaults.js.map +1 -1
- package/dist/core/model-runtime-streaming.d.ts +9 -2
- package/dist/core/model-runtime-streaming.d.ts.map +1 -1
- package/dist/core/model-runtime-streaming.js +121 -10
- package/dist/core/model-runtime-streaming.js.map +1 -1
- package/dist/core/model-runtime.d.ts +6 -0
- package/dist/core/model-runtime.d.ts.map +1 -1
- package/dist/core/model-runtime.js +103 -2
- package/dist/core/model-runtime.js.map +1 -1
- package/dist/core/provider-attribution.js +1 -1
- package/dist/core/provider-attribution.js.map +1 -1
- package/dist/core/queued-input-admission.d.ts +20 -0
- package/dist/core/queued-input-admission.d.ts.map +1 -0
- package/dist/core/queued-input-admission.js +55 -0
- package/dist/core/queued-input-admission.js.map +1 -0
- package/dist/core/resource-loader-reload.js +1 -1
- package/dist/core/resource-loader-reload.js.map +1 -1
- package/dist/core/resource-loader-types.d.ts +1 -1
- package/dist/core/resource-loader-types.d.ts.map +1 -1
- package/dist/core/resource-loader-types.js.map +1 -1
- package/dist/core/runtime-credentials.d.ts +1 -0
- package/dist/core/runtime-credentials.d.ts.map +1 -1
- package/dist/core/runtime-credentials.js +3 -0
- package/dist/core/runtime-credentials.js.map +1 -1
- package/dist/core/sdk-types.d.ts +4 -0
- package/dist/core/sdk-types.d.ts.map +1 -1
- package/dist/core/sdk-types.js.map +1 -1
- package/dist/core/sdk.d.ts +1 -1
- package/dist/core/sdk.d.ts.map +1 -1
- package/dist/core/sdk.js +145 -94
- package/dist/core/sdk.js.map +1 -1
- package/dist/core/session-lifecycle-work.d.ts +3 -0
- package/dist/core/session-lifecycle-work.d.ts.map +1 -1
- package/dist/core/session-lifecycle-work.js +2 -0
- package/dist/core/session-lifecycle-work.js.map +1 -1
- package/dist/core/session-manager-archive.d.ts +2 -16
- package/dist/core/session-manager-archive.d.ts.map +1 -1
- package/dist/core/session-manager-archive.js +8 -109
- package/dist/core/session-manager-archive.js.map +1 -1
- package/dist/core/session-manager-core.d.ts +53 -51
- package/dist/core/session-manager-core.d.ts.map +1 -1
- package/dist/core/session-manager-core.js +549 -315
- package/dist/core/session-manager-core.js.map +1 -1
- package/dist/core/session-manager-entries.d.ts.map +1 -1
- package/dist/core/session-manager-entries.js +5 -10
- package/dist/core/session-manager-entries.js.map +1 -1
- package/dist/core/session-manager-errors.d.ts +10 -0
- package/dist/core/session-manager-errors.d.ts.map +1 -0
- package/dist/core/session-manager-errors.js +27 -0
- package/dist/core/session-manager-errors.js.map +1 -0
- package/dist/core/session-manager-list.d.ts +1 -0
- package/dist/core/session-manager-list.d.ts.map +1 -1
- package/dist/core/session-manager-list.js +23 -25
- package/dist/core/session-manager-list.js.map +1 -1
- package/dist/core/session-manager-storage.d.ts +3 -12
- package/dist/core/session-manager-storage.d.ts.map +1 -1
- package/dist/core/session-manager-storage.js +60 -77
- package/dist/core/session-manager-storage.js.map +1 -1
- package/dist/core/session-manager-types.d.ts +4 -12
- package/dist/core/session-manager-types.d.ts.map +1 -1
- package/dist/core/session-manager-types.js +2 -1
- package/dist/core/session-manager-types.js.map +1 -1
- package/dist/core/session-manager-validation.d.ts +3 -0
- package/dist/core/session-manager-validation.d.ts.map +1 -1
- package/dist/core/session-manager-validation.js +18 -1
- package/dist/core/session-manager-validation.js.map +1 -1
- package/dist/core/session-manager.d.ts +3 -3
- package/dist/core/session-manager.d.ts.map +1 -1
- package/dist/core/session-manager.js +3 -3
- package/dist/core/session-manager.js.map +1 -1
- package/dist/core/session-mutation-queue.d.ts +3 -0
- package/dist/core/session-mutation-queue.d.ts.map +1 -0
- package/dist/core/session-mutation-queue.js +14 -0
- package/dist/core/session-mutation-queue.js.map +1 -0
- package/dist/core/session-resume-args.d.ts +4 -0
- package/dist/core/session-resume-args.d.ts.map +1 -0
- package/dist/core/session-resume-args.js +9 -0
- package/dist/core/session-resume-args.js.map +1 -0
- package/dist/core/session-storage.d.ts +26 -0
- package/dist/core/session-storage.d.ts.map +1 -0
- package/dist/core/session-storage.js +171 -0
- package/dist/core/session-storage.js.map +1 -0
- package/dist/core/session-store-list.d.ts +4 -0
- package/dist/core/session-store-list.d.ts.map +1 -0
- package/dist/core/session-store-list.js +28 -0
- package/dist/core/session-store-list.js.map +1 -0
- package/dist/core/settings-manager-basic-accessors.d.ts +0 -1
- package/dist/core/settings-manager-basic-accessors.d.ts.map +1 -1
- package/dist/core/settings-manager-basic-accessors.js +0 -5
- package/dist/core/settings-manager-basic-accessors.js.map +1 -1
- package/dist/core/settings-merge.d.ts.map +1 -1
- package/dist/core/settings-merge.js +8 -2
- package/dist/core/settings-merge.js.map +1 -1
- package/dist/core/settings-schema.d.ts +76 -6
- package/dist/core/settings-schema.d.ts.map +1 -1
- package/dist/core/settings-schema.js +29 -20
- package/dist/core/settings-schema.js.map +1 -1
- package/dist/core/storage/database.d.ts +21 -0
- package/dist/core/storage/database.d.ts.map +1 -0
- package/dist/core/storage/database.js +2 -0
- package/dist/core/storage/database.js.map +1 -0
- package/dist/core/storage/errors.d.ts +64 -0
- package/dist/core/storage/errors.d.ts.map +1 -0
- package/dist/core/storage/errors.js +103 -0
- package/dist/core/storage/errors.js.map +1 -0
- package/dist/core/storage/index.d.ts +10 -0
- package/dist/core/storage/index.d.ts.map +1 -0
- package/dist/core/storage/index.js +8 -0
- package/dist/core/storage/index.js.map +1 -0
- package/dist/core/storage/node-sqlite.d.ts +7 -0
- package/dist/core/storage/node-sqlite.d.ts.map +1 -0
- package/dist/core/storage/node-sqlite.js +202 -0
- package/dist/core/storage/node-sqlite.js.map +1 -0
- package/dist/core/storage/prefix.d.ts +5 -0
- package/dist/core/storage/prefix.d.ts.map +1 -0
- package/dist/core/storage/prefix.js +15 -0
- package/dist/core/storage/prefix.js.map +1 -0
- package/dist/core/storage/provider.d.ts +58 -0
- package/dist/core/storage/provider.d.ts.map +1 -0
- package/dist/core/storage/provider.js +243 -0
- package/dist/core/storage/provider.js.map +1 -0
- package/dist/core/storage/run-journal.d.ts +93 -0
- package/dist/core/storage/run-journal.d.ts.map +1 -0
- package/dist/core/storage/run-journal.js +15 -0
- package/dist/core/storage/run-journal.js.map +1 -0
- package/dist/core/storage/schema.d.ts +3 -0
- package/dist/core/storage/schema.d.ts.map +1 -0
- package/dist/core/storage/schema.js +6 -0
- package/dist/core/storage/schema.js.map +1 -0
- package/dist/core/storage/selection.d.ts +16 -0
- package/dist/core/storage/selection.d.ts.map +1 -0
- package/dist/core/storage/selection.js +87 -0
- package/dist/core/storage/selection.js.map +1 -0
- package/dist/core/storage/session/conformance.d.ts +12 -0
- package/dist/core/storage/session/conformance.d.ts.map +1 -0
- package/dist/core/storage/session/conformance.js +674 -0
- package/dist/core/storage/session/conformance.js.map +1 -0
- package/dist/core/storage/session/entry-structure.d.ts +4 -0
- package/dist/core/storage/session/entry-structure.d.ts.map +1 -0
- package/dist/core/storage/session/entry-structure.js +83 -0
- package/dist/core/storage/session/entry-structure.js.map +1 -0
- package/dist/core/storage/session/errors.d.ts +54 -0
- package/dist/core/storage/session/errors.d.ts.map +1 -0
- package/dist/core/storage/session/errors.js +95 -0
- package/dist/core/storage/session/errors.js.map +1 -0
- package/dist/core/storage/session/jsonl-session-store.d.ts +72 -0
- package/dist/core/storage/session/jsonl-session-store.d.ts.map +1 -0
- package/dist/core/storage/session/jsonl-session-store.js +564 -0
- package/dist/core/storage/session/jsonl-session-store.js.map +1 -0
- package/dist/core/storage/session/legacy-format.d.ts +20 -0
- package/dist/core/storage/session/legacy-format.d.ts.map +1 -0
- package/dist/core/storage/session/legacy-format.js +89 -0
- package/dist/core/storage/session/legacy-format.js.map +1 -0
- package/dist/core/storage/session/legacy-session-store.d.ts +63 -0
- package/dist/core/storage/session/legacy-session-store.d.ts.map +1 -0
- package/dist/core/storage/session/legacy-session-store.js +239 -0
- package/dist/core/storage/session/legacy-session-store.js.map +1 -0
- package/dist/core/storage/session/legacy-session-summary.d.ts +11 -0
- package/dist/core/storage/session/legacy-session-summary.d.ts.map +1 -0
- package/dist/core/storage/session/legacy-session-summary.js +103 -0
- package/dist/core/storage/session/legacy-session-summary.js.map +1 -0
- package/dist/core/storage/session/memory-session-store.d.ts +33 -0
- package/dist/core/storage/session/memory-session-store.d.ts.map +1 -0
- package/dist/core/storage/session/memory-session-store.js +120 -0
- package/dist/core/storage/session/memory-session-store.js.map +1 -0
- package/dist/core/storage/session/scratch-directory.d.ts +2 -0
- package/dist/core/storage/session/scratch-directory.d.ts.map +1 -0
- package/dist/core/storage/session/scratch-directory.js +5 -0
- package/dist/core/storage/session/scratch-directory.js.map +1 -0
- package/dist/core/storage/session/session-summary.d.ts +24 -0
- package/dist/core/storage/session/session-summary.d.ts.map +1 -0
- package/dist/core/storage/session/session-summary.js +79 -0
- package/dist/core/storage/session/session-summary.js.map +1 -0
- package/dist/core/storage/session/sql-session-store.d.ts +49 -0
- package/dist/core/storage/session/sql-session-store.d.ts.map +1 -0
- package/dist/core/storage/session/sql-session-store.js +246 -0
- package/dist/core/storage/session/sql-session-store.js.map +1 -0
- package/dist/core/storage/session/types.d.ts +72 -0
- package/dist/core/storage/session/types.d.ts.map +1 -0
- package/dist/core/storage/session/types.js +2 -0
- package/dist/core/storage/session/types.js.map +1 -0
- package/dist/core/storage/session/validation.d.ts +7 -0
- package/dist/core/storage/session/validation.d.ts.map +1 -0
- package/dist/core/storage/session/validation.js +47 -0
- package/dist/core/storage/session/validation.js.map +1 -0
- package/dist/core/storage/testing.d.ts +15 -0
- package/dist/core/storage/testing.d.ts.map +1 -0
- package/dist/core/storage/testing.js +309 -0
- package/dist/core/storage/testing.js.map +1 -0
- package/dist/core/tasks/completion.d.ts.map +1 -1
- package/dist/core/tasks/completion.js +2 -4
- package/dist/core/tasks/completion.js.map +1 -1
- package/dist/core/tools/bash-session-environment.d.ts.map +1 -1
- package/dist/core/tools/bash-session-environment.js +0 -2
- package/dist/core/tools/bash-session-environment.js.map +1 -1
- package/dist/core/tools/read-url.d.ts.map +1 -1
- package/dist/core/tools/read-url.js +6 -1
- package/dist/core/tools/read-url.js.map +1 -1
- package/dist/core/tools/todos-model.js +3 -3
- package/dist/core/tools/todos-model.js.map +1 -1
- package/dist/core/tools/todos-mutations.js +2 -2
- package/dist/core/tools/todos-mutations.js.map +1 -1
- package/dist/core/tools/todos-render.js +1 -1
- package/dist/core/tools/todos-render.js.map +1 -1
- package/dist/core/tools/todos-storage.js +2 -2
- package/dist/core/tools/todos-storage.js.map +1 -1
- package/dist/extensions/codemode/execute.d.ts.map +1 -1
- package/dist/extensions/codemode/execute.js +14 -1
- package/dist/extensions/codemode/execute.js.map +1 -1
- package/dist/extensions/codemode/tool.d.ts +1 -1
- package/dist/extensions/codemode/tool.d.ts.map +1 -1
- package/dist/extensions/codemode/tool.js.map +1 -1
- package/dist/extensions/herdr/index.d.ts.map +1 -1
- package/dist/extensions/herdr/index.js +6 -8
- package/dist/extensions/herdr/index.js.map +1 -1
- package/dist/extensions/mcp/client/transports/streamable-http.js +9 -8
- package/dist/extensions/mcp/client/transports/streamable-http.js.map +1 -1
- package/dist/extensions/mcp/index.js +1 -1
- package/dist/extensions/mcp/index.js.map +1 -1
- package/dist/extensions/mcp/tools.d.ts.map +1 -1
- package/dist/extensions/mcp/tools.js +6 -1
- package/dist/extensions/mcp/tools.js.map +1 -1
- package/dist/index-extensions.d.ts +1 -1
- package/dist/index-extensions.d.ts.map +1 -1
- package/dist/index-extensions.js +1 -1
- package/dist/index-extensions.js.map +1 -1
- package/dist/index.d.ts +4 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +4 -1
- package/dist/index.js.map +1 -1
- package/dist/main-session.d.ts +12 -2
- package/dist/main-session.d.ts.map +1 -1
- package/dist/main-session.js +151 -53
- package/dist/main-session.js.map +1 -1
- package/dist/main.d.ts.map +1 -1
- package/dist/main.js +97 -42
- package/dist/main.js.map +1 -1
- package/dist/modes/interactive/components/chat-session-host-actions.d.ts +4 -0
- package/dist/modes/interactive/components/chat-session-host-actions.d.ts.map +1 -1
- package/dist/modes/interactive/components/chat-session-host-actions.js +104 -30
- package/dist/modes/interactive/components/chat-session-host-actions.js.map +1 -1
- package/dist/modes/interactive/components/chat-session-host-events.d.ts.map +1 -1
- package/dist/modes/interactive/components/chat-session-host-events.js +1 -0
- package/dist/modes/interactive/components/chat-session-host-events.js.map +1 -1
- package/dist/modes/interactive/components/chat-session-host-state.d.ts +4 -0
- package/dist/modes/interactive/components/chat-session-host-state.d.ts.map +1 -1
- package/dist/modes/interactive/components/chat-session-host-state.js +4 -0
- package/dist/modes/interactive/components/chat-session-host-state.js.map +1 -1
- package/dist/modes/interactive/components/chat-session-host.d.ts +3 -1
- package/dist/modes/interactive/components/chat-session-host.d.ts.map +1 -1
- package/dist/modes/interactive/components/chat-session-host.js +18 -5
- package/dist/modes/interactive/components/chat-session-host.js.map +1 -1
- package/dist/modes/interactive/components/extension-input.d.ts +1 -1
- package/dist/modes/interactive/components/extension-input.d.ts.map +1 -1
- package/dist/modes/interactive/components/extension-input.js +2 -2
- package/dist/modes/interactive/components/extension-input.js.map +1 -1
- package/dist/modes/interactive/components/host-session-picker.js +1 -1
- package/dist/modes/interactive/components/host-session-picker.js.map +1 -1
- package/dist/modes/interactive/components/scoped-models-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/scoped-models-selector.js +9 -5
- package/dist/modes/interactive/components/scoped-models-selector.js.map +1 -1
- package/dist/modes/interactive/components/session-selector-delete.d.ts +1 -1
- package/dist/modes/interactive/components/session-selector-delete.d.ts.map +1 -1
- package/dist/modes/interactive/components/session-selector-delete.js.map +1 -1
- package/dist/modes/interactive/components/session-selector-list.d.ts +12 -9
- package/dist/modes/interactive/components/session-selector-list.d.ts.map +1 -1
- package/dist/modes/interactive/components/session-selector-list.js +27 -25
- package/dist/modes/interactive/components/session-selector-list.js.map +1 -1
- package/dist/modes/interactive/components/session-selector.d.ts +8 -4
- package/dist/modes/interactive/components/session-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/session-selector.js +31 -21
- package/dist/modes/interactive/components/session-selector.js.map +1 -1
- package/dist/modes/interactive/components/tree-selector-component.d.ts +5 -1
- package/dist/modes/interactive/components/tree-selector-component.d.ts.map +1 -1
- package/dist/modes/interactive/components/tree-selector-component.js +20 -3
- package/dist/modes/interactive/components/tree-selector-component.js.map +1 -1
- package/dist/modes/interactive/interactive-bash-compact.js +1 -1
- package/dist/modes/interactive/interactive-bash-compact.js.map +1 -1
- package/dist/modes/interactive/interactive-deferred-startup.js +2 -2
- package/dist/modes/interactive/interactive-deferred-startup.js.map +1 -1
- package/dist/modes/interactive/interactive-editor-actions.js +2 -2
- package/dist/modes/interactive/interactive-editor-actions.js.map +1 -1
- package/dist/modes/interactive/interactive-extension-runtime.js +2 -0
- package/dist/modes/interactive/interactive-extension-runtime.js.map +1 -1
- package/dist/modes/interactive/interactive-input-handling.js +14 -6
- package/dist/modes/interactive/interactive-input-handling.js.map +1 -1
- package/dist/modes/interactive/interactive-mode-base.d.ts +4 -0
- package/dist/modes/interactive/interactive-mode-base.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-mode-base.js +6 -1
- package/dist/modes/interactive/interactive-mode-base.js.map +1 -1
- package/dist/modes/interactive/interactive-mode-helpers.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-mode-helpers.js +7 -3
- package/dist/modes/interactive/interactive-mode-helpers.js.map +1 -1
- package/dist/modes/interactive/interactive-mode-surface.d.ts +5 -5
- package/dist/modes/interactive/interactive-mode-surface.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-mode-surface.js.map +1 -1
- package/dist/modes/interactive/interactive-model-routing.js +12 -7
- package/dist/modes/interactive/interactive-model-routing.js.map +1 -1
- package/dist/modes/interactive/interactive-process-lifecycle.js +8 -2
- package/dist/modes/interactive/interactive-process-lifecycle.js.map +1 -1
- package/dist/modes/interactive/interactive-queueing.js +94 -70
- package/dist/modes/interactive/interactive-queueing.js.map +1 -1
- package/dist/modes/interactive/interactive-selectors.js +2 -2
- package/dist/modes/interactive/interactive-selectors.js.map +1 -1
- package/dist/modes/interactive/interactive-session-routing.js +38 -14
- package/dist/modes/interactive/interactive-session-routing.js.map +1 -1
- package/dist/modes/interactive/interactive-session-runtime.js +7 -0
- package/dist/modes/interactive/interactive-session-runtime.js.map +1 -1
- package/dist/modes/interactive/interactive-slash-commands.js +5 -3
- package/dist/modes/interactive/interactive-slash-commands.js.map +1 -1
- package/dist/modes/interactive/interactive-tui.d.ts +1 -0
- package/dist/modes/interactive/interactive-tui.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-tui.js +9 -2
- package/dist/modes/interactive/interactive-tui.js.map +1 -1
- package/dist/modes/interactive/program-status-reporter.d.ts +4 -0
- package/dist/modes/interactive/program-status-reporter.d.ts.map +1 -1
- package/dist/modes/interactive/program-status-reporter.js +45 -6
- package/dist/modes/interactive/program-status-reporter.js.map +1 -1
- package/dist/modes/interactive-engine/create-isolated-runtime.d.ts.map +1 -1
- package/dist/modes/interactive-engine/create-isolated-runtime.js +8 -1
- package/dist/modes/interactive-engine/create-isolated-runtime.js.map +1 -1
- package/dist/modes/interactive-engine/engine-args.d.ts.map +1 -1
- package/dist/modes/interactive-engine/engine-args.js +11 -4
- package/dist/modes/interactive-engine/engine-args.js.map +1 -1
- package/dist/modes/interactive-engine/extension-ui-bridge.d.ts +2 -1
- package/dist/modes/interactive-engine/extension-ui-bridge.d.ts.map +1 -1
- package/dist/modes/interactive-engine/extension-ui-bridge.js +9 -1
- package/dist/modes/interactive-engine/extension-ui-bridge.js.map +1 -1
- package/dist/modes/interactive-engine/isolated-runtime.d.ts +1 -1
- package/dist/modes/interactive-engine/isolated-runtime.d.ts.map +1 -1
- package/dist/modes/interactive-engine/isolated-runtime.js +99 -74
- package/dist/modes/interactive-engine/isolated-runtime.js.map +1 -1
- package/dist/modes/interactive-engine/protocol.d.ts +4 -0
- package/dist/modes/interactive-engine/protocol.d.ts.map +1 -1
- package/dist/modes/interactive-engine/protocol.js +39 -1
- package/dist/modes/interactive-engine/protocol.js.map +1 -1
- package/dist/modes/rpc/rpc-bash-request-owners.js +1 -1
- package/dist/modes/rpc/rpc-bash-request-owners.js.map +1 -1
- package/dist/modes/rpc/rpc-client-api.d.ts +1 -1
- package/dist/modes/rpc/rpc-client-api.d.ts.map +1 -1
- package/dist/modes/rpc/rpc-client-api.js +2 -2
- package/dist/modes/rpc/rpc-client-api.js.map +1 -1
- package/dist/modes/rpc/rpc-client-process.d.ts +2 -2
- package/dist/modes/rpc/rpc-client-process.d.ts.map +1 -1
- package/dist/modes/rpc/rpc-client-process.js +20 -7
- package/dist/modes/rpc/rpc-client-process.js.map +1 -1
- package/dist/modes/rpc/rpc-client.d.ts +4 -1
- package/dist/modes/rpc/rpc-client.d.ts.map +1 -1
- package/dist/modes/rpc/rpc-client.js +6 -2
- package/dist/modes/rpc/rpc-client.js.map +1 -1
- package/dist/modes/rpc/rpc-command-handler.d.ts.map +1 -1
- package/dist/modes/rpc/rpc-command-handler.js +12 -9
- package/dist/modes/rpc/rpc-command-handler.js.map +1 -1
- package/dist/modes/rpc/rpc-provider-auth.js +2 -2
- package/dist/modes/rpc/rpc-provider-auth.js.map +1 -1
- package/dist/modes/rpc/rpc-session-binding.d.ts.map +1 -1
- package/dist/modes/rpc/rpc-session-binding.js +10 -0
- package/dist/modes/rpc/rpc-session-binding.js.map +1 -1
- package/dist/modes/rpc/rpc-terminal-drain.d.ts.map +1 -1
- package/dist/modes/rpc/rpc-terminal-drain.js +11 -2
- package/dist/modes/rpc/rpc-terminal-drain.js.map +1 -1
- package/dist/modes/rpc/rpc-types.d.ts +6 -2
- package/dist/modes/rpc/rpc-types.d.ts.map +1 -1
- package/dist/modes/rpc/rpc-types.js.map +1 -1
- package/dist/utils/canonical-path.d.ts +5 -0
- package/dist/utils/canonical-path.d.ts.map +1 -0
- package/dist/utils/canonical-path.js +26 -0
- package/dist/utils/canonical-path.js.map +1 -0
- package/dist/utils/paths.d.ts +1 -7
- package/dist/utils/paths.d.ts.map +1 -1
- package/dist/utils/paths.js +1 -15
- package/dist/utils/paths.js.map +1 -1
- package/docs/codemode.md +2 -0
- package/docs/compaction.md +2 -2
- package/docs/custom-provider/oauth.md +2 -2
- package/docs/custom-provider/override.md +3 -3
- package/docs/custom-provider/registration.md +7 -7
- package/docs/custom-provider/streaming.md +1 -1
- package/docs/custom-provider.md +5 -5
- package/docs/docs.json +7 -2
- package/docs/environment-variables.md +10 -2
- package/docs/extensions/api-reference.md +40 -19
- package/docs/extensions/authoring.md +1 -1
- package/docs/extensions/events.md +12 -8
- package/docs/extensions.md +2 -2
- package/docs/getting-started/installation.md +2 -4
- package/docs/json.md +1 -1
- package/docs/llama-cpp.md +94 -1
- package/docs/models/reference.md +2 -0
- package/docs/models-configuration.md +206 -0
- package/docs/models.md +11 -1
- package/docs/packages/authoring.md +1 -1
- package/docs/providers.md +9 -5
- package/docs/quickstart.md +2 -1
- package/docs/reference/cli.md +7 -3
- package/docs/rpc/protocol.md +10 -4
- package/docs/sdk/reference.md +16 -14
- package/docs/sdk/web-server.md +6 -7
- package/docs/sdk.md +67 -27
- package/docs/session-format.md +35 -34
- package/docs/sessions.md +52 -17
- package/docs/settings.md +35 -22
- package/docs/storage.md +387 -0
- package/docs/subagents.md +19 -6
- package/docs/usage.md +5 -2
- package/docs/workflows/api-reference.md +88 -62
- package/docs/workflows/authoring.md +2 -1
- package/docs/workflows/operations.md +32 -174
- package/docs/workflows/reliable-design.md +17 -17
- package/examples/extensions/bookmark.ts +2 -2
- package/examples/extensions/handoff.ts +2 -2
- package/examples/extensions/plan-mode/index.ts +15 -13
- package/examples/extensions/preset.ts +8 -8
- package/examples/extensions/session-name.ts +1 -1
- package/examples/extensions/snake.ts +3 -1
- package/examples/extensions/space-invaders.ts +3 -1
- package/examples/extensions/tic-tac-toe.ts +80 -80
- package/examples/sdk/11-sessions.ts +5 -5
- package/examples/sdk/13-session-runtime.ts +7 -7
- package/examples/sdk/README.md +1 -1
- package/npm-shrinkwrap.json +53 -469
- package/package.json +17 -9
- package/schemas/models.schema.json +62 -29
- package/schemas/settings.schema.json +138 -27
- package/dist/builtin/workflows/builtin/chunk-x6az1sxp.js +0 -8
- package/dist/builtin/workflows/builtin/chunk-ymwq372z.js +0 -11609
- package/dist/core/session-manager-migrations.d.ts +0 -11
- package/dist/core/session-manager-migrations.d.ts.map +0 -1
- package/dist/core/session-manager-migrations.js +0 -80
- package/dist/core/session-manager-migrations.js.map +0 -1
- package/docs/nvidia-rtx-llama-cpp.md +0 -101
|
@@ -7,7 +7,7 @@ Atomic accepts environment variables for configuration, provider credentials, an
|
|
|
7
7
|
| Atomic variable | Legacy alias | Purpose |
|
|
8
8
|
|---|---|---|
|
|
9
9
|
| `ATOMIC_CODING_AGENT_DIR` | `PI_CODING_AGENT_DIR` | Agent/config directory; default `~/.atomic/agent` |
|
|
10
|
-
| `ATOMIC_CODING_AGENT_SESSION_DIR` |
|
|
10
|
+
| `ATOMIC_CODING_AGENT_SESSION_DIR` | None | Non-empty value selects a JSONL session directory; `--session-dir` and `--no-session` take precedence. Without a selection, sessions use the shared local SQLite database. |
|
|
11
11
|
| `ATOMIC_PACKAGE_DIR` | `PI_PACKAGE_DIR` | Package directory override |
|
|
12
12
|
| `ATOMIC_OFFLINE` | `PI_OFFLINE` | Disable automatic network activity, including update checks, package updates, telemetry, and model catalog refreshes |
|
|
13
13
|
| `ATOMIC_SKIP_VERSION_CHECK` | `PI_SKIP_VERSION_CHECK` | Skip automatic startup version checks; explicit self-update still checks |
|
|
@@ -15,6 +15,7 @@ Atomic accepts environment variables for configuration, provider credentials, an
|
|
|
15
15
|
| `ATOMIC_REDUCED_MOTION` | `PI_REDUCED_MOTION` | Use static reduced-motion presentation |
|
|
16
16
|
| `ATOMIC_EXPERIMENTAL` | `PI_EXPERIMENTAL` | Set to `1` to enable experimental features and preferred strict JSON-schema constrained sampling for additional built-in tools; `read`, `edit`, `write`, `bash`, and PowerShell already prefer strict sampling by default. The footer shows an `xp` badge |
|
|
17
17
|
| `ATOMIC_CLIPBOARD_OSC52` | `PI_CLIPBOARD_OSC52` | Set to `1` to also send copied text to the terminal with OSC 52 after the local clipboard write, as Atomic does over SSH. Use it when a remote client reaches Atomic without SSH variables, such as a multiplexer attached from another machine or a remote IDE daemon |
|
|
18
|
+
| `ATOMIC_WORKFLOW_JOURNAL_PATH` | None | Non-empty value selects the local SQLite workflow journal file; overrides `workflows.journal` settings, but not SDK `RunOpts.journal` |
|
|
18
19
|
|
|
19
20
|
`VISUAL` and `EDITOR` select the Ctrl+G external editor when `externalEditor` is unset.
|
|
20
21
|
|
|
@@ -24,6 +25,12 @@ The renderer also owns `PI_HYPERLINKS`, `PI_IMAGE_PROTOCOL`, and `PI_TRUE_COLOR`
|
|
|
24
25
|
|
|
25
26
|
`PI_PROGRAM_STATUS=1` forces OSC 7501 program-status reports; `0` disables them. Otherwise Atomic reports only after the terminal confirms support. This renderer-owned variable has no `ATOMIC_*` alias. See [Program status](/terminal-setup#program-status).
|
|
26
27
|
|
|
28
|
+
## Workflow journal
|
|
29
|
+
|
|
30
|
+
Sessions and workflow runs default to the same local SQLite file, `~/.atomic/workflows/journal.sqlite`, with `session_` and `wf_` table prefixes. With a custom `ATOMIC_CODING_AGENT_DIR`, the file is `workflows/journal.sqlite` under the agent directory's parent. `ATOMIC_WORKFLOW_JOURNAL_PATH` changes the workflow journal only; `ATOMIC_CODING_AGENT_SESSION_DIR` selects JSONL for sessions only. Relative environment paths resolve against the working directory, and empty values leave settings in effect.
|
|
31
|
+
|
|
32
|
+
In `settings.json`, shared `storage` selects a database for both domains; `sessions.storage` and `workflows.journal` override their respective domains. Relative settings paths resolve against Atomic home. To select process-local memory explicitly, use `{ "memory": true }` in the appropriate selection. Memory cannot recover data after process exit and is never selected after a storage failure. See [Workflow storage](/settings#workflow-storage).
|
|
33
|
+
|
|
27
34
|
## Prompt-cache retention
|
|
28
35
|
|
|
29
36
|
Atomic defaults to **long** prompt-cache retention in main chat, workflow stages, and subagents wherever the provider/model supports it. `PI_CACHE_RETENTION` intentionally has no `ATOMIC_*` alias. Set it before launching Atomic to choose `short`, `none`, or `long`:
|
|
@@ -55,11 +62,12 @@ Every built-in, factory-created, direct, workflow-stage, and isolated bash or Po
|
|
|
55
62
|
| Atomic variable | Exact Pi alias | Value |
|
|
56
63
|
|---|---|---|
|
|
57
64
|
| `ATOMIC_SESSION_ID` | `PI_SESSION_ID` | Active session ID |
|
|
58
|
-
| `ATOMIC_SESSION_FILE` | `PI_SESSION_FILE` | Active JSONL file; omitted for unsaved/ephemeral sessions |
|
|
59
65
|
| `ATOMIC_PROVIDER` | `PI_PROVIDER` | Active provider; omitted when no model is selected |
|
|
60
66
|
| `ATOMIC_MODEL` | `PI_MODEL` | Active model ID; omitted when no model is selected |
|
|
61
67
|
| `ATOMIC_REASONING_LEVEL` | `PI_REASONING_LEVEL` | Active reasoning level |
|
|
62
68
|
|
|
63
69
|
Atomic clears these ten reserved names before overlaying the current snapshot, preventing stale metadata from another session or workflow stage. Unrelated inherited/caller variables remain intact. The snapshot is taken when execution begins, so a resumed session or later model change is reflected. SDK `createBashTool()` and `createPowerShellTool()` expose it by default; set `exposeSessionEnvironment: false` to opt out.
|
|
64
70
|
|
|
71
|
+
`ATOMIC_SESSION_FILE` and `PI_SESSION_FILE` are no longer supplied. Session IDs identify records within the selected store; a database location or JSONL path is only display metadata.
|
|
72
|
+
|
|
65
73
|
See [Using Atomic](/reference/cli#environment-variables) and [RPC direct bash](/rpc/protocol#bash) for execution and streaming behavior.
|
|
@@ -137,6 +137,25 @@ pi.on("tool_result", async (event, ctx) => {
|
|
|
137
137
|
});
|
|
138
138
|
```
|
|
139
139
|
|
|
140
|
+
### ctx.sessionSignal
|
|
141
|
+
|
|
142
|
+
A read-only `AbortSignal` for the session lifetime, available even while the agent is idle. It aborts when reload or shutdown begins, **before** Atomic drains admitted commands and emits `session_shutdown`. Unlike `ctx.signal`, it does not end when an agent turn finishes. A replacement session generation receives a new signal.
|
|
143
|
+
|
|
144
|
+
Custom UI mounted through `ctx.ui.custom` is dismissed automatically when the session ends; an explicit caller signal can still dismiss it earlier. Use `ctx.sessionSignal` for other long-running command resources, such as browser windows, instead of waiting for `session_shutdown`, which cannot run until those commands settle. Cancellation should stop waiting for input, not abandon a session write already started: keep awaiting that write so teardown can drain it safely.
|
|
145
|
+
|
|
146
|
+
```typescript
|
|
147
|
+
import { Text } from "@earendil-works/pi-tui";
|
|
148
|
+
|
|
149
|
+
pi.registerCommand("monitor", {
|
|
150
|
+
description: "Keep a monitor open until the session ends",
|
|
151
|
+
handler: async (_args, ctx) => {
|
|
152
|
+
await ctx.ui.custom(() => new Text("Monitoring; reload or quit to close."), {
|
|
153
|
+
signal: ctx.sessionSignal,
|
|
154
|
+
});
|
|
155
|
+
},
|
|
156
|
+
});
|
|
157
|
+
```
|
|
158
|
+
|
|
140
159
|
### ctx.isIdle() / ctx.abort() / ctx.hasPendingMessages()
|
|
141
160
|
|
|
142
161
|
Control flow helpers.
|
|
@@ -261,13 +280,13 @@ pi.registerCommand("my-cmd", {
|
|
|
261
280
|
Create a new session:
|
|
262
281
|
|
|
263
282
|
```typescript
|
|
264
|
-
const parentSession = ctx.sessionManager.
|
|
283
|
+
const parentSession = ctx.sessionManager.getSessionId();
|
|
265
284
|
const kickoff = "Continue in the replacement session";
|
|
266
285
|
|
|
267
286
|
const result = await ctx.newSession({
|
|
268
287
|
parentSession,
|
|
269
288
|
setup: async (sm) => {
|
|
270
|
-
sm.appendMessage({
|
|
289
|
+
await sm.appendMessage({
|
|
271
290
|
role: "user",
|
|
272
291
|
content: [{ type: "text", text: "Context from previous session..." }],
|
|
273
292
|
timestamp: Date.now(),
|
|
@@ -285,7 +304,7 @@ if (result.cancelled) {
|
|
|
285
304
|
```
|
|
286
305
|
|
|
287
306
|
Options:
|
|
288
|
-
- `parentSession`: parent session
|
|
307
|
+
- `parentSession`: parent session ID to record in the new session header
|
|
289
308
|
- `setup`: mutate the new session's `SessionManager` before `withSession` runs
|
|
290
309
|
- `withSession`: run post-switch work against a fresh replacement-session context. Do not use captured old `pi` / command `ctx`; see [Session replacement lifecycle and footguns](#session-replacement-lifecycle-and-footguns).
|
|
291
310
|
|
|
@@ -334,12 +353,12 @@ Options:
|
|
|
334
353
|
- `replaceInstructions`: If true, `customInstructions` replaces the default prompt instead of being appended
|
|
335
354
|
- `label`: Label to attach to the branch summary entry (or target entry if not summarizing)
|
|
336
355
|
|
|
337
|
-
### ctx.switchSession(
|
|
356
|
+
### ctx.switchSession(sessionId, options?)
|
|
338
357
|
|
|
339
|
-
Switch to a different session
|
|
358
|
+
Switch to a different session by its exact ID:
|
|
340
359
|
|
|
341
360
|
```typescript
|
|
342
|
-
const result = await ctx.switchSession("
|
|
361
|
+
const result = await ctx.switchSession("my-session-id", {
|
|
343
362
|
withSession: async (ctx) => {
|
|
344
363
|
await ctx.sendUserMessage("Resume work in the replacement session");
|
|
345
364
|
},
|
|
@@ -364,7 +383,7 @@ pi.registerCommand("switch", {
|
|
|
364
383
|
if (sessions.length === 0) return;
|
|
365
384
|
const choice = await ctx.ui.select(
|
|
366
385
|
"Pick session:",
|
|
367
|
-
sessions.map(s => s.
|
|
386
|
+
sessions.map(s => s.id),
|
|
368
387
|
);
|
|
369
388
|
if (choice) {
|
|
370
389
|
await ctx.switchSession(choice, {
|
|
@@ -633,7 +652,7 @@ See [send-user-message.ts](https://github.com/bastani-inc/atomic/blob/main/packa
|
|
|
633
652
|
Persist extension state (does NOT participate in LLM context).
|
|
634
653
|
|
|
635
654
|
```typescript
|
|
636
|
-
pi.appendEntry("my-state", { count: 42 });
|
|
655
|
+
await pi.appendEntry("my-state", { count: 42 });
|
|
637
656
|
|
|
638
657
|
// Restore on reload
|
|
639
658
|
pi.on("session_start", async (_event, ctx) => {
|
|
@@ -645,7 +664,9 @@ pi.on("session_start", async (_event, ctx) => {
|
|
|
645
664
|
});
|
|
646
665
|
```
|
|
647
666
|
|
|
648
|
-
Appending emits `entry_appended` with the
|
|
667
|
+
Await `pi.appendEntry` before using the new entry. The promise resolves after the write commits and rejects with the store's typed error if it fails. Setup entries also commit before the promise resolves. Appending emits `entry_appended` with the committed entry. This lets extensions react to session entries without polling.
|
|
668
|
+
|
|
669
|
+
During a transactional reload's `session_start` handler, `pi.appendEntry`, `pi.setSessionName`, and `pi.setLabel` stage their writes instead. Awaiting them confirms staging; the writes and their notifications are published in call order only after reload succeeds. Rejected reloads discard these changes. Do not depend on reading the staged changes back during that handler.
|
|
649
670
|
|
|
650
671
|
### pi.registerEntryRenderer(customType, renderer)
|
|
651
672
|
|
|
@@ -667,7 +688,7 @@ pi.registerEntryRenderer("status-card", (entry, { expanded }, theme) =>
|
|
|
667
688
|
Set the session display name (shown in session selector instead of first message).
|
|
668
689
|
|
|
669
690
|
```typescript
|
|
670
|
-
pi.setSessionName("Refactor auth module");
|
|
691
|
+
await pi.setSessionName("Refactor auth module");
|
|
671
692
|
```
|
|
672
693
|
|
|
673
694
|
### pi.getSessionName()
|
|
@@ -687,10 +708,10 @@ Set or clear a label on an entry. Labels are user-defined markers for bookmarkin
|
|
|
687
708
|
|
|
688
709
|
```typescript
|
|
689
710
|
// Set a label
|
|
690
|
-
pi.setLabel(entryId, "checkpoint-before-refactor");
|
|
711
|
+
await pi.setLabel(entryId, "checkpoint-before-refactor");
|
|
691
712
|
|
|
692
713
|
// Clear a label
|
|
693
|
-
pi.setLabel(entryId, undefined);
|
|
714
|
+
await pi.setLabel(entryId, undefined);
|
|
694
715
|
|
|
695
716
|
// Read labels via sessionManager
|
|
696
717
|
const label = ctx.sessionManager.getLabel(entryId);
|
|
@@ -895,7 +916,7 @@ Get the current thinking level. Level is clamped to model capabilities (non-reas
|
|
|
895
916
|
|
|
896
917
|
```typescript
|
|
897
918
|
const current = pi.getThinkingLevel(); // "off" | "minimal" | "low" | "medium" | "high" | "xhigh" | "max"
|
|
898
|
-
pi.setThinkingLevel("high");
|
|
919
|
+
await pi.setThinkingLevel("high");
|
|
899
920
|
```
|
|
900
921
|
|
|
901
922
|
### pi.events
|
|
@@ -919,7 +940,7 @@ In addition to `registerProvider(name, config)`, extensions can register a compl
|
|
|
919
940
|
|
|
920
941
|
### pi.registerProvider(name, config)
|
|
921
942
|
|
|
922
|
-
Register or override a model provider dynamically. Useful for proxies, custom endpoints, or team-wide model configurations.
|
|
943
|
+
Register or override a model provider dynamically. Await registration, aliases, and removal before starting dependent work. Useful for proxies, custom endpoints, or team-wide model configurations.
|
|
923
944
|
|
|
924
945
|
Calls made during the extension factory function are queued and applied once the runner initialises. Calls made after that — for example from a command handler following a user setup flow — take effect immediately without requiring a `/reload`.
|
|
925
946
|
|
|
@@ -927,7 +948,7 @@ If you need to discover models from a remote endpoint, prefer an async extension
|
|
|
927
948
|
|
|
928
949
|
```typescript
|
|
929
950
|
// Register a new provider with custom models
|
|
930
|
-
pi.registerProvider("my-proxy", {
|
|
951
|
+
await pi.registerProvider("my-proxy", {
|
|
931
952
|
name: "My Proxy",
|
|
932
953
|
baseUrl: "https://proxy.example.com",
|
|
933
954
|
apiKey: "$PROXY_API_KEY", // env var reference; omit $ for a literal
|
|
@@ -946,12 +967,12 @@ pi.registerProvider("my-proxy", {
|
|
|
946
967
|
});
|
|
947
968
|
|
|
948
969
|
// Override baseUrl for an existing provider (keeps all models)
|
|
949
|
-
pi.registerProvider("anthropic", {
|
|
970
|
+
await pi.registerProvider("anthropic", {
|
|
950
971
|
baseUrl: "https://proxy.example.com"
|
|
951
972
|
});
|
|
952
973
|
|
|
953
974
|
// Register provider with OAuth support for /login
|
|
954
|
-
pi.registerProvider("corporate-ai", {
|
|
975
|
+
await pi.registerProvider("corporate-ai", {
|
|
955
976
|
baseUrl: "https://ai.corp.com",
|
|
956
977
|
api: "openai-responses",
|
|
957
978
|
models: [...],
|
|
@@ -976,7 +997,7 @@ pi.registerProvider("corporate-ai", {
|
|
|
976
997
|
});
|
|
977
998
|
|
|
978
999
|
// Register provider-owned API-key setup for /login
|
|
979
|
-
pi.registerProvider("local-server", {
|
|
1000
|
+
await pi.registerProvider("local-server", {
|
|
980
1001
|
name: "Local Server",
|
|
981
1002
|
auth: {
|
|
982
1003
|
apiKey: {
|
|
@@ -1021,7 +1042,7 @@ Like `registerProvider`, this takes effect immediately when called after the ini
|
|
|
1021
1042
|
pi.registerCommand("my-setup-teardown", {
|
|
1022
1043
|
description: "Remove the custom proxy provider",
|
|
1023
1044
|
handler: async (_args, _ctx) => {
|
|
1024
|
-
pi.unregisterProvider("my-proxy");
|
|
1045
|
+
await pi.unregisterProvider("my-proxy");
|
|
1025
1046
|
},
|
|
1026
1047
|
});
|
|
1027
1048
|
```
|
|
@@ -56,7 +56,7 @@ export default async function (pi: ExtensionAPI) {
|
|
|
56
56
|
}>;
|
|
57
57
|
};
|
|
58
58
|
|
|
59
|
-
pi.registerProvider("local-openai", {
|
|
59
|
+
await pi.registerProvider("local-openai", {
|
|
60
60
|
baseUrl: "http://localhost:1234/v1",
|
|
61
61
|
apiKey: "$LOCAL_OPENAI_API_KEY",
|
|
62
62
|
api: "openai-completions",
|
|
@@ -59,13 +59,13 @@ user sends another prompt ◄─────────────────
|
|
|
59
59
|
/new (new session) or /resume (switch session)
|
|
60
60
|
├─► session_before_switch (can cancel)
|
|
61
61
|
├─► session_shutdown
|
|
62
|
-
├─► session_start { reason: "new" | "resume",
|
|
62
|
+
├─► session_start { reason: "new" | "resume", previousSessionId? }
|
|
63
63
|
└─► resources_discover { reason: "startup" }
|
|
64
64
|
|
|
65
65
|
/fork or /clone
|
|
66
66
|
├─► session_before_fork (can cancel)
|
|
67
67
|
├─► session_shutdown
|
|
68
|
-
├─► session_start { reason: "fork",
|
|
68
|
+
├─► session_start { reason: "fork", previousSessionId }
|
|
69
69
|
└─► resources_discover { reason: "startup" }
|
|
70
70
|
|
|
71
71
|
/compact or auto-compaction
|
|
@@ -141,8 +141,8 @@ Fired when a session is started, loaded, or reloaded.
|
|
|
141
141
|
```typescript
|
|
142
142
|
pi.on("session_start", async (event, ctx) => {
|
|
143
143
|
// event.reason - "startup" | "reload" | "new" | "resume" | "fork"
|
|
144
|
-
// event.
|
|
145
|
-
ctx.ui.notify(`Session: ${ctx.sessionManager.
|
|
144
|
+
// event.previousSessionId - present for "new", "resume", and "fork"
|
|
145
|
+
ctx.ui.notify(`Session: ${ctx.sessionManager.getSessionId()}`, "info");
|
|
146
146
|
});
|
|
147
147
|
```
|
|
148
148
|
|
|
@@ -164,7 +164,7 @@ Fired before starting a new session (`/new`) or switching sessions (`/resume`).
|
|
|
164
164
|
```typescript
|
|
165
165
|
pi.on("session_before_switch", async (event, ctx) => {
|
|
166
166
|
// event.reason - "new" or "resume"
|
|
167
|
-
// event.
|
|
167
|
+
// event.targetSessionId - session we're switching to (only for "resume")
|
|
168
168
|
|
|
169
169
|
if (event.reason === "new") {
|
|
170
170
|
const ok = await ctx.ui.confirm("Clear?", "Delete all messages?");
|
|
@@ -173,7 +173,7 @@ pi.on("session_before_switch", async (event, ctx) => {
|
|
|
173
173
|
});
|
|
174
174
|
```
|
|
175
175
|
|
|
176
|
-
After a successful switch or new-session action, Atomic emits `session_shutdown` for the old extension instance, reloads and rebinds extensions for the new session, then emits `session_start` with `reason: "new" | "resume"` and `
|
|
176
|
+
After a successful switch or new-session action, Atomic emits `session_shutdown` for the old extension instance, reloads and rebinds extensions for the new session, then emits `session_start` with `reason: "new" | "resume"` and `previousSessionId`.
|
|
177
177
|
Do cleanup work in `session_shutdown`, then reestablish any in-memory state in `session_start`.
|
|
178
178
|
|
|
179
179
|
#### session_before_fork
|
|
@@ -190,7 +190,7 @@ pi.on("session_before_fork", async (event, ctx) => {
|
|
|
190
190
|
});
|
|
191
191
|
```
|
|
192
192
|
|
|
193
|
-
After a successful fork or clone, Atomic emits `session_shutdown` for the old extension instance, reloads and rebinds extensions for the new session, then emits `session_start` with `reason: "fork"` and `
|
|
193
|
+
After a successful fork or clone, Atomic emits `session_shutdown` for the old extension instance, reloads and rebinds extensions for the new session, then emits `session_start` with `reason: "fork"` and `previousSessionId`.
|
|
194
194
|
Do cleanup work in `session_shutdown`, then reestablish any in-memory state in `session_start`.
|
|
195
195
|
|
|
196
196
|
#### session_before_compact / session_compact / session_compact_failed
|
|
@@ -259,7 +259,7 @@ Fired before a started session runtime is torn down. Use this to clean up resour
|
|
|
259
259
|
```typescript
|
|
260
260
|
pi.on("session_shutdown", async (event, ctx) => {
|
|
261
261
|
// event.reason - "quit" | "reload" | "new" | "resume" | "fork"
|
|
262
|
-
// event.
|
|
262
|
+
// event.targetSessionId - destination session for session replacement flows
|
|
263
263
|
// event.fromSignal - true when a "quit" came from a host SIGTERM/SIGHUP, not an explicit quit
|
|
264
264
|
// Cleanup, save state, etc.
|
|
265
265
|
});
|
|
@@ -511,6 +511,8 @@ Rules: keep a system message at index 0 (providers read the prompt and initial t
|
|
|
511
511
|
|
|
512
512
|
Fires after outgoing HTTP headers are assembled. Mutate `event.headers` to add, override, or remove headers. The event also identifies the provider and model.
|
|
513
513
|
|
|
514
|
+
When Atomic retries a request with credentials saved by another process after a credential rejection, this event fires again for the retry.
|
|
515
|
+
|
|
514
516
|
```typescript
|
|
515
517
|
pi.on("before_provider_headers", (event, ctx) => {
|
|
516
518
|
event.headers["x-session-id"] = ctx.sessionManager.getSessionId();
|
|
@@ -522,6 +524,8 @@ pi.on("before_provider_headers", (event, ctx) => {
|
|
|
522
524
|
|
|
523
525
|
Fired after the provider-specific payload is built, right before the request is sent. Handlers run in extension load order. Returning `undefined` keeps the payload unchanged. Returning any other value replaces the payload for later handlers and for the actual request.
|
|
524
526
|
|
|
527
|
+
Like `before_provider_headers`, it fires again when Atomic retries a request after a credential rejection.
|
|
528
|
+
|
|
525
529
|
This hook can rewrite provider-level system instructions or remove them entirely. Those payload-level changes are not reflected by `ctx.getSystemPrompt()`, which reports Atomic's system prompt string rather than the final serialized provider payload.
|
|
526
530
|
|
|
527
531
|
```typescript
|
package/docs/extensions.md
CHANGED
|
@@ -498,9 +498,9 @@ Moved to [Extension API reference](/extensions/api-reference#ctx-fork-entryid-op
|
|
|
498
498
|
|
|
499
499
|
Moved to [Extension API reference](/extensions/api-reference#ctx-navigatetree-targetid-options).
|
|
500
500
|
|
|
501
|
-
### ctx.switchSession(
|
|
501
|
+
### ctx.switchSession(sessionId, options?)
|
|
502
502
|
|
|
503
|
-
Moved to [Extension API reference](/extensions/api-reference#ctx-switchsession-
|
|
503
|
+
Moved to [Extension API reference](/extensions/api-reference#ctx-switchsession-sessionid-options).
|
|
504
504
|
|
|
505
505
|
### Session replacement lifecycle and footguns
|
|
506
506
|
|
|
@@ -33,11 +33,10 @@ bun add -g @bastani/atomic
|
|
|
33
33
|
|
|
34
34
|
Atomic does not require package install scripts. Add `--ignore-scripts` if you want to disable dependency lifecycle scripts during a package install.
|
|
35
35
|
|
|
36
|
-
|
|
36
|
+
Workflow persistence uses a local SQLite journal by default. No database server or separate database installation is needed. The default file is `~/.atomic/workflows/journal.sqlite`; configure another location with `ATOMIC_WORKFLOW_JOURNAL_PATH` or the [workflow storage settings](/settings#workflow-storage). To share runs across machines, see [Sharing storage across hosts](/storage#sharing-storage-across-hosts).
|
|
37
37
|
|
|
38
38
|
Keep a standalone archive's complete directory, including `node_modules`, libraries, and licenses. Package managers select the runtime for your platform automatically.
|
|
39
39
|
|
|
40
|
-
Windows ARM64 uses Windows x64 PostgreSQL under Windows 11's x64 emulation, not native PostgreSQL ARM64. It requires the Microsoft Visual C++ x64 v14 Redistributable. Windows 10 on ARM cannot run this x64 runtime, and Windows ARM64 execution still needs hardware validation.
|
|
41
40
|
|
|
42
41
|
### Release archive
|
|
43
42
|
|
|
@@ -103,10 +102,9 @@ How you install Atomic decides which runtime hosts it: a package-manager install
|
|
|
103
102
|
|
|
104
103
|
The shell installer detects Alpine and selects `atomic-linux-x64-musl.tar.gz` or `atomic-linux-arm64-musl.tar.gz`. Keep the complete archive, including payload-local `libgcc` and `libstdc++`; stock Alpine needs no runtime package install.
|
|
105
104
|
|
|
106
|
-
|
|
105
|
+
Clipboard setup depends on your environment:
|
|
107
106
|
|
|
108
107
|
- **Clipboard:** install `wl-clipboard` on Wayland, `xclip` or `xsel` on X11, or the Termux:API app and `termux-api` package on Termux. OSC 52 forwards copies over SSH or Mosh and is a fallback on headless Linux. Set `ATOMIC_CLIPBOARD_OSC52=1`, or the legacy `PI_CLIPBOARD_OSC52=1`, to force terminal forwarding. Your terminal must support it; forwarding does not confirm a successful local clipboard write.
|
|
109
|
-
- **Durable workflows:** PostgreSQL is included and provisions offline without Docker or external Postgres. If no durable backend can be provisioned, Atomic warns and uses non-durable in-memory storage.
|
|
110
108
|
|
|
111
109
|
Then start Atomic in the project directory you want it to work on:
|
|
112
110
|
|
package/docs/json.md
CHANGED
|
@@ -106,7 +106,7 @@ Extended messages from [`packages/coding-agent/src/core/messages.ts`](https://gi
|
|
|
106
106
|
Each line is a JSON object. The first line is the session header:
|
|
107
107
|
|
|
108
108
|
```json
|
|
109
|
-
{"type":"session","version":
|
|
109
|
+
{"type":"session","version":4,"id":"uuid","timestamp":"...","cwd":"/path"}
|
|
110
110
|
```
|
|
111
111
|
|
|
112
112
|
Followed by events as they occur:
|
package/docs/llama-cpp.md
CHANGED
|
@@ -32,7 +32,7 @@ llama-server \
|
|
|
32
32
|
|
|
33
33
|
Single-file models can sit directly in the model directory. Put multimodal and multi-shard models in separate subdirectories with their projection or shard files. Restart the router after manually adding files. Per-model context sizes and other options can be set with [model presets](https://github.com/ggml-org/llama.cpp/blob/master/tools/server/README.md#model-presets).
|
|
34
34
|
|
|
35
|
-
For settings tuned to a specific NVIDIA GPU and model, see [
|
|
35
|
+
For settings tuned to a specific NVIDIA GPU and model, see [NVIDIA RTX recipes](#nvidia-rtx-recipes).
|
|
36
36
|
|
|
37
37
|
## Configure Atomic
|
|
38
38
|
|
|
@@ -70,6 +70,99 @@ If the router disconnects, choose **Retry** to reconnect and refresh state witho
|
|
|
70
70
|
|
|
71
71
|
Each llama model uses the router-reported loaded context (`meta.n_ctx`, then training context, otherwise Atomic's fallback) for both `contextWindow` and `maxTokens`; Atomic no longer applies a separate 16K output cap. The server remains authoritative and may impose a smaller practical generation limit.
|
|
72
72
|
|
|
73
|
+
## NVIDIA RTX recipes
|
|
74
|
+
|
|
75
|
+
[NVIDIA Local AI Inference Recipes](https://nvidia.github.io/local-ai-inference-recipes/index.html) provides llama.cpp settings tuned for specific NVIDIA hardware and models. Each recipe gives a single-model `llama-server` command. Convert it into a router preset so the router can serve it alongside other models. The examples below use Windows PowerShell.
|
|
76
|
+
|
|
77
|
+
### Before you begin
|
|
78
|
+
|
|
79
|
+
1. Open the [recipe catalog](https://nvidia.github.io/local-ai-inference-recipes/index.html), select your hardware, operating system, and model, then choose **llama.cpp**. Check the prerequisites and memory requirements. Keep the recipe's launch command for the conversion below.
|
|
80
|
+
2. Install llama.cpp with the recipe's setup instructions. The recipe's settings depend on its build, for example CUDA support or speculative decoding options.
|
|
81
|
+
3. Run `llama-server --help` and check that it lists `--models-preset`. Without it, the build cannot load the recipe as a router preset. Use a newer build that still meets the recipe's requirements.
|
|
82
|
+
4. Install Atomic with the [Quickstart](/quickstart). On native Windows, also see [Run Atomic on Windows](/windows).
|
|
83
|
+
|
|
84
|
+
### Convert the recipe to a preset
|
|
85
|
+
|
|
86
|
+
A preset lists the settings for one or more models. Each section name becomes the model ID shown in Atomic. Save the preset next to `llama-server`, or pass its full path when starting the router.
|
|
87
|
+
|
|
88
|
+
Convert each option from the recipe command into one preset line:
|
|
89
|
+
|
|
90
|
+
- Remove the leading dashes: `--ctx-size 65536` becomes `ctx-size = 65536`.
|
|
91
|
+
- Write options without a value as `true`: `--jinja` becomes `jinja = true`.
|
|
92
|
+
- Remove quotes and PowerShell line-continuation backticks around values.
|
|
93
|
+
- Leave out `--host` and `--port`. They belong on the router command line.
|
|
94
|
+
- Add `load-on-startup = true` so the router loads the model when it starts.
|
|
95
|
+
- Replace short model-file options with their long preset keys:
|
|
96
|
+
|
|
97
|
+
| Recipe option | Preset key |
|
|
98
|
+
|---|---|
|
|
99
|
+
| `-hf` | `hf-repo` |
|
|
100
|
+
| `-hff` | `hf-file` |
|
|
101
|
+
| `-hfrd` | `hf-repo-draft` |
|
|
102
|
+
| `--spec-draft-model` | `spec-draft-model` |
|
|
103
|
+
|
|
104
|
+
For example, this recipe command:
|
|
105
|
+
|
|
106
|
+
```powershell
|
|
107
|
+
llama-server.exe -hf "unsloth/Qwen3.8-27B-GGUF" `
|
|
108
|
+
-hff "Qwen3.8-27B-UD-Q4_K_M.gguf" `
|
|
109
|
+
-hfrd "z-lab/Qwen3.8-27B-DFlash2-GGUF" `
|
|
110
|
+
--spec-draft-model "Qwen3.8-27B-DFlash2-Q4_K_M.gguf" `
|
|
111
|
+
--no-mmproj `
|
|
112
|
+
--host 127.0.0.1 `
|
|
113
|
+
--port 9931 `
|
|
114
|
+
--batch-size 4096 `
|
|
115
|
+
--ubatch-size 1024 `
|
|
116
|
+
--ctx-size 65536 `
|
|
117
|
+
--parallel 1 `
|
|
118
|
+
-ngl 999 `
|
|
119
|
+
--jinja `
|
|
120
|
+
--chat-template-kwargs '{"preserve_thinking":true}' `
|
|
121
|
+
--spec-type draft-dflash `
|
|
122
|
+
--spec-draft-n-max 7 `
|
|
123
|
+
--spec-draft-backend-sampling
|
|
124
|
+
```
|
|
125
|
+
|
|
126
|
+
becomes `qwen3.8-27b.ini`:
|
|
127
|
+
|
|
128
|
+
```ini
|
|
129
|
+
version = 1
|
|
130
|
+
|
|
131
|
+
[qwen3.8-27b]
|
|
132
|
+
load-on-startup = true
|
|
133
|
+
hf-repo = unsloth/Qwen3.8-27B-GGUF
|
|
134
|
+
hf-file = Qwen3.8-27B-UD-Q4_K_M.gguf
|
|
135
|
+
hf-repo-draft = z-lab/Qwen3.8-27B-DFlash2-GGUF
|
|
136
|
+
spec-draft-model = Qwen3.8-27B-DFlash2-Q4_K_M.gguf
|
|
137
|
+
no-mmproj = true
|
|
138
|
+
batch-size = 4096
|
|
139
|
+
ubatch-size = 1024
|
|
140
|
+
ctx-size = 65536
|
|
141
|
+
parallel = 1
|
|
142
|
+
ngl = 999
|
|
143
|
+
jinja = true
|
|
144
|
+
chat-template-kwargs = {"preserve_thinking":true}
|
|
145
|
+
spec-type = draft-dflash
|
|
146
|
+
spec-draft-n-max = 7
|
|
147
|
+
spec-draft-backend-sampling = true
|
|
148
|
+
```
|
|
149
|
+
|
|
150
|
+
### Start the recipe router
|
|
151
|
+
|
|
152
|
+
Open PowerShell in the llama.cpp folder and run:
|
|
153
|
+
|
|
154
|
+
```powershell
|
|
155
|
+
.\llama-server.exe --models-preset qwen3.8-27b.ini --host 127.0.0.1 --port 8080
|
|
156
|
+
```
|
|
157
|
+
|
|
158
|
+
If the recipe requires a Hugging Face token, set `$env:HF_TOKEN` in the same PowerShell window before starting the router. On its first start, the router downloads the model files.
|
|
159
|
+
|
|
160
|
+
Use the [health checks](#troubleshooting) to confirm that the server is ready. In Windows PowerShell, use `curl.exe` rather than `curl`, which PowerShell maps to a different command. The model is ready when `/models` lists `qwen3.8-27b` with the status `loaded`.
|
|
161
|
+
|
|
162
|
+
Then follow [Configure Atomic](#configure-atomic) and connect to `http://127.0.0.1:8080`. The preset section name is the model ID, so select `qwen3.8-27b` in `/model` for this example.
|
|
163
|
+
|
|
164
|
+
NVIDIA recipe memory settings assume that only the selected model uses the GPU. If `/llama` shows other loaded models, unload them before using the recipe model.
|
|
165
|
+
|
|
73
166
|
## Classification
|
|
74
167
|
|
|
75
168
|
Classifier models answer typed `choice`, `bool`, and `score` questions about JSON state, like TypeSafe's Jev models, so a local model can make `model: "auto"` routing decisions. Extensions can call `ctx.modelRegistry.classify()` and codemode scripts can call `models.classify()`; see [Classifier models](/models#use-classifier-models). Atomic lists llama.cpp models as classifiers in two ways:
|
package/docs/models/reference.md
CHANGED
|
@@ -52,6 +52,8 @@ The `apiKey` and `headers` fields support three formats:
|
|
|
52
52
|
"apiKey": "sk-..."
|
|
53
53
|
```
|
|
54
54
|
|
|
55
|
+
In non-command values, `$$` produces a literal `$` and `$!` produces a literal `!`.
|
|
56
|
+
|
|
55
57
|
Legacy uppercase env-var-like values in existing `models.json` provider config, such as `MY_API_KEY`, are migrated to `$MY_API_KEY` on startup only when that environment variable is present during migration; otherwise the value is preserved as a literal. New configs should use explicit `$ENV_VAR`/`${ENV_VAR}` syntax for environment variables.
|
|
56
58
|
|
|
57
59
|
For `models.json`, shell commands are resolved at request time. Atomic intentionally does not apply built-in TTL, stale reuse, or recovery logic for arbitrary commands. Different commands need different caching and failure strategies, and Atomic cannot infer the right one.
|