@vpxa/kb 0.1.23 → 0.1.25
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/README.md +3 -3
- package/package.json +9 -2
- package/packages/analyzers/dist/symbol-analyzer.js +5 -5
- package/packages/cli/dist/commands/init/adapters.js +1 -1
- package/packages/cli/dist/commands/init/constants.d.ts +4 -1
- package/packages/cli/dist/commands/init/constants.js +1 -1
- package/packages/cli/dist/commands/init/frontmatter.d.ts +54 -0
- package/packages/cli/dist/commands/init/frontmatter.js +2 -0
- package/packages/cli/dist/commands/init/index.js +4 -4
- package/packages/cli/dist/commands/init/manifest.d.ts +71 -0
- package/packages/cli/dist/commands/init/manifest.js +1 -0
- package/packages/cli/dist/commands/init/scaffold.d.ts +28 -5
- package/packages/cli/dist/commands/init/scaffold.js +1 -1
- package/packages/cli/dist/commands/init/templates.js +38 -9
- package/packages/cli/dist/commands/init/user.d.ts +1 -1
- package/packages/cli/dist/commands/init/user.js +4 -4
- package/packages/cli/dist/commands/system.js +2 -2
- package/packages/cli/dist/kb-init.js +1 -1
- package/packages/core/dist/errors.d.ts +2 -2
- package/packages/core/dist/errors.js +1 -1
- package/packages/core/dist/logger.d.ts +2 -1
- package/packages/core/dist/logger.js +1 -1
- package/packages/core/dist/types.d.ts +6 -0
- package/packages/dashboard/dist/assets/index-9ysCkze9.js +21 -0
- package/packages/dashboard/dist/assets/index-9ysCkze9.js.map +1 -0
- package/packages/dashboard/dist/assets/index-CHpVij2M.css +1 -0
- package/packages/dashboard/dist/index.html +18 -0
- package/packages/elicitation/dist/__tests__/build.test.d.ts +1 -0
- package/packages/elicitation/dist/__tests__/build.test.js +35 -0
- package/packages/elicitation/dist/__tests__/fields.test.d.ts +1 -0
- package/packages/elicitation/dist/__tests__/fields.test.js +81 -0
- package/packages/elicitation/dist/__tests__/normalize.test.d.ts +1 -0
- package/packages/elicitation/dist/__tests__/normalize.test.js +60 -0
- package/packages/elicitation/dist/build.d.ts +13 -0
- package/packages/elicitation/dist/build.js +23 -0
- package/packages/elicitation/dist/fields.d.ts +41 -0
- package/packages/elicitation/dist/fields.js +62 -0
- package/packages/elicitation/dist/index.d.ts +10 -0
- package/packages/elicitation/dist/index.js +12 -0
- package/packages/elicitation/dist/normalize.d.ts +15 -0
- package/packages/elicitation/dist/normalize.js +31 -0
- package/packages/elicitation/dist/types.d.ts +85 -0
- package/packages/elicitation/dist/types.js +8 -0
- package/packages/kb-client/dist/direct-client.d.ts +37 -0
- package/packages/kb-client/dist/direct-client.js +1 -0
- package/packages/kb-client/dist/index.d.ts +5 -0
- package/packages/kb-client/dist/index.js +1 -0
- package/packages/kb-client/dist/mcp-client.d.ts +19 -0
- package/packages/kb-client/dist/mcp-client.js +4 -0
- package/packages/kb-client/dist/parsers.d.ts +35 -0
- package/packages/kb-client/dist/parsers.js +2 -0
- package/packages/kb-client/dist/types.d.ts +62 -0
- package/packages/kb-client/dist/types.js +1 -0
- package/packages/present/dist/index.html +384 -0
- package/packages/server/dist/completions.d.ts +14 -0
- package/packages/server/dist/completions.js +1 -0
- package/packages/server/dist/config.js +1 -1
- package/packages/server/dist/dashboard-static.d.ts +27 -0
- package/packages/server/dist/dashboard-static.js +1 -0
- package/packages/server/dist/elicitor.d.ts +18 -0
- package/packages/server/dist/elicitor.js +1 -0
- package/packages/server/dist/index.js +1 -1
- package/packages/server/dist/mcp-logging.js +1 -1
- package/packages/server/dist/output-schemas.d.ts +118 -1
- package/packages/server/dist/output-schemas.js +1 -1
- package/packages/server/dist/prompts.d.ts +9 -2
- package/packages/server/dist/prompts.js +13 -6
- package/packages/server/dist/resources/curated-resources.js +1 -1
- package/packages/server/dist/resources/resource-notifier.d.ts +45 -0
- package/packages/server/dist/resources/resource-notifier.js +1 -0
- package/packages/server/dist/sampling.d.ts +41 -0
- package/packages/server/dist/sampling.js +2 -0
- package/packages/server/dist/server.d.ts +5 -2
- package/packages/server/dist/server.js +3 -1
- package/packages/server/dist/task-manager.d.ts +40 -0
- package/packages/server/dist/task-manager.js +1 -0
- package/packages/server/dist/tool-metadata.js +1 -1
- package/packages/server/dist/tool-prefix.d.ts +12 -0
- package/packages/server/dist/tool-prefix.js +1 -0
- package/packages/server/dist/tools/analyze.tools.js +4 -4
- package/packages/server/dist/tools/audit.tool.js +1 -1
- package/packages/server/dist/tools/brainstorm.tool.d.ts +7 -0
- package/packages/server/dist/tools/brainstorm.tool.js +9 -0
- package/packages/server/dist/tools/bridge.tools.js +1 -1
- package/packages/server/dist/tools/context.tools.js +9 -9
- package/packages/server/dist/tools/execution.tools.d.ts +2 -1
- package/packages/server/dist/tools/execution.tools.js +4 -3
- package/packages/server/dist/tools/forge.tools.js +10 -10
- package/packages/server/dist/tools/forget.tool.d.ts +2 -1
- package/packages/server/dist/tools/forget.tool.js +1 -1
- package/packages/server/dist/tools/graph.tool.js +2 -2
- package/packages/server/dist/tools/infra.tools.js +2 -2
- package/packages/server/dist/tools/list.tool.js +2 -2
- package/packages/server/dist/tools/lookup.tool.js +1 -1
- package/packages/server/dist/tools/manipulation.tools.js +4 -4
- package/packages/server/dist/tools/onboard.tool.js +2 -2
- package/packages/server/dist/tools/persistence.tools.js +4 -4
- package/packages/server/dist/tools/policy.tools.js +3 -2
- package/packages/server/dist/tools/present-blocks.d.ts +46 -0
- package/packages/server/dist/tools/present-blocks.js +27 -0
- package/packages/server/dist/tools/present-charts.d.ts +31 -0
- package/packages/server/dist/tools/present-charts.js +34 -0
- package/packages/server/dist/tools/present-theme.d.ts +14 -0
- package/packages/server/dist/tools/present-theme.js +395 -0
- package/packages/server/dist/tools/present-utils.d.ts +11 -0
- package/packages/server/dist/tools/present-utils.js +1 -0
- package/packages/server/dist/tools/present.tool.d.ts +7 -0
- package/packages/server/dist/tools/present.tool.js +113 -0
- package/packages/server/dist/tools/produce.tool.js +2 -2
- package/packages/server/dist/tools/read.tool.js +1 -1
- package/packages/server/dist/tools/reindex.tool.d.ts +2 -1
- package/packages/server/dist/tools/reindex.tool.js +2 -2
- package/packages/server/dist/tools/remember.tool.d.ts +2 -1
- package/packages/server/dist/tools/remember.tool.js +2 -2
- package/packages/server/dist/tools/replay.tool.js +2 -2
- package/packages/server/dist/tools/search.tool.d.ts +2 -1
- package/packages/server/dist/tools/search.tool.js +5 -4
- package/packages/server/dist/tools/status.tool.js +2 -2
- package/packages/server/dist/tools/update.tool.d.ts +2 -1
- package/packages/server/dist/tools/update.tool.js +1 -1
- package/packages/server/dist/tools/utility.tools.js +8 -8
- package/packages/store/dist/lance-store.d.ts +1 -0
- package/packages/store/dist/lance-store.js +1 -1
- package/packages/tools/dist/audit.js +1 -1
- package/packages/tools/dist/batch.js +1 -1
- package/packages/tools/dist/check.js +1 -1
- package/packages/tools/dist/checkpoint.js +1 -1
- package/packages/tools/dist/compact.js +2 -2
- package/packages/tools/dist/config-extractor.d.ts +9 -0
- package/packages/tools/dist/config-extractor.js +7 -0
- package/packages/tools/dist/dead-symbols.js +2 -2
- package/packages/tools/dist/diagram-builder.d.ts +9 -0
- package/packages/tools/dist/diagram-builder.js +9 -0
- package/packages/tools/dist/eval.js +2 -2
- package/packages/tools/dist/evidence-map.d.ts +12 -1
- package/packages/tools/dist/evidence-map.js +2 -2
- package/packages/tools/dist/file-summary.js +2 -2
- package/packages/tools/dist/find-examples.js +2 -2
- package/packages/tools/dist/forge-classify.d.ts +4 -0
- package/packages/tools/dist/forge-classify.js +1 -1
- package/packages/tools/dist/git-context.d.ts +1 -0
- package/packages/tools/dist/git-context.js +3 -3
- package/packages/tools/dist/index.d.ts +3 -2
- package/packages/tools/dist/index.js +1 -1
- package/packages/tools/dist/onboard-utils.d.ts +12 -0
- package/packages/tools/dist/onboard-utils.js +1 -0
- package/packages/tools/dist/onboard.js +2 -21
- package/packages/tools/dist/queue.js +1 -1
- package/packages/tools/dist/regex-utils.d.ts +8 -0
- package/packages/tools/dist/regex-utils.js +1 -0
- package/packages/tools/dist/rename.js +2 -2
- package/packages/tools/dist/replay.d.ts +2 -1
- package/packages/tools/dist/replay.js +4 -4
- package/packages/tools/dist/symbol.js +3 -3
- package/packages/tools/dist/synthesis-engine.d.ts +13 -0
- package/packages/tools/dist/synthesis-engine.js +6 -0
- package/packages/tools/dist/test-run.d.ts +3 -1
- package/packages/tools/dist/test-run.js +1 -1
- package/packages/tools/dist/trace.js +2 -2
- package/packages/tui/dist/App-DXY0-tlW.js +2 -0
- package/packages/tui/dist/App.d.ts +3 -3
- package/packages/tui/dist/App.js +1 -1
- package/packages/tui/dist/CuratedPanel-BIamXLNy.js +2 -0
- package/packages/tui/dist/LogPanel-D6u6o84n.js +3 -0
- package/packages/tui/dist/SearchPanel-CpJGczAc.js +2 -0
- package/packages/tui/dist/StatusPanel-BAbUxyqQ.js +2 -0
- package/packages/tui/dist/hooks/useKBClient.d.ts +9 -0
- package/packages/tui/dist/hooks/useKBClient.js +2 -0
- package/packages/tui/dist/hooks/usePolling.d.ts +8 -0
- package/packages/tui/dist/hooks/usePolling.js +2 -0
- package/packages/tui/dist/index.d.ts +6 -2
- package/packages/tui/dist/index.js +1 -1
- package/packages/tui/dist/jsx-runtime-y6Gdq5PZ.js +294 -0
- package/packages/tui/dist/panels/CuratedPanel.d.ts +1 -7
- package/packages/tui/dist/panels/CuratedPanel.js +1 -1
- package/packages/tui/dist/panels/LogPanel.js +1 -1
- package/packages/tui/dist/panels/SearchPanel.d.ts +1 -10
- package/packages/tui/dist/panels/SearchPanel.js +1 -1
- package/packages/tui/dist/panels/StatusPanel.d.ts +1 -7
- package/packages/tui/dist/panels/StatusPanel.js +1 -1
- package/packages/tui/dist/react-D__J1GQe.js +24 -0
- package/packages/tui/dist/types-VcTHNV6s.d.ts +64 -0
- package/packages/tui/dist/useKBClient-C35iA4uG.js +2 -0
- package/packages/tui/dist/usePolling-BbjnRWgx.js +2 -0
- package/scaffold/adapters/copilot.mjs +9 -81
- package/scaffold/definitions/agents.mjs +12 -0
- package/scaffold/definitions/bodies.mjs +39 -14
- package/scaffold/definitions/protocols.mjs +149 -0
- package/scaffold/definitions/tools.mjs +40 -5
- package/scaffold/general/agents/Architect-Reviewer-Alpha.agent.md +1 -1
- package/scaffold/general/agents/Architect-Reviewer-Beta.agent.md +1 -1
- package/scaffold/general/agents/Code-Reviewer-Alpha.agent.md +1 -1
- package/scaffold/general/agents/Code-Reviewer-Beta.agent.md +1 -1
- package/scaffold/general/agents/Debugger.agent.md +2 -2
- package/scaffold/general/agents/Documenter.agent.md +2 -2
- package/scaffold/general/agents/Explorer.agent.md +4 -3
- package/scaffold/general/agents/Frontend.agent.md +1 -1
- package/scaffold/general/agents/Implementer.agent.md +1 -1
- package/scaffold/general/agents/Orchestrator.agent.md +16 -1
- package/scaffold/general/agents/Planner.agent.md +11 -4
- package/scaffold/general/agents/Refactor.agent.md +1 -1
- package/scaffold/general/agents/Researcher-Alpha.agent.md +1 -1
- package/scaffold/general/agents/Researcher-Beta.agent.md +1 -1
- package/scaffold/general/agents/Researcher-Delta.agent.md +1 -1
- package/scaffold/general/agents/Researcher-Gamma.agent.md +1 -1
- package/scaffold/general/agents/Security.agent.md +10 -8
- package/scaffold/general/agents/_shared/architect-reviewer-base.md +1 -0
- package/scaffold/general/agents/_shared/code-agent-base.md +28 -0
- package/scaffold/general/agents/_shared/code-reviewer-base.md +1 -0
- package/scaffold/general/agents/_shared/forge-protocol.md +44 -0
- package/scaffold/general/agents/_shared/researcher-base.md +14 -0
- package/scaffold/general/agents/templates/adr-template.md +1 -0
- package/scaffold/general/agents/templates/execution-state.md +1 -0
- package/skills/knowledge-base/SKILL.md +19 -6
- package/skills/present/SKILL.md +153 -0
- package/packages/server/dist/tools/toolkit.tools.d.ts +0 -36
- package/packages/server/dist/tools/toolkit.tools.js +0 -20
- package/packages/tui/dist/App-DE_tdOhs.js +0 -2
- package/packages/tui/dist/CuratedPanel-sYdZAICX.js +0 -2
- package/packages/tui/dist/LogPanel-Ce3jMQbH.js +0 -3
- package/packages/tui/dist/SearchPanel-DREo6zgt.js +0 -2
- package/packages/tui/dist/StatusPanel-2ex8fLOO.js +0 -2
- package/packages/tui/dist/embedder.interface-IFCBpOlX.d.ts +0 -28
- package/packages/tui/dist/index-C8NmOF18.d.ts +0 -13
- package/packages/tui/dist/jsx-runtime-Cof-kwFn.js +0 -316
- package/packages/tui/dist/store.interface-CnY6SPOH.d.ts +0 -150
- /package/packages/tui/dist/{devtools-DUyj952l.js → devtools-DMOZMn70.js} +0 -0
|
@@ -10,6 +10,7 @@ export const PROTOCOLS = {
|
|
|
10
10
|
|
|
11
11
|
> This file contains shared protocols for all code-modifying agents (Implementer, Frontend, Refactor, Debugger). Each agent's definition file contains only its unique identity, constraints, and workflow. **Do not duplicate this content in agent files.**
|
|
12
12
|
|
|
13
|
+
|
|
13
14
|
## Invocation Mode Detection
|
|
14
15
|
|
|
15
16
|
You may be invoked in two modes:
|
|
@@ -58,6 +59,33 @@ Before returning your handoff, persist discoveries to KB:
|
|
|
58
59
|
|
|
59
60
|
---
|
|
60
61
|
|
|
62
|
+
## Context Efficiency
|
|
63
|
+
|
|
64
|
+
Minimize token usage by choosing the right compression tool:
|
|
65
|
+
- **\`compact({ path, query })\`** — Extract relevant sections from a single file (5-20x token reduction vs full read)
|
|
66
|
+
- **\`digest({ sources })\`** — Compress 3+ files into a single token-budgeted summary
|
|
67
|
+
- **\`stratum_card({ path })\`** — Generate a reusable T1/T2 context card for files you'll reference repeatedly
|
|
68
|
+
|
|
69
|
+
---
|
|
70
|
+
|
|
71
|
+
## User Interaction Rules
|
|
72
|
+
|
|
73
|
+
When you need user input or need to explain something before asking:
|
|
74
|
+
|
|
75
|
+
| Situation | Method | Details |
|
|
76
|
+
|-----------|--------|---------|
|
|
77
|
+
| Simple explanation + question | **Elicitation** | Text-only explanation, then ask via elicitation fields |
|
|
78
|
+
| Rich content explanation + question | **\`present\` (mode: html)** + **Elicitation** | Use \`present({ format: "html" })\` for rich visual explanation (tables, charts, diagrams), then use elicitation for user input |
|
|
79
|
+
| Complex visual explanation | **\`present\` (mode: browser)** | Use \`present({ format: "browser" })\` for full HTML dashboard. Confirmation/selection can be handled via browser actions, but for other user input fall back to elicitation |
|
|
80
|
+
|
|
81
|
+
**Rules:**
|
|
82
|
+
- **Never dump long tables or complex visuals as plain text** — use \`present\` to render them properly
|
|
83
|
+
- **Confirmation selections** (yes/no, pick from list) can be handled inside browser mode via actions
|
|
84
|
+
- **Free-form text input** always goes through elicitation, even when using \`present\` for the explanation
|
|
85
|
+
- **Prefer the simplest method** that adequately conveys the information
|
|
86
|
+
|
|
87
|
+
---
|
|
88
|
+
|
|
61
89
|
## Handoff Format
|
|
62
90
|
|
|
63
91
|
Always return this structure when invoked as a sub-agent:
|
|
@@ -81,6 +109,7 @@ Always return this structure when invoked as a sub-agent:
|
|
|
81
109
|
|
|
82
110
|
> Shared methodology for all Researcher variants. Each variant's definition contains only its unique identity and model assignment. **Do not duplicate.**
|
|
83
111
|
|
|
112
|
+
|
|
84
113
|
## Research Methodology
|
|
85
114
|
|
|
86
115
|
### Phase 1: KB Recall (BLOCKING)
|
|
@@ -114,6 +143,19 @@ Return structured findings. Always include:
|
|
|
114
143
|
|
|
115
144
|
---
|
|
116
145
|
|
|
146
|
+
## FORGE-Aware Research
|
|
147
|
+
|
|
148
|
+
When investigating tasks that involve code changes (architecture decisions, design analysis, subsystem investigation):
|
|
149
|
+
|
|
150
|
+
1. **Classify** — Run \`forge_classify({ task, files, root_path })\` to determine the complexity tier
|
|
151
|
+
2. **Track findings** (Standard+) — Use \`evidence_map\` to record critical findings as verified claims with receipts
|
|
152
|
+
3. **Flag risks** — If research reveals security, contract, or cross-boundary concerns, note the FORGE tier upgrade implications
|
|
153
|
+
4. **Report tier recommendation** — Include FORGE tier and triggers in your research report
|
|
154
|
+
|
|
155
|
+
This ensures the Orchestrator and Planner have tier context when planning implementation.
|
|
156
|
+
|
|
157
|
+
---
|
|
158
|
+
|
|
117
159
|
## Multi-Model Decision Context
|
|
118
160
|
|
|
119
161
|
When invoked for a decision analysis, you receive a specific question. You MUST:
|
|
@@ -143,6 +185,7 @@ When invoked for a decision analysis, you receive a specific question. You MUST:
|
|
|
143
185
|
|
|
144
186
|
> Shared methodology for all Code-Reviewer variants. Each variant's definition contains only identity and model. **Do not duplicate.**
|
|
145
187
|
|
|
188
|
+
|
|
146
189
|
## Review Workflow
|
|
147
190
|
|
|
148
191
|
1. **KB Recall** — Search for relevant conventions, past review findings
|
|
@@ -198,6 +241,7 @@ When invoked for a decision analysis, you receive a specific question. You MUST:
|
|
|
198
241
|
|
|
199
242
|
> Shared methodology for all Architect-Reviewer variants. Each variant's definition contains only identity and model. **Do not duplicate.**
|
|
200
243
|
|
|
244
|
+
|
|
201
245
|
## Review Workflow
|
|
202
246
|
|
|
203
247
|
1. **KB Recall** — Search for architecture decisions, boundary conventions
|
|
@@ -318,5 +362,110 @@ evidence_map({ action: "gate", task_id: "my-task" }) → YIELD / HOLD / HARD_BL
|
|
|
318
362
|
\`\`\`
|
|
319
363
|
|
|
320
364
|
Status values: **V** (Verified + receipt), **A** (Assumed + reasoning), **U** (Unresolved).
|
|
365
|
+
|
|
366
|
+
## Safety Gates (Standard+ only)
|
|
367
|
+
|
|
368
|
+
Three mandatory checks before YIELD:
|
|
369
|
+
|
|
370
|
+
| Gate | Rule | Failure |
|
|
371
|
+
|------|------|---------|
|
|
372
|
+
| **Provenance** | Every verified claim (V) has a non-empty receipt | HOLD — missing evidence trail |
|
|
373
|
+
| **Commitment** | Every commitment-tagged entry is verified | HOLD — unconfirmed promises |
|
|
374
|
+
| **Coverage** | No coverage-tagged entry is unresolved (U) | HOLD — dropped requirements |
|
|
375
|
+
|
|
376
|
+
Tag entries: \`evidence_map({ action: "add", ..., safety_gate: "provenance" })\`
|
|
377
|
+
|
|
378
|
+
Safety gates are evaluated automatically during \`evidence_map({ action: "gate" })\`. Failures produce HOLD — fixable in one retry.
|
|
379
|
+
|
|
380
|
+
## Score-Driven Iteration
|
|
381
|
+
|
|
382
|
+
For quality-sensitive tasks, use the execute→score→fix→re-score pattern:
|
|
383
|
+
|
|
384
|
+
1. Execute task (Build phase)
|
|
385
|
+
2. Score: check({}) + test_run({}) + evidence_map({ action: "gate" })
|
|
386
|
+
3. If gate != YIELD → fix issues → re-score (max 3 iterations)
|
|
387
|
+
4. Track progress: stash({ key: "iteration-N", value: { score, issues } })
|
|
388
|
+
|
|
389
|
+
Agents iterate until quality threshold is met, with diminishing returns tracked via stash.
|
|
390
|
+
|
|
391
|
+
## Example Evidence Map (Standard Tier)
|
|
392
|
+
|
|
393
|
+
\`\`\`
|
|
394
|
+
evidence_map({ action: "create", task_id: "add-user-api", tier: "standard" })
|
|
395
|
+
evidence_map({ action: "add", ..., claim: "User schema matches existing patterns", status: "V", receipt: "search → models/user.ts#L12", safety_gate: "provenance" })
|
|
396
|
+
evidence_map({ action: "add", ..., claim: "API route follows REST conventions", status: "V", receipt: "compact → routes/index.ts confirms RESTful pattern" })
|
|
397
|
+
evidence_map({ action: "add", ..., claim: "Input validation covers edge cases", status: "V", receipt: "test_run → 8/8 pass", safety_gate: "coverage" })
|
|
398
|
+
evidence_map({ action: "add", ..., claim: "No breaking changes to existing API", status: "V", receipt: "blast_radius → 0 affected", safety_gate: "commitment" })
|
|
399
|
+
evidence_map({ action: "gate", task_id: "add-user-api" }) → YIELD ✅
|
|
400
|
+
\`\`\`
|
|
401
|
+
|
|
402
|
+
## Quick Start
|
|
403
|
+
|
|
404
|
+
1. **Every task**: \`forge_classify({ task: "description", files: ["path"], root_path: "." })\`
|
|
405
|
+
2. **Floor**: Just implement — no evidence map needed
|
|
406
|
+
3. **Standard**: \`evidence_map create\` → add 3-8 claims during work → \`evidence_map gate\`
|
|
407
|
+
4. **Critical**: Full 4-phase flow with comprehensive evidence
|
|
408
|
+
5. **After gate**: YIELD = done, HOLD = fix + re-gate, HARD_BLOCK = escalate
|
|
409
|
+
`,
|
|
410
|
+
};
|
|
411
|
+
|
|
412
|
+
// ─── Templates ──────────────────────────────────────────────────────────────
|
|
413
|
+
// Keys map to filenames under agents/templates/
|
|
414
|
+
|
|
415
|
+
export const TEMPLATES = {
|
|
416
|
+
'execution-state': `# Execution State: {Task Title}
|
|
417
|
+
|
|
418
|
+
**Status:** PLANNING | IN_PROGRESS | REVIEW | COMPLETED | BLOCKED
|
|
419
|
+
**Started:** {timestamp}
|
|
420
|
+
**Plan:** {link to plan file}
|
|
421
|
+
|
|
422
|
+
## Phases
|
|
423
|
+
|
|
424
|
+
| # | Title | Agent | Status | Batch |
|
|
425
|
+
|---|-------|-------|--------|-------|
|
|
426
|
+
|
|
427
|
+
## Current Batch
|
|
428
|
+
|
|
429
|
+
**Batch {N}:** {phases in this batch}
|
|
430
|
+
**Status:** IMPLEMENTING | REVIEWING | APPROVED
|
|
431
|
+
|
|
432
|
+
## Decisions Log
|
|
433
|
+
|
|
434
|
+
| Decision | Rationale | ADR |
|
|
435
|
+
|----------|-----------|-----|
|
|
436
|
+
|
|
437
|
+
## Blockers
|
|
438
|
+
|
|
439
|
+
| Issue | Severity | Assigned |
|
|
440
|
+
|-------|----------|----------|
|
|
441
|
+
`,
|
|
442
|
+
|
|
443
|
+
'adr-template': `# DR-NNN: {Short Title}
|
|
444
|
+
|
|
445
|
+
**Status:** Proposed | Accepted | Rejected | Deprecated | Superseded
|
|
446
|
+
**Date:** YYYY-MM-DD
|
|
447
|
+
**Participants:** {which Researcher variants participated}
|
|
448
|
+
|
|
449
|
+
## Context
|
|
450
|
+
{What is the issue? Why are we making this decision?}
|
|
451
|
+
{If superseding, link: "Supersedes DR-NNN."}
|
|
452
|
+
|
|
453
|
+
## Decision
|
|
454
|
+
{What was decided and why — 2-5 sentences max}
|
|
455
|
+
|
|
456
|
+
## Decision Analysis Summary
|
|
457
|
+
| Model | Recommendation | Key Reasoning |
|
|
458
|
+
|-------|---------------|---------------|
|
|
459
|
+
|
|
460
|
+
**Agreements:** {what 3+ models agreed on}
|
|
461
|
+
**Disagreements:** {where they diverged}
|
|
462
|
+
|
|
463
|
+
## Consequences
|
|
464
|
+
**Positive:** {benefits}
|
|
465
|
+
**Negative:** {trade-offs accepted}
|
|
466
|
+
**Risks:** {what could go wrong, and any mitigations}
|
|
467
|
+
|
|
468
|
+
## Alternatives Considered
|
|
469
|
+
{Other approaches evaluated and why they were rejected — keeps the "why not" alongside the "why"}
|
|
321
470
|
`,
|
|
322
471
|
};
|
|
@@ -22,6 +22,7 @@ export const KB_TOOLS = [
|
|
|
22
22
|
'audit',
|
|
23
23
|
'batch',
|
|
24
24
|
'blast_radius',
|
|
25
|
+
'brainstorm',
|
|
25
26
|
'changelog',
|
|
26
27
|
'check',
|
|
27
28
|
'checkpoint',
|
|
@@ -52,6 +53,7 @@ export const KB_TOOLS = [
|
|
|
52
53
|
'measure',
|
|
53
54
|
'onboard',
|
|
54
55
|
'parse_output',
|
|
56
|
+
'present',
|
|
55
57
|
'process',
|
|
56
58
|
'produce_knowledge',
|
|
57
59
|
'queue',
|
|
@@ -61,6 +63,7 @@ export const KB_TOOLS = [
|
|
|
61
63
|
'remember',
|
|
62
64
|
'rename',
|
|
63
65
|
'replay',
|
|
66
|
+
'restore',
|
|
64
67
|
'schema_validate',
|
|
65
68
|
'scope_map',
|
|
66
69
|
'search',
|
|
@@ -125,9 +128,28 @@ export const IDE_CAPABILITIES = {
|
|
|
125
128
|
'todo',
|
|
126
129
|
'searchResults',
|
|
127
130
|
'textSearch',
|
|
131
|
+
'browser',
|
|
132
|
+
],
|
|
133
|
+
researcher: [
|
|
134
|
+
'terminal',
|
|
135
|
+
'problems',
|
|
136
|
+
'readFile',
|
|
137
|
+
'lastCommand',
|
|
138
|
+
'subagent',
|
|
139
|
+
'search',
|
|
140
|
+
'web',
|
|
141
|
+
'browser',
|
|
142
|
+
],
|
|
143
|
+
reviewer: [
|
|
144
|
+
'terminal',
|
|
145
|
+
'problems',
|
|
146
|
+
'readFile',
|
|
147
|
+
'lastCommand',
|
|
148
|
+
'subagent',
|
|
149
|
+
'search',
|
|
150
|
+
'web',
|
|
151
|
+
'browser',
|
|
128
152
|
],
|
|
129
|
-
researcher: ['terminal', 'problems', 'readFile', 'lastCommand', 'subagent', 'search', 'web'],
|
|
130
|
-
reviewer: ['terminal', 'problems', 'readFile', 'lastCommand', 'subagent', 'search', 'web'],
|
|
131
153
|
codeAgent: [
|
|
132
154
|
'createTask',
|
|
133
155
|
'terminal',
|
|
@@ -139,6 +161,7 @@ export const IDE_CAPABILITIES = {
|
|
|
139
161
|
'editFiles',
|
|
140
162
|
'search',
|
|
141
163
|
'todo',
|
|
164
|
+
'browser',
|
|
142
165
|
],
|
|
143
166
|
debugger: [
|
|
144
167
|
'terminal',
|
|
@@ -150,9 +173,19 @@ export const IDE_CAPABILITIES = {
|
|
|
150
173
|
'createFile',
|
|
151
174
|
'editFiles',
|
|
152
175
|
'search',
|
|
176
|
+
'browser',
|
|
177
|
+
],
|
|
178
|
+
refactor: [
|
|
179
|
+
'terminal',
|
|
180
|
+
'problems',
|
|
181
|
+
'readFile',
|
|
182
|
+
'lastCommand',
|
|
183
|
+
'subagent',
|
|
184
|
+
'editFiles',
|
|
185
|
+
'search',
|
|
186
|
+
'browser',
|
|
153
187
|
],
|
|
154
|
-
|
|
155
|
-
explorer: ['problems', 'readFile', 'search', 'fileSearch', 'listDir', 'textSearch'],
|
|
188
|
+
explorer: ['problems', 'readFile', 'search', 'fileSearch', 'listDir', 'textSearch', 'browser'],
|
|
156
189
|
planner: [
|
|
157
190
|
'terminal',
|
|
158
191
|
'problems',
|
|
@@ -164,8 +197,9 @@ export const IDE_CAPABILITIES = {
|
|
|
164
197
|
'search',
|
|
165
198
|
'web',
|
|
166
199
|
'todo',
|
|
200
|
+
'browser',
|
|
167
201
|
],
|
|
168
|
-
security: ['terminal', 'problems', 'readFile', 'subagent', 'search', 'web'],
|
|
202
|
+
security: ['terminal', 'problems', 'readFile', 'subagent', 'search', 'web', 'browser'],
|
|
169
203
|
documenter: [
|
|
170
204
|
'terminal',
|
|
171
205
|
'problems',
|
|
@@ -176,5 +210,6 @@ export const IDE_CAPABILITIES = {
|
|
|
176
210
|
'editFiles',
|
|
177
211
|
'search',
|
|
178
212
|
'web',
|
|
213
|
+
'browser',
|
|
179
214
|
],
|
|
180
215
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
description: 'Primary architecture reviewer'
|
|
3
3
|
argument-hint: Files, PR, or subsystem to architecture-review
|
|
4
|
-
tools: [execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, search/changes, search/codebase, search/usages, web/fetch, web/githubRepo,
|
|
4
|
+
tools: [execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, search/changes, search/codebase, search/usages, web/fetch, web/githubRepo, ms-vscode.vscode-websearchforcopilot/websearch, browser/*, knowledge-base/*]
|
|
5
5
|
model: GPT-5.4 (copilot)
|
|
6
6
|
---
|
|
7
7
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
description: 'Architecture reviewer variant — different LLM perspective for dual review'
|
|
3
3
|
argument-hint: Files, PR, or subsystem to architecture-review
|
|
4
|
-
tools: [execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, search/changes, search/codebase, search/usages, web/fetch, web/githubRepo,
|
|
4
|
+
tools: [execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, search/changes, search/codebase, search/usages, web/fetch, web/githubRepo, ms-vscode.vscode-websearchforcopilot/websearch, browser/*, knowledge-base/*]
|
|
5
5
|
model: Claude Opus 4.6 (copilot)
|
|
6
6
|
---
|
|
7
7
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
description: 'Primary code reviewer'
|
|
3
3
|
argument-hint: File path, PR, or code to review
|
|
4
|
-
tools: [execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, search/changes, search/codebase, search/usages, web/fetch, web/githubRepo,
|
|
4
|
+
tools: [execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, search/changes, search/codebase, search/usages, web/fetch, web/githubRepo, ms-vscode.vscode-websearchforcopilot/websearch, browser/*, knowledge-base/*]
|
|
5
5
|
model: GPT-5.4 (copilot)
|
|
6
6
|
---
|
|
7
7
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
description: 'Code reviewer variant — different LLM perspective for dual review'
|
|
3
3
|
argument-hint: File path, PR, or code to review
|
|
4
|
-
tools: [execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, search/changes, search/codebase, search/usages, web/fetch, web/githubRepo,
|
|
4
|
+
tools: [execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, search/changes, search/codebase, search/usages, web/fetch, web/githubRepo, ms-vscode.vscode-websearchforcopilot/websearch, browser/*, knowledge-base/*]
|
|
5
5
|
model: Claude Opus 4.6 (copilot)
|
|
6
6
|
---
|
|
7
7
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
description: 'Expert debugger that diagnoses issues, traces errors, and provides solutions'
|
|
3
3
|
argument-hint: Error message, stack trace, or description of issue
|
|
4
|
-
tools: [execute/runInTerminal, read/problems, read/readFile, read/terminalSelection, read/terminalLastCommand, agent/runSubagent, edit/createFile, edit/editFiles, search/changes, search/codebase, search/usages, knowledge-base/*]
|
|
4
|
+
tools: [execute/runInTerminal, read/problems, read/readFile, read/terminalSelection, read/terminalLastCommand, agent/runSubagent, edit/createFile, edit/editFiles, search/changes, search/codebase, search/usages, browser/*, knowledge-base/*]
|
|
5
5
|
model: Claude Opus 4.6 (copilot)
|
|
6
6
|
---
|
|
7
7
|
|
|
@@ -16,7 +16,7 @@ You are the **Debugger**, expert debugger that diagnoses issues, traces errors,
|
|
|
16
16
|
## Debugging Protocol
|
|
17
17
|
|
|
18
18
|
1. **KB Recall** — Search for known issues matching this error pattern
|
|
19
|
-
2. **Reproduce** — Confirm the error,
|
|
19
|
+
2. **Reproduce** — Confirm the error, use `parse_output` on stack traces and build errors for structured analysis
|
|
20
20
|
3. **Trace** — `symbol`, `trace`, follow call chains backwards
|
|
21
21
|
4. **Diagnose** — Form hypothesis, gather evidence, identify root cause
|
|
22
22
|
5. **Fix** — Implement the fix, verify with tests
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
description: 'Documentation specialist that creates and maintains comprehensive project documentation'
|
|
3
3
|
argument-hint: Component, API, feature, or area to document
|
|
4
|
-
tools: [execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, edit/createFile, edit/editFiles, search/changes, search/codebase, search/usages, web/fetch, web/githubRepo,
|
|
4
|
+
tools: [execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, edit/createFile, edit/editFiles, search/changes, search/codebase, search/usages, web/fetch, web/githubRepo, ms-vscode.vscode-websearchforcopilot/websearch, browser/*, knowledge-base/*]
|
|
5
5
|
model: GPT-5.4 (copilot)
|
|
6
6
|
---
|
|
7
7
|
|
|
@@ -26,7 +26,7 @@ You are the **Documenter**, documentation specialist that creates and maintains
|
|
|
26
26
|
| README | New package/module | Structure, usage, API |
|
|
27
27
|
| API docs | New/changed endpoints | Request/response, examples |
|
|
28
28
|
| Architecture | Design decisions | Context, decision, consequences |
|
|
29
|
-
| Changelog | After implementation | Keep a Changelog format |
|
|
29
|
+
| Changelog | After implementation | `changelog` tool, Keep a Changelog format |
|
|
30
30
|
|
|
31
31
|
## Rules
|
|
32
32
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
description: 'Rapid codebase exploration to find files, usages, dependencies, and structural context'
|
|
3
3
|
argument-hint: Find files, usages, and context related to: {topic or goal}
|
|
4
|
-
tools: [read/problems, read/readFile, search/changes, search/codebase, search/usages, search/fileSearch, search/listDirectory, search/textSearch, knowledge-base/*]
|
|
4
|
+
tools: [read/problems, read/readFile, search/changes, search/codebase, search/usages, search/fileSearch, search/listDirectory, search/textSearch, browser/*, knowledge-base/*]
|
|
5
5
|
model: Gemini 3 Flash (Preview) (copilot)
|
|
6
6
|
---
|
|
7
7
|
|
|
@@ -16,8 +16,9 @@ You are the **Explorer**, rapid codebase exploration to find files, usages, depe
|
|
|
16
16
|
1. **KB Recall** — `search` for existing analysis on this area
|
|
17
17
|
2. **Discover** — Use `find`, `symbol`, `scope_map` to locate relevant files
|
|
18
18
|
3. **Analyze** — Use `analyze_structure`, `analyze_dependencies`, `file_summary`
|
|
19
|
-
4. **
|
|
20
|
-
5. **
|
|
19
|
+
4. **Compress** — Use `compact` for targeted file sections, `digest` when synthesizing 3+ sources, `stratum_card` for files you'll reference repeatedly
|
|
20
|
+
5. **Map** — Build a picture of the subsystem: files, exports, dependencies, call chains
|
|
21
|
+
6. **Report** — Structured findings with file paths and key observations
|
|
21
22
|
|
|
22
23
|
## Exploration Modes
|
|
23
24
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
description: 'UI/UX specialist for React, styling, responsive design, and frontend implementation'
|
|
3
3
|
argument-hint: UI component, styling task, or frontend feature
|
|
4
|
-
tools: [execute/createAndRunTask, execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, edit/createFile, edit/editFiles, search/changes, search/codebase, search/usages, todo, knowledge-base/*]
|
|
4
|
+
tools: [execute/createAndRunTask, execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, edit/createFile, edit/editFiles, search/changes, search/codebase, search/usages, todo, browser/*, knowledge-base/*]
|
|
5
5
|
model: Gemini 3.1 Pro (Preview) (copilot)
|
|
6
6
|
---
|
|
7
7
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
description: 'Persistent implementation agent that writes code following TDD practices until all tasks are complete'
|
|
3
3
|
argument-hint: Implementation task, feature, or phase from plan
|
|
4
|
-
tools: [execute/createAndRunTask, execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, edit/createFile, edit/editFiles, search/changes, search/codebase, search/usages, todo, knowledge-base/*]
|
|
4
|
+
tools: [execute/createAndRunTask, execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, edit/createFile, edit/editFiles, search/changes, search/codebase, search/usages, todo, browser/*, knowledge-base/*]
|
|
5
5
|
model: GPT-5.4 (copilot)
|
|
6
6
|
---
|
|
7
7
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
description: 'Master conductor that orchestrates the full development lifecycle: Planning → Implementation → Review → Recovery → Commit'
|
|
3
|
-
tools: [vscode/memory, vscode/runCommand, vscode/switchAgent, execute/killTerminal, execute/createAndRunTask, execute/runInTerminal, read/terminalSelection, read/terminalLastCommand, read/problems, read/readFile, agent/runSubagent, edit/createFile, edit/editFiles, search/changes, search/codebase, search/usages, web/fetch, web/githubRepo,
|
|
3
|
+
tools: [vscode/memory, vscode/runCommand, vscode/switchAgent, execute/killTerminal, execute/createAndRunTask, execute/runInTerminal, read/terminalSelection, read/terminalLastCommand, read/problems, read/readFile, agent/runSubagent, edit/createFile, edit/editFiles, search/changes, search/codebase, search/usages, web/fetch, web/githubRepo, ms-vscode.vscode-websearchforcopilot/websearch, todo, search/searchResults, search/textSearch, browser/*, knowledge-base/*]
|
|
4
4
|
model: Claude Opus 4.6 (copilot)
|
|
5
5
|
---
|
|
6
6
|
|
|
@@ -57,6 +57,21 @@ Before Planning, determine the routing:
|
|
|
57
57
|
3. **Both?** → Brainstorming skill first. When it reaches unresolved technical choices, escalate those to the decision protocol, then return to the user for design approval.
|
|
58
58
|
4. **Neither?** → Skip to Phase 1: Planning
|
|
59
59
|
|
|
60
|
+
## FORGE Protocol (Orchestrator Responsibilities)
|
|
61
|
+
|
|
62
|
+
Before delegating any implementation task:
|
|
63
|
+
|
|
64
|
+
1. **Classify**: `forge_classify({ task, files, root_path: "." })` to determine tier (Floor/Standard/Critical)
|
|
65
|
+
2. **Delegate with tier**: Pass FORGE tier to sub-agents via context:
|
|
66
|
+
> **FORGE Context**: Tier = {tier}. {ceremony requirements}.
|
|
67
|
+
> Evidence map: {taskId}. Safety gates: provenance, commitment, coverage.
|
|
68
|
+
3. **Gate after completion**: Run `evidence_map({ action: "gate", task_id })` — YIELD/HOLD/HARD_BLOCK
|
|
69
|
+
4. **Auto-upgrade**: If unknowns reveal contract/security issues during Build, re-classify before next batch
|
|
70
|
+
|
|
71
|
+
Integrate into workflow:
|
|
72
|
+
- Phase 1 step 1: After parsing goal, run forge_classify
|
|
73
|
+
- Phase 2: After each batch's code review, evaluate evidence_map gate
|
|
74
|
+
|
|
60
75
|
## Multi-Model Decision Protocol
|
|
61
76
|
|
|
62
77
|
Launch ALL Researcher variants in parallel with identical framing. Each returns: recommendation, reasoning, trade-offs, risks.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
description: 'Autonomous planner that researches codebases and writes comprehensive TDD implementation plans'
|
|
3
|
-
tools: [execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, edit/createFile, edit/editFiles, search/changes, search/codebase, search/usages, web/fetch, web/githubRepo,
|
|
3
|
+
tools: [execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, edit/createFile, edit/editFiles, search/changes, search/codebase, search/usages, web/fetch, web/githubRepo, ms-vscode.vscode-websearchforcopilot/websearch, todo, browser/*, knowledge-base/*]
|
|
4
4
|
model: Claude Opus 4.6 (copilot)
|
|
5
5
|
---
|
|
6
6
|
|
|
@@ -15,9 +15,11 @@ You are the **Planner**, autonomous planner that researches codebases and writes
|
|
|
15
15
|
## Planning Workflow
|
|
16
16
|
|
|
17
17
|
1. **KB Recall** — Search for past plans, architecture decisions, known patterns
|
|
18
|
-
2. **FORGE
|
|
19
|
-
3. **
|
|
20
|
-
4. **
|
|
18
|
+
2. **FORGE Classify** — `forge_classify({ task, files, root_path: "." })` to determine complexity tier
|
|
19
|
+
3. **FORGE Ground** — `forge_ground` to scope map, seed unknowns, load constraints
|
|
20
|
+
4. **Research** — Delegate to Explorer and Researcher agents to gather context
|
|
21
|
+
5. **Auto-upgrade check** — If forge_ground reveals contract-type unknowns or security concerns not caught by initial classify, recommend tier upgrade in plan
|
|
22
|
+
6. **Draft Plan** — Produce a structured plan:
|
|
21
23
|
- 3-10 implementation phases
|
|
22
24
|
- Agent assignments per phase (Implementer, Frontend, Refactor, etc.)
|
|
23
25
|
- TDD steps (write test → fail → implement → pass → lint)
|
|
@@ -31,6 +33,11 @@ You are the **Planner**, autonomous planner that researches codebases and writes
|
|
|
31
33
|
## Plan: {Title}
|
|
32
34
|
{TL;DR: 1-3 sentences}
|
|
33
35
|
|
|
36
|
+
### FORGE Assessment
|
|
37
|
+
- **FORGE Tier**: {Floor | Standard | Critical}
|
|
38
|
+
- **Evidence Map entries needed**: {count}
|
|
39
|
+
- **Critical-path claims**: {list}
|
|
40
|
+
|
|
34
41
|
### Dependency Graph & Parallel Batches
|
|
35
42
|
| Phase | Depends On | Batch |
|
|
36
43
|
|-------|-----------|-------|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
description: 'Code refactoring specialist that improves structure, readability, and maintainability'
|
|
3
3
|
argument-hint: Code, component, or pattern to refactor
|
|
4
|
-
tools: [execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, edit/editFiles, search/changes, search/codebase, search/usages, knowledge-base/*]
|
|
4
|
+
tools: [execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, edit/editFiles, search/changes, search/codebase, search/usages, browser/*, knowledge-base/*]
|
|
5
5
|
model: GPT-5.4 (copilot)
|
|
6
6
|
---
|
|
7
7
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
description: 'Primary deep research agent — also serves as default Researcher'
|
|
3
3
|
argument-hint: Research question, problem statement, or subsystem to investigate
|
|
4
|
-
tools: [execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, search/changes, search/codebase, search/usages, web/fetch, web/githubRepo,
|
|
4
|
+
tools: [execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, search/changes, search/codebase, search/usages, web/fetch, web/githubRepo, ms-vscode.vscode-websearchforcopilot/websearch, browser/*, knowledge-base/*]
|
|
5
5
|
model: Claude Opus 4.6 (copilot)
|
|
6
6
|
---
|
|
7
7
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
description: 'Research variant for multi-model decision protocol — different LLM perspective'
|
|
3
3
|
argument-hint: Research question, problem statement, or subsystem to investigate
|
|
4
|
-
tools: [execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, search/changes, search/codebase, search/usages, web/fetch, web/githubRepo,
|
|
4
|
+
tools: [execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, search/changes, search/codebase, search/usages, web/fetch, web/githubRepo, ms-vscode.vscode-websearchforcopilot/websearch, browser/*, knowledge-base/*]
|
|
5
5
|
model: Claude Sonnet 4.6 (copilot)
|
|
6
6
|
---
|
|
7
7
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
description: 'Research variant for multi-model decision protocol — different LLM perspective'
|
|
3
3
|
argument-hint: Research question, problem statement, or subsystem to investigate
|
|
4
|
-
tools: [execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, search/changes, search/codebase, search/usages, web/fetch, web/githubRepo,
|
|
4
|
+
tools: [execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, search/changes, search/codebase, search/usages, web/fetch, web/githubRepo, ms-vscode.vscode-websearchforcopilot/websearch, browser/*, knowledge-base/*]
|
|
5
5
|
model: Gemini 3.1 Pro (Preview) (copilot)
|
|
6
6
|
---
|
|
7
7
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
description: 'Research variant for multi-model decision protocol — different LLM perspective'
|
|
3
3
|
argument-hint: Research question, problem statement, or subsystem to investigate
|
|
4
|
-
tools: [execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, search/changes, search/codebase, search/usages, web/fetch, web/githubRepo,
|
|
4
|
+
tools: [execute/runInTerminal, read/problems, read/readFile, read/terminalLastCommand, agent/runSubagent, search/changes, search/codebase, search/usages, web/fetch, web/githubRepo, ms-vscode.vscode-websearchforcopilot/websearch, browser/*, knowledge-base/*]
|
|
5
5
|
model: GPT-5.4 (copilot)
|
|
6
6
|
---
|
|
7
7
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
description: 'Security specialist that analyzes code for vulnerabilities and compliance'
|
|
3
3
|
argument-hint: Code, feature, or component to security review
|
|
4
|
-
tools: [execute/runInTerminal, read/problems, read/readFile, agent/runSubagent, search/changes, search/codebase, search/usages, web/fetch, web/githubRepo,
|
|
4
|
+
tools: [execute/runInTerminal, read/problems, read/readFile, agent/runSubagent, search/changes, search/codebase, search/usages, web/fetch, web/githubRepo, ms-vscode.vscode-websearchforcopilot/websearch, browser/*, knowledge-base/*]
|
|
5
5
|
model: Claude Opus 4.6 (copilot)
|
|
6
6
|
---
|
|
7
7
|
|
|
@@ -14,13 +14,15 @@ You are the **Security**, security specialist that analyzes code for vulnerabili
|
|
|
14
14
|
## Security Review Protocol
|
|
15
15
|
|
|
16
16
|
1. **KB Recall** — Search for past security findings and conventions
|
|
17
|
-
2. **
|
|
18
|
-
3. **
|
|
19
|
-
4. **
|
|
20
|
-
5. **
|
|
21
|
-
6. **
|
|
22
|
-
7. **
|
|
23
|
-
8. **
|
|
17
|
+
2. **Audit** — Run `audit` for a comprehensive project health check, then `find` for specific vulnerability patterns
|
|
18
|
+
3. **OWASP Top 10 Scan** — Check each category systematically
|
|
19
|
+
4. **Dependency Audit** — Check for known CVEs in dependencies
|
|
20
|
+
5. **Secret Detection** — Scan for hardcoded credentials, API keys, tokens
|
|
21
|
+
6. **Auth/AuthZ Review** — Verify access control, session management
|
|
22
|
+
7. **Input Validation** — Check all user inputs for injection vectors
|
|
23
|
+
8. **Impact Analysis** — Use `trace` on sensitive functions, `blast_radius` on security-critical files
|
|
24
|
+
9. **Report** — Severity-ranked findings with remediation guidance
|
|
25
|
+
10. **Persist** — `remember` findings with category `troubleshooting`
|
|
24
26
|
|
|
25
27
|
## Severity Levels
|
|
26
28
|
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
> This file contains shared protocols for all code-modifying agents (Implementer, Frontend, Refactor, Debugger). Each agent's definition file contains only its unique identity, constraints, and workflow. **Do not duplicate this content in agent files.**
|
|
4
4
|
|
|
5
|
+
|
|
5
6
|
## Invocation Mode Detection
|
|
6
7
|
|
|
7
8
|
You may be invoked in two modes:
|
|
@@ -50,6 +51,33 @@ Before returning your handoff, persist discoveries to KB:
|
|
|
50
51
|
|
|
51
52
|
---
|
|
52
53
|
|
|
54
|
+
## Context Efficiency
|
|
55
|
+
|
|
56
|
+
Minimize token usage by choosing the right compression tool:
|
|
57
|
+
- **`compact({ path, query })`** — Extract relevant sections from a single file (5-20x token reduction vs full read)
|
|
58
|
+
- **`digest({ sources })`** — Compress 3+ files into a single token-budgeted summary
|
|
59
|
+
- **`stratum_card({ path })`** — Generate a reusable T1/T2 context card for files you'll reference repeatedly
|
|
60
|
+
|
|
61
|
+
---
|
|
62
|
+
|
|
63
|
+
## User Interaction Rules
|
|
64
|
+
|
|
65
|
+
When you need user input or need to explain something before asking:
|
|
66
|
+
|
|
67
|
+
| Situation | Method | Details |
|
|
68
|
+
|-----------|--------|---------|
|
|
69
|
+
| Simple explanation + question | **Elicitation** | Text-only explanation, then ask via elicitation fields |
|
|
70
|
+
| Rich content explanation + question | **`present` (mode: html)** + **Elicitation** | Use `present({ format: "html" })` for rich visual explanation (tables, charts, diagrams), then use elicitation for user input |
|
|
71
|
+
| Complex visual explanation | **`present` (mode: browser)** | Use `present({ format: "browser" })` for full HTML dashboard. Confirmation/selection can be handled via browser actions, but for other user input fall back to elicitation |
|
|
72
|
+
|
|
73
|
+
**Rules:**
|
|
74
|
+
- **Never dump long tables or complex visuals as plain text** — use `present` to render them properly
|
|
75
|
+
- **Confirmation selections** (yes/no, pick from list) can be handled inside browser mode via actions
|
|
76
|
+
- **Free-form text input** always goes through elicitation, even when using `present` for the explanation
|
|
77
|
+
- **Prefer the simplest method** that adequately conveys the information
|
|
78
|
+
|
|
79
|
+
---
|
|
80
|
+
|
|
53
81
|
## Handoff Format
|
|
54
82
|
|
|
55
83
|
Always return this structure when invoked as a sub-agent:
|