@draht/coding-agent 2026.10.20 → 2026.10.23
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 +138 -0
- package/agents/advisor.md +2 -2
- package/agents/architect.md +11 -33
- package/agents/debugger.md +13 -54
- package/agents/git-committer.md +18 -42
- package/agents/implementer.md +14 -36
- package/agents/investigator.md +12 -63
- package/agents/reviewer.md +16 -44
- package/agents/security-auditor.md +22 -56
- package/agents/spec-reviewer.md +13 -53
- package/agents/verifier.md +14 -33
- package/bin/drahtbank.mjs +4 -0
- package/dist/agents/advisor.md +2 -2
- package/dist/agents/architect.md +11 -33
- package/dist/agents/debugger.md +13 -54
- package/dist/agents/git-committer.md +18 -42
- package/dist/agents/implementer.md +14 -36
- package/dist/agents/investigator.md +12 -63
- package/dist/agents/reviewer.md +16 -44
- package/dist/agents/security-auditor.md +22 -56
- package/dist/agents/spec-reviewer.md +13 -53
- package/dist/agents/verifier.md +14 -33
- package/dist/bundle/chunks/anthropic-messages-VEMVBETR.js +6 -0
- package/dist/bundle/chunks/anthropic.js +1 -1
- package/dist/bundle/chunks/azure-openai-responses-EXUP6SLM.js +2 -0
- package/dist/bundle/chunks/bedrock-converse-stream.js +23 -20
- package/dist/bundle/chunks/chunk-2MJ6J5N2.js +6 -0
- package/dist/bundle/chunks/chunk-2RI4GIFP.js +166 -0
- package/dist/bundle/chunks/chunk-57PET6SW.js +82 -0
- package/dist/bundle/chunks/chunk-76YNMQ57.js +2 -0
- package/dist/bundle/chunks/chunk-AACPRSR2.js +9 -0
- package/dist/bundle/chunks/chunk-CHRFWNPF.js +1424 -0
- package/dist/bundle/chunks/chunk-CI37W6HM.js +2 -0
- package/dist/bundle/chunks/chunk-CMKX4CSI.js +6 -0
- package/dist/bundle/chunks/chunk-DHZBWXZK.js +16 -0
- package/dist/bundle/chunks/{chunk-D6TMD5Q2.js → chunk-DLVZ3EK7.js} +4 -4
- package/dist/bundle/chunks/chunk-DQ4G4IS4.js +20 -0
- package/dist/bundle/chunks/chunk-FXCTQRNN.js +2 -0
- package/dist/bundle/chunks/chunk-FXLM6UQV.js +2 -0
- package/dist/bundle/chunks/chunk-ITP6IDBA.js +20 -0
- package/dist/bundle/chunks/chunk-JRHPLIE5.js +11 -0
- package/dist/bundle/chunks/chunk-KINQOWAP.js +4 -0
- package/dist/bundle/chunks/{chunk-IWTUBX6V.js → chunk-LK54N67E.js} +5 -2
- package/dist/bundle/chunks/chunk-MBFTIGLS.js +2 -0
- package/dist/bundle/chunks/chunk-QG2WW2SA.js +2 -0
- package/dist/bundle/chunks/{chunk-KPO5375S.js → chunk-RCRGGYLW.js} +1 -1
- package/dist/bundle/chunks/chunk-RGI7SF5G.js +2 -0
- package/dist/bundle/chunks/{chunk-6ZJKIMU7.js → chunk-SYRVFGYE.js} +1 -1
- package/dist/bundle/chunks/chunk-UQSONZLL.js +479 -0
- package/dist/bundle/chunks/chunk-USCN7R2E.js +2 -0
- package/dist/bundle/chunks/chunk-XB4F3WGD.js +132 -0
- package/dist/bundle/chunks/chunk-YSIQCH4Z.js +2 -0
- package/dist/bundle/chunks/chunk-ZRPAOMVB.js +2 -0
- package/dist/bundle/chunks/{cli-PYJB6AQ3.js → cli-LGOE6EXL.js} +6 -6
- package/dist/bundle/chunks/cloudflare-workers-ai-system-one-47PK45EQ.js +2 -0
- package/dist/bundle/chunks/codemode-worker.js +188 -21
- package/dist/bundle/chunks/execute-ZVQ7ITER.js +31 -0
- package/dist/bundle/chunks/github-copilot.js +1 -1
- package/dist/bundle/chunks/google-generative-ai-PBPH45HB.js +2 -0
- package/dist/bundle/chunks/google-vertex-ZPCFQNU6.js +2 -0
- package/dist/bundle/chunks/image-resize-worker.js +1 -1
- package/dist/bundle/chunks/{llama-cpp-classify-EJ5XMSQL.js → llama-cpp-classify-MWIQKGBR.js} +3 -3
- package/dist/bundle/chunks/mistral-conversations-7ODWQ37T.js +5 -0
- package/dist/bundle/chunks/node-BZAVEWJ3.js +16 -0
- package/dist/bundle/chunks/openai-chatgpt.js +1 -1
- package/dist/bundle/chunks/openai-codex-responses-7Y2SP2GS.js +10 -0
- package/dist/bundle/chunks/openai-codex.js +1 -1
- package/dist/bundle/chunks/openai-completions-QNWYJ4H4.js +7 -0
- package/dist/bundle/chunks/openai-decisions-4PKBAPR3.js +5 -0
- package/dist/bundle/chunks/openai-responses-73WU3TQM.js +4 -0
- package/dist/bundle/chunks/opencode-go.js +1 -1
- package/dist/bundle/chunks/openrouter-images-IMWDSQ5F.js +2 -0
- package/dist/bundle/chunks/pi-messages-AMNZ7HKZ.js +8 -0
- package/dist/bundle/chunks/runtime-7BIFTREJ.js +3 -0
- package/dist/bundle/chunks/runtime-MZVF4MP6.js +2 -0
- package/dist/bundle/chunks/settings-manager-QF6DRH5C.js +2 -0
- package/dist/bundle/chunks/typesafe-system-one-AXQRIVVX.js +2 -0
- package/dist/bundle/chunks/virtual-modules-Z4F3ZUX3.js +2 -0
- package/dist/bundle/cli-runtime.js +1 -1
- package/dist/bundle/index.js +1 -1
- package/dist/bundle/rpc-entry.js +1 -1
- package/dist/cli/args.d.ts +2 -1
- package/dist/cli/args.d.ts.map +1 -1
- package/dist/cli/args.js +30 -8
- package/dist/cli/args.js.map +1 -1
- package/dist/cli/credential-print.d.ts.map +1 -1
- package/dist/cli/credential-print.js +4 -4
- package/dist/cli/credential-print.js.map +1 -1
- package/dist/config.d.ts +18 -1
- package/dist/config.d.ts.map +1 -1
- package/dist/config.js +44 -6
- package/dist/config.js.map +1 -1
- package/dist/core/agent-session.d.ts +65 -8
- package/dist/core/agent-session.d.ts.map +1 -1
- package/dist/core/agent-session.js +240 -102
- package/dist/core/agent-session.js.map +1 -1
- package/dist/core/auth-storage.d.ts.map +1 -1
- package/dist/core/auth-storage.js +20 -13
- package/dist/core/auth-storage.js.map +1 -1
- package/dist/core/bash-executor.d.ts.map +1 -1
- package/dist/core/bash-executor.js +42 -52
- package/dist/core/bash-executor.js.map +1 -1
- package/dist/core/bug-report.d.ts +9 -1
- package/dist/core/bug-report.d.ts.map +1 -1
- package/dist/core/builtins/completion-checks.d.ts +3 -0
- package/dist/core/builtins/completion-checks.d.ts.map +1 -0
- package/dist/core/builtins/completion-checks.js +142 -0
- package/dist/core/builtins/completion-checks.js.map +1 -0
- package/dist/core/builtins/duet.d.ts.map +1 -1
- package/dist/core/builtins/duet.js +7 -5
- package/dist/core/builtins/duet.js.map +1 -1
- package/dist/core/builtins/git-safety.d.ts +3 -0
- package/dist/core/builtins/git-safety.d.ts.map +1 -0
- package/dist/core/builtins/git-safety.js +34 -0
- package/dist/core/builtins/git-safety.js.map +1 -0
- package/dist/core/builtins/index.d.ts.map +1 -1
- package/dist/core/builtins/index.js +4 -0
- package/dist/core/builtins/index.js.map +1 -1
- package/dist/core/client-identity.d.ts +8 -0
- package/dist/core/client-identity.d.ts.map +1 -0
- package/dist/core/client-identity.js +15 -0
- package/dist/core/client-identity.js.map +1 -0
- package/dist/core/compaction/branch-summarization.d.ts.map +1 -1
- package/dist/core/compaction/branch-summarization.js +1 -2
- package/dist/core/compaction/branch-summarization.js.map +1 -1
- package/dist/core/compaction/compaction.d.ts +2 -2
- package/dist/core/compaction/compaction.d.ts.map +1 -1
- package/dist/core/compaction/compaction.js +20 -15
- package/dist/core/compaction/compaction.js.map +1 -1
- package/dist/core/compaction/utils.d.ts +6 -0
- package/dist/core/compaction/utils.d.ts.map +1 -1
- package/dist/core/compaction/utils.js +7 -8
- package/dist/core/compaction/utils.js.map +1 -1
- package/dist/core/export-html/index.d.ts.map +1 -1
- package/dist/core/export-html/index.js +2 -0
- package/dist/core/export-html/index.js.map +1 -1
- package/dist/core/export-html/template.html +1 -0
- package/dist/core/export-html/template.js +23 -17
- package/dist/core/export-html/tool-renderer.d.ts +3 -3
- package/dist/core/export-html/tool-renderer.d.ts.map +1 -1
- package/dist/core/export-html/tool-renderer.js +5 -3
- package/dist/core/export-html/tool-renderer.js.map +1 -1
- package/dist/core/export-html/vendor/marked-cjk-friendly.min.js +6 -0
- package/dist/core/export-html/vendor/marked.min.js +30 -29
- package/dist/core/extensions/index.d.ts +1 -1
- package/dist/core/extensions/index.d.ts.map +1 -1
- package/dist/core/extensions/index.js.map +1 -1
- package/dist/core/extensions/loader.d.ts.map +1 -1
- package/dist/core/extensions/loader.js +7 -0
- package/dist/core/extensions/loader.js.map +1 -1
- package/dist/core/extensions/runner.d.ts +6 -2
- package/dist/core/extensions/runner.d.ts.map +1 -1
- package/dist/core/extensions/runner.js +16 -4
- package/dist/core/extensions/runner.js.map +1 -1
- package/dist/core/extensions/types.d.ts +61 -7
- package/dist/core/extensions/types.d.ts.map +1 -1
- package/dist/core/extensions/types.js.map +1 -1
- package/dist/core/extensions/virtual-modules.d.ts.map +1 -1
- package/dist/core/extensions/virtual-modules.js +2 -0
- package/dist/core/extensions/virtual-modules.js.map +1 -1
- package/dist/core/key-id-schema.d.ts +6 -0
- package/dist/core/key-id-schema.d.ts.map +1 -0
- package/dist/core/key-id-schema.js +16 -0
- package/dist/core/key-id-schema.js.map +1 -0
- package/dist/core/keybindings-schema.d.ts +4 -0
- package/dist/core/keybindings-schema.d.ts.map +1 -0
- package/dist/core/keybindings-schema.js +16 -0
- package/dist/core/keybindings-schema.js.map +1 -0
- package/dist/core/keybindings.d.ts +242 -75
- package/dist/core/keybindings.d.ts.map +1 -1
- package/dist/core/keybindings.js +30 -23
- package/dist/core/keybindings.js.map +1 -1
- package/dist/core/mcp-servers.d.ts +22 -0
- package/dist/core/mcp-servers.d.ts.map +1 -1
- package/dist/core/mcp-servers.js +72 -11
- package/dist/core/mcp-servers.js.map +1 -1
- package/dist/core/model-config.d.ts +1623 -74
- package/dist/core/model-config.d.ts.map +1 -1
- package/dist/core/model-config.js +70 -184
- package/dist/core/model-config.js.map +1 -1
- package/dist/core/model-registry.d.ts +3 -1
- package/dist/core/model-registry.d.ts.map +1 -1
- package/dist/core/model-registry.js +4 -0
- package/dist/core/model-registry.js.map +1 -1
- package/dist/core/model-resolver.d.ts +56 -43
- package/dist/core/model-resolver.d.ts.map +1 -1
- package/dist/core/model-resolver.js +253 -358
- package/dist/core/model-resolver.js.map +1 -1
- package/dist/core/model-runtime.d.ts.map +1 -1
- package/dist/core/model-runtime.js +19 -10
- package/dist/core/model-runtime.js.map +1 -1
- package/dist/core/nested-tool-calls.d.ts +1 -0
- package/dist/core/nested-tool-calls.d.ts.map +1 -1
- package/dist/core/nested-tool-calls.js +1 -0
- package/dist/core/nested-tool-calls.js.map +1 -1
- package/dist/core/package-manager.js +3 -3
- package/dist/core/package-manager.js.map +1 -1
- package/dist/core/polyphase/keyword.js +1 -1
- package/dist/core/polyphase/keyword.js.map +1 -1
- package/dist/core/polyphase/model-selection.d.ts.map +1 -1
- package/dist/core/polyphase/model-selection.js +15 -7
- package/dist/core/polyphase/model-selection.js.map +1 -1
- package/dist/core/polyphase/workflow/prelude.d.ts +2 -0
- package/dist/core/polyphase/workflow/prelude.d.ts.map +1 -1
- package/dist/core/polyphase/workflow/prelude.js +12 -16
- package/dist/core/polyphase/workflow/prelude.js.map +1 -1
- package/dist/core/polyphase/workflow/runtime.d.ts.map +1 -1
- package/dist/core/polyphase/workflow/runtime.js +2 -1
- package/dist/core/polyphase/workflow/runtime.js.map +1 -1
- package/dist/core/project-trust.d.ts.map +1 -1
- package/dist/core/project-trust.js +2 -1
- package/dist/core/project-trust.js.map +1 -1
- package/dist/core/prompt-templates.d.ts.map +1 -1
- package/dist/core/prompt-templates.js +7 -2
- package/dist/core/prompt-templates.js.map +1 -1
- package/dist/core/provider-composer.d.ts +2 -1
- package/dist/core/provider-composer.d.ts.map +1 -1
- package/dist/core/provider-composer.js +13 -0
- package/dist/core/provider-composer.js.map +1 -1
- package/dist/core/radius.d.ts +2 -0
- package/dist/core/radius.d.ts.map +1 -1
- package/dist/core/radius.js +2 -0
- package/dist/core/radius.js.map +1 -1
- package/dist/core/remote-catalog-provider.d.ts +12 -1
- package/dist/core/remote-catalog-provider.d.ts.map +1 -1
- package/dist/core/remote-catalog-provider.js +84 -24
- package/dist/core/remote-catalog-provider.js.map +1 -1
- package/dist/core/resource-loader.d.ts +3 -0
- package/dist/core/resource-loader.d.ts.map +1 -1
- package/dist/core/resource-loader.js +7 -4
- package/dist/core/resource-loader.js.map +1 -1
- package/dist/core/sdk.d.ts +13 -4
- package/dist/core/sdk.d.ts.map +1 -1
- package/dist/core/sdk.js +27 -15
- package/dist/core/sdk.js.map +1 -1
- package/dist/core/settings-defaults.d.ts +65 -0
- package/dist/core/settings-defaults.d.ts.map +1 -0
- package/dist/core/settings-defaults.js +66 -0
- package/dist/core/settings-defaults.js.map +1 -0
- package/dist/core/settings-manager.d.ts +17 -178
- package/dist/core/settings-manager.d.ts.map +1 -1
- package/dist/core/settings-manager.js +86 -57
- package/dist/core/settings-manager.js.map +1 -1
- package/dist/core/settings-schema.d.ts +269 -0
- package/dist/core/settings-schema.d.ts.map +1 -0
- package/dist/core/settings-schema.js +318 -0
- package/dist/core/settings-schema.js.map +1 -0
- package/dist/core/skills.d.ts +4 -1
- package/dist/core/skills.d.ts.map +1 -1
- package/dist/core/skills.js +6 -1
- package/dist/core/skills.js.map +1 -1
- package/dist/core/system-prompt.d.ts +6 -0
- package/dist/core/system-prompt.d.ts.map +1 -1
- package/dist/core/system-prompt.js +10 -5
- package/dist/core/system-prompt.js.map +1 -1
- package/dist/core/tools/bash.d.ts.map +1 -1
- package/dist/core/tools/bash.js +3 -5
- package/dist/core/tools/bash.js.map +1 -1
- package/dist/core/tools/grep.d.ts +8 -0
- package/dist/core/tools/grep.d.ts.map +1 -1
- package/dist/core/tools/grep.js +19 -7
- package/dist/core/tools/grep.js.map +1 -1
- package/dist/core/tools/index.d.ts +2 -0
- package/dist/core/tools/index.d.ts.map +1 -1
- package/dist/core/tools/index.js +2 -0
- package/dist/core/tools/index.js.map +1 -1
- package/dist/core/tools/output-accumulator.d.ts.map +1 -1
- package/dist/core/tools/output-accumulator.js +4 -10
- package/dist/core/tools/output-accumulator.js.map +1 -1
- package/dist/core/tools/path-utils.d.ts +1 -1
- package/dist/core/tools/path-utils.d.ts.map +1 -1
- package/dist/core/tools/path-utils.js +6 -6
- package/dist/core/tools/path-utils.js.map +1 -1
- package/dist/core/tools/read.d.ts +13 -0
- package/dist/core/tools/read.d.ts.map +1 -1
- package/dist/core/tools/read.js +32 -2
- package/dist/core/tools/read.js.map +1 -1
- package/dist/core/tools/render-utils.d.ts +20 -0
- package/dist/core/tools/render-utils.d.ts.map +1 -1
- package/dist/core/tools/render-utils.js +67 -0
- package/dist/core/tools/render-utils.js.map +1 -1
- package/dist/core/tools/renderers/bash.d.ts.map +1 -1
- package/dist/core/tools/renderers/bash.js +7 -35
- package/dist/core/tools/renderers/bash.js.map +1 -1
- package/dist/core/tools/renderers/edit.d.ts.map +1 -1
- package/dist/core/tools/renderers/edit.js +5 -4
- package/dist/core/tools/renderers/edit.js.map +1 -1
- package/dist/core/tools/renderers/index.d.ts +2 -2
- package/dist/core/tools/renderers/index.d.ts.map +1 -1
- package/dist/core/tools/renderers/index.js.map +1 -1
- package/dist/core/tools/renderers/read.d.ts.map +1 -1
- package/dist/core/tools/renderers/read.js +7 -11
- package/dist/core/tools/renderers/read.js.map +1 -1
- package/dist/extensions/codemode/execute.d.ts.map +1 -1
- package/dist/extensions/codemode/execute.js +391 -80
- package/dist/extensions/codemode/execute.js.map +1 -1
- package/dist/extensions/codemode/index.d.ts.map +1 -1
- package/dist/extensions/codemode/index.js +3 -1
- package/dist/extensions/codemode/index.js.map +1 -1
- package/dist/extensions/codemode/renderer.d.ts +2 -2
- package/dist/extensions/codemode/renderer.d.ts.map +1 -1
- package/dist/extensions/codemode/renderer.js +9 -3
- package/dist/extensions/codemode/renderer.js.map +1 -1
- package/dist/extensions/codemode/tool.d.ts +22 -21
- package/dist/extensions/codemode/tool.d.ts.map +1 -1
- package/dist/extensions/codemode/tool.js +96 -123
- package/dist/extensions/codemode/tool.js.map +1 -1
- package/dist/extensions/llama/provider.d.ts.map +1 -1
- package/dist/extensions/llama/provider.js +34 -11
- package/dist/extensions/llama/provider.js.map +1 -1
- package/dist/extensions/mcp/cli.d.ts.map +1 -1
- package/dist/extensions/mcp/cli.js +27 -33
- package/dist/extensions/mcp/cli.js.map +1 -1
- package/dist/extensions/mcp/config.d.ts +15 -3
- package/dist/extensions/mcp/config.d.ts.map +1 -1
- package/dist/extensions/mcp/config.js +49 -12
- package/dist/extensions/mcp/config.js.map +1 -1
- package/dist/extensions/mcp/index.d.ts +4 -1
- package/dist/extensions/mcp/index.d.ts.map +1 -1
- package/dist/extensions/mcp/index.js +279 -129
- package/dist/extensions/mcp/index.js.map +1 -1
- package/dist/extensions/mcp/oauth.d.ts +21 -11
- package/dist/extensions/mcp/oauth.d.ts.map +1 -1
- package/dist/extensions/mcp/oauth.js +166 -45
- package/dist/extensions/mcp/oauth.js.map +1 -1
- package/dist/extensions/mcp/resources.d.ts +3 -10
- package/dist/extensions/mcp/resources.d.ts.map +1 -1
- package/dist/extensions/mcp/resources.js +4 -5
- package/dist/extensions/mcp/resources.js.map +1 -1
- package/dist/extensions/mcp/runtime.d.ts +7 -7
- package/dist/extensions/mcp/runtime.d.ts.map +1 -1
- package/dist/extensions/mcp/runtime.js +31 -45
- package/dist/extensions/mcp/runtime.js.map +1 -1
- package/dist/extensions/mcp/tools.d.ts +7 -5
- package/dist/extensions/mcp/tools.d.ts.map +1 -1
- package/dist/extensions/mcp/tools.js +87 -29
- package/dist/extensions/mcp/tools.js.map +1 -1
- package/dist/extensions/mcp/ui.d.ts +3 -3
- package/dist/extensions/mcp/ui.d.ts.map +1 -1
- package/dist/extensions/mcp/ui.js +18 -6
- package/dist/extensions/mcp/ui.js.map +1 -1
- package/dist/extensions/tool-search/tool.d.ts +0 -2
- package/dist/extensions/tool-search/tool.d.ts.map +1 -1
- package/dist/extensions/tool-search/tool.js +2 -4
- package/dist/extensions/tool-search/tool.js.map +1 -1
- package/dist/hooks/checks/checks-runtime.cjs +215 -0
- package/dist/hooks/checks/git-safety.cjs +198 -0
- package/dist/hooks/checks/git-safety.d.cts +1 -0
- package/dist/hooks/gsd/draht-post-task.js +78 -39
- package/dist/hooks/gsd/draht-quality-gate.js +210 -122
- package/dist/hooks/gsd/package.json +3 -0
- package/dist/index.d.ts +5 -4
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -2
- package/dist/index.js.map +1 -1
- package/dist/main.d.ts.map +1 -1
- package/dist/main.js +11 -3
- package/dist/main.js.map +1 -1
- package/dist/modes/interactive/components/auth-url.d.ts +14 -0
- package/dist/modes/interactive/components/auth-url.d.ts.map +1 -0
- package/dist/modes/interactive/components/auth-url.js +37 -0
- package/dist/modes/interactive/components/auth-url.js.map +1 -0
- package/dist/modes/interactive/components/bash-execution.d.ts +5 -1
- package/dist/modes/interactive/components/bash-execution.d.ts.map +1 -1
- package/dist/modes/interactive/components/bash-execution.js +17 -14
- package/dist/modes/interactive/components/bash-execution.js.map +1 -1
- package/dist/modes/interactive/components/branch-summary-message.d.ts +2 -1
- package/dist/modes/interactive/components/branch-summary-message.d.ts.map +1 -1
- package/dist/modes/interactive/components/branch-summary-message.js +5 -2
- package/dist/modes/interactive/components/branch-summary-message.js.map +1 -1
- package/dist/modes/interactive/components/compaction-summary-message.d.ts +2 -1
- package/dist/modes/interactive/components/compaction-summary-message.d.ts.map +1 -1
- package/dist/modes/interactive/components/compaction-summary-message.js +5 -2
- package/dist/modes/interactive/components/compaction-summary-message.js.map +1 -1
- package/dist/modes/interactive/components/custom-entry.d.ts +3 -1
- package/dist/modes/interactive/components/custom-entry.d.ts.map +1 -1
- package/dist/modes/interactive/components/custom-entry.js +8 -2
- package/dist/modes/interactive/components/custom-entry.js.map +1 -1
- package/dist/modes/interactive/components/custom-message.d.ts.map +1 -1
- package/dist/modes/interactive/components/custom-message.js +1 -0
- package/dist/modes/interactive/components/custom-message.js.map +1 -1
- package/dist/modes/interactive/components/login-dialog.d.ts +3 -0
- package/dist/modes/interactive/components/login-dialog.d.ts.map +1 -1
- package/dist/modes/interactive/components/login-dialog.js +38 -10
- package/dist/modes/interactive/components/login-dialog.js.map +1 -1
- package/dist/modes/interactive/components/oauth-selector.d.ts +8 -2
- package/dist/modes/interactive/components/oauth-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/oauth-selector.js +24 -21
- package/dist/modes/interactive/components/oauth-selector.js.map +1 -1
- package/dist/modes/interactive/components/radius-login-selector.d.ts +15 -0
- package/dist/modes/interactive/components/radius-login-selector.d.ts.map +1 -0
- package/dist/modes/interactive/components/radius-login-selector.js +85 -0
- package/dist/modes/interactive/components/radius-login-selector.js.map +1 -0
- package/dist/modes/interactive/components/settings-selector.d.ts +3 -3
- package/dist/modes/interactive/components/settings-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/settings-selector.js +9 -8
- package/dist/modes/interactive/components/settings-selector.js.map +1 -1
- package/dist/modes/interactive/components/skill-invocation-message.d.ts +2 -1
- package/dist/modes/interactive/components/skill-invocation-message.d.ts.map +1 -1
- package/dist/modes/interactive/components/skill-invocation-message.js +5 -2
- package/dist/modes/interactive/components/skill-invocation-message.js.map +1 -1
- package/dist/modes/interactive/components/status-indicator.d.ts +1 -1
- package/dist/modes/interactive/components/status-indicator.d.ts.map +1 -1
- package/dist/modes/interactive/components/status-indicator.js +2 -2
- package/dist/modes/interactive/components/status-indicator.js.map +1 -1
- package/dist/modes/interactive/components/tool-execution.d.ts +12 -13
- package/dist/modes/interactive/components/tool-execution.d.ts.map +1 -1
- package/dist/modes/interactive/components/tool-execution.js +32 -45
- package/dist/modes/interactive/components/tool-execution.js.map +1 -1
- package/dist/modes/interactive/components/tree-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/tree-selector.js +2 -9
- package/dist/modes/interactive/components/tree-selector.js.map +1 -1
- package/dist/modes/interactive/components/user-message.d.ts.map +1 -1
- package/dist/modes/interactive/components/user-message.js +5 -4
- package/dist/modes/interactive/components/user-message.js.map +1 -1
- package/dist/modes/interactive/interactive-mode.d.ts +43 -48
- package/dist/modes/interactive/interactive-mode.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-mode.js +362 -278
- package/dist/modes/interactive/interactive-mode.js.map +1 -1
- package/dist/modes/interactive/program-status-reporter.d.ts +34 -0
- package/dist/modes/interactive/program-status-reporter.d.ts.map +1 -0
- package/dist/modes/interactive/program-status-reporter.js +110 -0
- package/dist/modes/interactive/program-status-reporter.js.map +1 -0
- package/dist/modes/interactive/theme/dark.json +1 -1
- package/dist/modes/interactive/theme/light.json +1 -1
- package/dist/modes/interactive/theme/system-theme.d.ts +2 -1
- package/dist/modes/interactive/theme/system-theme.d.ts.map +1 -1
- package/dist/modes/interactive/theme/system-theme.js +16 -5
- package/dist/modes/interactive/theme/system-theme.js.map +1 -1
- package/dist/modes/interactive/theme/theme-schema.d.ts +28 -0
- package/dist/modes/interactive/theme/theme-schema.d.ts.map +1 -0
- package/dist/modes/interactive/theme/theme-schema.js +105 -0
- package/dist/modes/interactive/theme/theme-schema.js.map +1 -0
- package/dist/modes/interactive/theme/theme-tokens.d.ts +257 -0
- package/dist/modes/interactive/theme/theme-tokens.d.ts.map +1 -0
- package/dist/modes/interactive/theme/theme-tokens.js +94 -0
- package/dist/modes/interactive/theme/theme-tokens.js.map +1 -0
- package/dist/modes/interactive/theme/theme.d.ts +13 -16
- package/dist/modes/interactive/theme/theme.d.ts.map +1 -1
- package/dist/modes/interactive/theme/theme.js +22 -29
- package/dist/modes/interactive/theme/theme.js.map +1 -1
- package/dist/modes/print-mode.d.ts.map +1 -1
- package/dist/modes/print-mode.js +4 -0
- package/dist/modes/print-mode.js.map +1 -1
- package/dist/package-manager-cli.d.ts.map +1 -1
- package/dist/package-manager-cli.js +26 -1
- package/dist/package-manager-cli.js.map +1 -1
- package/dist/prompts/commands/atomic-commit.md +8 -6
- package/dist/prompts/commands/brainstorm.md +5 -149
- package/dist/prompts/commands/create-verification-skill.md +8 -48
- package/dist/prompts/commands/discuss-phase.md +6 -10
- package/dist/prompts/commands/execute-phase.md +18 -45
- package/dist/prompts/commands/fix.md +16 -128
- package/dist/prompts/commands/grill.md +6 -53
- package/dist/prompts/commands/init-project.md +13 -18
- package/dist/prompts/commands/map-codebase.md +3 -3
- package/dist/prompts/commands/new-project.md +12 -17
- package/dist/prompts/commands/next-milestone.md +4 -8
- package/dist/prompts/commands/orchestrate-loop.md +12 -12
- package/dist/prompts/commands/orchestrate.md +12 -11
- package/dist/prompts/commands/pause-work.md +1 -1
- package/dist/prompts/commands/plan-phase.md +15 -37
- package/dist/prompts/commands/quick.md +11 -64
- package/dist/prompts/commands/resolve-conflicts.md +2 -15
- package/dist/prompts/commands/triage.md +3 -14
- package/dist/prompts/commands/verify-work.md +15 -63
- package/dist/prompts/commands/why.md +18 -118
- package/dist/skills/atomic-reasoning/SKILL.md +6 -105
- package/dist/skills/blast-radius/SKILL.md +1 -1
- package/dist/skills/epistemics/SKILL.md +12 -87
- package/dist/skills/explainers/SKILL.md +1 -1
- package/dist/skills/typescript-discipline/SKILL.md +12 -42
- package/dist/skills/typescript-discipline/references/patterns.md +25 -266
- package/dist/skills/unslop/SKILL.md +14 -105
- package/dist/utils/ansi.d.ts +8 -0
- package/dist/utils/ansi.d.ts.map +1 -1
- package/dist/utils/ansi.js +30 -11
- package/dist/utils/ansi.js.map +1 -1
- package/dist/utils/clipboard-command.d.ts.map +1 -1
- package/dist/utils/clipboard-command.js +3 -0
- package/dist/utils/clipboard-command.js.map +1 -1
- package/dist/utils/clipboard.d.ts.map +1 -1
- package/dist/utils/clipboard.js +18 -12
- package/dist/utils/clipboard.js.map +1 -1
- package/dist/utils/draht-user-agent.d.ts +1 -0
- package/dist/utils/draht-user-agent.d.ts.map +1 -1
- package/dist/utils/draht-user-agent.js +3 -2
- package/dist/utils/draht-user-agent.js.map +1 -1
- package/dist/utils/image-convert.d.ts +12 -0
- package/dist/utils/image-convert.d.ts.map +1 -1
- package/dist/utils/image-convert.js +45 -6
- package/dist/utils/image-convert.js.map +1 -1
- package/dist/utils/image-resize-core.d.ts +12 -0
- package/dist/utils/image-resize-core.d.ts.map +1 -1
- package/dist/utils/image-resize-core.js +5 -0
- package/dist/utils/image-resize-core.js.map +1 -1
- package/dist/utils/image-resize-worker.js +3 -2
- package/dist/utils/image-resize-worker.js.map +1 -1
- package/dist/utils/image-resize.d.ts.map +1 -1
- package/dist/utils/image-resize.js +9 -10
- package/dist/utils/image-resize.js.map +1 -1
- package/dist/utils/output-files.d.ts +15 -0
- package/dist/utils/output-files.d.ts.map +1 -0
- package/dist/utils/output-files.js +30 -0
- package/dist/utils/output-files.js.map +1 -0
- package/dist/utils/shell.d.ts.map +1 -1
- package/dist/utils/shell.js +43 -13
- package/dist/utils/shell.js.map +1 -1
- package/dist/utils/syntax-highlight.d.ts.map +1 -1
- package/dist/utils/syntax-highlight.js +6 -1
- package/dist/utils/syntax-highlight.js.map +1 -1
- package/dist/utils/tools-manager.d.ts.map +1 -1
- package/dist/utils/tools-manager.js +4 -3
- package/dist/utils/tools-manager.js.map +1 -1
- package/docs/cli-integration.md +1 -1
- package/docs/cli.md +30 -26
- package/docs/codemode.md +230 -0
- package/docs/compaction.md +5 -5
- package/docs/containerization.md +1 -1
- package/docs/custom-provider.md +53 -1
- package/docs/docs.json +17 -1
- package/docs/drahtbank.md +163 -0
- package/docs/environment-variables.md +5 -2
- package/docs/extensions.md +143 -13
- package/docs/index.md +1 -1
- package/docs/json.md +3 -3
- package/docs/keybindings.md +9 -5
- package/docs/llama-cpp.md +9 -2
- package/docs/mcp.md +59 -3
- package/docs/message-types.md +22 -4
- package/docs/models-configuration.md +187 -0
- package/docs/models.md +67 -4
- package/docs/nvidia-rtx-llama-cpp.md +96 -0
- package/docs/providers.md +70 -5
- package/docs/sdk.md +1 -1
- package/docs/settings.md +10 -8
- package/docs/terminal-setup.md +14 -0
- package/docs/themes.md +4 -2
- package/docs/tui.md +71 -1
- package/docs/usage.md +1 -1
- package/docs/windows.md +16 -2
- package/eval/drahtbank/adapters.d.mts +35 -0
- package/eval/drahtbank/adapters.mjs +192 -0
- package/eval/drahtbank/bank.d.mts +141 -0
- package/eval/drahtbank/bank.mjs +515 -0
- package/eval/drahtbank/cases-v2.d.mts +28 -0
- package/eval/drahtbank/cases-v2.mjs +164 -0
- package/eval/drahtbank/cases.d.mts +17 -0
- package/eval/drahtbank/cases.mjs +198 -0
- package/eval/drahtbank/cli.mjs +120 -0
- package/eval/drahtbank/grading-v2.d.mts +26 -0
- package/eval/drahtbank/grading-v2.mjs +227 -0
- package/eval/drahtbank/isolated-tools.ts +223 -0
- package/eval/drahtbank/isolation-worker.mjs +53 -0
- package/eval/drahtbank/isolation.d.mts +52 -0
- package/eval/drahtbank/isolation.mjs +345 -0
- package/eval/drahtbank/runtime-checks.d.mts +15 -0
- package/eval/drahtbank/runtime-checks.mjs +187 -0
- package/examples/extensions/dynamic-resources/dynamic.json +1 -1
- package/examples/extensions/minimal-mode.ts +4 -5
- package/examples/extensions/overlay-test.ts +2 -2
- package/examples/extensions/plan-mode/index.ts +6 -2
- package/examples/extensions/subagent/index.ts +4 -6
- package/hooks/checks/checks-runtime.cjs +215 -0
- package/hooks/checks/git-safety.cjs +198 -0
- package/hooks/checks/git-safety.d.cts +1 -0
- package/hooks/gsd/draht-post-task.js +78 -39
- package/hooks/gsd/draht-quality-gate.js +210 -122
- package/hooks/gsd/package.json +3 -0
- package/package.json +21 -16
- package/prompts/commands/atomic-commit.md +8 -6
- package/prompts/commands/brainstorm.md +5 -149
- package/prompts/commands/create-verification-skill.md +8 -48
- package/prompts/commands/discuss-phase.md +6 -10
- package/prompts/commands/execute-phase.md +18 -45
- package/prompts/commands/fix.md +16 -128
- package/prompts/commands/grill.md +6 -53
- package/prompts/commands/init-project.md +13 -18
- package/prompts/commands/map-codebase.md +3 -3
- package/prompts/commands/new-project.md +12 -17
- package/prompts/commands/next-milestone.md +4 -8
- package/prompts/commands/orchestrate-loop.md +12 -12
- package/prompts/commands/orchestrate.md +12 -11
- package/prompts/commands/pause-work.md +1 -1
- package/prompts/commands/plan-phase.md +15 -37
- package/prompts/commands/quick.md +11 -64
- package/prompts/commands/resolve-conflicts.md +2 -15
- package/prompts/commands/triage.md +3 -14
- package/prompts/commands/verify-work.md +15 -63
- package/prompts/commands/why.md +18 -118
- package/schemas/keybindings.schema.json +433 -0
- package/schemas/models.schema.json +1190 -0
- package/schemas/settings.schema.json +849 -0
- package/schemas/theme.schema.json +365 -0
- package/skills/atomic-reasoning/SKILL.md +6 -105
- package/skills/blast-radius/SKILL.md +1 -1
- package/skills/epistemics/SKILL.md +12 -87
- package/skills/explainers/SKILL.md +1 -1
- package/skills/typescript-discipline/SKILL.md +12 -42
- package/skills/typescript-discipline/references/patterns.md +25 -266
- package/skills/unslop/SKILL.md +14 -105
- package/dist/bundle/chunks/anthropic-messages-GAKYXF65.js +0 -6
- package/dist/bundle/chunks/azure-openai-responses-ZIXMK6JO.js +0 -2
- package/dist/bundle/chunks/chunk-2E5VODES.js +0 -2
- package/dist/bundle/chunks/chunk-2VAF4XJI.js +0 -146
- package/dist/bundle/chunks/chunk-4TVQYRQY.js +0 -2
- package/dist/bundle/chunks/chunk-7TYCZN4Z.js +0 -137
- package/dist/bundle/chunks/chunk-BXSHCX3G.js +0 -11
- package/dist/bundle/chunks/chunk-GVXA72ZA.js +0 -2
- package/dist/bundle/chunks/chunk-I5OKY6RH.js +0 -11
- package/dist/bundle/chunks/chunk-KU5HAKZL.js +0 -4
- package/dist/bundle/chunks/chunk-MO3SCGBN.js +0 -18
- package/dist/bundle/chunks/chunk-N2QZNJT6.js +0 -65
- package/dist/bundle/chunks/chunk-PGJAHC3R.js +0 -107
- package/dist/bundle/chunks/chunk-QVFELZW2.js +0 -312
- package/dist/bundle/chunks/chunk-RZKPFWMH.js +0 -42
- package/dist/bundle/chunks/chunk-SDRCE6OP.js +0 -2
- package/dist/bundle/chunks/chunk-SVNWI7EV.js +0 -8
- package/dist/bundle/chunks/chunk-TOWVIJ2O.js +0 -1623
- package/dist/bundle/chunks/chunk-XBUEMKIY.js +0 -2
- package/dist/bundle/chunks/chunk-ZA4QNPJY.js +0 -82
- package/dist/bundle/chunks/cloudflare-workers-ai-system-one-MJKOAE5S.js +0 -2
- package/dist/bundle/chunks/execute-6N7T7VLY.js +0 -18
- package/dist/bundle/chunks/google-generative-ai-RPUPQ6PM.js +0 -2
- package/dist/bundle/chunks/google-vertex-EZES5QVQ.js +0 -2
- package/dist/bundle/chunks/mistral-conversations-AOYGU43Y.js +0 -5
- package/dist/bundle/chunks/node-LQ52KV6B.js +0 -16
- package/dist/bundle/chunks/openai-codex-responses-M2Y77JEQ.js +0 -10
- package/dist/bundle/chunks/openai-completions-A4OKYOYV.js +0 -7
- package/dist/bundle/chunks/openai-responses-6IXV53T3.js +0 -3
- package/dist/bundle/chunks/openrouter-images-LYV4NKFM.js +0 -2
- package/dist/bundle/chunks/pi-messages-KKMEUT3Z.js +0 -8
- package/dist/bundle/chunks/runtime-363BOYEO.js +0 -3
- package/dist/bundle/chunks/runtime-D3KV73AE.js +0 -2
- package/dist/bundle/chunks/settings-manager-GEOZJXFQ.js +0 -2
- package/dist/bundle/chunks/typesafe-system-one-YBEEY5XU.js +0 -2
- package/dist/bundle/chunks/virtual-modules-RLC4Y5MX.js +0 -2
- package/dist/core/provider-attribution.d.ts +0 -4
- package/dist/core/provider-attribution.d.ts.map +0 -1
- package/dist/core/provider-attribution.js +0 -72
- package/dist/core/provider-attribution.js.map +0 -1
- package/dist/experimental/micro/api.d.ts +0 -81
- package/dist/experimental/micro/api.d.ts.map +0 -1
- package/dist/experimental/micro/api.js +0 -2
- package/dist/experimental/micro/api.js.map +0 -1
- package/dist/experimental/micro/main.d.ts +0 -3
- package/dist/experimental/micro/main.d.ts.map +0 -1
- package/dist/experimental/micro/main.js +0 -21
- package/dist/experimental/micro/main.js.map +0 -1
- package/dist/experimental/micro/models.d.ts +0 -11
- package/dist/experimental/micro/models.d.ts.map +0 -1
- package/dist/experimental/micro/models.js +0 -95
- package/dist/experimental/micro/models.js.map +0 -1
- package/dist/experimental/micro/runtime.d.ts +0 -12
- package/dist/experimental/micro/runtime.d.ts.map +0 -1
- package/dist/experimental/micro/runtime.js +0 -465
- package/dist/experimental/micro/runtime.js.map +0 -1
- package/dist/experimental/micro/sessions.d.ts +0 -10
- package/dist/experimental/micro/sessions.d.ts.map +0 -1
- package/dist/experimental/micro/sessions.js +0 -41
- package/dist/experimental/micro/sessions.js.map +0 -1
- package/dist/experimental/micro/tools.d.ts +0 -10
- package/dist/experimental/micro/tools.d.ts.map +0 -1
- package/dist/experimental/micro/tools.js +0 -96
- package/dist/experimental/micro/tools.js.map +0 -1
- package/dist/experimental/micro/tui.d.ts +0 -3
- package/dist/experimental/micro/tui.d.ts.map +0 -1
- package/dist/experimental/micro/tui.js +0 -510
- package/dist/experimental/micro/tui.js.map +0 -1
- package/dist/experimental/mini/main.d.ts +0 -7
- package/dist/experimental/mini/main.d.ts.map +0 -1
- package/dist/experimental/mini/main.js +0 -21
- package/dist/experimental/mini/main.js.map +0 -1
- package/dist/experimental/mini/server/entry.d.ts +0 -3
- package/dist/experimental/mini/server/entry.d.ts.map +0 -1
- package/dist/experimental/mini/server/entry.js +0 -11
- package/dist/experimental/mini/server/entry.js.map +0 -1
- package/dist/experimental/mini/server/run.d.ts +0 -13
- package/dist/experimental/mini/server/run.d.ts.map +0 -1
- package/dist/experimental/mini/server/run.js +0 -150
- package/dist/experimental/mini/server/run.js.map +0 -1
- package/dist/experimental/mini/shared/protocol.d.ts +0 -127
- package/dist/experimental/mini/shared/protocol.d.ts.map +0 -1
- package/dist/experimental/mini/shared/protocol.js +0 -13
- package/dist/experimental/mini/shared/protocol.js.map +0 -1
- package/dist/experimental/mini/shared/rpc.d.ts +0 -49
- package/dist/experimental/mini/shared/rpc.d.ts.map +0 -1
- package/dist/experimental/mini/shared/rpc.js +0 -171
- package/dist/experimental/mini/shared/rpc.js.map +0 -1
- package/dist/experimental/mini/shared/transport.d.ts +0 -35
- package/dist/experimental/mini/shared/transport.d.ts.map +0 -1
- package/dist/experimental/mini/shared/transport.js +0 -94
- package/dist/experimental/mini/shared/transport.js.map +0 -1
- package/dist/experimental/mini/tui/run.d.ts +0 -9
- package/dist/experimental/mini/tui/run.d.ts.map +0 -1
- package/dist/experimental/mini/tui/run.js +0 -62
- package/dist/experimental/mini/tui/run.js.map +0 -1
- package/dist/experimental/mini/tui/session.d.ts +0 -26
- package/dist/experimental/mini/tui/session.d.ts.map +0 -1
- package/dist/experimental/mini/tui/session.js +0 -94
- package/dist/experimental/mini/tui/session.js.map +0 -1
- package/dist/experimental/mini/tui/view.d.ts +0 -10
- package/dist/experimental/mini/tui/view.d.ts.map +0 -1
- package/dist/experimental/mini/tui/view.js +0 -461
- package/dist/experimental/mini/tui/view.js.map +0 -1
- package/dist/experimental/mini/worker/entry.d.ts +0 -3
- package/dist/experimental/mini/worker/entry.d.ts.map +0 -1
- package/dist/experimental/mini/worker/entry.js +0 -10
- package/dist/experimental/mini/worker/entry.js.map +0 -1
- package/dist/experimental/mini/worker/lane-service.d.ts +0 -44
- package/dist/experimental/mini/worker/lane-service.d.ts.map +0 -1
- package/dist/experimental/mini/worker/lane-service.js +0 -97
- package/dist/experimental/mini/worker/lane-service.js.map +0 -1
- package/dist/experimental/mini/worker/models-service.d.ts +0 -19
- package/dist/experimental/mini/worker/models-service.d.ts.map +0 -1
- package/dist/experimental/mini/worker/models-service.js +0 -136
- package/dist/experimental/mini/worker/models-service.js.map +0 -1
- package/dist/experimental/mini/worker/run.d.ts +0 -14
- package/dist/experimental/mini/worker/run.d.ts.map +0 -1
- package/dist/experimental/mini/worker/run.js +0 -88
- package/dist/experimental/mini/worker/run.js.map +0 -1
- package/dist/modes/interactive/theme/theme-json.d.ts +0 -85
- package/dist/modes/interactive/theme/theme-json.d.ts.map +0 -1
- package/dist/modes/interactive/theme/theme-json.js +0 -132
- package/dist/modes/interactive/theme/theme-json.js.map +0 -1
- package/dist/modes/interactive/theme/theme-schema.json +0 -361
|
@@ -1,76 +1,23 @@
|
|
|
1
1
|
---
|
|
2
|
-
description: "
|
|
2
|
+
description: "Complete an ad-hoc task directly with relevant verification and optional specialist help"
|
|
3
3
|
---
|
|
4
4
|
|
|
5
5
|
# /quick
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
## Usage
|
|
10
|
-
```
|
|
11
|
-
/quick [description]
|
|
12
|
-
```
|
|
13
|
-
|
|
7
|
+
Usage: `/quick [description]`
|
|
14
8
|
Task: $ARGUMENTS
|
|
15
9
|
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
Before planning, verify the task is actually quick: grep the blast radius (callers, imports, tests touching the target). If the change reaches further than the description implies, say so and recommend `/plan-phase`-level treatment instead of forcing it through. And if the description names a solution ("add a flag"), confirm the problem it solves — a smaller fix may exist. A "quick task" that silently grows is how untracked complexity enters a codebase.
|
|
19
|
-
|
|
20
|
-
## Atomic Reasoning
|
|
21
|
-
|
|
22
|
-
Decompose the work into independently verifiable units before acting; the `atomic-reasoning` skill holds the full discipline — load it when the decomposition is not obvious.
|
|
23
|
-
|
|
24
|
-
## Steps
|
|
25
|
-
1. Run `draht-tools next-quick-number` to get task number
|
|
26
|
-
2. Analyze the task and write a concrete plan with actual task details (files, actions, verification). Pipe it into `draht-tools create-quick-plan`:
|
|
27
|
-
```
|
|
28
|
-
echo 'plan content here' | draht-tools create-quick-plan NNN "$ARGUMENTS"
|
|
29
|
-
```
|
|
30
|
-
The plan content must include: a `# Quick Task NNN: title` heading, a `## Tasks` section with one or more `<task>` XML blocks containing real file paths, real actions, and real verification steps — NOT placeholders like `[files]`.
|
|
31
|
-
|
|
32
|
-
3. **Stage 1 — Implementer.** Use the `subagent` tool in **single mode** with the `implementer` agent:
|
|
33
|
-
```
|
|
34
|
-
Execute this task: $ARGUMENTS
|
|
35
|
-
|
|
36
|
-
Follow the TDD cycle:
|
|
37
|
-
- RED — Write a failing test that describes the desired behaviour
|
|
38
|
-
- GREEN — Write the minimum implementation to make it pass
|
|
39
|
-
- REFACTOR — Clean up while keeping the test green
|
|
40
|
-
Exception: skip the TDD cycle only for pure config or documentation-only tasks that have no testable behaviour.
|
|
41
|
-
|
|
42
|
-
Comment discipline: comments exist ONLY for constraints the code cannot express — a protocol quirk, a deliberate deviation, a non-obvious invariant. If code needs comments to be understood, rewrite the code until it doesn't. Never narrate steps, restate the diff, or leave "removed X" / "this handles Y" breadcrumbs. Comment density above the surrounding file's norm is a defect — fix it before committing. A heavily-commented solution signals the design is wrong: redesign, don't annotate.
|
|
43
|
-
|
|
44
|
-
After completion, report: files changed, tests written, and verification results.
|
|
45
|
-
|
|
46
|
-
End your response with `STATUS: DONE | DONE_WITH_CONCERNS | NEEDS_CONTEXT | BLOCKED` per the agent contract.
|
|
47
|
-
|
|
48
|
-
Do NOT run draht, draht-tools, draht help, or pi commands — use only standard tools.
|
|
49
|
-
```
|
|
50
|
-
|
|
51
|
-
Read the final `STATUS:` line:
|
|
52
|
-
- `DONE` → go to Stage 2 (or skip Stage 2 for pure-config / pure-docs).
|
|
53
|
-
- `DONE_WITH_CONCERNS` → log; if correctness, re-dispatch; otherwise continue.
|
|
54
|
-
- `NEEDS_CONTEXT` → provide missing info and re-dispatch.
|
|
55
|
-
- `BLOCKED` → STOP, report.
|
|
10
|
+
Complete the requested task directly, using an approach proportionate to its scope. Follow repository and user instructions. Ordinary work needs no numbered plan, XML, `.planning/` state, phase command, or session reset.
|
|
56
11
|
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
12
|
+
1. Inspect the relevant code, callers, and tests; identify the observable result the user needs.
|
|
13
|
+
2. Make the smallest complete change and preserve unrelated behavior. For behavior changes, add or update focused tests. Reproduce a bug before fixing it and demonstrate that the regression test detects it; skip tests for pure documentation or configuration changes with no testable behavior.
|
|
14
|
+
3. Run the relevant project checks and any tests you created or changed, following repository command restrictions. A failed command, timeout, or unavailable required check is not a pass; do not weaken checks to obtain one.
|
|
15
|
+
4. Report the result, changed files, and observed verification with decisive output. State what remains unverified. Do not commit unless requested.
|
|
60
16
|
|
|
61
|
-
|
|
62
|
-
```
|
|
63
|
-
- `DONE` → go to Stage 3.
|
|
64
|
-
- `BLOCKED` → re-dispatch implementer with Required Fixes. Repeat until `DONE`. **Hard cap: 3 re-dispatches total** — at the cap, STOP and report the disagreement to the user.
|
|
17
|
+
## Optional delegation
|
|
65
18
|
|
|
66
|
-
|
|
67
|
-
- `DONE` → task complete.
|
|
68
|
-
- `BLOCKED` → re-dispatch implementer with Must-fix list — same **hard cap of 3 re-dispatches**; at the cap, STOP and report.
|
|
19
|
+
Delegate when independent investigation, implementation, or fresh review materially helps. Give each agent the task, relevant context, scope, and expected evidence. Use the `implementer` agent for changes, the `spec-reviewer` agent for an explicit spec, and the `reviewer` agent for code quality; when both reviews are needed, check spec compliance first.
|
|
69
20
|
|
|
70
|
-
|
|
71
|
-
7. Update state: `draht-tools update-state`
|
|
21
|
+
Require delegated reports to end with one `STATUS: DONE | DONE_WITH_CONCERNS | NEEDS_CONTEXT | BLOCKED`. Check evidence before accepting `DONE`; resolve correctness concerns before completion. Supply missing context for `NEEDS_CONTEXT`. An implementer blocker stops the task; a review blocker returns its required fixes for implementation and re-review. Allow at most **3 implementer re-dispatches total across review stages**, then report unresolved findings. Never claim completion while required checks or review findings remain unresolved.
|
|
72
22
|
|
|
73
|
-
|
|
74
|
-
- Pure config (tsconfig, biome, formatter)
|
|
75
|
-
- Docs-only edits
|
|
76
|
-
- Single-line obvious changes (typo, version bump)
|
|
23
|
+
Use the `subagent` tool for optional delegation. Subagents use standard tools only; the orchestrator runs any `draht`, `draht-tools`, `draht help`, or `pi` commands.
|
|
@@ -19,11 +19,7 @@ Context: $ARGUMENTS
|
|
|
19
19
|
- `git status` reports unmerged paths — a merge, rebase, or cherry-pick is mid-flight.
|
|
20
20
|
- The `subagent` tool reported a failed worktree merge-back (its failure notice points here): the agent's work sits on an unmerged `agent/<taskId>` branch. Run `git merge agent/<taskId>` first to enter the conflict, then continue here.
|
|
21
21
|
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
> **EVERY HUNK RESOLUTION MUST BE JUSTIFIED BY THE RECOVERED INTENT OF BOTH SIDES. NO INTENT, NO RESOLUTION.**
|
|
25
|
-
|
|
26
|
-
A conflict is two changes with a reason each. Until you can state both reasons, you are not resolving — you are guessing.
|
|
22
|
+
Resolve conflicts from both sides' intended behavior and the operation's goal. Preserve compatible changes; clarify an unresolved semantic conflict instead of choosing a side blindly.
|
|
27
23
|
|
|
28
24
|
## Phase 1 — Map the Conflict
|
|
29
25
|
|
|
@@ -53,19 +49,10 @@ Exit criterion: a one-sentence intent statement per side, per conflicted area. I
|
|
|
53
49
|
|
|
54
50
|
## Phase 4 — Run the Project's Checks
|
|
55
51
|
|
|
56
|
-
Discover the project's own gates — package scripts, Makefile, CI config — and run
|
|
52
|
+
Discover the project's own gates — package scripts, Makefile, CI config — and run the required checks for the merged state, respecting repository command restrictions. Fix what the merge broke, under the same rule: no invented behaviour.
|
|
57
53
|
|
|
58
54
|
## Phase 5 — Finish the Operation
|
|
59
55
|
|
|
60
56
|
- Merge: stage the resolved files and commit. The merge commit message names each recorded trade-off — which intent won where, and why.
|
|
61
57
|
- Rebase or cherry-pick: `git rebase --continue` / `git cherry-pick --continue` until every commit is replayed.
|
|
62
58
|
- Never `--no-verify`.
|
|
63
|
-
|
|
64
|
-
## Red Flags — STOP
|
|
65
|
-
|
|
66
|
-
Stop immediately if you catch yourself:
|
|
67
|
-
- Resolving a hunk whose "why" you cannot state for both sides
|
|
68
|
-
- Taking one side wholesale because it is newer, bigger, or yours
|
|
69
|
-
- Introducing behaviour that exists on neither side
|
|
70
|
-
- Finishing with failing checks, or reaching for `--no-verify`
|
|
71
|
-
- Running `--abort` without explicit user sign-off
|
|
@@ -59,11 +59,11 @@ Bounded pass — report on each step:
|
|
|
59
59
|
2. Check whether the visible symptom belongs to that code path or to a dependency below it.
|
|
60
60
|
3. If the report looks like a regression: `git log --oneline -20` and recent diffs on the affected files — name candidate commits.
|
|
61
61
|
4. Check whether a merged commit or open PR already addresses the same symptom.
|
|
62
|
-
5. Separate confirmed facts from hypotheses — label
|
|
62
|
+
5. Separate confirmed facts from hypotheses — label the confidence of material findings as observed, derived, or assumed.
|
|
63
63
|
|
|
64
|
-
Stop at diagnosis strength sufficient for routing — a complete root cause is /fix's job, not yours. Do not build a reproduction unless one command is already obvious from the report itself.
|
|
64
|
+
Stop at diagnosis strength sufficient for routing — a complete root cause is /fix's job, not yours. Do not build a reproduction unless one command is already obvious from the report itself; labeled hypotheses without a reproduction are a complete answer for this pass.
|
|
65
65
|
|
|
66
|
-
End with STATUS: DONE | DONE_WITH_CONCERNS | NEEDS_CONTEXT | BLOCKED
|
|
66
|
+
End with STATUS: DONE | DONE_WITH_CONCERNS | NEEDS_CONTEXT | BLOCKED. DONE means the routing-strength diagnosis is done — no fix is expected.
|
|
67
67
|
```
|
|
68
68
|
|
|
69
69
|
The pass does not need a complete root cause — it must be strong enough to avoid routing a visible symptom to the wrong component. A keyword match between the report and a module name is not a trace; a visible symptom alone is not enough when cause tracing points to a dependency below it. When the report smells like a regression and design intent matters ("was this behaviour a decision or an accident?"), a bounded `/why` consult can supplement the trace — not a full archaeology run.
|
|
@@ -146,14 +146,3 @@ End the report with exactly one marker line, the last line of the response:
|
|
|
146
146
|
```
|
|
147
147
|
|
|
148
148
|
`bug` and `performance` carry `tracker=` only when this run matched or created a live issue. Everything else — feature request, question, feedback, reroute, unclear — closes with `[triage:other]`. Never emit two markers; never bury the marker mid-report. A follow-up `/fix` run takes the marker plus its tracker link as the issue input.
|
|
149
|
-
|
|
150
|
-
## Rationalization Table
|
|
151
|
-
|
|
152
|
-
| Excuse | Reality |
|
|
153
|
-
|---|---|
|
|
154
|
-
| "The report names the component, route it there" | A keyword match is not a trace. Route on a confirmed code path or signature, or say the owner is unclear. |
|
|
155
|
-
| "Probably a duplicate of #123" | Probably means possibly related: link it as uncertain and create nothing. |
|
|
156
|
-
| "Filing a ticket is harmless" | A guessed or duplicate ticket costs a maintainer two triages. Prefer no ticket. |
|
|
157
|
-
| "The old closed issue matches, done" | A long-closed issue is a regression lead — trace what re-broke it. |
|
|
158
|
-
| "No repo access, but the cause is obvious" | Reading a report yields hypotheses. Classify conservatively and say the trace was unavailable. |
|
|
159
|
-
| "I'll fix it while I'm here" | Triage ends at the verdict. Hand `[triage:bug]` to `/fix`. |
|
|
@@ -4,69 +4,21 @@ description: "Acceptance testing of completed phase work (parallel verifier + se
|
|
|
4
4
|
|
|
5
5
|
# /verify-work
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
## Usage
|
|
10
|
-
```
|
|
11
|
-
/verify-work [N]
|
|
12
|
-
```
|
|
7
|
+
Verify the selected GSD phase against its acceptance criteria.
|
|
13
8
|
|
|
14
9
|
Phase: $1
|
|
15
10
|
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
4. **Spot-check before aggregating.** Subagent claims are inputs, not verdicts. Before accepting the verifier's `DONE`, re-run the test suite headline yourself and read the counts. Before accepting the spec-reviewer's compliance verdict, read one plan's diff yourself. A pass you only heard about is an "assumed pass" — and an assumed pass is not a pass. This costs two commands and catches the most expensive failure mode this command has: trust laundered into evidence.
|
|
31
|
-
|
|
32
|
-
5. **Read each subagent's `STATUS:` line.** Treat the phase as failed if any of these is `BLOCKED`:
|
|
33
|
-
- `verifier` (tests / lint / typecheck failed)
|
|
34
|
-
- `security-auditor` (Critical or High findings)
|
|
35
|
-
- `spec-reviewer` (any plan non-compliant)
|
|
36
|
-
- `reviewer` (Must-fix correctness issues)
|
|
37
|
-
|
|
38
|
-
6. Collect results and walk user through each deliverable, incorporating findings.
|
|
39
|
-
7. Record results (pass/fail/partially/skip). Label each: **observed** (you or a subagent ran it and quoted output), **derived** (follows necessarily from something observed), or **assumed** (unchecked). Verdicts inherit the weakest label they rest on.
|
|
40
|
-
8. For failures: diagnose and create fix plans via `draht-tools create-fix-plan $1 P`
|
|
41
|
-
- Fix plans MUST include a reproducing test that demonstrates the failure before any implementation — held to the /fix Phase 1 red-capable standard: one named command, already run once, invocation and output shown, asserting the exact failing symptom (red now, green once fixed)
|
|
42
|
-
- Spec-reviewer omissions become explicit fix-plan tasks (one task per omission)
|
|
43
|
-
9. Write UAT report: `draht-tools write-uat $1`
|
|
44
|
-
- Order: **verdict first** (phase pass/fail, X/Y deliverables, in the first line), **evidence second** (test health summary with pass/fail/coverage, security audit results, spec compliance summary per plan, domain model status, deliverable results with labels), **risk last** (what was NOT tested and how it could bite). Never bury a failure under passes.
|
|
45
|
-
- Report prose follows the `unslop` skill — plain words, active voice, no filler; quoted command output and the verdict-first ordering stay untouched.
|
|
46
|
-
- When the user asks, also write an HTML explainer of the UAT report per the `explainers` skill, with the deliverable results and their observed/derived/assumed labels as its data block. The UAT report stays the source of truth.
|
|
47
|
-
10. If all passed: mark phase complete.
|
|
48
|
-
- If more phases remain in the milestone: tell the user to start a new session and run `/discuss-phase N+1`.
|
|
49
|
-
- If ALL phases in the milestone are complete: tell the user to start a new session and run `/next-milestone`.
|
|
50
|
-
11. If failures: route to `execute-phase $1 --gaps-only`
|
|
51
|
-
|
|
52
|
-
## Why a phase-level spec-reviewer
|
|
53
|
-
|
|
54
|
-
`/execute-phase` already runs spec-reviewer **per task** before the next task starts. The phase-level pass here catches things the per-task loop can miss:
|
|
55
|
-
- A whole plan was skipped (no implementer ever ran on it)
|
|
56
|
-
- A task's commit was reverted or rebased away
|
|
57
|
-
- Out-of-scope drift that accumulated across multiple tasks
|
|
58
|
-
|
|
59
|
-
Cheap insurance — the diff and plans already exist; the agent maps one to the other.
|
|
60
|
-
|
|
61
|
-
## Workflow
|
|
62
|
-
This is the last step in the per-phase cycle. Each step runs in its own session (`/new` between steps):
|
|
63
|
-
|
|
64
|
-
```
|
|
65
|
-
/discuss-phase N → /new → /plan-phase N → /new → /execute-phase N → /new → /verify-work N
|
|
66
|
-
```
|
|
67
|
-
|
|
68
|
-
After verify-work passes:
|
|
69
|
-
- More phases remaining → `/new` → `/discuss-phase N+1`
|
|
70
|
-
- ALL phases in milestone verified → `/new` → `/next-milestone`
|
|
71
|
-
|
|
72
|
-
`/next-milestone` is ONLY for generating new phases after every phase in the current milestone is complete.
|
|
11
|
+
1. Run `draht-tools extract-deliverables $1` and read the phase's plans. Identify the exact commit range and any uncommitted work being verified; retain the baseline and relevant configuration.
|
|
12
|
+
2. Collect verification evidence and focused reviews. Parallelize independent roles where useful:
|
|
13
|
+
- Dispatch `verifier` with the deliverables, changed scope, required commands, and any existing check records. It must inspect actual command outcomes and run missing, stale, or insufficient checks. Use a relevant project `verify-<app>` skill for user-visible behavior when available; preserve its artifacts and cleanup rules. Without such a skill, other direct behavior checks remain possible.
|
|
14
|
+
- Dispatch `security-auditor` with the phase diff and relevant deployment/threat context. Request confirmed findings and actionable suspected risks with severity and evidence.
|
|
15
|
+
- Dispatch `reviewer` with the phase diff and established project conventions. Existing domain documentation and graph impact can inform the review; an unknown glossary word or cross-directory import alone is not a defect.
|
|
16
|
+
- Dispatch `spec-reviewer` with the plan paths, phase diff, and acceptance criteria. Request per-plan compliance, omissions, and over-builds, including work lost or reverted since task reviews.
|
|
17
|
+
|
|
18
|
+
Require every role to finish with `STATUS: DONE | DONE_WITH_CONCERNS | NEEDS_CONTEXT | BLOCKED`. Supply missing available context; stop a blocked required review rather than treating it as a pass. At most 3 re-dispatches for missing context or correction; preserve the execution workflow's combined repair cap.
|
|
19
|
+
3. Inspect the evidence and load-bearing review findings. Reuse a check only when its source, tests, configuration, dependencies, and execution environment are unchanged and its scope covers the claim. A status line alone is not evidence. Rerun missing, stale, or unverifiable checks; do not repeat a suite merely because an agent ran it.
|
|
20
|
+
4. Honor the project's required deterministic quality checks. A failed process, signal, timeout, required unavailable check, non-compliant plan, Must-fix review issue, or confirmed Critical/High security issue prevents a passing phase verdict. Review remaining concerns explicitly.
|
|
21
|
+
5. Record each deliverable as pass/fail/partial/skip with evidence. Preserve the labels **observed** (executed behavior with output), **derived** (conclusion supported by observations), and **assumed** (unchecked). Ask for human verification only where automation and available evidence cannot resolve the acceptance criterion.
|
|
22
|
+
6. For failures, use `draht-tools create-fix-plan $1 P`. Include a reproduction with observed output where feasible, or the exact missing evidence/access needed to construct one. Group corrections by coherent behavior; no implementation starts on an invented diagnosis.
|
|
23
|
+
7. Write the UAT report with `draht-tools write-uat $1`: **verdict first**, **evidence second**, **risk last**. Include deliverable outcomes, commands/checked state, review findings, and material gaps. Follow `unslop` for prose and `explainers` when a diagram or requested HTML report helps.
|
|
24
|
+
8. Mark the phase complete only when acceptance and required checks pass. Otherwise route to `/execute-phase $1 --gaps-only`. More phases lead to `/discuss-phase N+1`; `/next-milestone` is only for when all phases are verified. A fresh session is optional.
|
package/prompts/commands/why.md
CHANGED
|
@@ -4,136 +4,36 @@ description: "Investigate why code is the way it is — parallel evidence invest
|
|
|
4
4
|
|
|
5
5
|
# /why
|
|
6
6
|
|
|
7
|
-
Reconstruct why code is the way it is — the design rationale, the history, the rejected alternatives — from the evidence the repository and its surroundings actually carry. The output is a confidence-tiered, citation-backed answer with an explicit coverage map, never a plausible story.
|
|
8
|
-
|
|
9
|
-
## Usage
|
|
10
|
-
```
|
|
11
|
-
/why <file, symbol, or question>
|
|
12
|
-
```
|
|
13
|
-
|
|
14
7
|
Question: $ARGUMENTS
|
|
15
8
|
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
## Routing
|
|
19
|
-
|
|
20
|
-
`/why` answers intent, history, and forces. Something misbehaving right now is a defect — route it to `/fix`, which is reproduction-gated. A `/why` run that uncovers a live defect hands off to `/fix`; a `/fix` that needs design intent (is this behaviour a decision or an accident?) consults `/why`. For structure and architecture walkthroughs — what the code IS rather than why it is that way — use `/map-codebase`.
|
|
21
|
-
|
|
22
|
-
## Epistemics
|
|
23
|
-
|
|
24
|
-
Every claim in the output follows the `epistemics` skill — five confidence tiers, cite-or-label-as-inference, null results as evidence. Load it before synthesising; the epistemic framing is the product, and de-hedging it to sound authoritative is the exact failure this command exists to prevent.
|
|
25
|
-
|
|
26
|
-
## Steps
|
|
27
|
-
|
|
28
|
-
### 1 — Parse the target and the question archetype
|
|
29
|
-
|
|
30
|
-
Identify what is being asked about (file, symbol, pattern, value) and which archetype the question is: design rationale ("why is this a queue?"), tradeoff-vs-alternative ("why X instead of Y?"), defensive reasoning ("why the triple-check here?"), external forcing function ("why did this change in March?"), dead code ("why does this exist at all?"), or a broad sweep ("why is this module shaped like this?"). If the target is vague, state your best-guess interpretation from context and proceed — do not block on a clarifying question.
|
|
31
|
-
|
|
32
|
-
### 2 — Build the code anchor
|
|
33
|
-
|
|
34
|
-
Cheap, done once by the lead, pasted into every brief:
|
|
35
|
-
|
|
36
|
-
- file paths and line ranges; the key symbols involved
|
|
37
|
-
- `git blame -L <range> <file>` on the target lines
|
|
38
|
-
- `git log --follow --oneline -20 <file>`
|
|
39
|
-
- PR numbers extracted from `(#N)` commit subjects; for each, `gh pr view <n> --json title,body,author,createdAt,mergedAt,labels,closingIssuesReferences,comments,reviews`
|
|
40
|
-
- linked ticket and ADR identifiers found along the way
|
|
41
|
-
- optionally a pasted `draht-tools graph-context <file>` slice for orientation (lead-only; subagents cannot run draht-tools)
|
|
42
|
-
|
|
43
|
-
### 3 — Probe the evidence map
|
|
44
|
-
|
|
45
|
-
Five categories. Probe availability before dispatching; each row is the assigned investigator's playbook.
|
|
46
|
-
|
|
47
|
-
| Category | Availability probe | What it uniquely surfaces + playbook |
|
|
48
|
-
|---|---|---|
|
|
49
|
-
| Git history | Always available | Pickaxe (`git log -S`/`-G`), blame, `git show`; test names encoding edge cases; `red:`/`green:`/`refactor:` and `docs:` prefixes as semantic signal. Pitfalls: squash flatlands → fall back to the PR record; misleading messages → read the diff; cargo-culted patterns → investigate the origin commit; bot commits carry no motivation. |
|
|
50
|
-
| Review record | `git remote` + `gh auth status` | PR bodies, review threads, linked issues — the argument that happened before merge, including rejected alternatives. |
|
|
51
|
-
| Planning record | `.planning/` exists | `STATE.md` `## Decisions` (dated, attributed) and `## Lessons`; `phases/NN-*/` PLAN, SUMMARY, VERIFICATION, and UAT files (observed/derived/assumed labels); `specs/`; `quick/`; `loop/PROGRESS.md`; `CONTINUE-HERE.md`. Probe before assuming `.planning/decisions/` and `.planning/tickets/` — they exist only when a grill chose that output. |
|
|
52
|
-
| Decision records | `docs/adr/` and `CHANGELOG.md` files exist | ADR titles are decisions; dated Update blocks cite forcing commits; per-package changelogs date user-visible shifts. |
|
|
53
|
-
| External systems | A registered extension tool only | Tracker, chat, observability, error tracking, analytics — the conversational and operational record. Searchable only via a project-registered tool; when none exists, do not dispatch: record one Sources Consulted gap line — "External records: unavailable — no tool registered in this runtime; the conversational and operational record was not searched." |
|
|
54
|
-
|
|
55
|
-
The map is extensible: a project-registered tool adds an investigator with the same brief shape; an unavailable category is a coverage gap, never a silent drop.
|
|
56
|
-
|
|
57
|
-
**Incident overlay**: when the target looks defensive — null guards, retry, timeout, rate limiting, feature flags — instruct every investigator to hunt incident-shaped evidence inside its own category: revert-then-reapply chains, `## Lessons` entries, ADR Update blocks, UAT failure verdicts.
|
|
58
|
-
|
|
59
|
-
### 4 — Dispatch parallel investigators
|
|
60
|
-
|
|
61
|
-
Dispatch one `investigator` agent per AVAILABLE category in one parallel-mode call; follow the subagent tool limits (max 8 tasks, 4 concurrent) — if the category count ever exceeds them, fold overflow into the nearest category. Skip rules:
|
|
62
|
-
|
|
63
|
-
- A skip needs a written justification that surfaces in Sources Consulted. Unavailability is a gap, not a choice.
|
|
64
|
-
- "Provably irrelevant, not just probably" — a build-time script with no runtime path provably cannot appear in runtime error tracking; "it's feature code, error tracking won't have anything" is a guess, so search it.
|
|
65
|
-
|
|
66
|
-
Each brief is standalone:
|
|
67
|
-
|
|
68
|
-
```
|
|
69
|
-
You are investigating ONE evidence category for a why-question. Gather evidence, not narrative — a verbatim quote with a precise citation beats a paragraph of plausible summary.
|
|
70
|
-
|
|
71
|
-
Question: <the question and its archetype>
|
|
72
|
-
|
|
73
|
-
Code anchor:
|
|
74
|
-
<the anchor from Step 2>
|
|
75
|
-
|
|
76
|
-
Your category: <name + the playbook row from Step 3>
|
|
77
|
-
<if the incident overlay applies: hunt incident-shaped evidence inside your category — revert/re-apply chains, Lessons entries, ADR Update blocks, UAT failure verdicts>
|
|
78
|
-
|
|
79
|
-
Report using exactly these sections: Source / What I Searched (queries verbatim) / Direct Evidence Found / Indirect-Circumstantial Evidence (inference chain + alternative readings) / Contradictions / Gaps / Additional Leads.
|
|
80
|
-
|
|
81
|
-
Stay inside your category; record cross-category references under Additional Leads for the owning investigator — never chase them.
|
|
82
|
-
|
|
83
|
-
Do NOT run draht, draht-tools, or pi commands.
|
|
84
|
-
|
|
85
|
-
End with STATUS: DONE | DONE_WITH_CONCERNS | NEEDS_CONTEXT | BLOCKED
|
|
86
|
-
```
|
|
87
|
-
|
|
88
|
-
`NEEDS_CONTEXT` / `BLOCKED` → supply the missing info and re-dispatch. Hard cap: 3 re-dispatches total.
|
|
89
|
-
|
|
90
|
-
### 5 — Synthesize (the lead, in this context)
|
|
9
|
+
Explain historical intent from evidence. Use `epistemics` to distinguish direct statements, supported conclusions, inference, speculation, and unknowns. Current defects belong in `/fix`; a structural walkthrough may use `/map-codebase`.
|
|
91
10
|
|
|
92
|
-
|
|
93
|
-
- Merge duplicate citations into one authoritative reference.
|
|
94
|
-
- Surface contradictions without picking a side.
|
|
95
|
-
- Tier every claim per the `epistemics` skill.
|
|
96
|
-
- Hand each investigator's Additional Leads to the owning category's follow-up, or record them as gaps.
|
|
97
|
-
- When competing hypotheses are decision-changing for an imminent code change, consult the `advisor` agent with the tiered findings for a steer.
|
|
11
|
+
## Investigate
|
|
98
12
|
|
|
99
|
-
|
|
13
|
+
Identify the target files/symbols and the specific decision being asked about. Read the relevant source, blame, and history; use `git log --follow`, pickaxe, and linked PR/issue discussions to trace the decision. Source mechanics alone do not establish motivation.
|
|
100
14
|
|
|
101
|
-
|
|
15
|
+
Select evidence sources that can answer the question:
|
|
102
16
|
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
6. **What We Don't Know** — specific searches that came up empty, named unavailable sources, people who would know
|
|
109
|
-
7. **Sources Consulted** — one line per category INCLUDING empties, gaps, and justified skips: `- <Category>: <what was searched>. <found / no relevant results / skipped: reason / unavailable: gap>`
|
|
110
|
-
8. **Confidence Summary** — 1-2 sentences
|
|
17
|
+
- Git history and changed tests: origin, later changes, reversions, and constraints.
|
|
18
|
+
- PR/review record: rejected alternatives and discussion before merge.
|
|
19
|
+
- Existing planning records: decisions, lessons, summaries, verification, and handoffs.
|
|
20
|
+
- ADRs and changelogs: recorded rationale and later revisions.
|
|
21
|
+
- Available external tools: relevant tracker, conversation, or operational evidence. Do not invent access or contact people.
|
|
111
22
|
|
|
112
|
-
|
|
23
|
+
Follow decisive leads, including incident evidence for defensive code. A direct answer in a relevant record may be sufficient; do not require an investigator for every category. Report unavailable sources when they materially limit the answer.
|
|
113
24
|
|
|
114
|
-
|
|
25
|
+
## Delegate when useful
|
|
115
26
|
|
|
116
|
-
|
|
27
|
+
Use `investigator` agents for independent evidence searches. Give each only the question, code anchor, assigned sources, relevant leads, and read-only scope. Shared investigator instructions already define citations and reporting; avoid copying the entire protocol into every task.
|
|
117
28
|
|
|
118
|
-
|
|
29
|
+
Require `STATUS: DONE | DONE_WITH_CONCERNS | NEEDS_CONTEXT | BLOCKED`. Supply available missing context for `NEEDS_CONTEXT`; an unavailable required tool is a blocker, not a reason to retry unchanged. At most 3 re-dispatches total.
|
|
119
30
|
|
|
120
|
-
|
|
31
|
+
The lead checks load-bearing citations, merges duplicate evidence, and resolves cross-source leads. Consult the `advisor` agent when a contested inference would change an imminent implementation decision.
|
|
121
32
|
|
|
122
|
-
|
|
33
|
+
## Report
|
|
123
34
|
|
|
124
|
-
|
|
125
|
-
- Citing code as evidence of its own intent
|
|
126
|
-
- Recency bias — explaining an accretion as one decision; trace back
|
|
127
|
-
- Sycophantic agreement with the asker's embedded hypothesis
|
|
128
|
-
- Skipping the gaps section
|
|
129
|
-
- Skipping investigators by anticipation — a null result is a data point; a skipped search is a blind spot
|
|
130
|
-
- Collapsing categories into one investigator
|
|
35
|
+
Lead with the answer and its confidence. Separate what sources establish from what is inferred; cite each material claim and preserve contradictions. Include unresolved hypotheses only when they help answer the question.
|
|
131
36
|
|
|
132
|
-
|
|
37
|
+
End with a concise **Sources Consulted** account of the searches, relevant null results, and material coverage gaps. Do not require empty headings or searches unrelated to the question. Follow `unslop` for prose and `explainers` when a timeline, dependency, or causal diagram helps.
|
|
133
38
|
|
|
134
|
-
|
|
135
|
-
|--------|---------|
|
|
136
|
-
| "The commit message says X, done" | One source is a lead, not a verdict — the record contradicts itself more often than it lies consistently. |
|
|
137
|
-
| "The code obviously does this for performance" | Code is mechanics; motivation needs an external source or an [Inferred] label. |
|
|
138
|
-
| "The user already told me why" | That is a hypothesis; check it independently. |
|
|
139
|
-
| "No .planning/ here, nothing to search" | git and gh still exist; report the missing categories as gaps, don't invent. |
|
|
39
|
+
When this investigation precedes a change, state the resulting Preserve / Change / Avoid / Risk constraints. These can guide ordinary implementation or an explicitly selected GSD plan.
|