@selesai/code 0.6.3 → 0.8.0
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 +22 -1
- package/README.md +5 -3
- package/dist/bun/cli.d.ts +0 -1
- package/dist/bun/cli.js +0 -1
- package/dist/bun/register-bedrock.d.ts +0 -1
- package/dist/bun/register-bedrock.js +0 -1
- package/dist/bun/restore-sandbox-env.d.ts +0 -1
- package/dist/bun/restore-sandbox-env.js +0 -1
- package/dist/cli/args.d.ts +0 -1
- package/dist/cli/args.js +0 -1
- package/dist/cli/config-selector.d.ts +0 -1
- package/dist/cli/config-selector.js +0 -1
- package/dist/cli/credential-print.d.ts +0 -1
- package/dist/cli/credential-print.js +0 -1
- package/dist/cli/file-processor.d.ts +0 -1
- package/dist/cli/file-processor.js +0 -1
- package/dist/cli/initial-message.d.ts +0 -1
- package/dist/cli/initial-message.js +0 -1
- package/dist/cli/list-models.d.ts +0 -1
- package/dist/cli/list-models.js +0 -1
- package/dist/cli/project-trust.d.ts +0 -1
- package/dist/cli/project-trust.js +0 -1
- package/dist/cli/session-picker.d.ts +0 -1
- package/dist/cli/session-picker.js +0 -1
- package/dist/cli/startup-ui.d.ts +0 -1
- package/dist/cli/startup-ui.js +0 -1
- package/dist/cli.d.ts +0 -1
- package/dist/cli.js +0 -1
- package/dist/config.d.ts +0 -1
- package/dist/config.js +0 -1
- package/dist/core/agent-session-auto-handoff.test.d.ts +0 -1
- package/dist/core/agent-session-auto-handoff.test.js +0 -1
- package/dist/core/agent-session-runtime.d.ts +0 -1
- package/dist/core/agent-session-runtime.js +0 -1
- package/dist/core/agent-session-services.d.ts +0 -1
- package/dist/core/agent-session-services.js +0 -1
- package/dist/core/agent-session-skill-block.test.d.ts +0 -1
- package/dist/core/agent-session-skill-block.test.js +0 -1
- package/dist/core/agent-session.d.ts +0 -1
- package/dist/core/agent-session.js +0 -1
- package/dist/core/agents.d.ts +0 -1
- package/dist/core/agents.js +0 -1
- package/dist/core/auth-guidance.d.ts +0 -1
- package/dist/core/auth-guidance.js +0 -1
- package/dist/core/auth-storage.d.ts +0 -1
- package/dist/core/auth-storage.js +0 -1
- package/dist/core/bash-executor.d.ts +0 -1
- package/dist/core/bash-executor.js +0 -1
- package/dist/core/built-in-extensions.d.ts +0 -1
- package/dist/core/built-in-extensions.js +0 -1
- package/dist/core/cache-stats.d.ts +0 -1
- package/dist/core/cache-stats.js +0 -1
- package/dist/core/compaction/branch-summarization.d.ts +0 -1
- package/dist/core/compaction/branch-summarization.js +0 -1
- package/dist/core/compaction/compaction.d.ts +0 -1
- package/dist/core/compaction/compaction.js +0 -1
- package/dist/core/compaction/index.d.ts +0 -1
- package/dist/core/compaction/index.js +0 -1
- package/dist/core/compaction/utils.d.ts +0 -1
- package/dist/core/compaction/utils.js +0 -1
- package/dist/core/defaults.d.ts +0 -1
- package/dist/core/defaults.js +0 -1
- package/dist/core/diagnostics.d.ts +0 -1
- package/dist/core/diagnostics.js +0 -1
- package/dist/core/event-bus.d.ts +0 -1
- package/dist/core/event-bus.js +0 -1
- package/dist/core/exec.d.ts +0 -1
- package/dist/core/exec.js +0 -1
- package/dist/core/experimental.d.ts +0 -1
- package/dist/core/experimental.js +0 -1
- package/dist/core/export-html/ansi-to-html.d.ts +0 -1
- package/dist/core/export-html/ansi-to-html.js +0 -1
- package/dist/core/export-html/index.d.ts +0 -1
- package/dist/core/export-html/index.js +0 -1
- package/dist/core/export-html/tool-renderer.d.ts +0 -1
- package/dist/core/export-html/tool-renderer.js +0 -1
- package/dist/core/extensions/index.d.ts +0 -1
- package/dist/core/extensions/index.js +0 -1
- package/dist/core/extensions/loader.d.ts +0 -1
- package/dist/core/extensions/loader.js +0 -1
- package/dist/core/extensions/runner.d.ts +0 -1
- package/dist/core/extensions/runner.js +0 -1
- package/dist/core/extensions/types.d.ts +0 -1
- package/dist/core/extensions/types.js +0 -1
- package/dist/core/extensions/wrapper.d.ts +0 -1
- package/dist/core/extensions/wrapper.js +0 -1
- package/dist/core/footer-data-provider.d.ts +0 -1
- package/dist/core/footer-data-provider.js +0 -1
- package/dist/core/git-command.d.ts +0 -1
- package/dist/core/git-command.js +0 -1
- package/dist/core/http-dispatcher.d.ts +0 -1
- package/dist/core/http-dispatcher.js +0 -1
- package/dist/core/index.d.ts +0 -1
- package/dist/core/index.js +0 -1
- package/dist/core/keybindings.d.ts +0 -1
- package/dist/core/keybindings.js +0 -1
- package/dist/core/llama/client.d.ts +0 -1
- package/dist/core/llama/client.js +0 -1
- package/dist/core/llama/huggingface.d.ts +0 -1
- package/dist/core/llama/huggingface.js +0 -1
- package/dist/core/llama/index.d.ts +0 -1
- package/dist/core/llama/index.js +0 -1
- package/dist/core/llama/provider.d.ts +0 -1
- package/dist/core/llama/provider.js +0 -1
- package/dist/core/llama/ui.d.ts +0 -1
- package/dist/core/llama/ui.js +0 -1
- package/dist/core/messages.d.ts +0 -1
- package/dist/core/messages.js +0 -1
- package/dist/core/model-config.d.ts +0 -1
- package/dist/core/model-config.js +0 -1
- package/dist/core/model-registry.d.ts +0 -1
- package/dist/core/model-registry.js +0 -1
- package/dist/core/model-resolver.d.ts +0 -1
- package/dist/core/model-resolver.js +0 -1
- package/dist/core/model-runtime.d.ts +0 -1
- package/dist/core/model-runtime.js +0 -1
- package/dist/core/models-store.d.ts +0 -1
- package/dist/core/models-store.js +0 -1
- package/dist/core/output-guard.d.ts +0 -1
- package/dist/core/output-guard.js +0 -1
- package/dist/core/package-manager.d.ts +0 -1
- package/dist/core/package-manager.js +0 -1
- package/dist/core/package-manager.test.d.ts +0 -1
- package/dist/core/package-manager.test.js +0 -1
- package/dist/core/project-trust.d.ts +0 -1
- package/dist/core/project-trust.js +0 -1
- package/dist/core/prompt-templates.d.ts +0 -1
- package/dist/core/prompt-templates.js +0 -1
- package/dist/core/provider-attribution.d.ts +0 -1
- package/dist/core/provider-attribution.js +0 -1
- package/dist/core/provider-composer.d.ts +0 -1
- package/dist/core/provider-composer.js +0 -1
- package/dist/core/radius.d.ts +0 -1
- package/dist/core/radius.js +0 -1
- package/dist/core/remote-catalog-provider.d.ts +0 -1
- package/dist/core/remote-catalog-provider.js +0 -1
- package/dist/core/resolve-config-value.d.ts +0 -1
- package/dist/core/resolve-config-value.js +0 -1
- package/dist/core/resource-loader.d.ts +0 -1
- package/dist/core/resource-loader.js +0 -1
- package/dist/core/runtime-credentials.d.ts +0 -1
- package/dist/core/runtime-credentials.js +0 -1
- package/dist/core/sdk.d.ts +0 -1
- package/dist/core/sdk.js +0 -1
- package/dist/core/session-cwd.d.ts +0 -1
- package/dist/core/session-cwd.js +0 -1
- package/dist/core/session-manager.d.ts +0 -1
- package/dist/core/session-manager.js +0 -1
- package/dist/core/settings-manager-auto-handoff.test.d.ts +0 -1
- package/dist/core/settings-manager-auto-handoff.test.js +0 -1
- package/dist/core/settings-manager.d.ts +0 -4
- package/dist/core/settings-manager.js +0 -12
- package/dist/core/skills.d.ts +0 -1
- package/dist/core/skills.js +0 -1
- package/dist/core/slash-commands.d.ts +0 -1
- package/dist/core/slash-commands.js +0 -1
- package/dist/core/source-info.d.ts +0 -1
- package/dist/core/source-info.js +0 -1
- package/dist/core/system-prompt.d.ts +0 -1
- package/dist/core/system-prompt.js +0 -1
- package/dist/core/system-prompt.test.d.ts +0 -1
- package/dist/core/system-prompt.test.js +0 -1
- package/dist/core/telemetry.d.ts +0 -1
- package/dist/core/telemetry.js +0 -1
- package/dist/core/timings.d.ts +0 -1
- package/dist/core/timings.js +0 -1
- package/dist/core/tools/bash.d.ts +0 -1
- package/dist/core/tools/bash.js +0 -1
- package/dist/core/tools/edit-diff.d.ts +0 -1
- package/dist/core/tools/edit-diff.js +0 -1
- package/dist/core/tools/edit.d.ts +0 -1
- package/dist/core/tools/edit.js +0 -1
- package/dist/core/tools/file-mutation-queue.d.ts +0 -1
- package/dist/core/tools/file-mutation-queue.js +0 -1
- package/dist/core/tools/find.d.ts +0 -1
- package/dist/core/tools/find.js +0 -1
- package/dist/core/tools/grep.d.ts +0 -1
- package/dist/core/tools/grep.js +0 -1
- package/dist/core/tools/index.d.ts +0 -1
- package/dist/core/tools/index.js +0 -1
- package/dist/core/tools/ls.d.ts +0 -1
- package/dist/core/tools/ls.js +0 -1
- package/dist/core/tools/output-accumulator.d.ts +0 -1
- package/dist/core/tools/output-accumulator.js +0 -1
- package/dist/core/tools/path-utils.d.ts +0 -1
- package/dist/core/tools/path-utils.js +0 -1
- package/dist/core/tools/read.d.ts +0 -1
- package/dist/core/tools/read.js +0 -1
- package/dist/core/tools/render-utils.d.ts +0 -1
- package/dist/core/tools/render-utils.js +0 -1
- package/dist/core/tools/tool-definition-wrapper.d.ts +0 -1
- package/dist/core/tools/tool-definition-wrapper.js +0 -1
- package/dist/core/tools/truncate.d.ts +0 -1
- package/dist/core/tools/truncate.js +0 -1
- package/dist/core/tools/write.d.ts +0 -1
- package/dist/core/tools/write.js +0 -1
- package/dist/core/trust-manager.d.ts +0 -1
- package/dist/core/trust-manager.js +0 -1
- package/dist/core/usage-totals.d.ts +0 -1
- package/dist/core/usage-totals.js +0 -1
- package/dist/defaults/models.json +8 -0
- package/dist/defaults/settings.json +6 -7
- package/dist/extensions/agent-browser.test.ts +195 -0
- package/dist/extensions/agent-browser.ts +158 -0
- package/dist/extensions/inline-skills.test.ts +27 -13
- package/dist/extensions/inline-skills.ts +18 -11
- package/dist/extensions/package.json +2 -1
- package/dist/extensions/pi-powerline-footer/.github/workflows/test.yml +27 -0
- package/dist/extensions/pi-powerline-footer/CHANGELOG.md +153 -0
- package/dist/extensions/pi-powerline-footer/CONTRIBUTING.md +16 -0
- package/dist/extensions/pi-powerline-footer/README.md +192 -44
- package/dist/extensions/pi-powerline-footer/bash-mode/completion.ts +19 -4
- package/dist/extensions/pi-powerline-footer/bash-mode/editor.ts +80 -25
- package/dist/extensions/pi-powerline-footer/bash-mode/history.ts +81 -29
- package/dist/extensions/pi-powerline-footer/bash-mode/types.ts +1 -1
- package/dist/extensions/pi-powerline-footer/cd-command.ts +190 -0
- package/dist/extensions/pi-powerline-footer/colors.ts +2 -1
- package/dist/extensions/pi-powerline-footer/context-usage.ts +121 -6
- package/dist/extensions/pi-powerline-footer/currency-rates.ts +142 -0
- package/dist/extensions/pi-powerline-footer/editor-composition.ts +32 -0
- package/dist/extensions/pi-powerline-footer/git-status.ts +108 -6
- package/dist/extensions/pi-powerline-footer/icons.ts +11 -2
- package/dist/extensions/pi-powerline-footer/index.ts +1056 -324
- package/dist/extensions/pi-powerline-footer/lifecycle.ts +10 -0
- package/dist/extensions/pi-powerline-footer/package.json +10 -6
- package/dist/extensions/pi-powerline-footer/paths.ts +22 -0
- package/dist/extensions/pi-powerline-footer/powerline-config.ts +297 -15
- package/dist/extensions/pi-powerline-footer/presets.ts +6 -25
- package/dist/extensions/pi-powerline-footer/queue/store.ts +361 -0
- package/dist/extensions/pi-powerline-footer/queue/types.ts +54 -0
- package/dist/extensions/pi-powerline-footer/render-scheduler.ts +12 -7
- package/dist/extensions/pi-powerline-footer/segments.ts +114 -107
- package/dist/extensions/pi-powerline-footer/session-usage.ts +1 -1
- package/dist/extensions/pi-powerline-footer/shortcuts.ts +17 -3
- package/dist/extensions/pi-powerline-footer/tests/bash-mode.test.ts +189 -17
- package/dist/extensions/pi-powerline-footer/tests/cd-command.test.ts +144 -0
- package/dist/extensions/pi-powerline-footer/tests/context-usage.test.ts +120 -2
- package/dist/extensions/pi-powerline-footer/tests/custom-items.test.ts +245 -22
- package/dist/extensions/pi-powerline-footer/tests/editor-composition.test.ts +48 -0
- package/dist/extensions/pi-powerline-footer/tests/editor-responsiveness.test.ts +34 -0
- package/dist/extensions/pi-powerline-footer/tests/fixed-editor-border.test.ts +39 -0
- package/dist/extensions/pi-powerline-footer/tests/git-status.test.ts +92 -0
- package/dist/extensions/pi-powerline-footer/tests/guide.test.ts +4 -1
- package/dist/extensions/pi-powerline-footer/tests/jump-shortcuts.test.ts +33 -197
- package/dist/extensions/pi-powerline-footer/tests/mode-aware-trigger.test.ts +79 -0
- package/dist/extensions/pi-powerline-footer/tests/paths.test.ts +63 -0
- package/dist/extensions/pi-powerline-footer/tests/queue-store.test.ts +195 -0
- package/dist/extensions/pi-powerline-footer/tests/quit-cursor.test.ts +14 -0
- package/dist/extensions/pi-powerline-footer/tests/remaining-regressions.test.ts +167 -0
- package/dist/extensions/pi-powerline-footer/tests/stash-shortcut.test.ts +23 -18
- package/dist/extensions/pi-powerline-footer/tests/thinking-segment.test.ts +16 -1
- package/dist/extensions/pi-powerline-footer/tests/token-stats.test.ts +249 -0
- package/dist/extensions/pi-powerline-footer/tests/usage-display.test.ts +237 -0
- package/dist/extensions/pi-powerline-footer/tests/welcome.test.ts +199 -0
- package/dist/extensions/pi-powerline-footer/tests/working-vibes.test.ts +191 -100
- package/dist/extensions/pi-powerline-footer/theme.ts +32 -18
- package/dist/extensions/pi-powerline-footer/token-stats.ts +304 -0
- package/dist/extensions/pi-powerline-footer/tsconfig.json +13 -0
- package/dist/extensions/pi-powerline-footer/types.ts +74 -29
- package/dist/extensions/pi-powerline-footer/welcome-dismiss.ts +34 -0
- package/dist/extensions/pi-powerline-footer/welcome.ts +65 -10
- package/dist/extensions/pi-powerline-footer/working-vibes.ts +44 -11
- package/dist/extensions/pi-subagents/CHANGELOG.md +89 -12
- package/dist/extensions/pi-subagents/README.md +339 -604
- package/dist/extensions/pi-subagents/package-lock.json +190 -2079
- package/dist/extensions/pi-subagents/package.json +13 -5
- package/dist/extensions/pi-subagents/prompts/parallel-context-build.md +1 -1
- package/dist/extensions/pi-subagents/prompts/parallel-handoff-plan.md +1 -1
- package/dist/extensions/pi-subagents/prompts/review-loop.md +1 -1
- package/dist/extensions/pi-subagents/skills/pi-subagents/SKILL.md +10 -10
- package/dist/extensions/pi-subagents/skills/pi-subagents/references/constraints-and-recipes.md +32 -43
- package/dist/extensions/pi-subagents/skills/pi-subagents/references/execution-controls.md +106 -105
- package/dist/extensions/pi-subagents/skills/pi-subagents/references/management-authoring-rpc.md +3 -3
- package/dist/extensions/pi-subagents/skills/pi-subagents/references/prompting-and-roles.md +28 -35
- package/dist/extensions/pi-subagents/src/agents/agent-management.ts +167 -124
- package/dist/extensions/pi-subagents/src/agents/agent-serializer.ts +19 -0
- package/dist/extensions/pi-subagents/src/agents/agents.ts +163 -75
- package/dist/extensions/pi-subagents/src/agents/chain-serializer.ts +10 -7
- package/dist/extensions/pi-subagents/src/agents/frontmatter.ts +5 -3
- package/dist/extensions/pi-subagents/src/agents/identity.ts +1 -1
- package/dist/extensions/pi-subagents/src/agents/proactive-skills.ts +14 -11
- package/dist/extensions/pi-subagents/src/agents/skills.ts +23 -6
- package/dist/extensions/pi-subagents/src/agents/task-aware-routing.ts +8 -1
- package/dist/extensions/pi-subagents/src/api/control-channel.ts +4 -0
- package/dist/extensions/pi-subagents/src/api/delegation.ts +26 -194
- package/dist/extensions/pi-subagents/src/api/external-runs.ts +129 -0
- package/dist/extensions/pi-subagents/src/api/intercom-bridge.ts +3 -0
- package/dist/extensions/pi-subagents/src/api/pi-args.ts +5 -0
- package/dist/extensions/pi-subagents/src/api/preflight.ts +4 -4
- package/dist/extensions/pi-subagents/src/api/shared-types.ts +19 -0
- package/dist/extensions/pi-subagents/src/extension/config.ts +10 -0
- package/dist/extensions/pi-subagents/src/extension/control-notices.ts +5 -39
- package/dist/extensions/pi-subagents/src/extension/doctor.ts +10 -9
- package/dist/extensions/pi-subagents/src/extension/fanout-child.ts +7 -4
- package/dist/extensions/pi-subagents/src/extension/index.ts +243 -77
- package/dist/extensions/pi-subagents/src/extension/rpc.ts +18 -6
- package/dist/extensions/pi-subagents/src/extension/schemas.ts +50 -39
- package/dist/extensions/pi-subagents/src/extension/tool-description.ts +36 -103
- package/dist/extensions/pi-subagents/src/inspectors/herdr/actions.ts +229 -0
- package/dist/extensions/pi-subagents/src/inspectors/herdr/client.ts +130 -0
- package/dist/extensions/pi-subagents/src/inspectors/herdr/inspector-runner.ts +141 -0
- package/dist/extensions/pi-subagents/src/inspectors/herdr/project-panes.ts +154 -0
- package/dist/extensions/pi-subagents/src/integrations/herdr-status.ts +330 -0
- package/dist/extensions/pi-subagents/src/intercom/intercom-bridge.ts +3 -2
- package/dist/extensions/pi-subagents/src/intercom/result-intercom.ts +5 -1
- package/dist/extensions/pi-subagents/src/missions/actions.ts +372 -0
- package/dist/extensions/pi-subagents/src/missions/lifecycle.ts +314 -0
- package/dist/extensions/pi-subagents/src/missions/store.ts +442 -0
- package/dist/extensions/pi-subagents/src/missions/types.ts +135 -0
- package/dist/extensions/pi-subagents/src/policy/authority.ts +46 -0
- package/dist/extensions/pi-subagents/src/profiles/profiles.ts +32 -6
- package/dist/extensions/pi-subagents/src/runs/background/async-execution.ts +103 -72
- package/dist/extensions/pi-subagents/src/runs/background/async-job-tracker.ts +10 -2
- package/dist/extensions/pi-subagents/src/runs/background/async-resume.ts +6 -6
- package/dist/extensions/pi-subagents/src/runs/background/async-status.ts +29 -1
- package/dist/extensions/pi-subagents/src/runs/background/auto-drain.ts +3 -3
- package/dist/extensions/pi-subagents/src/runs/background/chain-append.ts +3 -2
- package/dist/extensions/pi-subagents/src/runs/background/control-channel.ts +9 -7
- package/dist/extensions/pi-subagents/src/runs/background/fleet-view.ts +3 -4
- package/dist/extensions/pi-subagents/src/runs/background/notify.ts +3 -28
- package/dist/extensions/pi-subagents/src/runs/background/process-terminal.ts +5 -5
- package/dist/extensions/pi-subagents/src/runs/background/result-watcher.ts +18 -68
- package/dist/extensions/pi-subagents/src/runs/background/run-id-resolver.ts +3 -3
- package/dist/extensions/pi-subagents/src/runs/background/run-status.ts +35 -8
- package/dist/extensions/pi-subagents/src/runs/background/scheduled-runs.ts +602 -375
- package/dist/extensions/pi-subagents/src/runs/background/stale-run-reconciler.ts +3 -3
- package/dist/extensions/pi-subagents/src/runs/background/subagent-runner.ts +612 -464
- package/dist/extensions/pi-subagents/src/runs/background/subagent-wait.ts +50 -9
- package/dist/extensions/pi-subagents/src/runs/background/wait-subscriptions.ts +253 -0
- package/dist/extensions/pi-subagents/src/runs/background/wait-tool.ts +12 -4
- package/dist/extensions/pi-subagents/src/runs/foreground/async-steering-action.ts +3 -3
- package/dist/extensions/pi-subagents/src/runs/foreground/chain-clarify.ts +8 -4
- package/dist/extensions/pi-subagents/src/runs/foreground/chain-execution.ts +74 -102
- package/dist/extensions/pi-subagents/src/runs/foreground/execution.ts +21 -22
- package/dist/extensions/pi-subagents/src/runs/foreground/subagent-executor.ts +1050 -396
- package/dist/extensions/pi-subagents/src/runs/shared/acceptance.ts +44 -18
- package/dist/extensions/pi-subagents/src/runs/shared/capability-ceiling.ts +0 -1
- package/dist/extensions/pi-subagents/src/runs/shared/child-protocol.ts +302 -22
- package/dist/extensions/pi-subagents/src/runs/shared/dynamic-fanout.ts +1 -1
- package/dist/extensions/pi-subagents/src/runs/shared/external-cli-runner.ts +130 -0
- package/dist/extensions/pi-subagents/src/runs/shared/long-running-guard.ts +42 -1
- package/dist/extensions/pi-subagents/src/runs/shared/model-fallback.ts +1 -1
- package/dist/extensions/pi-subagents/src/runs/shared/nested-events.ts +59 -5
- package/dist/extensions/pi-subagents/src/runs/shared/nested-render.ts +9 -4
- package/dist/extensions/pi-subagents/src/runs/shared/parallel-handoff.ts +86 -2
- package/dist/extensions/pi-subagents/src/runs/shared/parallel-utils.ts +11 -2
- package/dist/extensions/pi-subagents/src/runs/shared/permissions.ts +95 -0
- package/dist/extensions/pi-subagents/src/runs/shared/pi-args.ts +11 -1
- package/dist/extensions/pi-subagents/src/runs/shared/pi-spawn.ts +15 -6
- package/dist/extensions/pi-subagents/src/runs/shared/run-history.ts +1 -1
- package/dist/extensions/pi-subagents/src/runs/shared/single-output.ts +9 -63
- package/dist/extensions/pi-subagents/src/runs/shared/subagent-prompt-runtime.ts +37 -6
- package/dist/extensions/pi-subagents/src/runs/shared/subagent-startup-retry.ts +5 -2
- package/dist/extensions/pi-subagents/src/runs/shared/task-intent.ts +2 -23
- package/dist/extensions/pi-subagents/src/runs/shared/turn-budget.ts +6 -6
- package/dist/extensions/pi-subagents/src/runs/shared/worktree.ts +124 -13
- package/dist/extensions/pi-subagents/src/shared/accessible-dir.ts +29 -7
- package/dist/extensions/pi-subagents/src/shared/artifacts.ts +18 -1
- package/dist/extensions/pi-subagents/src/shared/fork-context.ts +3 -2
- package/dist/extensions/pi-subagents/src/shared/launch-contract.ts +1 -0
- package/dist/extensions/pi-subagents/src/shared/settings.ts +10 -0
- package/dist/extensions/pi-subagents/src/shared/types.ts +158 -55
- package/dist/extensions/pi-subagents/src/shared/utils.ts +16 -66
- package/dist/extensions/pi-subagents/src/slash/delegation-adapters.ts +33 -199
- package/dist/extensions/pi-subagents/src/slash/delegation-request.ts +43 -126
- package/dist/extensions/pi-subagents/src/slash/inline-subagents.ts +136 -0
- package/dist/extensions/pi-subagents/src/slash/prompt-template-bridge.ts +158 -205
- package/dist/extensions/pi-subagents/src/slash/prompt-workflows.ts +22 -58
- package/dist/extensions/pi-subagents/src/slash/slash-bridge.ts +14 -0
- package/dist/extensions/pi-subagents/src/slash/slash-commands.ts +44 -642
- package/dist/extensions/pi-subagents/src/slash/subagents-admin.ts +18 -14
- package/dist/extensions/pi-subagents/src/tui/fleet-status.ts +156 -21
- package/dist/extensions/pi-subagents/src/tui/fleet-transcript.ts +110 -5
- package/dist/extensions/pi-subagents/src/tui/fleet.ts +60 -24
- package/dist/extensions/pi-subagents/src/tui/render.ts +296 -140
- package/dist/extensions/pi-subagents/src/types/pi-runtime-compat.d.ts +14 -0
- package/dist/extensions/pi-subagents/src/watchdog/change-signature.ts +1 -1
- package/dist/extensions/pi-subagents/src/watchdog/lsp-diagnostics.ts +13 -7
- package/dist/extensions/pi-subagents/src/watchdog/model-selection.ts +2 -2
- package/dist/extensions/pi-subagents/src/watchdog/permission-arbiter.ts +145 -0
- package/dist/extensions/pi-subagents/src/watchdog/register-child.ts +1 -1
- package/dist/extensions/pi-subagents/src/watchdog/register-main.ts +1 -1
- package/dist/extensions/pi-subagents/src/watchdog/review.ts +4 -1
- package/dist/extensions/pi-subagents/src/watchdog/runtime.ts +3 -2
- package/dist/extensions/pi-subagents/src/workflows/chat-progress.ts +140 -0
- package/dist/extensions/pi-subagents/src/workflows/scripted-workflow.ts +415 -0
- package/dist/extensions/pi-subagents/test/e2e/real-session-subagent.test.ts +41 -144
- package/dist/extensions/pi-subagents/test/integration/acceptance-file-report.test.ts +16 -16
- package/dist/extensions/pi-subagents/test/integration/async-execution.test.ts +415 -298
- package/dist/extensions/pi-subagents/test/integration/async-job-tracker.test.ts +149 -82
- package/dist/extensions/pi-subagents/test/integration/async-status.test.ts +40 -40
- package/dist/extensions/pi-subagents/test/integration/chain-clarify.test.ts +15 -15
- package/dist/extensions/pi-subagents/test/integration/chain-execution.test.ts +193 -133
- package/dist/extensions/pi-subagents/test/integration/detect-error.test.ts +1 -49
- package/dist/extensions/pi-subagents/test/integration/external-cli-runner.test.ts +62 -0
- package/dist/extensions/pi-subagents/test/integration/fork-context-execution.test.ts +56 -58
- package/dist/extensions/pi-subagents/test/integration/intercom-result-delivery.test.ts +81 -68
- package/dist/extensions/pi-subagents/test/integration/parallel-execution.test.ts +20 -25
- package/dist/extensions/pi-subagents/test/integration/render-fork-badge.test.ts +425 -317
- package/dist/extensions/pi-subagents/test/integration/render-widget.test.ts +73 -73
- package/dist/extensions/pi-subagents/test/integration/result-watcher.test.ts +123 -98
- package/dist/extensions/pi-subagents/test/integration/single-execution.test.ts +653 -240
- package/dist/extensions/pi-subagents/test/integration/slash-commands.test.ts +20 -1661
- package/dist/extensions/pi-subagents/test/integration/slash-live-state.test.ts +9 -9
- package/dist/extensions/pi-subagents/test/integration/template-resolution.test.ts +3 -3
- package/dist/extensions/pi-subagents/test/integration/top-level-async.test.ts +2 -2
- package/dist/extensions/pi-subagents/test/support/mock-pi-script.mjs +8 -5
- package/dist/extensions/pi-subagents/test/support/mock-pi.ts +6 -6
- package/dist/extensions/pi-subagents/test/support/real-session-runner.ts +4 -20
- package/dist/extensions/pi-subagents/test/unit/acceptance.test.ts +25 -4
- package/dist/extensions/pi-subagents/test/unit/agent-disabled.test.ts +1 -1
- package/dist/extensions/pi-subagents/test/unit/agent-frontmatter.test.ts +280 -295
- package/dist/extensions/pi-subagents/test/unit/agent-management.test.ts +47 -207
- package/dist/extensions/pi-subagents/test/unit/agent-memory.test.ts +26 -26
- package/dist/extensions/pi-subagents/test/unit/agent-overrides.test.ts +89 -89
- package/dist/extensions/pi-subagents/test/unit/agent-selection.test.ts +9 -9
- package/dist/extensions/pi-subagents/test/unit/artifacts.test.ts +10 -0
- package/dist/extensions/pi-subagents/test/unit/async-execution.test.ts +33 -9
- package/dist/extensions/pi-subagents/test/unit/async-interrupt-action.test.ts +24 -2
- package/dist/extensions/pi-subagents/test/unit/async-permission-session.test.ts +11 -9
- package/dist/extensions/pi-subagents/test/unit/async-recovery-descriptor.test.ts +2 -2
- package/dist/extensions/pi-subagents/test/unit/async-resume.test.ts +40 -40
- package/dist/extensions/pi-subagents/test/unit/authority-policy.test.ts +22 -0
- package/dist/extensions/pi-subagents/test/unit/background-work.test.ts +1 -1
- package/dist/extensions/pi-subagents/test/unit/capability-ceiling-agent-allowlist.test.ts +5 -39
- package/dist/extensions/pi-subagents/test/unit/chain-append.test.ts +19 -19
- package/dist/extensions/pi-subagents/test/unit/chain-root-attachment.test.ts +9 -9
- package/dist/extensions/pi-subagents/test/unit/chain-serializer.test.ts +20 -20
- package/dist/extensions/pi-subagents/test/unit/child-protocol.test.ts +99 -0
- package/dist/extensions/pi-subagents/test/unit/child-transcript.test.ts +9 -9
- package/dist/extensions/pi-subagents/test/unit/compaction-resume.test.ts +41 -0
- package/dist/extensions/pi-subagents/test/unit/completion-dedupe.test.ts +2 -2
- package/dist/extensions/pi-subagents/test/unit/completion-guard.test.ts +35 -5
- package/dist/extensions/pi-subagents/test/unit/config-dir-runtime.test.ts +7 -0
- package/dist/extensions/pi-subagents/test/unit/control-notices.test.ts +16 -82
- package/dist/extensions/pi-subagents/test/unit/delegation-api.test.ts +162 -620
- package/dist/extensions/pi-subagents/test/unit/doctor.test.ts +1 -1
- package/dist/extensions/pi-subagents/test/unit/dynamic-fanout.test.ts +25 -25
- package/dist/extensions/pi-subagents/test/unit/ensure-accessible-dir.test.ts +125 -0
- package/dist/extensions/pi-subagents/test/unit/external-cli-runner.test.ts +94 -0
- package/dist/extensions/pi-subagents/test/unit/external-runs.test.ts +66 -0
- package/dist/extensions/pi-subagents/test/unit/extra-agent-dirs.test.ts +3 -3
- package/dist/extensions/pi-subagents/test/unit/fleet-status.test.ts +242 -52
- package/dist/extensions/pi-subagents/test/unit/fleet-transcript.test.ts +127 -0
- package/dist/extensions/pi-subagents/test/unit/fleet.test.ts +197 -36
- package/dist/extensions/pi-subagents/test/unit/foreground-control.test.ts +4 -4
- package/dist/extensions/pi-subagents/test/unit/herdr-inspector.test.ts +245 -0
- package/dist/extensions/pi-subagents/test/unit/herdr-status-bridge.test.ts +494 -0
- package/dist/extensions/pi-subagents/test/unit/index-child-registration.test.ts +261 -31
- package/dist/extensions/pi-subagents/test/unit/inline-subagents.test.ts +127 -0
- package/dist/extensions/pi-subagents/test/unit/intercom-bridge.test.ts +6 -6
- package/dist/extensions/pi-subagents/test/unit/mission-lifecycle.test.ts +217 -0
- package/dist/extensions/pi-subagents/test/unit/mission-store.test.ts +182 -0
- package/dist/extensions/pi-subagents/test/unit/mock-pi.test.ts +22 -0
- package/dist/extensions/pi-subagents/test/unit/model-fallback.test.ts +1 -1
- package/dist/extensions/pi-subagents/test/unit/native-supervisor-channel.test.ts +10 -10
- package/dist/extensions/pi-subagents/test/unit/nested-control.test.ts +20 -12
- package/dist/extensions/pi-subagents/test/unit/nested-events.test.ts +47 -5
- package/dist/extensions/pi-subagents/test/unit/notify.test.ts +49 -55
- package/dist/extensions/pi-subagents/test/unit/package-manifest.test.ts +20 -3
- package/dist/extensions/pi-subagents/test/unit/parallel-handoff.test.ts +37 -7
- package/dist/extensions/pi-subagents/test/unit/parallel-utils.test.ts +10 -10
- package/dist/extensions/pi-subagents/test/unit/path-handling.test.ts +3 -3
- package/dist/extensions/pi-subagents/test/unit/permissions.test.ts +46 -0
- package/dist/extensions/pi-subagents/test/unit/pi-args.test.ts +31 -10
- package/dist/extensions/pi-subagents/test/unit/pi-spawn.test.ts +40 -16
- package/dist/extensions/pi-subagents/test/unit/preflight.test.ts +42 -44
- package/dist/extensions/pi-subagents/test/unit/proactive-skills.test.ts +13 -13
- package/dist/extensions/pi-subagents/test/unit/process-terminal.test.ts +4 -4
- package/dist/extensions/pi-subagents/test/unit/profiles.test.ts +75 -9
- package/dist/extensions/pi-subagents/test/unit/prompt-template-bridge.test.ts +20 -84
- package/dist/extensions/pi-subagents/test/unit/prompt-workflows.test.ts +15 -16
- package/dist/extensions/pi-subagents/test/unit/render-helpers.test.ts +28 -28
- package/dist/extensions/pi-subagents/test/unit/result-intercom.test.ts +19 -12
- package/dist/extensions/pi-subagents/test/unit/rpc.test.ts +37 -21
- package/dist/extensions/pi-subagents/test/unit/run-id-resolver.test.ts +1 -1
- package/dist/extensions/pi-subagents/test/unit/run-status.test.ts +50 -50
- package/dist/extensions/pi-subagents/test/unit/scheduled-runs.test.ts +396 -433
- package/dist/extensions/pi-subagents/test/unit/schemas.test.ts +76 -153
- package/dist/extensions/pi-subagents/test/unit/scripted-workflow.test.ts +411 -0
- package/dist/extensions/pi-subagents/test/unit/single-output.test.ts +1 -91
- package/dist/extensions/pi-subagents/test/unit/skills-fallback.test.ts +139 -0
- package/dist/extensions/pi-subagents/test/unit/slash-bridge.test.ts +29 -0
- package/dist/extensions/pi-subagents/test/unit/stale-run-reconciler.test.ts +13 -13
- package/dist/extensions/pi-subagents/test/unit/steering-action.test.ts +2 -2
- package/dist/extensions/pi-subagents/test/unit/steering.test.ts +2 -2
- package/dist/extensions/pi-subagents/test/unit/subagent-control.test.ts +35 -35
- package/dist/extensions/pi-subagents/test/unit/subagent-prompt-runtime.test.ts +53 -18
- package/dist/extensions/pi-subagents/test/unit/subagent-startup-retry.test.ts +13 -1
- package/dist/extensions/pi-subagents/test/unit/subagent-wait.test.ts +44 -11
- package/dist/extensions/pi-subagents/test/unit/task-intent.test.ts +2 -26
- package/dist/extensions/pi-subagents/test/unit/tool-description.test.ts +24 -148
- package/dist/extensions/pi-subagents/test/unit/turn-budget.test.ts +11 -9
- package/dist/extensions/pi-subagents/test/unit/wait-subscriptions.test.ts +351 -0
- package/dist/extensions/pi-subagents/test/unit/watchdog-child-status.test.ts +13 -13
- package/dist/extensions/pi-subagents/test/unit/watchdog-lsp-diagnostics.test.ts +1 -1
- package/dist/extensions/pi-subagents/test/unit/watchdog-permission-arbiter.test.ts +79 -0
- package/dist/extensions/pi-subagents/test/unit/watchdog-runtime.test.ts +1 -1
- package/dist/extensions/pi-subagents/test/unit/watchdog-settings.test.ts +8 -8
- package/dist/extensions/pi-subagents/test/unit/widget-nested-render.test.ts +45 -9
- package/dist/extensions/pi-subagents/test/unit/workflow-chat-progress.test.ts +197 -0
- package/dist/extensions/pi-subagents/test/unit/workflow-graph.test.ts +8 -8
- package/dist/extensions/pi-subagents/test/unit/worktree.test.ts +142 -12
- package/dist/extensions/pi-subagents/tsconfig.json +15 -0
- package/dist/extensions/ponytail/index.js +1 -31
- package/dist/extensions/ponytail/test/extension.test.js +5 -22
- package/dist/extensions/rtk.test.ts +141 -0
- package/dist/extensions/rtk.ts +78 -36
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/main.d.ts +0 -1
- package/dist/main.js +0 -1
- package/dist/migrations.d.ts +0 -1
- package/dist/migrations.js +0 -1
- package/dist/modes/index.d.ts +0 -1
- package/dist/modes/index.js +0 -1
- package/dist/modes/interactive/components/armin.d.ts +0 -1
- package/dist/modes/interactive/components/armin.js +0 -1
- package/dist/modes/interactive/components/assistant-message.d.ts +0 -1
- package/dist/modes/interactive/components/assistant-message.js +0 -1
- package/dist/modes/interactive/components/bash-execution.d.ts +0 -1
- package/dist/modes/interactive/components/bash-execution.js +0 -1
- package/dist/modes/interactive/components/bordered-loader.d.ts +0 -1
- package/dist/modes/interactive/components/bordered-loader.js +0 -1
- package/dist/modes/interactive/components/branch-summary-message.d.ts +0 -1
- package/dist/modes/interactive/components/branch-summary-message.js +0 -1
- package/dist/modes/interactive/components/compaction-summary-message.d.ts +0 -1
- package/dist/modes/interactive/components/compaction-summary-message.js +0 -1
- package/dist/modes/interactive/components/config-selector.d.ts +0 -1
- package/dist/modes/interactive/components/config-selector.js +0 -1
- package/dist/modes/interactive/components/countdown-timer.d.ts +0 -1
- package/dist/modes/interactive/components/countdown-timer.js +0 -1
- package/dist/modes/interactive/components/custom-editor.d.ts +0 -1
- package/dist/modes/interactive/components/custom-editor.js +0 -1
- package/dist/modes/interactive/components/custom-entry.d.ts +0 -1
- package/dist/modes/interactive/components/custom-entry.js +0 -1
- package/dist/modes/interactive/components/custom-message.d.ts +0 -1
- package/dist/modes/interactive/components/custom-message.js +0 -1
- package/dist/modes/interactive/components/daxnuts.d.ts +0 -1
- package/dist/modes/interactive/components/daxnuts.js +0 -1
- package/dist/modes/interactive/components/diff.d.ts +0 -1
- package/dist/modes/interactive/components/diff.js +0 -1
- package/dist/modes/interactive/components/dynamic-border.d.ts +0 -1
- package/dist/modes/interactive/components/dynamic-border.js +0 -1
- package/dist/modes/interactive/components/earendil-announcement.d.ts +0 -1
- package/dist/modes/interactive/components/earendil-announcement.js +0 -1
- package/dist/modes/interactive/components/extension-editor.d.ts +0 -1
- package/dist/modes/interactive/components/extension-editor.js +0 -1
- package/dist/modes/interactive/components/extension-input.d.ts +0 -1
- package/dist/modes/interactive/components/extension-input.js +0 -1
- package/dist/modes/interactive/components/extension-selector.d.ts +0 -1
- package/dist/modes/interactive/components/extension-selector.js +0 -1
- package/dist/modes/interactive/components/first-time-setup.d.ts +0 -1
- package/dist/modes/interactive/components/first-time-setup.js +0 -1
- package/dist/modes/interactive/components/footer.d.ts +0 -1
- package/dist/modes/interactive/components/footer.js +0 -1
- package/dist/modes/interactive/components/index.d.ts +0 -1
- package/dist/modes/interactive/components/index.js +0 -1
- package/dist/modes/interactive/components/keybinding-hints.d.ts +0 -1
- package/dist/modes/interactive/components/keybinding-hints.js +0 -1
- package/dist/modes/interactive/components/login-dialog.d.ts +0 -1
- package/dist/modes/interactive/components/login-dialog.js +0 -1
- package/dist/modes/interactive/components/model-selector.d.ts +0 -1
- package/dist/modes/interactive/components/model-selector.js +0 -1
- package/dist/modes/interactive/components/oauth-selector.d.ts +0 -1
- package/dist/modes/interactive/components/oauth-selector.js +0 -1
- package/dist/modes/interactive/components/scoped-models-selector.d.ts +0 -1
- package/dist/modes/interactive/components/scoped-models-selector.js +0 -1
- package/dist/modes/interactive/components/session-selector-search.d.ts +0 -1
- package/dist/modes/interactive/components/session-selector-search.js +0 -1
- package/dist/modes/interactive/components/session-selector.d.ts +0 -1
- package/dist/modes/interactive/components/session-selector.js +0 -1
- package/dist/modes/interactive/components/settings-selector.d.ts +0 -3
- package/dist/modes/interactive/components/settings-selector.js +1 -14
- package/dist/modes/interactive/components/show-images-selector.d.ts +0 -1
- package/dist/modes/interactive/components/show-images-selector.js +0 -1
- package/dist/modes/interactive/components/skill-invocation-message.d.ts +0 -1
- package/dist/modes/interactive/components/skill-invocation-message.js +0 -1
- package/dist/modes/interactive/components/status-indicator.d.ts +0 -1
- package/dist/modes/interactive/components/status-indicator.js +0 -1
- package/dist/modes/interactive/components/theme-selector.d.ts +0 -1
- package/dist/modes/interactive/components/theme-selector.js +0 -1
- package/dist/modes/interactive/components/thinking-selector.d.ts +0 -1
- package/dist/modes/interactive/components/thinking-selector.js +0 -1
- package/dist/modes/interactive/components/tool-execution.d.ts +0 -1
- package/dist/modes/interactive/components/tool-execution.js +0 -1
- package/dist/modes/interactive/components/tree-selector.d.ts +0 -1
- package/dist/modes/interactive/components/tree-selector.js +0 -1
- package/dist/modes/interactive/components/trust-selector.d.ts +0 -1
- package/dist/modes/interactive/components/trust-selector.js +0 -1
- package/dist/modes/interactive/components/user-message-selector.d.ts +0 -1
- package/dist/modes/interactive/components/user-message-selector.js +0 -1
- package/dist/modes/interactive/components/user-message.d.ts +0 -1
- package/dist/modes/interactive/components/user-message.js +0 -1
- package/dist/modes/interactive/components/visual-truncate.d.ts +0 -1
- package/dist/modes/interactive/components/visual-truncate.js +0 -1
- package/dist/modes/interactive/external-editor.d.ts +0 -1
- package/dist/modes/interactive/external-editor.js +0 -1
- package/dist/modes/interactive/interactive-mode.d.ts +0 -2
- package/dist/modes/interactive/interactive-mode.js +1 -22
- package/dist/modes/interactive/model-search.d.ts +0 -1
- package/dist/modes/interactive/model-search.js +0 -1
- package/dist/modes/interactive/theme/theme-controller.d.ts +0 -1
- package/dist/modes/interactive/theme/theme-controller.js +0 -1
- package/dist/modes/interactive/theme/theme.d.ts +0 -1
- package/dist/modes/interactive/theme/theme.js +0 -1
- package/dist/modes/print-mode.d.ts +0 -1
- package/dist/modes/print-mode.js +0 -1
- package/dist/modes/rpc/jsonl.d.ts +0 -1
- package/dist/modes/rpc/jsonl.js +0 -1
- package/dist/modes/rpc/rpc-client.d.ts +1 -2
- package/dist/modes/rpc/rpc-client.js +1 -2
- package/dist/modes/rpc/rpc-mode.d.ts +0 -1
- package/dist/modes/rpc/rpc-mode.js +0 -9
- package/dist/modes/rpc/rpc-types.d.ts +0 -1
- package/dist/modes/rpc/rpc-types.js +0 -1
- package/dist/package-manager-cli.d.ts +0 -1
- package/dist/package-manager-cli.js +0 -1
- package/dist/rpc-entry.d.ts +0 -1
- package/dist/rpc-entry.js +0 -1
- package/dist/utils/ansi.d.ts +0 -1
- package/dist/utils/ansi.js +0 -1
- package/dist/utils/changelog.d.ts +0 -1
- package/dist/utils/changelog.js +0 -1
- package/dist/utils/child-process.d.ts +0 -1
- package/dist/utils/child-process.js +0 -1
- package/dist/utils/clipboard-image.d.ts +0 -1
- package/dist/utils/clipboard-image.js +0 -1
- package/dist/utils/clipboard-native.d.ts +0 -1
- package/dist/utils/clipboard-native.js +0 -1
- package/dist/utils/clipboard.d.ts +0 -1
- package/dist/utils/clipboard.js +0 -1
- package/dist/utils/deprecation.d.ts +0 -1
- package/dist/utils/deprecation.js +0 -1
- package/dist/utils/exif-orientation.d.ts +0 -1
- package/dist/utils/exif-orientation.js +0 -1
- package/dist/utils/frontmatter.d.ts +0 -1
- package/dist/utils/frontmatter.js +0 -1
- package/dist/utils/fs-watch.d.ts +0 -1
- package/dist/utils/fs-watch.js +0 -1
- package/dist/utils/git.d.ts +0 -1
- package/dist/utils/git.js +0 -1
- package/dist/utils/html.d.ts +0 -1
- package/dist/utils/html.js +0 -1
- package/dist/utils/image-convert.d.ts +0 -1
- package/dist/utils/image-convert.js +0 -1
- package/dist/utils/image-process.d.ts +0 -1
- package/dist/utils/image-process.js +0 -1
- package/dist/utils/image-resize-core.d.ts +0 -1
- package/dist/utils/image-resize-core.js +0 -1
- package/dist/utils/image-resize-worker.d.ts +0 -1
- package/dist/utils/image-resize-worker.js +0 -1
- package/dist/utils/image-resize.d.ts +0 -1
- package/dist/utils/image-resize.js +0 -1
- package/dist/utils/json.d.ts +0 -1
- package/dist/utils/json.js +0 -1
- package/dist/utils/mime.d.ts +0 -1
- package/dist/utils/mime.js +0 -1
- package/dist/utils/open-browser.d.ts +0 -1
- package/dist/utils/open-browser.js +0 -1
- package/dist/utils/paths.d.ts +0 -1
- package/dist/utils/paths.js +0 -1
- package/dist/utils/photon.d.ts +0 -1
- package/dist/utils/photon.js +0 -1
- package/dist/utils/pi-user-agent.d.ts +0 -1
- package/dist/utils/pi-user-agent.js +0 -1
- package/dist/utils/shell.d.ts +0 -1
- package/dist/utils/shell.js +0 -1
- package/dist/utils/sleep.d.ts +0 -1
- package/dist/utils/sleep.js +0 -1
- package/dist/utils/syntax-highlight.d.ts +0 -1
- package/dist/utils/syntax-highlight.js +0 -1
- package/dist/utils/thinking-tags.d.ts +0 -1
- package/dist/utils/thinking-tags.js +0 -1
- package/dist/utils/tools-manager.d.ts +3 -3
- package/dist/utils/tools-manager.js +125 -42
- package/dist/utils/version-check.d.ts +0 -1
- package/dist/utils/version-check.js +0 -1
- package/dist/utils/windows-self-update.d.ts +0 -1
- package/dist/utils/windows-self-update.js +0 -1
- package/docs/rpc.md +1 -2
- package/docs/settings.md +0 -1
- package/docs/skills.md +10 -18
- package/package.json +3 -2
- package/dist/bun/cli.d.ts.map +0 -1
- package/dist/bun/cli.js.map +0 -1
- package/dist/bun/register-bedrock.d.ts.map +0 -1
- package/dist/bun/register-bedrock.js.map +0 -1
- package/dist/bun/restore-sandbox-env.d.ts.map +0 -1
- package/dist/bun/restore-sandbox-env.js.map +0 -1
- package/dist/cli/args.d.ts.map +0 -1
- package/dist/cli/args.js.map +0 -1
- package/dist/cli/config-selector.d.ts.map +0 -1
- package/dist/cli/config-selector.js.map +0 -1
- package/dist/cli/credential-print.d.ts.map +0 -1
- package/dist/cli/credential-print.js.map +0 -1
- package/dist/cli/file-processor.d.ts.map +0 -1
- package/dist/cli/file-processor.js.map +0 -1
- package/dist/cli/initial-message.d.ts.map +0 -1
- package/dist/cli/initial-message.js.map +0 -1
- package/dist/cli/list-models.d.ts.map +0 -1
- package/dist/cli/list-models.js.map +0 -1
- package/dist/cli/project-trust.d.ts.map +0 -1
- package/dist/cli/project-trust.js.map +0 -1
- package/dist/cli/session-picker.d.ts.map +0 -1
- package/dist/cli/session-picker.js.map +0 -1
- package/dist/cli/startup-ui.d.ts.map +0 -1
- package/dist/cli/startup-ui.js.map +0 -1
- package/dist/cli.d.ts.map +0 -1
- package/dist/cli.js.map +0 -1
- package/dist/config.d.ts.map +0 -1
- package/dist/config.js.map +0 -1
- package/dist/core/agent-session-auto-handoff.test.d.ts.map +0 -1
- package/dist/core/agent-session-auto-handoff.test.js.map +0 -1
- package/dist/core/agent-session-runtime.d.ts.map +0 -1
- package/dist/core/agent-session-runtime.js.map +0 -1
- package/dist/core/agent-session-services.d.ts.map +0 -1
- package/dist/core/agent-session-services.js.map +0 -1
- package/dist/core/agent-session-skill-block.test.d.ts.map +0 -1
- package/dist/core/agent-session-skill-block.test.js.map +0 -1
- package/dist/core/agent-session.d.ts.map +0 -1
- package/dist/core/agent-session.js.map +0 -1
- package/dist/core/agents.d.ts.map +0 -1
- package/dist/core/agents.js.map +0 -1
- package/dist/core/auth-guidance.d.ts.map +0 -1
- package/dist/core/auth-guidance.js.map +0 -1
- package/dist/core/auth-storage.d.ts.map +0 -1
- package/dist/core/auth-storage.js.map +0 -1
- package/dist/core/bash-executor.d.ts.map +0 -1
- package/dist/core/bash-executor.js.map +0 -1
- package/dist/core/built-in-extensions.d.ts.map +0 -1
- package/dist/core/built-in-extensions.js.map +0 -1
- package/dist/core/cache-stats.d.ts.map +0 -1
- package/dist/core/cache-stats.js.map +0 -1
- package/dist/core/compaction/branch-summarization.d.ts.map +0 -1
- package/dist/core/compaction/branch-summarization.js.map +0 -1
- package/dist/core/compaction/compaction.d.ts.map +0 -1
- package/dist/core/compaction/compaction.js.map +0 -1
- package/dist/core/compaction/index.d.ts.map +0 -1
- package/dist/core/compaction/index.js.map +0 -1
- package/dist/core/compaction/utils.d.ts.map +0 -1
- package/dist/core/compaction/utils.js.map +0 -1
- package/dist/core/defaults.d.ts.map +0 -1
- package/dist/core/defaults.js.map +0 -1
- package/dist/core/diagnostics.d.ts.map +0 -1
- package/dist/core/diagnostics.js.map +0 -1
- package/dist/core/event-bus.d.ts.map +0 -1
- package/dist/core/event-bus.js.map +0 -1
- package/dist/core/exec.d.ts.map +0 -1
- package/dist/core/exec.js.map +0 -1
- package/dist/core/experimental.d.ts.map +0 -1
- package/dist/core/experimental.js.map +0 -1
- package/dist/core/export-html/ansi-to-html.d.ts.map +0 -1
- package/dist/core/export-html/ansi-to-html.js.map +0 -1
- package/dist/core/export-html/index.d.ts.map +0 -1
- package/dist/core/export-html/index.js.map +0 -1
- package/dist/core/export-html/tool-renderer.d.ts.map +0 -1
- package/dist/core/export-html/tool-renderer.js.map +0 -1
- package/dist/core/extensions/index.d.ts.map +0 -1
- package/dist/core/extensions/index.js.map +0 -1
- package/dist/core/extensions/loader.d.ts.map +0 -1
- package/dist/core/extensions/loader.js.map +0 -1
- package/dist/core/extensions/runner.d.ts.map +0 -1
- package/dist/core/extensions/runner.js.map +0 -1
- package/dist/core/extensions/types.d.ts.map +0 -1
- package/dist/core/extensions/types.js.map +0 -1
- package/dist/core/extensions/wrapper.d.ts.map +0 -1
- package/dist/core/extensions/wrapper.js.map +0 -1
- package/dist/core/footer-data-provider.d.ts.map +0 -1
- package/dist/core/footer-data-provider.js.map +0 -1
- package/dist/core/git-command.d.ts.map +0 -1
- package/dist/core/git-command.js.map +0 -1
- package/dist/core/http-dispatcher.d.ts.map +0 -1
- package/dist/core/http-dispatcher.js.map +0 -1
- package/dist/core/index.d.ts.map +0 -1
- package/dist/core/index.js.map +0 -1
- package/dist/core/keybindings.d.ts.map +0 -1
- package/dist/core/keybindings.js.map +0 -1
- package/dist/core/llama/client.d.ts.map +0 -1
- package/dist/core/llama/client.js.map +0 -1
- package/dist/core/llama/huggingface.d.ts.map +0 -1
- package/dist/core/llama/huggingface.js.map +0 -1
- package/dist/core/llama/index.d.ts.map +0 -1
- package/dist/core/llama/index.js.map +0 -1
- package/dist/core/llama/provider.d.ts.map +0 -1
- package/dist/core/llama/provider.js.map +0 -1
- package/dist/core/llama/ui.d.ts.map +0 -1
- package/dist/core/llama/ui.js.map +0 -1
- package/dist/core/messages.d.ts.map +0 -1
- package/dist/core/messages.js.map +0 -1
- package/dist/core/model-config.d.ts.map +0 -1
- package/dist/core/model-config.js.map +0 -1
- package/dist/core/model-registry.d.ts.map +0 -1
- package/dist/core/model-registry.js.map +0 -1
- package/dist/core/model-resolver.d.ts.map +0 -1
- package/dist/core/model-resolver.js.map +0 -1
- package/dist/core/model-runtime.d.ts.map +0 -1
- package/dist/core/model-runtime.js.map +0 -1
- package/dist/core/models-store.d.ts.map +0 -1
- package/dist/core/models-store.js.map +0 -1
- package/dist/core/output-guard.d.ts.map +0 -1
- package/dist/core/output-guard.js.map +0 -1
- package/dist/core/package-manager.d.ts.map +0 -1
- package/dist/core/package-manager.js.map +0 -1
- package/dist/core/package-manager.test.d.ts.map +0 -1
- package/dist/core/package-manager.test.js.map +0 -1
- package/dist/core/project-trust.d.ts.map +0 -1
- package/dist/core/project-trust.js.map +0 -1
- package/dist/core/prompt-templates.d.ts.map +0 -1
- package/dist/core/prompt-templates.js.map +0 -1
- package/dist/core/provider-attribution.d.ts.map +0 -1
- package/dist/core/provider-attribution.js.map +0 -1
- package/dist/core/provider-composer.d.ts.map +0 -1
- package/dist/core/provider-composer.js.map +0 -1
- package/dist/core/radius.d.ts.map +0 -1
- package/dist/core/radius.js.map +0 -1
- package/dist/core/remote-catalog-provider.d.ts.map +0 -1
- package/dist/core/remote-catalog-provider.js.map +0 -1
- package/dist/core/resolve-config-value.d.ts.map +0 -1
- package/dist/core/resolve-config-value.js.map +0 -1
- package/dist/core/resource-loader.d.ts.map +0 -1
- package/dist/core/resource-loader.js.map +0 -1
- package/dist/core/runtime-credentials.d.ts.map +0 -1
- package/dist/core/runtime-credentials.js.map +0 -1
- package/dist/core/sdk.d.ts.map +0 -1
- package/dist/core/sdk.js.map +0 -1
- package/dist/core/session-cwd.d.ts.map +0 -1
- package/dist/core/session-cwd.js.map +0 -1
- package/dist/core/session-manager.d.ts.map +0 -1
- package/dist/core/session-manager.js.map +0 -1
- package/dist/core/settings-manager-auto-handoff.test.d.ts.map +0 -1
- package/dist/core/settings-manager-auto-handoff.test.js.map +0 -1
- package/dist/core/settings-manager.d.ts.map +0 -1
- package/dist/core/settings-manager.js.map +0 -1
- package/dist/core/skills.d.ts.map +0 -1
- package/dist/core/skills.js.map +0 -1
- package/dist/core/slash-commands.d.ts.map +0 -1
- package/dist/core/slash-commands.js.map +0 -1
- package/dist/core/source-info.d.ts.map +0 -1
- package/dist/core/source-info.js.map +0 -1
- package/dist/core/system-prompt.d.ts.map +0 -1
- package/dist/core/system-prompt.js.map +0 -1
- package/dist/core/system-prompt.test.d.ts.map +0 -1
- package/dist/core/system-prompt.test.js.map +0 -1
- package/dist/core/telemetry.d.ts.map +0 -1
- package/dist/core/telemetry.js.map +0 -1
- package/dist/core/timings.d.ts.map +0 -1
- package/dist/core/timings.js.map +0 -1
- package/dist/core/tools/bash.d.ts.map +0 -1
- package/dist/core/tools/bash.js.map +0 -1
- package/dist/core/tools/edit-diff.d.ts.map +0 -1
- package/dist/core/tools/edit-diff.js.map +0 -1
- package/dist/core/tools/edit.d.ts.map +0 -1
- package/dist/core/tools/edit.js.map +0 -1
- package/dist/core/tools/file-mutation-queue.d.ts.map +0 -1
- package/dist/core/tools/file-mutation-queue.js.map +0 -1
- package/dist/core/tools/find.d.ts.map +0 -1
- package/dist/core/tools/find.js.map +0 -1
- package/dist/core/tools/grep.d.ts.map +0 -1
- package/dist/core/tools/grep.js.map +0 -1
- package/dist/core/tools/index.d.ts.map +0 -1
- package/dist/core/tools/index.js.map +0 -1
- package/dist/core/tools/ls.d.ts.map +0 -1
- package/dist/core/tools/ls.js.map +0 -1
- package/dist/core/tools/output-accumulator.d.ts.map +0 -1
- package/dist/core/tools/output-accumulator.js.map +0 -1
- package/dist/core/tools/path-utils.d.ts.map +0 -1
- package/dist/core/tools/path-utils.js.map +0 -1
- package/dist/core/tools/read.d.ts.map +0 -1
- package/dist/core/tools/read.js.map +0 -1
- package/dist/core/tools/render-utils.d.ts.map +0 -1
- package/dist/core/tools/render-utils.js.map +0 -1
- package/dist/core/tools/tool-definition-wrapper.d.ts.map +0 -1
- package/dist/core/tools/tool-definition-wrapper.js.map +0 -1
- package/dist/core/tools/truncate.d.ts.map +0 -1
- package/dist/core/tools/truncate.js.map +0 -1
- package/dist/core/tools/write.d.ts.map +0 -1
- package/dist/core/tools/write.js.map +0 -1
- package/dist/core/trust-manager.d.ts.map +0 -1
- package/dist/core/trust-manager.js.map +0 -1
- package/dist/core/usage-totals.d.ts.map +0 -1
- package/dist/core/usage-totals.js.map +0 -1
- package/dist/extensions/node_modules/.vite/vitest/da39a3ee5e6b4b0d3255bfef95601890afd80709/results.json +0 -1
- package/dist/extensions/pi-subagents/test/unit/slash-chain-groups.test.ts +0 -464
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js.map +0 -1
- package/dist/main.d.ts.map +0 -1
- package/dist/main.js.map +0 -1
- package/dist/migrations.d.ts.map +0 -1
- package/dist/migrations.js.map +0 -1
- package/dist/modes/index.d.ts.map +0 -1
- package/dist/modes/index.js.map +0 -1
- package/dist/modes/interactive/components/armin.d.ts.map +0 -1
- package/dist/modes/interactive/components/armin.js.map +0 -1
- package/dist/modes/interactive/components/assistant-message.d.ts.map +0 -1
- package/dist/modes/interactive/components/assistant-message.js.map +0 -1
- package/dist/modes/interactive/components/bash-execution.d.ts.map +0 -1
- package/dist/modes/interactive/components/bash-execution.js.map +0 -1
- package/dist/modes/interactive/components/bordered-loader.d.ts.map +0 -1
- package/dist/modes/interactive/components/bordered-loader.js.map +0 -1
- package/dist/modes/interactive/components/branch-summary-message.d.ts.map +0 -1
- package/dist/modes/interactive/components/branch-summary-message.js.map +0 -1
- package/dist/modes/interactive/components/compaction-summary-message.d.ts.map +0 -1
- package/dist/modes/interactive/components/compaction-summary-message.js.map +0 -1
- package/dist/modes/interactive/components/config-selector.d.ts.map +0 -1
- package/dist/modes/interactive/components/config-selector.js.map +0 -1
- package/dist/modes/interactive/components/countdown-timer.d.ts.map +0 -1
- package/dist/modes/interactive/components/countdown-timer.js.map +0 -1
- package/dist/modes/interactive/components/custom-editor.d.ts.map +0 -1
- package/dist/modes/interactive/components/custom-editor.js.map +0 -1
- package/dist/modes/interactive/components/custom-entry.d.ts.map +0 -1
- package/dist/modes/interactive/components/custom-entry.js.map +0 -1
- package/dist/modes/interactive/components/custom-message.d.ts.map +0 -1
- package/dist/modes/interactive/components/custom-message.js.map +0 -1
- package/dist/modes/interactive/components/daxnuts.d.ts.map +0 -1
- package/dist/modes/interactive/components/daxnuts.js.map +0 -1
- package/dist/modes/interactive/components/diff.d.ts.map +0 -1
- package/dist/modes/interactive/components/diff.js.map +0 -1
- package/dist/modes/interactive/components/dynamic-border.d.ts.map +0 -1
- package/dist/modes/interactive/components/dynamic-border.js.map +0 -1
- package/dist/modes/interactive/components/earendil-announcement.d.ts.map +0 -1
- package/dist/modes/interactive/components/earendil-announcement.js.map +0 -1
- package/dist/modes/interactive/components/extension-editor.d.ts.map +0 -1
- package/dist/modes/interactive/components/extension-editor.js.map +0 -1
- package/dist/modes/interactive/components/extension-input.d.ts.map +0 -1
- package/dist/modes/interactive/components/extension-input.js.map +0 -1
- package/dist/modes/interactive/components/extension-selector.d.ts.map +0 -1
- package/dist/modes/interactive/components/extension-selector.js.map +0 -1
- package/dist/modes/interactive/components/first-time-setup.d.ts.map +0 -1
- package/dist/modes/interactive/components/first-time-setup.js.map +0 -1
- package/dist/modes/interactive/components/footer.d.ts.map +0 -1
- package/dist/modes/interactive/components/footer.js.map +0 -1
- package/dist/modes/interactive/components/index.d.ts.map +0 -1
- package/dist/modes/interactive/components/index.js.map +0 -1
- package/dist/modes/interactive/components/keybinding-hints.d.ts.map +0 -1
- package/dist/modes/interactive/components/keybinding-hints.js.map +0 -1
- package/dist/modes/interactive/components/login-dialog.d.ts.map +0 -1
- package/dist/modes/interactive/components/login-dialog.js.map +0 -1
- package/dist/modes/interactive/components/model-selector.d.ts.map +0 -1
- package/dist/modes/interactive/components/model-selector.js.map +0 -1
- package/dist/modes/interactive/components/oauth-selector.d.ts.map +0 -1
- package/dist/modes/interactive/components/oauth-selector.js.map +0 -1
- package/dist/modes/interactive/components/scoped-models-selector.d.ts.map +0 -1
- package/dist/modes/interactive/components/scoped-models-selector.js.map +0 -1
- package/dist/modes/interactive/components/session-selector-search.d.ts.map +0 -1
- package/dist/modes/interactive/components/session-selector-search.js.map +0 -1
- package/dist/modes/interactive/components/session-selector.d.ts.map +0 -1
- package/dist/modes/interactive/components/session-selector.js.map +0 -1
- package/dist/modes/interactive/components/settings-selector.d.ts.map +0 -1
- package/dist/modes/interactive/components/settings-selector.js.map +0 -1
- package/dist/modes/interactive/components/show-images-selector.d.ts.map +0 -1
- package/dist/modes/interactive/components/show-images-selector.js.map +0 -1
- package/dist/modes/interactive/components/skill-invocation-message.d.ts.map +0 -1
- package/dist/modes/interactive/components/skill-invocation-message.js.map +0 -1
- package/dist/modes/interactive/components/status-indicator.d.ts.map +0 -1
- package/dist/modes/interactive/components/status-indicator.js.map +0 -1
- package/dist/modes/interactive/components/theme-selector.d.ts.map +0 -1
- package/dist/modes/interactive/components/theme-selector.js.map +0 -1
- package/dist/modes/interactive/components/thinking-selector.d.ts.map +0 -1
- package/dist/modes/interactive/components/thinking-selector.js.map +0 -1
- package/dist/modes/interactive/components/tool-execution.d.ts.map +0 -1
- package/dist/modes/interactive/components/tool-execution.js.map +0 -1
- package/dist/modes/interactive/components/tree-selector.d.ts.map +0 -1
- package/dist/modes/interactive/components/tree-selector.js.map +0 -1
- package/dist/modes/interactive/components/trust-selector.d.ts.map +0 -1
- package/dist/modes/interactive/components/trust-selector.js.map +0 -1
- package/dist/modes/interactive/components/user-message-selector.d.ts.map +0 -1
- package/dist/modes/interactive/components/user-message-selector.js.map +0 -1
- package/dist/modes/interactive/components/user-message.d.ts.map +0 -1
- package/dist/modes/interactive/components/user-message.js.map +0 -1
- package/dist/modes/interactive/components/visual-truncate.d.ts.map +0 -1
- package/dist/modes/interactive/components/visual-truncate.js.map +0 -1
- package/dist/modes/interactive/external-editor.d.ts.map +0 -1
- package/dist/modes/interactive/external-editor.js.map +0 -1
- package/dist/modes/interactive/interactive-mode.d.ts.map +0 -1
- package/dist/modes/interactive/interactive-mode.js.map +0 -1
- package/dist/modes/interactive/model-search.d.ts.map +0 -1
- package/dist/modes/interactive/model-search.js.map +0 -1
- package/dist/modes/interactive/theme/theme-controller.d.ts.map +0 -1
- package/dist/modes/interactive/theme/theme-controller.js.map +0 -1
- package/dist/modes/interactive/theme/theme.d.ts.map +0 -1
- package/dist/modes/interactive/theme/theme.js.map +0 -1
- package/dist/modes/print-mode.d.ts.map +0 -1
- package/dist/modes/print-mode.js.map +0 -1
- package/dist/modes/rpc/jsonl.d.ts.map +0 -1
- package/dist/modes/rpc/jsonl.js.map +0 -1
- package/dist/modes/rpc/rpc-client.d.ts.map +0 -1
- package/dist/modes/rpc/rpc-client.js.map +0 -1
- package/dist/modes/rpc/rpc-mode.d.ts.map +0 -1
- package/dist/modes/rpc/rpc-mode.js.map +0 -1
- package/dist/modes/rpc/rpc-types.d.ts.map +0 -1
- package/dist/modes/rpc/rpc-types.js.map +0 -1
- package/dist/package-manager-cli.d.ts.map +0 -1
- package/dist/package-manager-cli.js.map +0 -1
- package/dist/rpc-entry.d.ts.map +0 -1
- package/dist/rpc-entry.js.map +0 -1
- package/dist/utils/ansi.d.ts.map +0 -1
- package/dist/utils/ansi.js.map +0 -1
- package/dist/utils/changelog.d.ts.map +0 -1
- package/dist/utils/changelog.js.map +0 -1
- package/dist/utils/child-process.d.ts.map +0 -1
- package/dist/utils/child-process.js.map +0 -1
- package/dist/utils/clipboard-image.d.ts.map +0 -1
- package/dist/utils/clipboard-image.js.map +0 -1
- package/dist/utils/clipboard-native.d.ts.map +0 -1
- package/dist/utils/clipboard-native.js.map +0 -1
- package/dist/utils/clipboard.d.ts.map +0 -1
- package/dist/utils/clipboard.js.map +0 -1
- package/dist/utils/deprecation.d.ts.map +0 -1
- package/dist/utils/deprecation.js.map +0 -1
- package/dist/utils/exif-orientation.d.ts.map +0 -1
- package/dist/utils/exif-orientation.js.map +0 -1
- package/dist/utils/frontmatter.d.ts.map +0 -1
- package/dist/utils/frontmatter.js.map +0 -1
- package/dist/utils/fs-watch.d.ts.map +0 -1
- package/dist/utils/fs-watch.js.map +0 -1
- package/dist/utils/git.d.ts.map +0 -1
- package/dist/utils/git.js.map +0 -1
- package/dist/utils/html.d.ts.map +0 -1
- package/dist/utils/html.js.map +0 -1
- package/dist/utils/image-convert.d.ts.map +0 -1
- package/dist/utils/image-convert.js.map +0 -1
- package/dist/utils/image-process.d.ts.map +0 -1
- package/dist/utils/image-process.js.map +0 -1
- package/dist/utils/image-resize-core.d.ts.map +0 -1
- package/dist/utils/image-resize-core.js.map +0 -1
- package/dist/utils/image-resize-worker.d.ts.map +0 -1
- package/dist/utils/image-resize-worker.js.map +0 -1
- package/dist/utils/image-resize.d.ts.map +0 -1
- package/dist/utils/image-resize.js.map +0 -1
- package/dist/utils/json.d.ts.map +0 -1
- package/dist/utils/json.js.map +0 -1
- package/dist/utils/mime.d.ts.map +0 -1
- package/dist/utils/mime.js.map +0 -1
- package/dist/utils/open-browser.d.ts.map +0 -1
- package/dist/utils/open-browser.js.map +0 -1
- package/dist/utils/paths.d.ts.map +0 -1
- package/dist/utils/paths.js.map +0 -1
- package/dist/utils/photon.d.ts.map +0 -1
- package/dist/utils/photon.js.map +0 -1
- package/dist/utils/pi-user-agent.d.ts.map +0 -1
- package/dist/utils/pi-user-agent.js.map +0 -1
- package/dist/utils/shell.d.ts.map +0 -1
- package/dist/utils/shell.js.map +0 -1
- package/dist/utils/sleep.d.ts.map +0 -1
- package/dist/utils/sleep.js.map +0 -1
- package/dist/utils/syntax-highlight.d.ts.map +0 -1
- package/dist/utils/syntax-highlight.js.map +0 -1
- package/dist/utils/thinking-tags.d.ts.map +0 -1
- package/dist/utils/thinking-tags.js.map +0 -1
- package/dist/utils/tools-manager.d.ts.map +0 -1
- package/dist/utils/tools-manager.js.map +0 -1
- package/dist/utils/version-check.d.ts.map +0 -1
- package/dist/utils/version-check.js.map +0 -1
- package/dist/utils/windows-self-update.d.ts.map +0 -1
- package/dist/utils/windows-self-update.js.map +0 -1
|
@@ -62,10 +62,10 @@ describe("below-editor subagent FleetView", () => {
|
|
|
62
62
|
mode: "single",
|
|
63
63
|
startedAt: now - 11_000 + index,
|
|
64
64
|
updatedAt: now,
|
|
65
|
-
currentAgent: `
|
|
65
|
+
currentAgent: `builder-${index}`,
|
|
66
66
|
description: index === 0 ? "Inspect\nmodule 0" : `Inspect module ${index}`,
|
|
67
67
|
...(index === 0 ? { model: "anthropic/fable-5", thinking: "low" } : {}),
|
|
68
|
-
tokens: index === 0 ? 13_100 :
|
|
68
|
+
tokens: index === 0 ? 13_100 : 100,
|
|
69
69
|
});
|
|
70
70
|
}
|
|
71
71
|
|
|
@@ -91,13 +91,68 @@ describe("below-editor subagent FleetView", () => {
|
|
|
91
91
|
try {
|
|
92
92
|
fleet.setContext(ctx);
|
|
93
93
|
assert.ok(widgetFactory);
|
|
94
|
-
const
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
94
|
+
const tui = {
|
|
95
|
+
requestRender() {},
|
|
96
|
+
focusedComponent: Object.create(Editor.prototype) as Editor,
|
|
97
|
+
};
|
|
98
|
+
const component = widgetFactory!(tui, theme);
|
|
99
|
+
const compactLines = component.render(80);
|
|
100
|
+
assert.equal(compactLines.length, 1);
|
|
101
|
+
assert.ok(compactLines[0]!.includes("7 active agents"));
|
|
102
|
+
assert.ok(compactLines[0]!.includes("↓ 13.7k tokens"));
|
|
103
|
+
assert.ok(compactLines[0]!.includes("↓/← to inspect"));
|
|
104
|
+
assert.ok(visibleWidth(compactLines[0]!) <= 80);
|
|
105
|
+
|
|
106
|
+
assert.deepEqual(fleet.handleKey("\x1b[B"), { consume: true });
|
|
107
|
+
const expandedLines = component.render(80);
|
|
108
|
+
assert.ok(expandedLines.some((line) => line.includes("> main")));
|
|
109
|
+
assert.ok(expandedLines.some((line) => line.includes(" builder-0")), "unselected agents use blank focus space");
|
|
110
|
+
assert.ok(expandedLines.every((line) => !/[⏺◯]/u.test(line)), "selection avoids terminal-ambiguous circle glyphs");
|
|
111
|
+
assert.ok(expandedLines.some((line) => line.includes("builder-0 (fable-5 · thinking low)")));
|
|
112
|
+
assert.ok(expandedLines.some((line) => line.includes("11s · ↓ 13.1k tokens")));
|
|
113
|
+
assert.ok(expandedLines.some((line) => line.includes("↓ 1 more")));
|
|
114
|
+
for (const line of expandedLines) assert.ok(visibleWidth(line) <= 80, `line exceeded width: ${line}`);
|
|
115
|
+
|
|
116
|
+
assert.deepEqual(fleet.handleKey("\x1b"), { consume: true });
|
|
117
|
+
assert.equal(component.render(80).length, 1);
|
|
118
|
+
assert.deepEqual(fleet.handleKey("\x1b[D"), { consume: true });
|
|
119
|
+
assert.ok(component.render(80).length > 1, "Left should also expand the roster");
|
|
120
|
+
} finally {
|
|
121
|
+
fleet.dispose();
|
|
122
|
+
}
|
|
123
|
+
});
|
|
124
|
+
|
|
125
|
+
it("keeps one queued agent visible in the compact summary", () => {
|
|
126
|
+
const state = stateForTest();
|
|
127
|
+
state.asyncJobs.set("run-builder", {
|
|
128
|
+
asyncId: "run-builder",
|
|
129
|
+
asyncDir: "/tmp/run-builder",
|
|
130
|
+
status: "queued",
|
|
131
|
+
mode: "single",
|
|
132
|
+
startedAt: 10,
|
|
133
|
+
updatedAt: 20,
|
|
134
|
+
totalTokens: { input: 40, output: 2, total: 42 },
|
|
135
|
+
});
|
|
136
|
+
let widgetFactory: ((tui: unknown, theme: typeof theme) => { render(width: number): string[] }) | undefined;
|
|
137
|
+
const ctx = {
|
|
138
|
+
hasUI: true,
|
|
139
|
+
ui: {
|
|
140
|
+
setWidget(_key: string, content: typeof widgetFactory | undefined) { if (content) widgetFactory = content; },
|
|
141
|
+
onTerminalInput() { return () => {}; },
|
|
142
|
+
getEditorText() { return ""; },
|
|
143
|
+
requestRender() {},
|
|
144
|
+
notify() {},
|
|
145
|
+
theme,
|
|
146
|
+
},
|
|
147
|
+
} as unknown as ExtensionContext;
|
|
148
|
+
const fleet = new SubagentFleetStatus(state, () => {}, { refreshMs: 60_000 });
|
|
149
|
+
try {
|
|
150
|
+
fleet.setContext(ctx);
|
|
151
|
+
const lines = widgetFactory!({ requestRender() {} }, theme).render(50);
|
|
152
|
+
assert.equal(lines.length, 1);
|
|
153
|
+
assert.ok(lines[0]!.includes("1 active agent"));
|
|
154
|
+
assert.ok(lines[0]!.includes("↓ 42 tokens"));
|
|
155
|
+
assert.ok(visibleWidth(lines[0]!) <= 50);
|
|
101
156
|
} finally {
|
|
102
157
|
fleet.dispose();
|
|
103
158
|
}
|
|
@@ -105,12 +160,12 @@ describe("below-editor subagent FleetView", () => {
|
|
|
105
160
|
|
|
106
161
|
it("registers above the editor when configured", () => {
|
|
107
162
|
const state = stateForTest();
|
|
108
|
-
state.foregroundControls.set("run-
|
|
109
|
-
runId: "run-
|
|
163
|
+
state.foregroundControls.set("run-builder", {
|
|
164
|
+
runId: "run-builder",
|
|
110
165
|
mode: "single",
|
|
111
166
|
startedAt: 10,
|
|
112
167
|
updatedAt: 20,
|
|
113
|
-
currentAgent: "
|
|
168
|
+
currentAgent: "builder",
|
|
114
169
|
});
|
|
115
170
|
let placement: string | undefined;
|
|
116
171
|
const ctx = {
|
|
@@ -136,12 +191,12 @@ describe("below-editor subagent FleetView", () => {
|
|
|
136
191
|
|
|
137
192
|
it("stops refreshing when the captured extension context becomes stale", () => {
|
|
138
193
|
const state = stateForTest();
|
|
139
|
-
state.foregroundControls.set("run-
|
|
140
|
-
runId: "run-
|
|
194
|
+
state.foregroundControls.set("run-builder", {
|
|
195
|
+
runId: "run-builder",
|
|
141
196
|
mode: "single",
|
|
142
197
|
startedAt: 10,
|
|
143
198
|
updatedAt: 20,
|
|
144
|
-
currentAgent: "
|
|
199
|
+
currentAgent: "builder",
|
|
145
200
|
});
|
|
146
201
|
let stale = false;
|
|
147
202
|
let contextReads = 0;
|
|
@@ -183,12 +238,12 @@ describe("below-editor subagent FleetView", () => {
|
|
|
183
238
|
|
|
184
239
|
it("does not swallow unrelated widget cleanup errors", () => {
|
|
185
240
|
const state = stateForTest();
|
|
186
|
-
state.foregroundControls.set("run-
|
|
187
|
-
runId: "run-
|
|
241
|
+
state.foregroundControls.set("run-builder", {
|
|
242
|
+
runId: "run-builder",
|
|
188
243
|
mode: "single",
|
|
189
244
|
startedAt: 10,
|
|
190
245
|
updatedAt: 20,
|
|
191
|
-
currentAgent: "
|
|
246
|
+
currentAgent: "builder",
|
|
192
247
|
});
|
|
193
248
|
const ctx = {
|
|
194
249
|
hasUI: true,
|
|
@@ -209,12 +264,12 @@ describe("below-editor subagent FleetView", () => {
|
|
|
209
264
|
|
|
210
265
|
it("preserves multiple unrelated UI cleanup errors", () => {
|
|
211
266
|
const state = stateForTest();
|
|
212
|
-
state.foregroundControls.set("run-
|
|
213
|
-
runId: "run-
|
|
267
|
+
state.foregroundControls.set("run-builder", {
|
|
268
|
+
runId: "run-builder",
|
|
214
269
|
mode: "single",
|
|
215
270
|
startedAt: 10,
|
|
216
271
|
updatedAt: 20,
|
|
217
|
-
currentAgent: "
|
|
272
|
+
currentAgent: "builder",
|
|
218
273
|
});
|
|
219
274
|
const ctx = {
|
|
220
275
|
hasUI: true,
|
|
@@ -242,12 +297,12 @@ describe("below-editor subagent FleetView", () => {
|
|
|
242
297
|
|
|
243
298
|
it("keeps widget ownership through invalidation so an empty refresh removes it", () => {
|
|
244
299
|
const state = stateForTest();
|
|
245
|
-
state.foregroundControls.set("run-
|
|
246
|
-
runId: "run-
|
|
300
|
+
state.foregroundControls.set("run-builder", {
|
|
301
|
+
runId: "run-builder",
|
|
247
302
|
mode: "single",
|
|
248
303
|
startedAt: 10,
|
|
249
304
|
updatedAt: 20,
|
|
250
|
-
currentAgent: "
|
|
305
|
+
currentAgent: "builder",
|
|
251
306
|
});
|
|
252
307
|
let widgetFactory: ((tui: unknown, theme: typeof theme) => { render(width: number): string[]; invalidate(): void }) | undefined;
|
|
253
308
|
let removals = 0;
|
|
@@ -280,12 +335,12 @@ describe("below-editor subagent FleetView", () => {
|
|
|
280
335
|
|
|
281
336
|
it("removes the dynamic widget while the fleet inspector owns the viewport", () => {
|
|
282
337
|
const state = stateForTest();
|
|
283
|
-
state.foregroundControls.set("run-
|
|
284
|
-
runId: "run-
|
|
338
|
+
state.foregroundControls.set("run-builder", {
|
|
339
|
+
runId: "run-builder",
|
|
285
340
|
mode: "single",
|
|
286
341
|
startedAt: 10,
|
|
287
342
|
updatedAt: 20,
|
|
288
|
-
currentAgent: "
|
|
343
|
+
currentAgent: "builder",
|
|
289
344
|
});
|
|
290
345
|
const registrations: string[] = [];
|
|
291
346
|
const ctx = {
|
|
@@ -314,6 +369,126 @@ describe("below-editor subagent FleetView", () => {
|
|
|
314
369
|
}
|
|
315
370
|
});
|
|
316
371
|
|
|
372
|
+
it("renders retained nested terminal siblings under an active owner with bounded leaves", () => {
|
|
373
|
+
const state = stateForTest();
|
|
374
|
+
state.asyncJobs.set("supervisor", {
|
|
375
|
+
asyncId: "supervisor",
|
|
376
|
+
asyncDir: "/tmp/supervisor",
|
|
377
|
+
status: "running",
|
|
378
|
+
mode: "single",
|
|
379
|
+
startedAt: 10,
|
|
380
|
+
updatedAt: 20,
|
|
381
|
+
steps: [{ agent: "supervisor", index: 0, status: "running" }],
|
|
382
|
+
nestedChildren: [0, 1, 2, 3, 4].map((index) => ({
|
|
383
|
+
id: `nested-${index}`,
|
|
384
|
+
parentRunId: "supervisor",
|
|
385
|
+
parentStepIndex: 0,
|
|
386
|
+
depth: 1,
|
|
387
|
+
path: [{ runId: "supervisor", stepIndex: 0 }],
|
|
388
|
+
state: index === 0 ? "complete" as const : "running" as const,
|
|
389
|
+
agent: `leaf-${index}`,
|
|
390
|
+
model: index === 0 ? "provider/gpt-5.6-luna:medium" : "provider/gpt-5.6-luna",
|
|
391
|
+
thinking: "medium",
|
|
392
|
+
startedAt: 10,
|
|
393
|
+
lastUpdate: 20,
|
|
394
|
+
})),
|
|
395
|
+
});
|
|
396
|
+
let widgetFactory: ((tui: unknown, theme: typeof theme) => { render(width: number): string[] }) | undefined;
|
|
397
|
+
const ctx = {
|
|
398
|
+
hasUI: true,
|
|
399
|
+
ui: {
|
|
400
|
+
setWidget(_key: string, content: typeof widgetFactory | undefined) { if (content) widgetFactory = content; },
|
|
401
|
+
onTerminalInput() { return () => {}; },
|
|
402
|
+
getEditorText() { return ""; },
|
|
403
|
+
requestRender() {},
|
|
404
|
+
notify() {},
|
|
405
|
+
theme,
|
|
406
|
+
},
|
|
407
|
+
} as unknown as ExtensionContext;
|
|
408
|
+
const fleet = new SubagentFleetStatus(state, () => {}, { refreshMs: 60_000 });
|
|
409
|
+
try {
|
|
410
|
+
fleet.setContext(ctx);
|
|
411
|
+
const tui = { requestRender() {}, focusedComponent: Object.create(Editor.prototype) as Editor };
|
|
412
|
+
const component = widgetFactory!(tui, theme);
|
|
413
|
+
assert.equal(component.render(120).length, 1, "nested activity should stay compact until navigation activates the roster");
|
|
414
|
+
assert.deepEqual(fleet.handleKey("\x1b[B"), { consume: true });
|
|
415
|
+
const lines = component.render(120).join("\n");
|
|
416
|
+
assert.match(lines, /supervisor/);
|
|
417
|
+
for (const [index, state] of ["complete", "running", "running", "running"].entries()) {
|
|
418
|
+
const line = lines.split("\n").find((candidate) => candidate.includes(`leaf-${index}`));
|
|
419
|
+
assert.ok(line);
|
|
420
|
+
assert.match(line!, /gpt-5.6-luna/);
|
|
421
|
+
assert.match(line!, /thinking medium/);
|
|
422
|
+
assert.match(line!, new RegExp(state));
|
|
423
|
+
}
|
|
424
|
+
assert.doesNotMatch(lines, /leaf-4.*running/);
|
|
425
|
+
assert.match(lines, /\+1 nested leaves/);
|
|
426
|
+
} finally {
|
|
427
|
+
fleet.dispose();
|
|
428
|
+
}
|
|
429
|
+
});
|
|
430
|
+
|
|
431
|
+
it("counts hidden nested leaves across multiple parallel children", () => {
|
|
432
|
+
const state = stateForTest();
|
|
433
|
+
state.asyncJobs.set("supervisor", {
|
|
434
|
+
asyncId: "supervisor",
|
|
435
|
+
asyncDir: "/tmp/supervisor",
|
|
436
|
+
status: "running",
|
|
437
|
+
mode: "single",
|
|
438
|
+
startedAt: 10,
|
|
439
|
+
updatedAt: 20,
|
|
440
|
+
steps: [{ agent: "supervisor", index: 0, status: "running" }],
|
|
441
|
+
nestedChildren: [
|
|
442
|
+
{
|
|
443
|
+
id: "nested-a",
|
|
444
|
+
parentRunId: "supervisor",
|
|
445
|
+
parentStepIndex: 0,
|
|
446
|
+
depth: 1,
|
|
447
|
+
path: [{ runId: "supervisor", stepIndex: 0 }],
|
|
448
|
+
state: "running",
|
|
449
|
+
mode: "parallel",
|
|
450
|
+
steps: [0, 1, 2, 3].map((index) => ({ agent: `child-a-${index}`, index, status: "running" as const })),
|
|
451
|
+
},
|
|
452
|
+
{
|
|
453
|
+
id: "nested-b",
|
|
454
|
+
parentRunId: "supervisor",
|
|
455
|
+
parentStepIndex: 0,
|
|
456
|
+
depth: 1,
|
|
457
|
+
path: [{ runId: "supervisor", stepIndex: 0 }],
|
|
458
|
+
state: "running",
|
|
459
|
+
mode: "parallel",
|
|
460
|
+
steps: [0, 1].map((index) => ({ agent: `child-b-${index}`, index, status: "running" as const })),
|
|
461
|
+
},
|
|
462
|
+
],
|
|
463
|
+
});
|
|
464
|
+
let widgetFactory: ((tui: unknown, theme: typeof theme) => { render(width: number): string[] }) | undefined;
|
|
465
|
+
const ctx = {
|
|
466
|
+
hasUI: true,
|
|
467
|
+
ui: {
|
|
468
|
+
setWidget(_key: string, content: typeof widgetFactory | undefined) { if (content) widgetFactory = content; },
|
|
469
|
+
onTerminalInput() { return () => {}; },
|
|
470
|
+
getEditorText() { return ""; },
|
|
471
|
+
requestRender() {},
|
|
472
|
+
notify() {},
|
|
473
|
+
theme,
|
|
474
|
+
},
|
|
475
|
+
} as unknown as ExtensionContext;
|
|
476
|
+
const fleet = new SubagentFleetStatus(state, () => {}, { refreshMs: 60_000 });
|
|
477
|
+
try {
|
|
478
|
+
fleet.setContext(ctx);
|
|
479
|
+
const tui = { requestRender() {}, focusedComponent: Object.create(Editor.prototype) as Editor };
|
|
480
|
+
const component = widgetFactory!(tui, theme);
|
|
481
|
+
assert.equal(component.render(120).length, 1, "parallel nested activity should stay compact until activated");
|
|
482
|
+
assert.deepEqual(fleet.handleKey("\x1b[B"), { consume: true });
|
|
483
|
+
const lines = component.render(120).join("\n");
|
|
484
|
+
for (const index of [0, 1, 2, 3]) assert.match(lines, new RegExp(`child-a-${index}`));
|
|
485
|
+
assert.doesNotMatch(lines, /child-b-[01]/);
|
|
486
|
+
assert.match(lines, /\+2 nested leaves/);
|
|
487
|
+
} finally {
|
|
488
|
+
fleet.dispose();
|
|
489
|
+
}
|
|
490
|
+
});
|
|
491
|
+
|
|
317
492
|
it("shows only the current sequential chain step while retaining active parallel siblings", () => {
|
|
318
493
|
const state = stateForTest();
|
|
319
494
|
state.asyncJobs.set("sequential", {
|
|
@@ -325,9 +500,9 @@ describe("below-editor subagent FleetView", () => {
|
|
|
325
500
|
startedAt: 50,
|
|
326
501
|
updatedAt: 200,
|
|
327
502
|
steps: [
|
|
328
|
-
{ agent: "
|
|
329
|
-
{ agent: "
|
|
330
|
-
{ agent: "
|
|
503
|
+
{ agent: "explorer", index: 0, status: "complete" },
|
|
504
|
+
{ agent: "builder", index: 1, status: "running" },
|
|
505
|
+
{ agent: "commentator", index: 2, status: "pending" },
|
|
331
506
|
],
|
|
332
507
|
});
|
|
333
508
|
state.asyncJobs.set("parallel-group", {
|
|
@@ -340,7 +515,7 @@ describe("below-editor subagent FleetView", () => {
|
|
|
340
515
|
startedAt: 100,
|
|
341
516
|
updatedAt: 200,
|
|
342
517
|
steps: [
|
|
343
|
-
{ agent: "
|
|
518
|
+
{ agent: "commentator", index: 3, status: "running" },
|
|
344
519
|
{ agent: "tester", index: 4, status: "pending" },
|
|
345
520
|
],
|
|
346
521
|
});
|
|
@@ -359,9 +534,9 @@ describe("below-editor subagent FleetView", () => {
|
|
|
359
534
|
startedAt: 10,
|
|
360
535
|
updatedAt: 30,
|
|
361
536
|
activeChildren: new Map([
|
|
362
|
-
[0, { index: 0, agent: "
|
|
363
|
-
[1, { index: 1, agent: "
|
|
364
|
-
[2, { index: 2, agent: "
|
|
537
|
+
[0, { index: 0, agent: "commentator", description: "Review correctness", startedAt: 11, updatedAt: 21, tokens: 100 }],
|
|
538
|
+
[1, { index: 1, agent: "commentator", description: "Review quality", startedAt: 12, updatedAt: 22, tokens: 200 }],
|
|
539
|
+
[2, { index: 2, agent: "commentator", description: "Review tests", startedAt: 13, updatedAt: 23, tokens: 300 }],
|
|
365
540
|
]),
|
|
366
541
|
});
|
|
367
542
|
|
|
@@ -382,7 +557,7 @@ describe("below-editor subagent FleetView", () => {
|
|
|
382
557
|
mode: "single",
|
|
383
558
|
startedAt: 10,
|
|
384
559
|
updatedAt: 20,
|
|
385
|
-
currentAgent: "
|
|
560
|
+
currentAgent: "builder",
|
|
386
561
|
currentIndex: 2,
|
|
387
562
|
});
|
|
388
563
|
const asyncJob = {
|
|
@@ -393,7 +568,7 @@ describe("below-editor subagent FleetView", () => {
|
|
|
393
568
|
mode: "single" as const,
|
|
394
569
|
startedAt: 10,
|
|
395
570
|
updatedAt: 20,
|
|
396
|
-
steps: [{ agent: "
|
|
571
|
+
steps: [{ agent: "commentator", index: 0, status: "running" as const }],
|
|
397
572
|
};
|
|
398
573
|
state.asyncJobs.set(asyncJob.asyncId, asyncJob);
|
|
399
574
|
state.fleetJobs!.set(asyncJob.asyncId, asyncJob);
|
|
@@ -414,8 +589,8 @@ describe("below-editor subagent FleetView", () => {
|
|
|
414
589
|
startedAt: 100,
|
|
415
590
|
updatedAt: 200,
|
|
416
591
|
steps: [
|
|
417
|
-
{ agent: "
|
|
418
|
-
{ agent: "
|
|
592
|
+
{ agent: "commentator", index: 0, status: "running", description: "Review only authentication", startedAt: 120, model: "openai/gpt-5", thinking: "medium", tokens: { input: 4_000, output: 200, total: 4_200 } },
|
|
593
|
+
{ agent: "builder", index: 1, status: "running", description: "Implement only billing", startedAt: 121, tokens: { input: 100, output: 20, total: 120 } },
|
|
419
594
|
],
|
|
420
595
|
});
|
|
421
596
|
const fleet = new SubagentFleetStatus(state, () => {}, { refreshMs: 60_000 });
|
|
@@ -433,9 +608,12 @@ describe("below-editor subagent FleetView", () => {
|
|
|
433
608
|
} as unknown as ExtensionContext;
|
|
434
609
|
try {
|
|
435
610
|
fleet.setContext(ctx);
|
|
436
|
-
const
|
|
437
|
-
|
|
438
|
-
assert.
|
|
611
|
+
const tui = { requestRender() {}, focusedComponent: Object.create(Editor.prototype) as Editor };
|
|
612
|
+
const component = widgetFactory!(tui, theme);
|
|
613
|
+
assert.deepEqual(fleet.handleKey("\x1b[B"), { consume: true });
|
|
614
|
+
const lines = component.render(180);
|
|
615
|
+
assert.ok(lines.some((line) => line.includes("commentator (gpt-5 · thinking medium)") && line.includes("Review only authentication")));
|
|
616
|
+
assert.ok(lines.some((line) => line.includes("builder") && line.includes("Implement only billing")));
|
|
439
617
|
assert.ok(lines.every((line) => !line.includes("Review the authentication changes")), "per-child descriptions should replace the run-level fallback when present");
|
|
440
618
|
assert.ok(lines.some((line) => line.includes("↓ 4.2k tokens")));
|
|
441
619
|
} finally {
|
|
@@ -445,22 +623,23 @@ describe("below-editor subagent FleetView", () => {
|
|
|
445
623
|
|
|
446
624
|
it("only captures navigation at an empty editor and opens the selected child", async () => {
|
|
447
625
|
const state = stateForTest();
|
|
448
|
-
state.foregroundControls.set("run-
|
|
449
|
-
runId: "run-
|
|
626
|
+
state.foregroundControls.set("run-builder", {
|
|
627
|
+
runId: "run-builder",
|
|
450
628
|
mode: "single",
|
|
451
629
|
startedAt: Date.now() - 1_000,
|
|
452
630
|
updatedAt: Date.now(),
|
|
453
|
-
currentAgent: "
|
|
631
|
+
currentAgent: "builder",
|
|
454
632
|
description: "Implement FleetView",
|
|
455
633
|
});
|
|
456
634
|
let editorText = "draft";
|
|
457
635
|
let inputHandler: ((data: string) => { consume?: boolean } | undefined) | undefined;
|
|
458
636
|
let widgetFactory: ((tui: unknown, theme: typeof theme) => { render(width: number): string[] }) | undefined;
|
|
459
637
|
const opened: string[] = [];
|
|
638
|
+
let closeInspector: (() => void) | undefined;
|
|
460
639
|
const ctx = {
|
|
461
640
|
hasUI: true,
|
|
462
641
|
ui: {
|
|
463
|
-
setWidget(_key: string, content: typeof widgetFactory | undefined) {
|
|
642
|
+
setWidget(_key: string, content: typeof widgetFactory | undefined) { widgetFactory = content; },
|
|
464
643
|
onTerminalInput(handler: typeof inputHandler) { inputHandler = handler; return () => { inputHandler = undefined; }; },
|
|
465
644
|
getEditorText() { return editorText; },
|
|
466
645
|
requestRender() {},
|
|
@@ -468,7 +647,10 @@ describe("below-editor subagent FleetView", () => {
|
|
|
468
647
|
theme,
|
|
469
648
|
},
|
|
470
649
|
} as unknown as ExtensionContext;
|
|
471
|
-
const fleet = new SubagentFleetStatus(state,
|
|
650
|
+
const fleet = new SubagentFleetStatus(state, (key) => {
|
|
651
|
+
opened.push(key);
|
|
652
|
+
return new Promise<void>((resolve) => { closeInspector = resolve; });
|
|
653
|
+
}, { refreshMs: 60_000 });
|
|
472
654
|
try {
|
|
473
655
|
fleet.setContext(ctx);
|
|
474
656
|
assert.ok(inputHandler);
|
|
@@ -496,22 +678,30 @@ describe("below-editor subagent FleetView", () => {
|
|
|
496
678
|
tui.focusedComponent = crossModuleCustomEditor as unknown as Editor;
|
|
497
679
|
assert.equal(inputHandler!("j"), undefined, "inactive FleetView should retain printable navigation keys");
|
|
498
680
|
assert.equal(inputHandler!("k"), undefined, "inactive FleetView should retain printable navigation keys");
|
|
681
|
+
assert.equal(component.render(100).length, 1, "inactive FleetView should stay compact");
|
|
499
682
|
assert.deepEqual(inputHandler!("\x1b[B"), { consume: true }, "custom editors should activate FleetView across jiti boundaries");
|
|
683
|
+
assert.ok(component.render(100).length > 1, "keyboard activation should expand the roster");
|
|
500
684
|
assert.deepEqual(inputHandler!("j"), { consume: true }, "active FleetView should navigate down with j");
|
|
501
|
-
assert.ok(component.render(100).some((line) => line.includes("
|
|
685
|
+
assert.ok(component.render(100).some((line) => line.includes("> builder")));
|
|
502
686
|
assert.deepEqual(inputHandler!("k"), { consume: true }, "active FleetView should navigate up with k");
|
|
503
|
-
assert.ok(component.render(100).some((line) => line.includes("
|
|
687
|
+
assert.ok(component.render(100).some((line) => line.includes("> main")));
|
|
504
688
|
|
|
505
689
|
tui.focusedComponent = Object.create(Editor.prototype) as Editor;
|
|
506
690
|
assert.deepEqual(inputHandler!("\x1b[B"), { consume: true });
|
|
507
|
-
assert.ok(component.render(100).some((line) => line.includes("
|
|
691
|
+
assert.ok(component.render(100).some((line) => line.includes("> builder")));
|
|
508
692
|
assert.deepEqual(inputHandler!("\r"), { consume: true });
|
|
509
693
|
await Promise.resolve();
|
|
510
|
-
assert.deepEqual(opened, ["foreground-active:run-
|
|
694
|
+
assert.deepEqual(opened, ["foreground-active:run-builder:0"]);
|
|
695
|
+
assert.equal(widgetFactory, undefined, "the widget should unregister while the inspector owns the viewport");
|
|
696
|
+
|
|
697
|
+
closeInspector!();
|
|
511
698
|
await new Promise<void>((resolve) => setImmediate(resolve));
|
|
512
|
-
widgetFactory
|
|
699
|
+
assert.ok(widgetFactory, "closing should restore the FleetView widget");
|
|
700
|
+
assert.notEqual(widgetFactory, component, "restoration should install a new component factory");
|
|
701
|
+
const restoredComponent = widgetFactory!(tui, theme);
|
|
702
|
+
assert.ok(restoredComponent.render(100).some((line) => line.includes("> builder")), "closing should restore the prior selected roster row");
|
|
513
703
|
assert.deepEqual(inputHandler!("\x1b"), { consume: true });
|
|
514
|
-
assert.
|
|
704
|
+
assert.equal(restoredComponent.render(100).length, 1, "Escape should return to the compact summary");
|
|
515
705
|
} finally {
|
|
516
706
|
fleet.dispose();
|
|
517
707
|
}
|
|
@@ -127,11 +127,119 @@ describe("Fleet inspector structured transcript", () => {
|
|
|
127
127
|
}],
|
|
128
128
|
};
|
|
129
129
|
const rendered = renderFleetTranscript(transcript, 24, theme as never, markdownTheme, { expandedTools: true });
|
|
130
|
+
assert.doesNotMatch(rendered.join("\n"), /\u001b/u);
|
|
131
|
+
assert.ok(rendered.some((line) => line.includes("U+001B")));
|
|
130
132
|
for (const line of rendered) {
|
|
131
133
|
assert.ok(visibleWidth(line) <= 24, `line exceeded width: ${JSON.stringify(line)}`);
|
|
132
134
|
}
|
|
133
135
|
});
|
|
134
136
|
|
|
137
|
+
it("escapes unsafe transcript code points across messages, notices, and tool fields", () => {
|
|
138
|
+
const root = fs.mkdtempSync(path.join(os.tmpdir(), "pi-fleet-unsafe-transcript-"));
|
|
139
|
+
try {
|
|
140
|
+
const unsafe = "escape:\u001b carriage:\r bidi:\u202e private:\ue000 invalid:\ud800";
|
|
141
|
+
const transcriptPath = writeTranscript(root, [
|
|
142
|
+
{ recordType: "message", role: "assistant", text: `**safe Markdown**\n${unsafe}` },
|
|
143
|
+
{ recordType: "message", role: "user", text: `supervisor ${unsafe}` },
|
|
144
|
+
{ recordType: "stderr", text: `notice ${unsafe}` },
|
|
145
|
+
{ recordType: "tool_start", toolName: "custom", argsPreview: `preview ${unsafe}`, argsPayload: JSON.stringify({ value: unsafe }) },
|
|
146
|
+
{ recordType: "message", role: "toolResult", toolName: "custom", text: `output ${unsafe}`, isError: false },
|
|
147
|
+
{ recordType: "tool_start", toolName: "failing", argsPreview: "failure" },
|
|
148
|
+
{ recordType: "message", role: "toolResult", toolName: "failing", text: `error ${unsafe}`, isError: true },
|
|
149
|
+
]);
|
|
150
|
+
|
|
151
|
+
const transcript = readFleetTranscript(transcriptPath, { trustedRoots: [root] });
|
|
152
|
+
const serialized = JSON.stringify(transcript.events);
|
|
153
|
+
assert.doesNotMatch(serialized, /[\u001b\r\u202e\ue000\ud800]/u);
|
|
154
|
+
assert.match(serialized, /U\+001B/);
|
|
155
|
+
assert.match(serialized, /U\+000D/);
|
|
156
|
+
assert.match(serialized, /U\+202E/);
|
|
157
|
+
assert.match(serialized, /U\+E000/);
|
|
158
|
+
assert.match(serialized, /U\+D800/);
|
|
159
|
+
|
|
160
|
+
const compact = renderFleetTranscript(transcript, 44, theme as never, markdownTheme);
|
|
161
|
+
assert.ok(compact.some((line) => line.includes("preview escape:[U+001B]")));
|
|
162
|
+
const rendered = renderFleetTranscript(transcript, 44, theme as never, markdownTheme, { expandedTools: true });
|
|
163
|
+
assert.ok(rendered.some((line) => line.includes("safe Markdown")));
|
|
164
|
+
assert.ok(rendered.some((line) => line.includes("output escape:[U+001B]")));
|
|
165
|
+
assert.ok(rendered.some((line) => line.includes("error escape:[U+001B]")));
|
|
166
|
+
assert.doesNotMatch(rendered.join("\n"), /[\u001b\u202e\ue000\ud800]/u);
|
|
167
|
+
for (const line of [...compact, ...rendered]) assert.ok(visibleWidth(line) <= 44, `line exceeded width: ${JSON.stringify(line)}`);
|
|
168
|
+
} finally {
|
|
169
|
+
fs.rmSync(root, { recursive: true, force: true });
|
|
170
|
+
}
|
|
171
|
+
});
|
|
172
|
+
|
|
173
|
+
it("preserves safe tool argument JSON formatting while sanitizing decoded values", () => {
|
|
174
|
+
const root = fs.mkdtempSync(path.join(os.tmpdir(), "pi-fleet-args-payload-"));
|
|
175
|
+
try {
|
|
176
|
+
const safePayload = '{\r\n\t"path": "src/tui/fleet.ts",\r\n\t"lines": [1, 2]\r\n}';
|
|
177
|
+
const standaloneCarriageReturnPayload = '{\r"safe": true\r}';
|
|
178
|
+
const unsafePayload = '{\n "value": "\\u001b"\n}';
|
|
179
|
+
const protoPayload = '{"nested":{"__proto__":"\\u001b"}}';
|
|
180
|
+
const transcriptPath = writeTranscript(root, [
|
|
181
|
+
{ recordType: "tool_start", toolName: "safe", argsPayload: safePayload },
|
|
182
|
+
{ recordType: "tool_start", toolName: "standalone-cr", argsPayload: standaloneCarriageReturnPayload },
|
|
183
|
+
{ recordType: "tool_start", toolName: "unsafe", argsPayload: unsafePayload },
|
|
184
|
+
{ recordType: "tool_start", toolName: "proto", argsPayload: protoPayload },
|
|
185
|
+
]);
|
|
186
|
+
const transcript = readFleetTranscript(transcriptPath, { trustedRoots: [root] });
|
|
187
|
+
const tools = transcript.events.filter((event) => event.kind === "tool");
|
|
188
|
+
assert.equal(tools[0]?.kind, "tool");
|
|
189
|
+
assert.equal(tools[1]?.kind, "tool");
|
|
190
|
+
assert.equal(tools[2]?.kind, "tool");
|
|
191
|
+
assert.equal(tools[3]?.kind, "tool");
|
|
192
|
+
if (tools[0]?.kind === "tool") assert.equal(tools[0].argsPayload, safePayload.replace(/\r\n/g, "\n"));
|
|
193
|
+
if (tools[1]?.kind === "tool") assert.equal(tools[1].argsPayload, '{[U+000D]"safe": true[U+000D]}');
|
|
194
|
+
if (tools[2]?.kind === "tool") assert.equal(tools[2].argsPayload, '{"value":"[U+001B]"}');
|
|
195
|
+
if (tools[3]?.kind === "tool") assert.equal(tools[3].argsPayload, '{"nested":{"__proto__":"[U+001B]"}}');
|
|
196
|
+
} finally {
|
|
197
|
+
fs.rmSync(root, { recursive: true, force: true });
|
|
198
|
+
}
|
|
199
|
+
});
|
|
200
|
+
|
|
201
|
+
it("replaces obvious binary transcript content with a warning placeholder", () => {
|
|
202
|
+
const root = fs.mkdtempSync(path.join(os.tmpdir(), "pi-fleet-binary-transcript-"));
|
|
203
|
+
try {
|
|
204
|
+
const binary = "PNG\u0000\u0001\u0002payload";
|
|
205
|
+
const transcriptPath = writeTranscript(root, [
|
|
206
|
+
{ recordType: "message", role: "assistant", text: binary },
|
|
207
|
+
{ recordType: "tool_start", toolName: "custom", argsPreview: binary, argsPayload: JSON.stringify({ data: binary }) },
|
|
208
|
+
{ recordType: "message", role: "toolResult", toolName: "custom", text: binary, isError: false },
|
|
209
|
+
]);
|
|
210
|
+
|
|
211
|
+
const transcript = readFleetTranscript(transcriptPath, { trustedRoots: [root] });
|
|
212
|
+
const serialized = JSON.stringify(transcript.events);
|
|
213
|
+
assert.doesNotMatch(serialized, /[\u0000-\u0002]/u);
|
|
214
|
+
assert.match(serialized, /binary content omitted/i);
|
|
215
|
+
|
|
216
|
+
const rendered = renderFleetTranscript(transcript, 36, theme as never, markdownTheme, { expandedTools: true });
|
|
217
|
+
assert.ok(rendered.some((line) => /binary content omitted/i.test(line)));
|
|
218
|
+
for (const line of rendered) assert.ok(visibleWidth(line) <= 36, `line exceeded width: ${JSON.stringify(line)}`);
|
|
219
|
+
} finally {
|
|
220
|
+
fs.rmSync(root, { recursive: true, force: true });
|
|
221
|
+
}
|
|
222
|
+
});
|
|
223
|
+
|
|
224
|
+
it("preserves normal Unicode, newlines, tabs, Markdown, code highlighting, and width", () => {
|
|
225
|
+
const root = fs.mkdtempSync(path.join(os.tmpdir(), "pi-fleet-unicode-transcript-"));
|
|
226
|
+
try {
|
|
227
|
+
const text = "## Résumé 世界 👩🏽💻\r\n\r\n```ts\r\nconst café = \"☕\";\r\n```\r\n\tindented";
|
|
228
|
+
const transcriptPath = writeTranscript(root, [{ recordType: "message", role: "assistant", text }]);
|
|
229
|
+
const transcript = readFleetTranscript(transcriptPath, { trustedRoots: [root] });
|
|
230
|
+
assert.equal(transcript.events[0]?.kind, "assistant");
|
|
231
|
+
if (transcript.events[0]?.kind === "assistant") assert.equal(transcript.events[0].text, text.replace(/\r\n/g, "\n"));
|
|
232
|
+
|
|
233
|
+
const rendered = renderFleetTranscript(transcript, 28, theme as never, markdownTheme);
|
|
234
|
+
assert.ok(rendered.some((line) => line.includes("Résumé 世界")));
|
|
235
|
+
assert.ok(rendered.some((line) => line.includes("const café")));
|
|
236
|
+
assert.ok(rendered.some((line) => line.includes("indented")));
|
|
237
|
+
for (const line of rendered) assert.ok(visibleWidth(line) <= 28, `line exceeded width: ${JSON.stringify(line)}`);
|
|
238
|
+
} finally {
|
|
239
|
+
fs.rmSync(root, { recursive: true, force: true });
|
|
240
|
+
}
|
|
241
|
+
});
|
|
242
|
+
|
|
135
243
|
it("associates parallel same-name tool results by tool call id", () => {
|
|
136
244
|
const root = fs.mkdtempSync(path.join(os.tmpdir(), "pi-fleet-parallel-tools-"));
|
|
137
245
|
try {
|
|
@@ -277,4 +385,23 @@ describe("Fleet inspector structured transcript", () => {
|
|
|
277
385
|
fs.rmSync(outsideRoot, { recursive: true, force: true });
|
|
278
386
|
}
|
|
279
387
|
});
|
|
388
|
+
|
|
389
|
+
it("sanitizes read-boundary warnings before other Fleet views consume them", () => {
|
|
390
|
+
const trustedRoot = fs.mkdtempSync(path.join(os.tmpdir(), "pi-fleet-warning-trusted-"));
|
|
391
|
+
const outsideRoot = fs.mkdtempSync(path.join(os.tmpdir(), "pi-fleet-warning-outside-"));
|
|
392
|
+
try {
|
|
393
|
+
writeTranscript(outsideRoot, [{ recordType: "message", role: "assistant", text: "secret" }]);
|
|
394
|
+
const transcript = readFleetTranscript(path.join(outsideRoot, "unsafe-\u001b[31m.jsonl"), { trustedRoots: [trustedRoot] });
|
|
395
|
+
assert.deepEqual(transcript.events, []);
|
|
396
|
+
assert.doesNotMatch(transcript.warning ?? "", /\u001b/u);
|
|
397
|
+
assert.match(transcript.warning ?? "", /U\+001B/);
|
|
398
|
+
|
|
399
|
+
const rendered = renderFleetTranscript(transcript, 40, theme as never, markdownTheme);
|
|
400
|
+
assert.doesNotMatch(rendered.join("\n"), /\u001b/u);
|
|
401
|
+
for (const line of rendered) assert.ok(visibleWidth(line) <= 40, `line exceeded width: ${JSON.stringify(line)}`);
|
|
402
|
+
} finally {
|
|
403
|
+
fs.rmSync(trustedRoot, { recursive: true, force: true });
|
|
404
|
+
fs.rmSync(outsideRoot, { recursive: true, force: true });
|
|
405
|
+
}
|
|
406
|
+
});
|
|
280
407
|
});
|