@xrkseek/harness 0.4.3 → 0.4.5
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/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/node_modules/@xrkseek/a2a/README.md +43 -0
- package/node_modules/@xrkseek/a2a/dist/client.d.ts +35 -0
- package/node_modules/@xrkseek/a2a/dist/client.d.ts.map +1 -0
- package/node_modules/@xrkseek/a2a/dist/client.js +229 -0
- package/node_modules/@xrkseek/a2a/dist/client.js.map +1 -0
- package/node_modules/@xrkseek/a2a/dist/inbound.d.ts +42 -0
- package/node_modules/@xrkseek/a2a/dist/inbound.d.ts.map +1 -0
- package/node_modules/@xrkseek/a2a/dist/inbound.js +263 -0
- package/node_modules/@xrkseek/a2a/dist/inbound.js.map +1 -0
- package/node_modules/@xrkseek/a2a/dist/index.d.ts +6 -0
- package/node_modules/@xrkseek/a2a/dist/index.d.ts.map +1 -0
- package/node_modules/@xrkseek/a2a/dist/index.js +6 -0
- package/node_modules/@xrkseek/a2a/dist/index.js.map +1 -0
- package/node_modules/@xrkseek/a2a/dist/peers.d.ts +25 -0
- package/node_modules/@xrkseek/a2a/dist/peers.d.ts.map +1 -0
- package/node_modules/@xrkseek/a2a/dist/peers.js +90 -0
- package/node_modules/@xrkseek/a2a/dist/peers.js.map +1 -0
- package/node_modules/@xrkseek/a2a/dist/protocol.d.ts +45 -0
- package/node_modules/@xrkseek/a2a/dist/protocol.d.ts.map +1 -0
- package/node_modules/@xrkseek/a2a/dist/protocol.js +172 -0
- package/node_modules/@xrkseek/a2a/dist/protocol.js.map +1 -0
- package/node_modules/@xrkseek/a2a/dist/tools.d.ts +10 -0
- package/node_modules/@xrkseek/a2a/dist/tools.d.ts.map +1 -0
- package/node_modules/@xrkseek/a2a/dist/tools.js +145 -0
- package/node_modules/@xrkseek/a2a/dist/tools.js.map +1 -0
- package/node_modules/@xrkseek/a2a/package.json +28 -0
- package/node_modules/@xrkseek/attachment/README.md +23 -17
- package/node_modules/@xrkseek/attachment/dist/image-tokens.d.ts +30 -0
- package/node_modules/@xrkseek/attachment/dist/image-tokens.d.ts.map +1 -0
- package/node_modules/@xrkseek/attachment/dist/image-tokens.js +142 -0
- package/node_modules/@xrkseek/attachment/dist/image-tokens.js.map +1 -0
- package/node_modules/@xrkseek/attachment/dist/index.d.ts +2 -0
- package/node_modules/@xrkseek/attachment/dist/index.d.ts.map +1 -1
- package/node_modules/@xrkseek/attachment/dist/index.js +2 -0
- package/node_modules/@xrkseek/attachment/dist/index.js.map +1 -1
- package/node_modules/@xrkseek/attachment/dist/request-projection.d.ts +20 -0
- package/node_modules/@xrkseek/attachment/dist/request-projection.d.ts.map +1 -0
- package/node_modules/@xrkseek/attachment/dist/request-projection.js +49 -0
- package/node_modules/@xrkseek/attachment/dist/request-projection.js.map +1 -0
- package/node_modules/@xrkseek/attachment-local/dist/request-image.d.ts +2 -11
- package/node_modules/@xrkseek/attachment-local/dist/request-image.d.ts.map +1 -1
- package/node_modules/@xrkseek/attachment-local/dist/request-image.js +3 -29
- package/node_modules/@xrkseek/attachment-local/dist/request-image.js.map +1 -1
- package/node_modules/@xrkseek/checkpoint/README.md +4 -2
- package/node_modules/@xrkseek/checkpoint/dist/process-git.d.ts +6 -0
- package/node_modules/@xrkseek/checkpoint/dist/process-git.d.ts.map +1 -1
- package/node_modules/@xrkseek/checkpoint/dist/process-git.js +23 -1
- package/node_modules/@xrkseek/checkpoint/dist/process-git.js.map +1 -1
- package/node_modules/@xrkseek/checkpoint/dist/store.d.ts +30 -2
- package/node_modules/@xrkseek/checkpoint/dist/store.d.ts.map +1 -1
- package/node_modules/@xrkseek/checkpoint/dist/store.js +58 -15
- package/node_modules/@xrkseek/checkpoint/dist/store.js.map +1 -1
- package/node_modules/@xrkseek/checkpoint/dist/types.d.ts +14 -4
- package/node_modules/@xrkseek/checkpoint/dist/types.d.ts.map +1 -1
- package/node_modules/@xrkseek/checkpoint/dist/types.js.map +1 -1
- package/node_modules/@xrkseek/checkpoint/package.json +4 -1
- package/node_modules/@xrkseek/context-fragments/dist/index.d.ts +14 -0
- package/node_modules/@xrkseek/context-fragments/dist/index.d.ts.map +1 -1
- package/node_modules/@xrkseek/context-fragments/dist/index.js +33 -0
- package/node_modules/@xrkseek/context-fragments/dist/index.js.map +1 -1
- package/node_modules/@xrkseek/core-agent/dist/index.d.ts +7 -0
- package/node_modules/@xrkseek/core-agent/dist/index.d.ts.map +1 -1
- package/node_modules/@xrkseek/core-agent/dist/index.js +6 -0
- package/node_modules/@xrkseek/core-agent/dist/index.js.map +1 -1
- package/node_modules/@xrkseek/core-agent-loop/dist/compaction.d.ts.map +1 -1
- package/node_modules/@xrkseek/core-agent-loop/dist/compaction.js +1 -0
- package/node_modules/@xrkseek/core-agent-loop/dist/compaction.js.map +1 -1
- package/node_modules/@xrkseek/core-agent-loop/dist/index.d.ts +12 -0
- package/node_modules/@xrkseek/core-agent-loop/dist/index.d.ts.map +1 -1
- package/node_modules/@xrkseek/core-agent-loop/dist/index.js +95 -50
- package/node_modules/@xrkseek/core-agent-loop/dist/index.js.map +1 -1
- package/node_modules/@xrkseek/core-session/dist/compaction.d.ts +14 -0
- package/node_modules/@xrkseek/core-session/dist/compaction.d.ts.map +1 -1
- package/node_modules/@xrkseek/core-session/dist/compaction.js +41 -1
- package/node_modules/@xrkseek/core-session/dist/compaction.js.map +1 -1
- package/node_modules/@xrkseek/core-session/dist/index.d.ts +1 -1
- package/node_modules/@xrkseek/core-session/dist/index.d.ts.map +1 -1
- package/node_modules/@xrkseek/core-session/dist/index.js +1 -1
- package/node_modules/@xrkseek/core-session/dist/index.js.map +1 -1
- package/node_modules/@xrkseek/core-session/package.json +1 -0
- package/node_modules/@xrkseek/core-system-prompt/dist/index.d.ts +1 -0
- package/node_modules/@xrkseek/core-system-prompt/dist/index.d.ts.map +1 -1
- package/node_modules/@xrkseek/core-system-prompt/dist/index.js +1 -0
- package/node_modules/@xrkseek/core-system-prompt/dist/index.js.map +1 -1
- package/node_modules/@xrkseek/core-system-prompt/dist/time-context.d.ts +22 -0
- package/node_modules/@xrkseek/core-system-prompt/dist/time-context.d.ts.map +1 -0
- package/node_modules/@xrkseek/core-system-prompt/dist/time-context.js +47 -0
- package/node_modules/@xrkseek/core-system-prompt/dist/time-context.js.map +1 -0
- package/node_modules/@xrkseek/core-tools/dist/definition.d.ts +14 -0
- package/node_modules/@xrkseek/core-tools/dist/definition.d.ts.map +1 -1
- package/node_modules/@xrkseek/core-tools/dist/definition.js.map +1 -1
- package/node_modules/@xrkseek/core-tools/dist/index.d.ts +2 -2
- package/node_modules/@xrkseek/core-tools/dist/index.d.ts.map +1 -1
- package/node_modules/@xrkseek/core-tools/dist/index.js +1 -1
- package/node_modules/@xrkseek/core-tools/dist/index.js.map +1 -1
- package/node_modules/@xrkseek/core-tools/dist/materialize.d.ts +9 -3
- package/node_modules/@xrkseek/core-tools/dist/materialize.d.ts.map +1 -1
- package/node_modules/@xrkseek/core-tools/dist/materialize.js +38 -8
- package/node_modules/@xrkseek/core-tools/dist/materialize.js.map +1 -1
- package/node_modules/@xrkseek/exec-computer-use/dist/format.d.ts +2 -0
- package/node_modules/@xrkseek/exec-computer-use/dist/format.d.ts.map +1 -1
- package/node_modules/@xrkseek/exec-computer-use/dist/format.js +4 -1
- package/node_modules/@xrkseek/exec-computer-use/dist/format.js.map +1 -1
- package/node_modules/@xrkseek/exec-environment/README.md +21 -0
- package/node_modules/@xrkseek/exec-environment/dist/http.d.ts +34 -0
- package/node_modules/@xrkseek/exec-environment/dist/http.d.ts.map +1 -0
- package/node_modules/@xrkseek/exec-environment/dist/http.js +259 -0
- package/node_modules/@xrkseek/exec-environment/dist/http.js.map +1 -0
- package/node_modules/@xrkseek/exec-environment/dist/index.d.ts +5 -0
- package/node_modules/@xrkseek/exec-environment/dist/index.d.ts.map +1 -0
- package/node_modules/@xrkseek/exec-environment/dist/index.js +4 -0
- package/node_modules/@xrkseek/exec-environment/dist/index.js.map +1 -0
- package/node_modules/@xrkseek/exec-environment/dist/local.d.ts +11 -0
- package/node_modules/@xrkseek/exec-environment/dist/local.d.ts.map +1 -0
- package/node_modules/@xrkseek/exec-environment/dist/local.js +30 -0
- package/node_modules/@xrkseek/exec-environment/dist/local.js.map +1 -0
- package/node_modules/@xrkseek/exec-environment/dist/resolve.d.ts +23 -0
- package/node_modules/@xrkseek/exec-environment/dist/resolve.d.ts.map +1 -0
- package/node_modules/@xrkseek/exec-environment/dist/resolve.js +39 -0
- package/node_modules/@xrkseek/exec-environment/dist/resolve.js.map +1 -0
- package/node_modules/@xrkseek/exec-environment/dist/types.d.ts +33 -0
- package/node_modules/@xrkseek/exec-environment/dist/types.d.ts.map +1 -0
- package/node_modules/@xrkseek/exec-environment/dist/types.js +9 -0
- package/node_modules/@xrkseek/exec-environment/dist/types.js.map +1 -0
- package/node_modules/@xrkseek/exec-environment/package.json +28 -0
- package/node_modules/@xrkseek/exec-fs/dist/index.d.ts.map +1 -1
- package/node_modules/@xrkseek/exec-fs/dist/index.js +1 -0
- package/node_modules/@xrkseek/exec-fs/dist/index.js.map +1 -1
- package/node_modules/@xrkseek/exec-fs/dist/present.d.ts +5 -2
- package/node_modules/@xrkseek/exec-fs/dist/present.d.ts.map +1 -1
- package/node_modules/@xrkseek/exec-fs/dist/present.js +22 -4
- package/node_modules/@xrkseek/exec-fs/dist/present.js.map +1 -1
- package/node_modules/@xrkseek/exec-image-gen/README.md +6 -4
- package/node_modules/@xrkseek/exec-image-gen/dist/format.d.ts.map +1 -1
- package/node_modules/@xrkseek/exec-image-gen/dist/format.js +6 -3
- package/node_modules/@xrkseek/exec-image-gen/dist/format.js.map +1 -1
- package/node_modules/@xrkseek/exec-image-gen/dist/index.d.ts +4 -2
- package/node_modules/@xrkseek/exec-image-gen/dist/index.d.ts.map +1 -1
- package/node_modules/@xrkseek/exec-image-gen/dist/index.js +4 -2
- package/node_modules/@xrkseek/exec-image-gen/dist/index.js.map +1 -1
- package/node_modules/@xrkseek/exec-image-gen/dist/memory.d.ts +4 -1
- package/node_modules/@xrkseek/exec-image-gen/dist/memory.d.ts.map +1 -1
- package/node_modules/@xrkseek/exec-image-gen/dist/memory.js +16 -1
- package/node_modules/@xrkseek/exec-image-gen/dist/memory.js.map +1 -1
- package/node_modules/@xrkseek/exec-image-gen/dist/openai-http.d.ts +5 -2
- package/node_modules/@xrkseek/exec-image-gen/dist/openai-http.d.ts.map +1 -1
- package/node_modules/@xrkseek/exec-image-gen/dist/openai-http.js +88 -38
- package/node_modules/@xrkseek/exec-image-gen/dist/openai-http.js.map +1 -1
- package/node_modules/@xrkseek/exec-image-gen/dist/references.d.ts +21 -0
- package/node_modules/@xrkseek/exec-image-gen/dist/references.d.ts.map +1 -0
- package/node_modules/@xrkseek/exec-image-gen/dist/references.js +145 -0
- package/node_modules/@xrkseek/exec-image-gen/dist/references.js.map +1 -0
- package/node_modules/@xrkseek/exec-image-gen/dist/schema.d.ts +15 -0
- package/node_modules/@xrkseek/exec-image-gen/dist/schema.d.ts.map +1 -0
- package/node_modules/@xrkseek/exec-image-gen/dist/schema.js +67 -0
- package/node_modules/@xrkseek/exec-image-gen/dist/schema.js.map +1 -0
- package/node_modules/@xrkseek/exec-image-gen/dist/tools.d.ts +5 -2
- package/node_modules/@xrkseek/exec-image-gen/dist/tools.d.ts.map +1 -1
- package/node_modules/@xrkseek/exec-image-gen/dist/tools.js +38 -36
- package/node_modules/@xrkseek/exec-image-gen/dist/tools.js.map +1 -1
- package/node_modules/@xrkseek/exec-image-gen/dist/types.d.ts +34 -2
- package/node_modules/@xrkseek/exec-image-gen/dist/types.d.ts.map +1 -1
- package/node_modules/@xrkseek/exec-image-gen/dist/types.js +16 -1
- package/node_modules/@xrkseek/exec-image-gen/dist/types.js.map +1 -1
- package/node_modules/@xrkseek/exec-memory/README.md +3 -2
- package/node_modules/@xrkseek/exec-memory/dist/index.d.ts +2 -1
- package/node_modules/@xrkseek/exec-memory/dist/index.d.ts.map +1 -1
- package/node_modules/@xrkseek/exec-memory/dist/index.js +2 -1
- package/node_modules/@xrkseek/exec-memory/dist/index.js.map +1 -1
- package/node_modules/@xrkseek/exec-memory/dist/provider.d.ts +1 -1
- package/node_modules/@xrkseek/exec-memory/dist/provider.d.ts.map +1 -1
- package/node_modules/@xrkseek/exec-memory/dist/resolve.d.ts +15 -4
- package/node_modules/@xrkseek/exec-memory/dist/resolve.d.ts.map +1 -1
- package/node_modules/@xrkseek/exec-memory/dist/resolve.js +13 -3
- package/node_modules/@xrkseek/exec-memory/dist/resolve.js.map +1 -1
- package/node_modules/@xrkseek/exec-memory/dist/sqlite.d.ts +19 -0
- package/node_modules/@xrkseek/exec-memory/dist/sqlite.d.ts.map +1 -0
- package/node_modules/@xrkseek/exec-memory/dist/sqlite.js +190 -0
- package/node_modules/@xrkseek/exec-memory/dist/sqlite.js.map +1 -0
- package/node_modules/@xrkseek/exec-memory/dist/write-path.d.ts +21 -0
- package/node_modules/@xrkseek/exec-memory/dist/write-path.d.ts.map +1 -1
- package/node_modules/@xrkseek/exec-memory/dist/write-path.js +128 -25
- package/node_modules/@xrkseek/exec-memory/dist/write-path.js.map +1 -1
- package/node_modules/@xrkseek/exec-video-gen/README.md +27 -19
- package/node_modules/@xrkseek/exec-video-gen/dist/catalog.d.ts +16 -0
- package/node_modules/@xrkseek/exec-video-gen/dist/catalog.d.ts.map +1 -0
- package/node_modules/@xrkseek/exec-video-gen/dist/catalog.js +90 -0
- package/node_modules/@xrkseek/exec-video-gen/dist/catalog.js.map +1 -0
- package/node_modules/@xrkseek/exec-video-gen/dist/format.d.ts.map +1 -1
- package/node_modules/@xrkseek/exec-video-gen/dist/format.js +3 -1
- package/node_modules/@xrkseek/exec-video-gen/dist/format.js.map +1 -1
- package/node_modules/@xrkseek/exec-video-gen/dist/index.d.ts +5 -2
- package/node_modules/@xrkseek/exec-video-gen/dist/index.d.ts.map +1 -1
- package/node_modules/@xrkseek/exec-video-gen/dist/index.js +5 -2
- package/node_modules/@xrkseek/exec-video-gen/dist/index.js.map +1 -1
- package/node_modules/@xrkseek/exec-video-gen/dist/memory.d.ts +3 -2
- package/node_modules/@xrkseek/exec-video-gen/dist/memory.d.ts.map +1 -1
- package/node_modules/@xrkseek/exec-video-gen/dist/memory.js +45 -4
- package/node_modules/@xrkseek/exec-video-gen/dist/memory.js.map +1 -1
- package/node_modules/@xrkseek/exec-video-gen/dist/openai-http.d.ts +3 -6
- package/node_modules/@xrkseek/exec-video-gen/dist/openai-http.d.ts.map +1 -1
- package/node_modules/@xrkseek/exec-video-gen/dist/openai-http.js +81 -2
- package/node_modules/@xrkseek/exec-video-gen/dist/openai-http.js.map +1 -1
- package/node_modules/@xrkseek/exec-video-gen/dist/references.d.ts +24 -0
- package/node_modules/@xrkseek/exec-video-gen/dist/references.d.ts.map +1 -0
- package/node_modules/@xrkseek/exec-video-gen/dist/references.js +151 -0
- package/node_modules/@xrkseek/exec-video-gen/dist/references.js.map +1 -0
- package/node_modules/@xrkseek/exec-video-gen/dist/schema.d.ts +15 -0
- package/node_modules/@xrkseek/exec-video-gen/dist/schema.d.ts.map +1 -0
- package/node_modules/@xrkseek/exec-video-gen/dist/schema.js +104 -0
- package/node_modules/@xrkseek/exec-video-gen/dist/schema.js.map +1 -0
- package/node_modules/@xrkseek/exec-video-gen/dist/tools.d.ts +4 -2
- package/node_modules/@xrkseek/exec-video-gen/dist/tools.d.ts.map +1 -1
- package/node_modules/@xrkseek/exec-video-gen/dist/tools.js +99 -70
- package/node_modules/@xrkseek/exec-video-gen/dist/tools.js.map +1 -1
- package/node_modules/@xrkseek/exec-video-gen/dist/types.d.ts +73 -2
- package/node_modules/@xrkseek/exec-video-gen/dist/types.d.ts.map +1 -1
- package/node_modules/@xrkseek/exec-video-gen/dist/types.js +20 -1
- package/node_modules/@xrkseek/exec-video-gen/dist/types.js.map +1 -1
- package/node_modules/@xrkseek/exec-web/README.md +2 -2
- package/node_modules/@xrkseek/exec-web/dist/browser-tools.d.ts +3 -0
- package/node_modules/@xrkseek/exec-web/dist/browser-tools.d.ts.map +1 -1
- package/node_modules/@xrkseek/exec-web/dist/browser-tools.js +3 -0
- package/node_modules/@xrkseek/exec-web/dist/browser-tools.js.map +1 -1
- package/node_modules/@xrkseek/exec-web/dist/browser-vault-tools.d.ts +32 -0
- package/node_modules/@xrkseek/exec-web/dist/browser-vault-tools.d.ts.map +1 -0
- package/node_modules/@xrkseek/exec-web/dist/browser-vault-tools.js +141 -0
- package/node_modules/@xrkseek/exec-web/dist/browser-vault-tools.js.map +1 -0
- package/node_modules/@xrkseek/exec-web/dist/index.d.ts +1 -0
- package/node_modules/@xrkseek/exec-web/dist/index.d.ts.map +1 -1
- package/node_modules/@xrkseek/exec-web/dist/index.js +1 -0
- package/node_modules/@xrkseek/exec-web/dist/index.js.map +1 -1
- package/node_modules/@xrkseek/llm-deepseek/dist/index.d.ts +1 -0
- package/node_modules/@xrkseek/llm-deepseek/dist/index.d.ts.map +1 -1
- package/node_modules/@xrkseek/llm-deepseek/dist/index.js +2 -1
- package/node_modules/@xrkseek/llm-deepseek/dist/index.js.map +1 -1
- package/node_modules/@xrkseek/llm-deepseek/dist/request-policy.d.ts +13 -3
- package/node_modules/@xrkseek/llm-deepseek/dist/request-policy.d.ts.map +1 -1
- package/node_modules/@xrkseek/llm-deepseek/dist/request-policy.js +27 -4
- package/node_modules/@xrkseek/llm-deepseek/dist/request-policy.js.map +1 -1
- package/node_modules/@xrkseek/preset-harness/README.md +8 -8
- package/node_modules/@xrkseek/preset-harness/dist/preset.d.ts +11 -1
- package/node_modules/@xrkseek/preset-harness/dist/preset.d.ts.map +1 -1
- package/node_modules/@xrkseek/preset-harness/dist/preset.js +11 -3
- package/node_modules/@xrkseek/preset-harness/dist/preset.js.map +1 -1
- package/node_modules/@xrkseek/preset-harness/dist/tsconfig.tsbuildinfo +1 -1
- package/node_modules/@xrkseek/preset-minimal/README.md +2 -2
- package/node_modules/@xrkseek/preset-minimal/dist/preset.js +1 -1
- package/node_modules/@xrkseek/preset-minimal/dist/preset.js.map +1 -1
- package/node_modules/@xrkseek/preset-minimal/dist/tsconfig.tsbuildinfo +1 -1
- package/node_modules/@xrkseek/preset-server/README.md +5 -5
- package/node_modules/@xrkseek/preset-server/dist/preset.d.ts.map +1 -1
- package/node_modules/@xrkseek/preset-server/dist/preset.js +3 -2
- package/node_modules/@xrkseek/preset-server/dist/preset.js.map +1 -1
- package/node_modules/@xrkseek/preset-server/dist/tsconfig.tsbuildinfo +1 -1
- package/node_modules/@xrkseek/protocol/dist/session-events.d.ts +9 -0
- package/node_modules/@xrkseek/protocol/dist/session-events.d.ts.map +1 -1
- package/node_modules/@xrkseek/protocol/dist/session-events.js.map +1 -1
- package/node_modules/@xrkseek/protocol/dist/validate.d.ts.map +1 -1
- package/node_modules/@xrkseek/protocol/dist/validate.js +9 -0
- package/node_modules/@xrkseek/protocol/dist/validate.js.map +1 -1
- package/node_modules/@xrkseek/server-config/dist/index.d.ts +1 -0
- package/node_modules/@xrkseek/server-config/dist/index.d.ts.map +1 -1
- package/node_modules/@xrkseek/server-config/dist/index.js +1 -0
- package/node_modules/@xrkseek/server-config/dist/index.js.map +1 -1
- package/node_modules/@xrkseek/server-config/dist/json-text.d.ts +8 -0
- package/node_modules/@xrkseek/server-config/dist/json-text.d.ts.map +1 -0
- package/node_modules/@xrkseek/server-config/dist/json-text.js +12 -0
- package/node_modules/@xrkseek/server-config/dist/json-text.js.map +1 -0
- package/node_modules/@xrkseek/server-cron/README.md +3 -2
- package/node_modules/@xrkseek/server-cron/dist/executions.d.ts +31 -0
- package/node_modules/@xrkseek/server-cron/dist/executions.d.ts.map +1 -0
- package/node_modules/@xrkseek/server-cron/dist/executions.js +95 -0
- package/node_modules/@xrkseek/server-cron/dist/executions.js.map +1 -0
- package/node_modules/@xrkseek/server-cron/dist/index.d.ts +1 -0
- package/node_modules/@xrkseek/server-cron/dist/index.d.ts.map +1 -1
- package/node_modules/@xrkseek/server-cron/dist/index.js +6 -0
- package/node_modules/@xrkseek/server-cron/dist/index.js.map +1 -1
- package/node_modules/@xrkseek/server-cron/dist/scheduler.d.ts +4 -0
- package/node_modules/@xrkseek/server-cron/dist/scheduler.d.ts.map +1 -1
- package/node_modules/@xrkseek/server-cron/dist/scheduler.js +33 -24
- package/node_modules/@xrkseek/server-cron/dist/scheduler.js.map +1 -1
- package/node_modules/@xrkseek/server-cron/dist/tools.d.ts.map +1 -1
- package/node_modules/@xrkseek/server-cron/dist/tools.js +44 -6
- package/node_modules/@xrkseek/server-cron/dist/tools.js.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/dispatch.d.ts.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/dispatch.js +2 -0
- package/node_modules/@xrkseek/server-face/dist/dispatch.js.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/external-agent-runtime.d.ts +37 -2
- package/node_modules/@xrkseek/server-face/dist/external-agent-runtime.d.ts.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/external-agent-runtime.js +191 -28
- package/node_modules/@xrkseek/server-face/dist/external-agent-runtime.js.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/handlers/worktree.d.ts +10 -0
- package/node_modules/@xrkseek/server-face/dist/handlers/worktree.d.ts.map +1 -0
- package/node_modules/@xrkseek/server-face/dist/handlers/worktree.js +33 -0
- package/node_modules/@xrkseek/server-face/dist/handlers/worktree.js.map +1 -0
- package/node_modules/@xrkseek/server-face/dist/host-open-path.d.ts +9 -0
- package/node_modules/@xrkseek/server-face/dist/host-open-path.d.ts.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/host-open-path.js +13 -7
- package/node_modules/@xrkseek/server-face/dist/host-open-path.js.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/index.d.ts +2 -2
- package/node_modules/@xrkseek/server-face/dist/index.d.ts.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/index.js +1 -1
- package/node_modules/@xrkseek/server-face/dist/index.js.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/llm-provider-context.d.ts +2 -0
- package/node_modules/@xrkseek/server-face/dist/llm-provider-context.d.ts.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/llm-provider-context.js +13 -0
- package/node_modules/@xrkseek/server-face/dist/llm-provider-context.js.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/llm-resolve.d.ts.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/llm-resolve.js +3 -1
- package/node_modules/@xrkseek/server-face/dist/llm-resolve.js.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/model-catalog.d.ts +4 -0
- package/node_modules/@xrkseek/server-face/dist/model-catalog.d.ts.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/model-catalog.js +24 -5
- package/node_modules/@xrkseek/server-face/dist/model-catalog.js.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/presets-catalog.js +5 -5
- package/node_modules/@xrkseek/server-face/dist/presets-catalog.js.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/runtime.d.ts.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/runtime.js +14 -2
- package/node_modules/@xrkseek/server-face/dist/runtime.js.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/select-session-model.d.ts.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/select-session-model.js +8 -0
- package/node_modules/@xrkseek/server-face/dist/select-session-model.js.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/session-model-store.d.ts +11 -0
- package/node_modules/@xrkseek/server-face/dist/session-model-store.d.ts.map +1 -0
- package/node_modules/@xrkseek/server-face/dist/session-model-store.js +66 -0
- package/node_modules/@xrkseek/server-face/dist/session-model-store.js.map +1 -0
- package/node_modules/@xrkseek/server-face/dist/session-status.d.ts +64 -13
- package/node_modules/@xrkseek/server-face/dist/session-status.d.ts.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/session-status.js +173 -5
- package/node_modules/@xrkseek/server-face/dist/session-status.js.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/settings-credentials.d.ts.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/settings-credentials.js +4 -5
- package/node_modules/@xrkseek/server-face/dist/settings-credentials.js.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/settings-schemas.d.ts.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/settings-schemas.js +36 -4
- package/node_modules/@xrkseek/server-face/dist/settings-schemas.js.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/subagent-tools.d.ts +1 -1
- package/node_modules/@xrkseek/server-face/dist/subagent-tools.d.ts.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/subagent-tools.js +1 -1
- package/node_modules/@xrkseek/server-face/dist/subagent-tools.js.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/workspace-checkpoint.d.ts +15 -1
- package/node_modules/@xrkseek/server-face/dist/workspace-checkpoint.d.ts.map +1 -1
- package/node_modules/@xrkseek/server-face/dist/workspace-checkpoint.js +35 -7
- package/node_modules/@xrkseek/server-face/dist/workspace-checkpoint.js.map +1 -1
- package/node_modules/@xrkseek/server-host/dist/a2a-inbound-public.d.ts +11 -0
- package/node_modules/@xrkseek/server-host/dist/a2a-inbound-public.d.ts.map +1 -0
- package/node_modules/@xrkseek/server-host/dist/a2a-inbound-public.js +22 -0
- package/node_modules/@xrkseek/server-host/dist/a2a-inbound-public.js.map +1 -0
- package/node_modules/@xrkseek/server-host/dist/index.d.ts +3 -0
- package/node_modules/@xrkseek/server-host/dist/index.d.ts.map +1 -1
- package/node_modules/@xrkseek/server-host/dist/index.js +178 -48
- package/node_modules/@xrkseek/server-host/dist/index.js.map +1 -1
- package/node_modules/@xrkseek/server-host/dist/mcp-wire.d.ts.map +1 -1
- package/node_modules/@xrkseek/server-host/dist/mcp-wire.js +3 -3
- package/node_modules/@xrkseek/server-host/dist/mcp-wire.js.map +1 -1
- package/node_modules/@xrkseek/server-host/package.json +2 -0
- package/node_modules/@xrkseek/server-http/dist/dsh-compat/embedded-vector-store.d.ts +2 -2
- package/node_modules/@xrkseek/server-http/dist/dsh-compat/embedded-vector-store.d.ts.map +1 -1
- package/node_modules/@xrkseek/server-http/dist/dsh-compat/embedded-vector-store.js +9 -4
- package/node_modules/@xrkseek/server-http/dist/dsh-compat/embedded-vector-store.js.map +1 -1
- package/node_modules/@xrkseek/server-http/dist/dsh-compat/memory-embeddings.d.ts +37 -1
- package/node_modules/@xrkseek/server-http/dist/dsh-compat/memory-embeddings.d.ts.map +1 -1
- package/node_modules/@xrkseek/server-http/dist/dsh-compat/memory-embeddings.js +125 -9
- package/node_modules/@xrkseek/server-http/dist/dsh-compat/memory-embeddings.js.map +1 -1
- package/node_modules/@xrkseek/workspace/dist/index.d.ts +1 -0
- package/node_modules/@xrkseek/workspace/dist/index.d.ts.map +1 -1
- package/node_modules/@xrkseek/workspace/dist/index.js +1 -0
- package/node_modules/@xrkseek/workspace/dist/index.js.map +1 -1
- package/node_modules/@xrkseek/workspace/dist/skill-curator.d.ts +46 -0
- package/node_modules/@xrkseek/workspace/dist/skill-curator.d.ts.map +1 -0
- package/node_modules/@xrkseek/workspace/dist/skill-curator.js +114 -0
- package/node_modules/@xrkseek/workspace/dist/skill-curator.js.map +1 -0
- package/package.json +5 -1
|
@@ -5,6 +5,8 @@ import { assertPolicyAllow, PolicyGateError } from "@xrkseek/policy";
|
|
|
5
5
|
import { contentHasImage, } from "@xrkseek/protocol";
|
|
6
6
|
import { readSessionEvents } from "@xrkseek/core-session";
|
|
7
7
|
import { saveAgentDefaultModel, } from "./model-catalog.js";
|
|
8
|
+
import { saveSessionModelSelection, sessionModelsPath, } from "./session-model-store.js";
|
|
9
|
+
import { resolveXrkHome } from "@xrkseek/server-config";
|
|
8
10
|
import { resolveLlmForSelection } from "./llm-resolve.js";
|
|
9
11
|
import { publishRemoteEvent } from "./remote-event.js";
|
|
10
12
|
function sessionHasImageContent(runtime, sessionId) {
|
|
@@ -113,6 +115,12 @@ export async function selectSessionModel(runtime, args) {
|
|
|
113
115
|
};
|
|
114
116
|
}
|
|
115
117
|
runtime.sessionModels.set(sessionId, selected);
|
|
118
|
+
try {
|
|
119
|
+
saveSessionModelSelection(sessionModelsPath(runtime.productDir?.trim() || resolveXrkHome()), sessionId, selected);
|
|
120
|
+
}
|
|
121
|
+
catch {
|
|
122
|
+
/* disk persist best-effort */
|
|
123
|
+
}
|
|
116
124
|
try {
|
|
117
125
|
await saveAgentDefaultModel(runtime, selected);
|
|
118
126
|
publishRemoteEvent(runtime.bus, "settings/document-updated", [
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"select-session-model.js","sourceRoot":"","sources":["../src/select-session-model.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,iBAAiB,EAAE,eAAe,EAAE,MAAM,iBAAiB,CAAC;AACrE,OAAO,EACL,eAAe,GAEhB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAE,iBAAiB,EAAE,MAAM,uBAAuB,CAAC;AAG1D,OAAO,EACL,qBAAqB,GAEtB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAE,sBAAsB,EAAE,MAAM,kBAAkB,CAAC;AAC1D,OAAO,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAC;AAEvD,SAAS,sBAAsB,CAC7B,OAAoB,EACpB,SAAiB;IAEjB,IAAI,OAAO,CAAC,eAAe,CAAC,GAAG,CAAC,SAAS,CAAC;QAAE,OAAO,IAAI,CAAC;IACxD,IAAI,OAAO,CAAC,mBAAmB,CAAC,GAAG,CAAC,SAAS,CAAC;QAAE,OAAO,KAAK,CAAC;IAC7D,KAAK,MAAM,EAAE,IAAI,iBAAiB,CAAC,OAAO,CAAC,KAAK,EAAE,SAAS,CAAC,EAAE,CAAC;QAC7D,IAAI,EAAE,CAAC,IAAI,KAAK,cAAc,IAAI,EAAE,CAAC,IAAI,KAAK,iBAAiB;YAAE,SAAS;QAC1E,MAAM,OAAO,GAAI,EAAmC,CAAC,OAAO,CAAC;QAC7D,IAAI,OAAO,KAAK,SAAS,IAAI,e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,CAAC,aAAa,CAAC,GAAG,CAAC,SAAS,EAAE,QAAQ,CAAC,CAAC;IAC/C,IAAI,CAAC;QACH,yBAAyB,CACvB,iBAAiB,CACf,OAAO,CAAC,UAAU,EAAE,IAAI,EAAE,IAAI,cAAc,EAAE,CAC/C,EACD,SAAS,EACT,QAAQ,CACT,CAAC;IACJ,CAAC;IAAC,MAAM,CAAC;QACP,8BAA8B;IAChC,CAAC;IACD,IAAI,CAAC;QACH,MAAM,qBAAqB,CAAC,OAAO,EAAE,QAAQ,CAAC,CAAC;QAC/C,kBAAkB,CAAC,OAAO,CAAC,GAAG,EAAE,2BAA2B,EAAE;YAC3D,qBAAqB;YACrB,OAAO,CAAC,kBAAkB,CAAC,MAAM,CAAC,qBAAqB,CAAC,CAAC,QAAQ;SAClE,CAAC,CAAC;IACL,CAAC;IAAC,MAAM,CAAC;QACP,qCAAqC;IACvC,CAAC;IACD,OAAO,EAAE,EAAE,EAAE,IAAI,EAAE,KAAK,EAAE,EAAE,QAAQ,EAAE,EAAE,CAAC;AAC3C,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Per-session model selection sidecar (DSH session metadata parity).
|
|
3
|
+
* Survives Host restart; distinct from Settings `agent-default-model`.
|
|
4
|
+
*/
|
|
5
|
+
import type { FaceModelSelection } from "./model-catalog.js";
|
|
6
|
+
export declare function sessionModelsPath(productHome: string): string;
|
|
7
|
+
/** Load all persisted session overrides (empty map when missing/corrupt). */
|
|
8
|
+
export declare function loadSessionModelSelections(filePath: string): Map<string, FaceModelSelection>;
|
|
9
|
+
/** Persist one session override (merge into the file). */
|
|
10
|
+
export declare function saveSessionModelSelection(filePath: string, sessionId: string, selection: FaceModelSelection): void;
|
|
11
|
+
//# sourceMappingURL=session-model-store.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"session-model-store.d.ts","sourceRoot":"","sources":["../src/session-model-store.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAKH,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AAiB7D,wBAAgB,iBAAiB,CAAC,WAAW,EAAE,MAAM,GAAG,MAAM,CAE7D;AAED,6EAA6E;AAC7E,wBAAgB,0BAA0B,CACxC,QAAQ,EAAE,MAAM,GACf,GAAG,CAAC,MAAM,EAAE,kBAAkB,CAAC,CAwBjC;AAED,0DAA0D;AAC1D,wBAAgB,yBAAyB,CACvC,QAAQ,EAAE,MAAM,EAChB,SAAS,EAAE,MAAM,EACjB,SAAS,EAAE,kBAAkB,GAC5B,IAAI,CAeN"}
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Per-session model selection sidecar (DSH session metadata parity).
|
|
3
|
+
* Survives Host restart; distinct from Settings `agent-default-model`.
|
|
4
|
+
*/
|
|
5
|
+
import { mkdirSync, readFileSync, renameSync, writeFileSync } from "node:fs";
|
|
6
|
+
import path from "node:path";
|
|
7
|
+
import { randomUUID } from "node:crypto";
|
|
8
|
+
const VERSION = 1;
|
|
9
|
+
function atomicWrite(filePath, text) {
|
|
10
|
+
const dir = path.dirname(filePath);
|
|
11
|
+
mkdirSync(dir, { recursive: true });
|
|
12
|
+
const tmp = `${filePath}.${process.pid}.${randomUUID().slice(0, 8)}.tmp`;
|
|
13
|
+
writeFileSync(tmp, text, "utf8");
|
|
14
|
+
renameSync(tmp, filePath);
|
|
15
|
+
}
|
|
16
|
+
export function sessionModelsPath(productHome) {
|
|
17
|
+
return path.join(productHome, "session-models.json");
|
|
18
|
+
}
|
|
19
|
+
/** Load all persisted session overrides (empty map when missing/corrupt). */
|
|
20
|
+
export function loadSessionModelSelections(filePath) {
|
|
21
|
+
const out = new Map();
|
|
22
|
+
try {
|
|
23
|
+
const raw = JSON.parse(readFileSync(filePath, "utf8"));
|
|
24
|
+
if (raw?.version !== VERSION || !raw.selections || typeof raw.selections !== "object") {
|
|
25
|
+
return out;
|
|
26
|
+
}
|
|
27
|
+
for (const [id, sel] of Object.entries(raw.selections)) {
|
|
28
|
+
const sessionId = id.trim();
|
|
29
|
+
const provider = String(sel?.provider ?? "").trim();
|
|
30
|
+
const model = String(sel?.model ?? "").trim();
|
|
31
|
+
if (!sessionId || !provider || !model)
|
|
32
|
+
continue;
|
|
33
|
+
out.set(sessionId, {
|
|
34
|
+
provider,
|
|
35
|
+
model,
|
|
36
|
+
...(typeof sel.reasoningEffort === "string" && sel.reasoningEffort.trim()
|
|
37
|
+
? { reasoningEffort: sel.reasoningEffort.trim() }
|
|
38
|
+
: {}),
|
|
39
|
+
});
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
catch {
|
|
43
|
+
/* missing or unreadable — cold start */
|
|
44
|
+
}
|
|
45
|
+
return out;
|
|
46
|
+
}
|
|
47
|
+
/** Persist one session override (merge into the file). */
|
|
48
|
+
export function saveSessionModelSelection(filePath, sessionId, selection) {
|
|
49
|
+
const id = sessionId.trim();
|
|
50
|
+
if (!id)
|
|
51
|
+
return;
|
|
52
|
+
const map = loadSessionModelSelections(filePath);
|
|
53
|
+
map.set(id, {
|
|
54
|
+
provider: selection.provider,
|
|
55
|
+
model: selection.model,
|
|
56
|
+
...(selection.reasoningEffort
|
|
57
|
+
? { reasoningEffort: selection.reasoningEffort }
|
|
58
|
+
: {}),
|
|
59
|
+
});
|
|
60
|
+
const selections = {};
|
|
61
|
+
for (const [k, v] of map)
|
|
62
|
+
selections[k] = v;
|
|
63
|
+
const body = { version: VERSION, selections };
|
|
64
|
+
atomicWrite(filePath, `${JSON.stringify(body, null, 2)}\n`);
|
|
65
|
+
}
|
|
66
|
+
//# sourceMappingURL=session-model-store.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"session-model-store.js","sourceRoot":"","sources":["../src/session-model-store.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,SAAS,EAAE,YAAY,EAAE,UAAU,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC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,CAAC,CAAC,IAAI,GAAG;QAAE,UAAU,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;IAC5C,MAAM,IAAI,GAAiB,EAAE,OAAO,EAAE,OAAO,EAAE,UAAU,EAAE,CAAC;IAC5D,WAAW,CAAC,QAAQ,EAAE,GAAG,IAAI,CAAC,SAAS,CAAC,IAAI,EAAE,IAAI,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC;AAC9D,CAAC"}
|
|
@@ -16,6 +16,13 @@ export interface SessionStatusSubagentLive {
|
|
|
16
16
|
readonly queued?: number;
|
|
17
17
|
/** Child inbox admits waiting as steer. */
|
|
18
18
|
readonly steering?: number;
|
|
19
|
+
/** External runtime kind when this child is ACP / app-server backed. */
|
|
20
|
+
readonly externalKind?: "acp" | "app-server";
|
|
21
|
+
/**
|
|
22
|
+
* `live` = process handle attached; `cold` = sidecar handle only (Host
|
|
23
|
+
* restart / dispose) — follow-up may attempt reopen via thread/resume.
|
|
24
|
+
*/
|
|
25
|
+
readonly externalResume?: "live" | "cold";
|
|
19
26
|
}
|
|
20
27
|
/** Depth / concurrency caps for Status + model `analytics`. */
|
|
21
28
|
export interface SessionStatusSubagentQuota {
|
|
@@ -73,6 +80,48 @@ export interface SessionStatusBilling {
|
|
|
73
80
|
readonly byModel: readonly SessionStatusCostModelRow[];
|
|
74
81
|
/** Month window `provider:model`, ranked (max 8). */
|
|
75
82
|
readonly byProviderModel: readonly SessionStatusCostModelRow[];
|
|
83
|
+
/** Recent daily points from ledger history (Hermes insights / dsh-wallet). */
|
|
84
|
+
readonly dailyTrend: readonly SessionStatusBillingDay[];
|
|
85
|
+
}
|
|
86
|
+
/** One day on the billing trend sparkline. */
|
|
87
|
+
export interface SessionStatusBillingDay {
|
|
88
|
+
readonly date: string;
|
|
89
|
+
readonly cost: number;
|
|
90
|
+
readonly tokens: number;
|
|
91
|
+
}
|
|
92
|
+
/**
|
|
93
|
+
* Fleet health for Status (subagents · jobs · channels) — Hermes StatusPage
|
|
94
|
+
* style operator glance, not a separate monitoring product.
|
|
95
|
+
*/
|
|
96
|
+
export type SessionStatusFleetHealth = "ok" | "warn" | "critical";
|
|
97
|
+
export interface SessionStatusFleetAlert {
|
|
98
|
+
readonly id: string;
|
|
99
|
+
readonly severity: "info" | "warn" | "critical";
|
|
100
|
+
readonly message: string;
|
|
101
|
+
}
|
|
102
|
+
export interface SessionStatusFleet {
|
|
103
|
+
readonly health: SessionStatusFleetHealth;
|
|
104
|
+
readonly runningJobs: number;
|
|
105
|
+
readonly runningSubagents: number;
|
|
106
|
+
readonly slotsFree: number;
|
|
107
|
+
readonly queuedInbox: number;
|
|
108
|
+
readonly channelAlerts: number;
|
|
109
|
+
readonly alerts: readonly SessionStatusFleetAlert[];
|
|
110
|
+
}
|
|
111
|
+
export interface SessionStatusChannels {
|
|
112
|
+
readonly process: readonly {
|
|
113
|
+
readonly pluginId: string;
|
|
114
|
+
readonly channelId: string;
|
|
115
|
+
readonly displayName?: string;
|
|
116
|
+
}[];
|
|
117
|
+
readonly im: readonly {
|
|
118
|
+
readonly channelId: string;
|
|
119
|
+
readonly displayName: string;
|
|
120
|
+
readonly wired: string;
|
|
121
|
+
}[];
|
|
122
|
+
readonly note: string;
|
|
123
|
+
/** Discover stubs / bridge-only IM that need operator attention. */
|
|
124
|
+
readonly alerts: readonly SessionStatusFleetAlert[];
|
|
76
125
|
}
|
|
77
126
|
export interface SessionStatusTimeline {
|
|
78
127
|
readonly total: number;
|
|
@@ -110,17 +159,26 @@ export interface SessionStatusCompaction {
|
|
|
110
159
|
readonly pipeline: SessionStatusCompactionPipeline;
|
|
111
160
|
/** Ordered stages for that last pipeline (empty when `none`). */
|
|
112
161
|
readonly stages: readonly SessionStatusCompactionStage[];
|
|
162
|
+
/**
|
|
163
|
+
* Configured soft-budget strategy (Face `agent-loop.compactionStrategy`).
|
|
164
|
+
* Distinct from last-turn `pipeline` (what actually ran).
|
|
165
|
+
*/
|
|
166
|
+
readonly strategy?: "prune-summary" | "prune-only" | "summary-only" | "off";
|
|
113
167
|
readonly lastReason?: ContextTimelineCompactReason;
|
|
114
168
|
readonly lastShadowedTokens?: number;
|
|
115
169
|
readonly pruneCount: number;
|
|
116
170
|
/** Count of `context/compaction` (summary) timeline rows. */
|
|
117
171
|
readonly summaryCount: number;
|
|
118
172
|
readonly spillCount: number;
|
|
173
|
+
/** Recent unique spill absolute paths (newest last; capped). */
|
|
174
|
+
readonly spillPaths?: readonly string[];
|
|
119
175
|
/**
|
|
120
176
|
* Live latch: turn or manual `/compact` holds the agent busy bit
|
|
121
177
|
* (compact and turn are mutually exclusive on the same latch).
|
|
122
178
|
*/
|
|
123
179
|
readonly phase: "idle" | "busy";
|
|
180
|
+
/** Thin Guardian fragment registered (Settings `guardianFragments`). */
|
|
181
|
+
readonly guardian?: boolean;
|
|
124
182
|
}
|
|
125
183
|
/**
|
|
126
184
|
* Queue vs turn mutual exclusion facts for the Overview Status column.
|
|
@@ -139,19 +197,6 @@ export interface SessionStatusDelivery {
|
|
|
139
197
|
/** One-line operator note (slash + Overview). */
|
|
140
198
|
readonly note: string;
|
|
141
199
|
}
|
|
142
|
-
export interface SessionStatusChannels {
|
|
143
|
-
readonly process: readonly {
|
|
144
|
-
readonly pluginId: string;
|
|
145
|
-
readonly channelId: string;
|
|
146
|
-
readonly displayName?: string;
|
|
147
|
-
}[];
|
|
148
|
-
readonly im: readonly {
|
|
149
|
-
readonly channelId: string;
|
|
150
|
-
readonly displayName: string;
|
|
151
|
-
readonly wired: string;
|
|
152
|
-
}[];
|
|
153
|
-
readonly note: string;
|
|
154
|
-
}
|
|
155
200
|
export interface SessionStatusTeamTask {
|
|
156
201
|
readonly id: string;
|
|
157
202
|
readonly title: string;
|
|
@@ -164,6 +209,10 @@ export interface SessionStatusTeamTask {
|
|
|
164
209
|
readonly worktreePath?: string;
|
|
165
210
|
readonly worktreeBranch?: string;
|
|
166
211
|
readonly worktreeId?: string;
|
|
212
|
+
/** Managed lease status (`active` · `retained` · `reclaimed`) when known. */
|
|
213
|
+
readonly worktreeLeaseStatus?: string;
|
|
214
|
+
/** Truncated completion / failure preview from the task board. */
|
|
215
|
+
readonly resultPreview?: string;
|
|
167
216
|
}
|
|
168
217
|
/** Structured Status facts shared by slash `/status` and Overview. */
|
|
169
218
|
export interface SessionStatusSnapshot {
|
|
@@ -190,6 +239,8 @@ export interface SessionStatusSnapshot {
|
|
|
190
239
|
readonly cost: SessionStatusCost;
|
|
191
240
|
/** Host-wide ledger fold (cross-session · cross-model). */
|
|
192
241
|
readonly billing: SessionStatusBilling;
|
|
242
|
+
/** Subagent / job / channel health glance. */
|
|
243
|
+
readonly fleet: SessionStatusFleet;
|
|
193
244
|
readonly timeline: SessionStatusTimeline;
|
|
194
245
|
/** Prune → summary stage fold + live busy phase. */
|
|
195
246
|
readonly compaction: SessionStatusCompaction;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"session-status.d.ts","sourceRoot":"","sources":["../src/session-status.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAUhD,OAAO,KAAK,EACV,4BAA4B,EAG7B,MAAM,yCAAyC,CAAC;AAMjD,MAAM,WAAW,mBAAmB;IAClC,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC;CACzB;AAED,MAAM,WAAW,yBAAyB;IACxC,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,QAAQ,EAAE,SAAS,GAAG,UAAU,CAAC;IAC1C,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAC3B,6DAA6D;IA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E,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,wBAAwB,CAAC,CAAC,EACvD,KAAK,SAAI,GACR,yBAAyB,EAAE,CAiB7B;AA8SD;;;GAGG;AACH,wBAAgB,0BAA0B,CACxC,OAAO,EAAE,WAAW,EACpB,SAAS,EAAE,MAAM,GAChB,qBAAqB,CAsMvB;AAED,4DAA4D;AAC5D,wBAAgB,uBAAuB,CAAC,IAAI,EAAE,qBAAqB,GAAG,MAAM,CA+O3E"}
|
|
@@ -18,7 +18,10 @@ function jobRow(view) {
|
|
|
18
18
|
...(view.label ? { label: view.label } : {}),
|
|
19
19
|
};
|
|
20
20
|
}
|
|
21
|
-
function teamTaskRow(task) {
|
|
21
|
+
function teamTaskRow(task, runtime) {
|
|
22
|
+
const lease = task.worktreeId !== undefined
|
|
23
|
+
? runtime.managedWorktrees.get(task.worktreeId)
|
|
24
|
+
: undefined;
|
|
22
25
|
return {
|
|
23
26
|
id: task.id,
|
|
24
27
|
title: task.title,
|
|
@@ -33,6 +36,8 @@ function teamTaskRow(task) {
|
|
|
33
36
|
...(task.worktreePath ? { worktreePath: task.worktreePath } : {}),
|
|
34
37
|
...(task.worktreeBranch ? { worktreeBranch: task.worktreeBranch } : {}),
|
|
35
38
|
...(task.worktreeId ? { worktreeId: task.worktreeId } : {}),
|
|
39
|
+
...(lease?.status ? { worktreeLeaseStatus: lease.status } : {}),
|
|
40
|
+
...(task.resultPreview ? { resultPreview: task.resultPreview } : {}),
|
|
36
41
|
};
|
|
37
42
|
}
|
|
38
43
|
const ZERO_BUCKETS = {
|
|
@@ -107,6 +112,12 @@ function billingFromLedger() {
|
|
|
107
112
|
try {
|
|
108
113
|
const state = costMeterGetState();
|
|
109
114
|
const month = state.month;
|
|
115
|
+
const history = [...(state.history ?? [])].sort((a, b) => a.date.localeCompare(b.date));
|
|
116
|
+
const dailyTrend = history.slice(-14).map((day) => ({
|
|
117
|
+
date: day.date,
|
|
118
|
+
cost: day.cost,
|
|
119
|
+
tokens: dayTokens(day),
|
|
120
|
+
}));
|
|
110
121
|
return {
|
|
111
122
|
todayCost: state.today.cost,
|
|
112
123
|
monthCost: month.cost,
|
|
@@ -115,6 +126,7 @@ function billingFromLedger() {
|
|
|
115
126
|
monthTokens: dayTokens(month),
|
|
116
127
|
byModel: rankCostModelRows(asBucketMap(month.byModel)),
|
|
117
128
|
byProviderModel: rankCostModelRows(asBucketMap(month.byProviderModel)),
|
|
129
|
+
dailyTrend,
|
|
118
130
|
};
|
|
119
131
|
}
|
|
120
132
|
catch {
|
|
@@ -126,9 +138,78 @@ function billingFromLedger() {
|
|
|
126
138
|
monthTokens: 0,
|
|
127
139
|
byModel: [],
|
|
128
140
|
byProviderModel: [],
|
|
141
|
+
dailyTrend: [],
|
|
129
142
|
};
|
|
130
143
|
}
|
|
131
144
|
}
|
|
145
|
+
function channelAlertsFromDiscover(channels) {
|
|
146
|
+
const alerts = [];
|
|
147
|
+
for (const im of channels.im) {
|
|
148
|
+
if (im.wired === "bridge" || im.wired === "stub" || im.wired === "discover") {
|
|
149
|
+
alerts.push({
|
|
150
|
+
id: `im:${im.channelId}`,
|
|
151
|
+
severity: "info",
|
|
152
|
+
message: `IM ${im.displayName || im.channelId} is ${im.wired} (not long-lived)`,
|
|
153
|
+
});
|
|
154
|
+
}
|
|
155
|
+
}
|
|
156
|
+
if (channels.process.length === 0 && channels.im.every((c) => c.wired === "bridge")) {
|
|
157
|
+
alerts.push({
|
|
158
|
+
id: "channels:empty",
|
|
159
|
+
severity: "info",
|
|
160
|
+
message: "No process channels; IM entries are bridge stubs only",
|
|
161
|
+
});
|
|
162
|
+
}
|
|
163
|
+
if (channels.note.trim()) {
|
|
164
|
+
alerts.push({
|
|
165
|
+
id: "channels:note",
|
|
166
|
+
severity: "info",
|
|
167
|
+
message: channels.note.trim().slice(0, 160),
|
|
168
|
+
});
|
|
169
|
+
}
|
|
170
|
+
return alerts.slice(0, 8);
|
|
171
|
+
}
|
|
172
|
+
function buildFleet(input) {
|
|
173
|
+
const runningJobs = input.jobs.filter((j) => j.status === "running").length;
|
|
174
|
+
const runningSubagents = input.live.filter((s) => s.activity === "running").length;
|
|
175
|
+
const queuedInbox = input.live.reduce((n, s) => n + (s.queued ?? 0) + (s.steering ?? 0), 0);
|
|
176
|
+
const alerts = [...input.channelAlerts];
|
|
177
|
+
if (input.quota.slotsFree <= 0 && input.quota.maxActive > 0) {
|
|
178
|
+
alerts.unshift({
|
|
179
|
+
id: "fleet:slots",
|
|
180
|
+
severity: "warn",
|
|
181
|
+
message: `Subagent slots full (${input.quota.active}/${input.quota.maxActive})`,
|
|
182
|
+
});
|
|
183
|
+
}
|
|
184
|
+
if (queuedInbox > 0) {
|
|
185
|
+
alerts.unshift({
|
|
186
|
+
id: "fleet:inbox",
|
|
187
|
+
severity: "warn",
|
|
188
|
+
message: `${queuedInbox} child inbox admit(s) waiting (queue/steer)`,
|
|
189
|
+
});
|
|
190
|
+
}
|
|
191
|
+
if (input.quota.depth >= input.quota.maxDepth && input.quota.maxDepth > 0) {
|
|
192
|
+
alerts.unshift({
|
|
193
|
+
id: "fleet:depth",
|
|
194
|
+
severity: "critical",
|
|
195
|
+
message: `Delegation depth at cap (${input.quota.depth}/${input.quota.maxDepth})`,
|
|
196
|
+
});
|
|
197
|
+
}
|
|
198
|
+
let health = "ok";
|
|
199
|
+
if (alerts.some((a) => a.severity === "critical"))
|
|
200
|
+
health = "critical";
|
|
201
|
+
else if (alerts.some((a) => a.severity === "warn"))
|
|
202
|
+
health = "warn";
|
|
203
|
+
return {
|
|
204
|
+
health,
|
|
205
|
+
runningJobs,
|
|
206
|
+
runningSubagents,
|
|
207
|
+
slotsFree: input.quota.slotsFree,
|
|
208
|
+
queuedInbox,
|
|
209
|
+
channelAlerts: input.channelAlerts.length,
|
|
210
|
+
alerts: alerts.slice(0, 12),
|
|
211
|
+
};
|
|
212
|
+
}
|
|
132
213
|
function injectSourceLabel(ev) {
|
|
133
214
|
if (ev.name)
|
|
134
215
|
return `${ev.source ?? ev.form ?? "inject"}:${ev.name}`;
|
|
@@ -146,6 +227,8 @@ function summarizeTimelineEvents(events) {
|
|
|
146
227
|
let spillCount = 0;
|
|
147
228
|
let pruneCount = 0;
|
|
148
229
|
let summaryCount = 0;
|
|
230
|
+
const spillPathList = [];
|
|
231
|
+
const spillPathSeen = new Set();
|
|
149
232
|
// Per-turn markers for prune-first → summary pairing (DSH soft-budget order).
|
|
150
233
|
const turnPrune = new Set();
|
|
151
234
|
const turnSummary = new Map();
|
|
@@ -174,6 +257,13 @@ function summarizeTimelineEvents(events) {
|
|
|
174
257
|
pruneCount += 1;
|
|
175
258
|
if (ev.spill)
|
|
176
259
|
spillCount += 1;
|
|
260
|
+
const path = typeof ev.spillPath === "string"
|
|
261
|
+
? String(ev.spillPath).trim()
|
|
262
|
+
: "";
|
|
263
|
+
if (path && !spillPathSeen.has(path)) {
|
|
264
|
+
spillPathSeen.add(path);
|
|
265
|
+
spillPathList.push(path);
|
|
266
|
+
}
|
|
177
267
|
turnPrune.add(ev.turn);
|
|
178
268
|
if (ev.turn >= lastStageTurn)
|
|
179
269
|
lastStageTurn = ev.turn;
|
|
@@ -208,6 +298,7 @@ function summarizeTimelineEvents(events) {
|
|
|
208
298
|
summaryCount,
|
|
209
299
|
pipeline,
|
|
210
300
|
stages,
|
|
301
|
+
spillPaths: spillPathList.slice(-12),
|
|
211
302
|
};
|
|
212
303
|
}
|
|
213
304
|
function deliveryNote(input) {
|
|
@@ -292,6 +383,8 @@ export function buildSessionStatusSnapshot(runtime, sessionId) {
|
|
|
292
383
|
else
|
|
293
384
|
queued += 1;
|
|
294
385
|
}
|
|
386
|
+
const externalKind = runtime.externalAgents.kind(link.childSessionId);
|
|
387
|
+
const externalResume = runtime.externalAgents.resumeState(link.childSessionId);
|
|
295
388
|
live.push({
|
|
296
389
|
id: link.childSessionId,
|
|
297
390
|
activity,
|
|
@@ -301,6 +394,8 @@ export function buildSessionStatusSnapshot(runtime, sessionId) {
|
|
|
301
394
|
...(line.tool ? { liveTool: line.tool } : {}),
|
|
302
395
|
...(queued > 0 ? { queued } : {}),
|
|
303
396
|
...(steering > 0 ? { steering } : {}),
|
|
397
|
+
...(externalKind ? { externalKind } : {}),
|
|
398
|
+
...(externalResume ? { externalResume } : {}),
|
|
304
399
|
});
|
|
305
400
|
}
|
|
306
401
|
const quota = resolveSubagentQuota(runtime, sessionId);
|
|
@@ -321,7 +416,7 @@ export function buildSessionStatusSnapshot(runtime, sessionId) {
|
|
|
321
416
|
const teamTasks = runtime.agentTeamTasks
|
|
322
417
|
.list(sessionId)
|
|
323
418
|
.slice(0, 24)
|
|
324
|
-
.map(teamTaskRow);
|
|
419
|
+
.map((t) => teamTaskRow(t, runtime));
|
|
325
420
|
const snap = runtime.projections.snapshot(sessionId);
|
|
326
421
|
const costRaw = snap.values.costUsage;
|
|
327
422
|
const cost = costFromProjection(costRaw);
|
|
@@ -364,9 +459,20 @@ export function buildSessionStatusSnapshot(runtime, sessionId) {
|
|
|
364
459
|
else
|
|
365
460
|
queued += 1;
|
|
366
461
|
}
|
|
462
|
+
const loopValue = runtime.settingsNamespaces.view("agent-loop").value;
|
|
463
|
+
const strategyRaw = String(loopValue.compactionStrategy ?? "").trim();
|
|
464
|
+
const strategy = strategyRaw === "prune-summary" ||
|
|
465
|
+
strategyRaw === "prune-only" ||
|
|
466
|
+
strategyRaw === "summary-only" ||
|
|
467
|
+
strategyRaw === "off"
|
|
468
|
+
? strategyRaw
|
|
469
|
+
: "prune-summary";
|
|
470
|
+
const guardian = loopValue.guardianFragments !== false;
|
|
367
471
|
const compaction = {
|
|
368
472
|
pipeline: eventSummary.pipeline,
|
|
369
473
|
stages: eventSummary.stages,
|
|
474
|
+
strategy,
|
|
475
|
+
guardian,
|
|
370
476
|
...(eventSummary.lastCompactReason
|
|
371
477
|
? { lastReason: eventSummary.lastCompactReason }
|
|
372
478
|
: {}),
|
|
@@ -376,6 +482,9 @@ export function buildSessionStatusSnapshot(runtime, sessionId) {
|
|
|
376
482
|
pruneCount: eventSummary.pruneCount,
|
|
377
483
|
summaryCount: eventSummary.summaryCount,
|
|
378
484
|
spillCount: eventSummary.spillCount,
|
|
485
|
+
...(eventSummary.spillPaths.length > 0
|
|
486
|
+
? { spillPaths: eventSummary.spillPaths }
|
|
487
|
+
: {}),
|
|
379
488
|
phase: turnActive ? "busy" : "idle",
|
|
380
489
|
};
|
|
381
490
|
const delivery = {
|
|
@@ -390,6 +499,11 @@ export function buildSessionStatusSnapshot(runtime, sessionId) {
|
|
|
390
499
|
const discover = buildFaceChannelDiscover(runtime.plugins, {
|
|
391
500
|
imGatewayWired: resolveImGatewayWired(),
|
|
392
501
|
});
|
|
502
|
+
const channelAlertRows = channelAlertsFromDiscover({
|
|
503
|
+
process: discover.process,
|
|
504
|
+
im: discover.im,
|
|
505
|
+
note: discover.note,
|
|
506
|
+
});
|
|
393
507
|
const channels = {
|
|
394
508
|
process: discover.process.map((p) => ({
|
|
395
509
|
pluginId: p.pluginId,
|
|
@@ -402,7 +516,14 @@ export function buildSessionStatusSnapshot(runtime, sessionId) {
|
|
|
402
516
|
wired: c.wired,
|
|
403
517
|
})),
|
|
404
518
|
note: discover.note,
|
|
519
|
+
alerts: channelAlertRows,
|
|
405
520
|
};
|
|
521
|
+
const fleet = buildFleet({
|
|
522
|
+
jobs,
|
|
523
|
+
live,
|
|
524
|
+
quota,
|
|
525
|
+
channelAlerts: channelAlertRows,
|
|
526
|
+
});
|
|
406
527
|
return {
|
|
407
528
|
sessionId,
|
|
408
529
|
badge,
|
|
@@ -417,6 +538,7 @@ export function buildSessionStatusSnapshot(runtime, sessionId) {
|
|
|
417
538
|
teamTasks,
|
|
418
539
|
cost,
|
|
419
540
|
billing,
|
|
541
|
+
fleet,
|
|
420
542
|
timeline,
|
|
421
543
|
compaction,
|
|
422
544
|
delivery,
|
|
@@ -458,12 +580,21 @@ export function formatSessionStatusText(snap) {
|
|
|
458
580
|
const inbox = (sub.queued ?? 0) > 0 || (sub.steering ?? 0) > 0
|
|
459
581
|
? ` q=${sub.queued ?? 0}/steer=${sub.steering ?? 0}`
|
|
460
582
|
: "";
|
|
461
|
-
|
|
583
|
+
const ext = sub.externalKind
|
|
584
|
+
? ` · ext:${sub.externalKind}${sub.externalResume ? `/${sub.externalResume}` : ""}`
|
|
585
|
+
: "";
|
|
586
|
+
lines.push(` - ${sub.label ?? sub.id} [${tip}]${inbox}${ext}`);
|
|
462
587
|
}
|
|
463
588
|
for (const sub of snap.subagents.live
|
|
464
|
-
.filter((s) => s.activity !== "running" &&
|
|
589
|
+
.filter((s) => s.activity !== "running" &&
|
|
590
|
+
(s.externalResume === "cold" ||
|
|
591
|
+
(s.queued ?? 0) > 0 ||
|
|
592
|
+
(s.steering ?? 0) > 0))
|
|
465
593
|
.slice(0, 4)) {
|
|
466
|
-
|
|
594
|
+
const ext = sub.externalKind
|
|
595
|
+
? ` · ext:${sub.externalKind}${sub.externalResume ? `/${sub.externalResume}` : ""}`
|
|
596
|
+
: "";
|
|
597
|
+
lines.push(` - ${sub.label ?? sub.id} [idle · q=${sub.queued ?? 0}/steer=${sub.steering ?? 0}]${ext}`);
|
|
467
598
|
}
|
|
468
599
|
const openTasks = snap.teamTasks.filter((t) => t.status === "pending" ||
|
|
469
600
|
t.status === "in_progress" ||
|
|
@@ -475,6 +606,7 @@ export function formatSessionStatusText(snap) {
|
|
|
475
606
|
task.status,
|
|
476
607
|
task.role ? `role:${task.role}` : null,
|
|
477
608
|
task.humanOwned ? "human" : null,
|
|
609
|
+
task.childSessionId ? `child:${task.childSessionId}` : null,
|
|
478
610
|
task.worktreeBranch ? `wt:${task.worktreeBranch}` : null,
|
|
479
611
|
task.schemaValid === false
|
|
480
612
|
? "schema!"
|
|
@@ -483,6 +615,18 @@ export function formatSessionStatusText(snap) {
|
|
|
483
615
|
: null,
|
|
484
616
|
].filter(Boolean);
|
|
485
617
|
lines.push(` - ${task.title} [${bits.join(" · ")}] (${task.id})`);
|
|
618
|
+
if (task.resultPreview) {
|
|
619
|
+
lines.push(` result: ${task.resultPreview}`);
|
|
620
|
+
}
|
|
621
|
+
if (task.worktreePath) {
|
|
622
|
+
lines.push(` worktree: ${task.worktreePath}`);
|
|
623
|
+
}
|
|
624
|
+
if (task.worktreeLeaseStatus) {
|
|
625
|
+
lines.push(` worktree_lease: ${task.worktreeLeaseStatus}` +
|
|
626
|
+
(task.worktreeLeaseStatus === "retained"
|
|
627
|
+
? " (ff-only merge blocked — lease kept; Face worktree.merge when ready)"
|
|
628
|
+
: ""));
|
|
629
|
+
}
|
|
486
630
|
}
|
|
487
631
|
lines.push(`cost: $${snap.cost.cost.toFixed(4)} (in ${snap.cost.input} · out ${snap.cost.output}` +
|
|
488
632
|
(snap.cost.cacheRead ? ` · cacheR ${snap.cost.cacheRead}` : "") +
|
|
@@ -499,12 +643,27 @@ export function formatSessionStatusText(snap) {
|
|
|
499
643
|
` · month $${snap.billing.monthCost.toFixed(4)}` +
|
|
500
644
|
` · total $${snap.billing.totalCost.toFixed(4)}` +
|
|
501
645
|
` (cross-session ledger)`);
|
|
646
|
+
if (snap.billing.dailyTrend.length > 0) {
|
|
647
|
+
const recent = snap.billing.dailyTrend.slice(-7);
|
|
648
|
+
lines.push(` daily: ${recent.map((d) => `${d.date.slice(5)}=$${d.cost.toFixed(2)}`).join(" · ")}`);
|
|
649
|
+
}
|
|
502
650
|
if (snap.billing.byProviderModel.length > 0) {
|
|
503
651
|
lines.push(" by model (month ledger):");
|
|
504
652
|
for (const row of snap.billing.byProviderModel.slice(0, 6)) {
|
|
505
653
|
lines.push(` - ${row.key}: $${row.cost.toFixed(4)} (in ${row.input} · out ${row.output})`);
|
|
506
654
|
}
|
|
507
655
|
}
|
|
656
|
+
lines.push(`fleet: ${snap.fleet.health}` +
|
|
657
|
+
` · jobs ${snap.fleet.runningJobs} running` +
|
|
658
|
+
` · subs ${snap.fleet.runningSubagents} live` +
|
|
659
|
+
` · slots_free ${snap.fleet.slotsFree}` +
|
|
660
|
+
(snap.fleet.queuedInbox > 0 ? ` · inbox ${snap.fleet.queuedInbox}` : "") +
|
|
661
|
+
(snap.fleet.channelAlerts > 0
|
|
662
|
+
? ` · channel_alerts ${snap.fleet.channelAlerts}`
|
|
663
|
+
: ""));
|
|
664
|
+
for (const alert of snap.fleet.alerts.slice(0, 6)) {
|
|
665
|
+
lines.push(` - [${alert.severity}] ${alert.message}`);
|
|
666
|
+
}
|
|
508
667
|
lines.push(`timeline: total ${snap.timeline.total}` +
|
|
509
668
|
` (sys ${snap.timeline.system} · tools ${snap.timeline.tools}` +
|
|
510
669
|
` · user ${snap.timeline.user} · inject ${snap.timeline.inject}` +
|
|
@@ -530,6 +689,10 @@ export function formatSessionStatusText(snap) {
|
|
|
530
689
|
: snap.compaction.pipeline;
|
|
531
690
|
lines.push(`compaction: ${snap.compaction.phase}` +
|
|
532
691
|
` · pipeline ${stageLabel}` +
|
|
692
|
+
(snap.compaction.strategy
|
|
693
|
+
? ` · strategy ${snap.compaction.strategy}`
|
|
694
|
+
: "") +
|
|
695
|
+
(snap.compaction.guardian ? " · guardian on" : "") +
|
|
533
696
|
(snap.compaction.lastReason
|
|
534
697
|
? ` · last ${snap.compaction.lastReason}`
|
|
535
698
|
: "") +
|
|
@@ -541,6 +704,11 @@ export function formatSessionStatusText(snap) {
|
|
|
541
704
|
(snap.compaction.spillCount > 0
|
|
542
705
|
? ` · spill ${snap.compaction.spillCount}`
|
|
543
706
|
: ""));
|
|
707
|
+
if (snap.compaction.spillPaths && snap.compaction.spillPaths.length > 0) {
|
|
708
|
+
for (const p of snap.compaction.spillPaths.slice(-6)) {
|
|
709
|
+
lines.push(` spill: ${p}`);
|
|
710
|
+
}
|
|
711
|
+
}
|
|
544
712
|
lines.push(`delivery: ${snap.delivery.note}` +
|
|
545
713
|
` · queued ${snap.delivery.queued}` +
|
|
546
714
|
` · steering ${snap.delivery.steering}` +
|