|
| 1 | +--- |
| 2 | +name: configure |
| 3 | +description: Set up dev-loop's capability-role tool profile — map `knowledge` (your domain wiki / MCP), `verify` (your project's test/build/QA command), `explore` (code search), `tacit` (past incidents), and `design` (Figma/visual spec) to the actual tools this environment has, then write ~/.claude/dev-loop/tools.json (global) or <repo>/.dev-loop/tools.json (per-repo). Use when asked to "configure dev-loop", "set up tools", "map my wiki/test command", or "/dev-loop:configure". |
| 4 | +--- |
| 5 | + |
| 6 | +# configure — set up the dev-loop tool profile |
| 7 | + |
| 8 | +dev-loop runs fully generic with **no** config (every role falls back to the |
| 9 | +model's own behavior). Configuring the roles makes the loop use *your* real tools: |
| 10 | +your domain wiki for facts, your actual test command for verification, etc. The |
| 11 | +bundled best-practice `wiki/` (used by `wiki-plan`) needs no config — the |
| 12 | +`knowledge` role is for a separate *external/domain* wiki. |
| 13 | + |
| 14 | +> Note: the plan step is fixed to `wiki-plan` and is NOT configurable. There is no |
| 15 | +> `plan` role. |
| 16 | +
|
| 17 | +## Steps |
| 18 | + |
| 19 | +1. **Show the current profile.** Run and report what is already set vs. default: |
| 20 | + ```sh |
| 21 | + sh ${CLAUDE_PLUGIN_ROOT}/scripts/resolve-tools.sh --summary |
| 22 | + ``` |
| 23 | + |
| 24 | +2. **Decide scope.** |
| 25 | + - **Global** (all your projects): `~/.claude/dev-loop/tools.json` |
| 26 | + - **Per-repo** (committed, team-shared; overrides global per role/field): |
| 27 | + `<repo>/.dev-loop/tools.json` |
| 28 | + Ask the user which, if unclear. (Legacy `~/.claude/loop-orchestrator/tools.json` |
| 29 | + and `<repo>/.loop-orchestrator/tools.json` are still read as a fallback.) |
| 30 | + |
| 31 | +3. **Map each role to a real tool.** Read `${CLAUDE_PLUGIN_ROOT}/examples/tools.example.json` |
| 32 | + as the shape and `references/tool-profile.md` for the schema. For THIS |
| 33 | + environment, detect and propose concrete mappings, then confirm with the user: |
| 34 | + |
| 35 | + | Role | Map to | How to find it | |
| 36 | + |------|--------|----------------| |
| 37 | + | `knowledge` | your domain/policy **wiki** or knowledge MCP | check available MCP servers (e.g. a `wiki_search`/`search_wiki` tool) | |
| 38 | + | `verify` | your project's **test / build / QA** command | read `package.json` scripts / Makefile / `pom.xml` / CI config for the real command | |
| 39 | + | `explore` | code/symbol search (LSP, `rtb-sourcecode`, ripgrep) | what this repo/language supports | |
| 40 | + | `tacit` | past incidents / danger-zone lore (MCP) | check for a lore/incidents MCP | |
| 41 | + | `design` | Figma / visual-spec MCP | only if UI work; check for a Figma MCP | |
| 42 | + | `intake` | issue tracker (orchestrate work-list) | Jira/GitHub issues MCP, if used | |
| 43 | + |
| 44 | + Leave any role the user has no tool for as `default` (omit it). |
| 45 | + `kind` is one of `mcp | skill | agent | cli | default`; add `ref`, and |
| 46 | + optionally `how` (invocation hint) and `when` (a one-line trigger). |
| 47 | + |
| 48 | +4. **Write the file** for the chosen scope, e.g. global: |
| 49 | + ```jsonc |
| 50 | + // ~/.claude/dev-loop/tools.json |
| 51 | + { |
| 52 | + "knowledge": { "kind": "mcp", "ref": "<your-wiki-mcp>", "how": "search -> read", "when": "domain facts, policy, code values" }, |
| 53 | + "verify": { "kind": "cli", "ref": "<your test/build command>", "how": "run only; report failures verbatim", "when": "step 5 — running tests" } |
| 54 | + } |
| 55 | + ``` |
| 56 | + Include only the roles being set; unset roles inherit `default`. For `verify`, |
| 57 | + map the **exact** command (e.g. `pnpm -w test`, `./gradlew test`) — verified by |
| 58 | + reading the project's build config, not guessed. |
| 59 | + |
| 60 | +5. **Validate.** Re-run `resolve-tools.sh --summary` and confirm each role now |
| 61 | + resolves as intended (not `default` where you set it). Report the final profile. |
| 62 | + |
| 63 | +## Guardrails |
| 64 | +- Never map `verify` (or any role) to a tool that runs its own implement/fix/retry |
| 65 | + loop — a role is injected into ONE loop step, never a nested loop (see |
| 66 | + `references/tool-profile.md`). `verify` must run tests and report only. |
| 67 | +- Do not invent MCP/tool names — only map tools you confirmed exist in this |
| 68 | + environment. If unsure, leave the role `default` and say so. |
| 69 | +- Never write secrets/tokens into tools.json; reference tools by name only. |
0 commit comments