--- name: multi-model-delegation description: Multi-model design consults via PAL (kimi, glm, gemini, gpt). Use when asking other models to brainstorm a design or reconciling their split answers. user-invocable: false allowed-tools: Read, Glob, Grep, TodoWrite, mcp__pal__listmodels, mcp__pal__chat, mcp__pal__consensus, mcp__pal__thinkdeep model: opus created: 2026-07-17 modified: 2026-11-25 reviewed: 2026-08-21 --- # Multi-Model Delegation Protocol for consulting *other* models — kimi, glm, gemini, gpt via the PAL MCP gateway (`chat`, `consensus`) — on design and judgment work, and for acting on what comes back. The core insight, which inverts the naive approach: > **The value is the disagreement, not the union.** Two competent models > briefed identically converge on the obvious 80% — the part you'd have > written anyway. Where they **split** is a precise pointer at the one > decision that is genuinely load-bearing and underdetermined by the prompt. > Resolve the split against **the codebase** — which usually already decided, > and which the models structurally cannot see — never by picking the more > confident model. Treat delegated models as *idea generators*, never as *authorities*. Taking the majority answer, or the more confident one, launders a coin-flip into a decision that merely looks researched. You — the orchestrating Claude session — run the whole consult: you dispatch the PAL MCP calls, collect the replies, and do the judgment steps (diff, adjudicate, synthesize) yourself in the main loop. ## The Tool Prefix Is Derived, Not Fixed PAL's tools are reachable as **`mcp____`**, where `` is the key the server is **registered under** — not the product name, and not the binary. That key can live in any registration scope: a project `.mcp.json`, a **user**-scope entry in `~/.claude.json` (`claude mcp add -s user …`, which has no `.mcp.json` at all), or a local one. So read the registration rather than a file — `claude mcp list` is authoritative in every scope, and `claude mcp get` names the scope that owns it: ```bash claude mcp list # "pal: uvx palaver-mcp-server@latest - ✔ Connected" claude mcp get pal # Scope: Project config (shared via .mcp.json) ``` The portfolio registers PAL under the key `pal` (the `mcpServers.pal` entry in configure-plugin's `policy/repo-baseline.json`, which `/configure:mcp` writes), so `chat` is `mcp__pal__chat`; a repo that registers the same server under a different key gets that key in the prefix instead. Every `mcp__pal__*` name below assumes that registration — substitute the key `claude mcp list` reports. If a lookup under the correct prefix still finds nothing, see [REFERENCE.md](REFERENCE.md) — that message has a second cause. ## When to Use This Skill | Use this skill when... | Use alternative when... | |---|---| | Brainstorming an open design decision with foreign models (PAL `chat`/`consensus`) | Fanning out **Claude subagents** that do work → `parallel-agent-dispatch`, `agent-teams` | | Reconciling two models' conflicting design proposals | Red-teaming a *finished* artifact → `adversarial-review` | | Deciding whether a multi-model consult is worth the tokens | A lookup answers the question → PAL `apilookup`, official docs | ## The Protocol Execute a multi-model consult in these steps: ### Step 1: Resolve model IDs, then probe each provider Run `mcp__pal__listmodels` once at the start of the consult whenever a model is named loosely ("kimi2.7", "glm5.2") — registry IDs (`kimi-k2.7-code`, `glm-5.2`) and their aliases (`kimi`, `glm`) rarely match what anyone types from memory. Then send a one-line `mcp__pal__chat` (`Reply with OK`) to every model you plan to brief, before the fan-out. `listmodels` reports configuration, not reachability: it lists a provider whose key is an unexpanded `${VAR}`, and it cannot see a spent usage limit. In one review round OpenAI and OpenCode Go both listed as available; the probes returned a 401 and a monthly-limit 429, and only Gemini answered. Fewer than two answering providers means there is no disagreement to read, so replace the dead provider or tell the user the consult is single-model before spending the round. ### Step 2: Brief every model with the same prompt Send the identical brief, verbatim, to each model — one `mcp__pal__chat` call per model — and collect every reply before judging any of them. Different prompts produce divergences that are artifacts of the framing, not of the problem — and afterward you cannot tell a real design tension from a wording accident. Pass code via the `absolute_file_paths` parameter rather than pasting it into the prompt: it is what the parameter is for, and the pasted copy risks truncation. Attachments carry a **per-model token budget** that a multi-file set routinely exceeds — when it does, build one curated excerpt bundle rather than trimming per model (see below). ### Step 3: Keep round one independent Withhold model A's answer from model B. You want independent draws, not an echo. Cross-critique is a deliberate *later* round, never the first one. ### Step 4: Diff the answers for the split With every reply collected, compare them point by point: - **Convergence** → the safe default; adopt it and move on. - **Divergence** → this is the actual decision, and it is now yours — not theirs. Don't ask "which answer do I take?" Ask "what did they disagree about, and what in my codebase already decides it?" ### Step 5: Adjudicate against the code, not taste Go read the thing the decision turns on. Very often the codebase has *already decided*, and the models couldn't know because they can't see it. This is the step that makes the whole exercise worth its tokens. ### Step 6: Graft, never adopt wholesale Even the winning proposal carries ideas that are wrong for your repo. Graft the good parts from the runner-up; reject what doesn't fit and say why. > Canonical case (gh-board priority grading, 2026-07): `kimi-k2.7-code` and > `glm-5.2`, identical briefs. They converged on the module shape and > config-first weights, and both independently proposed a contribution > ledger — the one idea not already in hand, and the one convergent idea > worth keeping. They split on exactly one question: does the triage bucket > feed the priority score, or sit above it? One minute in > `src/app/filter.rs` settled it — `build_rows` already groups into bucket > sections *after* sorting, so a bucket baseline would double-count the > grouping. Both models also proposed an A–F letter grade; **both were > overruled** — grade bands stack a second set of magic thresholds on the > weights and quantize away the fine ordering the score exists to produce. > The models produced the *question*; the repo produced the *answer*. ### Step 7: When a claim is refuted, ask the second question When Step 5 refutes a claim, ask why the test suite could not answer it, then add and kill-test the missing gate: [references/refuted-claims.md](references/refuted-claims.md). ## When It's Worth the Tokens | Worth it | Skip it | |---|---| | Open design decision with a wide solution space and no conventional default — scoring models, architecture splits, API shape, migration strategy | Anything with a conventional default: pick it, state it, proceed | | Genuinely underdetermined trade-offs where an independent draw adds information | A lookup or doc read answers it | | | Seeking agreement on a decision already made — a model asked to validate **will** validate; you pay for confirmation, not information | | An independent single-model review: `chat` with the files and a neutral question. Check every finding against the branch before acting: in a six-PR review on `kimi-k3`/`kimi-k2.7-code`/`glm-5.3` (laurigates/.github #85–#105, 2026-10), none of the four findings rated *high* held, and every fix that merged came from a *medium* or *low* finding | Reading a PAL `codereview`/`precommit`/`debug` expert's agreement as corroboration — it is anchored on your step-2 findings ([REFERENCE.md](REFERENCE.md#single-model-review-through-pal-workflow-tools)) | ## PAL Mechanics That Bite | Mechanic | Symptom | Fix | |---|---|---| | `kimi-k2.7-code` 400s whenever `temperature` is sent (OpenCode Go) | Opaque `Error from provider (Console Go): Upstream request failed` — names neither parameter nor constraint, so it reads as flakiness or "prompt too long" | Omit `temperature` for kimi; `glm-5.2` accepts it fine. Prompt length, attachments, `thinking_mode` are all innocent. [pal#67](https://github.com/laurigates/palaver-mcp-server/issues/67) | | `absolute_file_paths` is capped at ~60% of context headroom, and the cap varies **wildly** by model | The attachment set is rejected for exceeding the budget. Observed on a 262K context: `gpt-5.3-codex` ≈ 76,800 tokens but `kimi-k2.7-code` only ≈ 28,311 — one ~84K, 7-file set bounced on **both** | Size attachments to the **smallest** target model's budget. Because the identical-briefs invariant is load-bearing, one model's ceiling trims the set for *all* of them — build a curated excerpt bundle instead | | `working_directory_absolute_path` must live inside `PAL_WORKSPACE_ROOT` | A scratchpad path outside the repo is rejected: `must reside within the PAL workspace root` | Work in `/tmp//`, never a system temp dir. Diffs and files from another repository (PRs under review elsewhere) are exported there first, e.g. `gh pr diff -R / > /tmp//pr-.diff` | | External models are third-party services | Sending a **private** repo's diff or files is denied by auto mode as data exfiltration; a public repo's content goes through | Consult external models only on content that is already public; review private code with a Claude agent instead | | `model_used` is **untrustworthy under concurrency** | Three *concurrent* `chat` calls returned `model_used` values rotated across each other while `provider_used` stayed request-consistent | Verify independence via `provider_used`, and pick models on **different providers** — a silently same-model pair breaks the disagreement-is-the-payload logic. [pal#68](https://github.com/laurigates/palaver-mcp-server/issues/68) | | Registry models get retired upstream mid-consult | A `listmodels`-listed id 404s ("no longer available") | Pick a same-provider fallback *before* dispatching, and re-send the **identical** brief — a reworded one breaks the invariant | | `glm-5.3` at `thinking_mode: high` times out on large attachments (OpenCode Go) | `Request timed out` after one attempt, many minutes in; observed on PR diffs of ~1,200 and ~3,500 lines, while a 585-line diff finished | Use `thinking_mode: medium` for attachments over ~30K tokens; the same 3,500-line diff then completed | | OpenCode Go enforces a **5-hour usage window** and a **monthly** one | `429 GoUsageLimitError: Go usage limit exceeded`, with `limitName: '5 hour'` (retried 4× then failed; hit after ~10 high-thinking review calls, one alone used ~123K tokens) or `limitName: 'monthly'` (every model, every call, until the monthly reset) | Budget the fan-out before dispatching. Either limit applies to the whole workspace, so every OpenCode Go model and every session sharing the key is out until it resets: finish the round on another provider or stop | | `listmodels` shows a provider ✅ whenever its key is non-empty, including an **unexpanded `${VAR}` placeholder** from `.mcp.json` | OpenAI listed "Configured and available", then every `chat` failed with `401 Incorrect API key provided: ${OPENAI*****KEY}`. This happens in a session started without the variable, such as a launchd-started Desktop task | Prove a provider works with a one-line `chat` (`Reply with OK`) before routing work to it. Never pick a model just because `listmodels` lists it | | PAL reads provider keys from the **inherited Claude Code environment**, not only from the `.mcp.json` `env` block | OpenCode Go was ✅ in an interactive session while `.mcp.json` named no `OPENCODE_API_KEY`, and ❌ in a session started without it | Whether a provider is available depends on the session's environment as well as the config, so test in the environment that will run the work (scheduled task, cloud session) | | Models end a review by asking you to run web searches or send more files | A response of findings plus "please search for X and reply with the continuation_id"; one `kimi-k2.7-code` reply held no findings at all, only requests | Add "Do not ask for searches or more files; state uncertainty inline" to the brief. Verify the facts they asked about yourself (`gh api`, the pinned action source) rather than relaying them | When PAL's MCP server is not connected, the same models are reachable directly over the OpenCode Go gateway — see [REFERENCE.md](REFERENCE.md) for that route's three failure modes. Scripting the `opencode run` CLI unattended has its own traps (permission prompts nobody answers, a shared SQLite lock, a free tier gated to OpenCode's own agent): [references/opencode-cli.md](references/opencode-cli.md). ## The Curated Excerpt Bundle When the load-bearing code spans more than the smallest model's attachment budget allows, **do not trim per model** — that silently un-identicals the briefs. Build one file and attach *it* to every model: 1. Write it **inside the workspace**: `/tmp//context-excerpts.md`. 2. Include **verbatim** excerpts of exactly the load-bearing regions — no paraphrase; the whole point is that the models read the real code. 3. Number the sections (`§1`…`§N`), each titled with its **real file path + line range**, so a cited `§7` resolves back to source. 4. **The smallest model's budget bounds the bundle.** Size the whole file under it, then attach that one path to every model. 5. Reference sections from the brief by number ("weigh §3 against §9"). > Canonical case (loractl #132, 2026-07): a 7-file, ~84K-token attachment set > bounced on both `gpt-5.3-codex` and `kimi-k2.7-code`. An 11-section bundle > at ~21K tokens fit all three budgets, kept the briefs byte-identical, and > the models cited sections accurately. ## Related - [references/agentic-optimizations.md](references/agentic-optimizations.md) — which PAL call fits each consult step - `parallel-agent-dispatch` — delegating *work* to Claude subagents: those are delegates producing output; this skill's models are second opinions producing judgment - `agent-teams` — implicit-team / SendMessage mechanics for Claude teammates - `adversarial-review` — inverted-objective second pass on a finished artifact, by an isolated Claude reviewer - `verify-before-plan` — the same adjudicate-against-reality instinct, applied to orchestrator premises before a dispatch For the second cause of an empty deferred-tool lookup and the direct OpenCode Go gateway route (model enumeration, streaming, reasoning-budget exhaustion), see [REFERENCE.md](REFERENCE.md).