/sdlc-workflow:consult [codex|claude|gemini|openai|<provider>/<model>] <question>from sdlc-workflow
Consult external models as READ-ONLY oracles — plan critique, code/implementation review, design analysis, diagnosis, second opinion. Fans out to all available providers by default (codex, claude, gemini, openai; a provider keyword narrows to one). Returns a panel of opinions and never edits the repo. The model may invoke it autonomously when a second opinion adds material value; model-initiated runs pin a free subscription CLI (codex/claude).
Ships in sdlc-workflow. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them; scripts run unread.
Apply the boundary rule in _output-boundary.md to every external-facing output this operation produces: translate workflow context to product language and leak-check before publishing.
Read _host-invocation.md first. It defines the invocation
spelling, <skill-dir>, and the $ARGUMENTS token for your host.
consult sends a question to one or more external AI models acting as read-only
oracles and brings back their written opinions — a plan critique, a code or
implementation review, a design trade-off analysis, a diagnosis, a second
opinion. It is advisory only: the oracles can read and search the repo but
cannot edit, write, or run commands. It writes no code and proposes no patch.
No /wf stage runs this skill as a step. The user may run it at any time. A hook or the server never starts it. Cost depends on the provider, not on how
often it runs: a self-initiated run pins a free subscription CLI (codex/claude). "Sparing" governs only the paid REST oracles (gemini,
openai, gateway models) — never fan those out unattended (see Step 0).
Cost safety (autonomous runs). No consent flag gates consult — it runs on
demand. But when YOU (the model) self-initiate a consult rather than the user
typing /consult explicitly, pin a free subscription CLI — pass codex (or
claude) as the provider so the run costs nothing per call. Never bare-fan-out
(which hits the paid REST oracles per-token) on a self-initiated run; reserve the
paid fan-out for an explicit user request that names a paid provider.
Resolve providers (wf-style positional parse). Look at the first token of
$ARGUMENTS:
codex, claude, gemini, openai) or a
"<provider>/<model>" token (contains /, routed through the Vercel AI
Gateway, e.g. anthropic/<model-id>, openai/<model-id>), pin that
provider; the rest is the question.$ARGUMENTS is the question → fan out to all
available providers (the default).
Pass the resolved provider(s), if any, straight through to the runner; do not
pre-filter on availability yourself — the runner reports which it skipped.Infer intent and target from the prose (no flags). From the question and the artifact in context, decide:
<wf-dir>/04-plan.md, where <wf-dir> is the folder that the /wf dispatch prints as wf-dir:), a
diff (git diff, git diff <base>...HEAD), or "the repo." Resolve the repo
root (the git toplevel of the cwd).Compose a single prompt and write it to .ai/consult/<unix-ts>.prompt.md (create
.ai/consult/ if needed). The file is ephemeral: delete it once the runner of
Step 2 returns, whatever its exit code, so a prompt that inlines code does not stay
in the tree. It contains:
codex, claude) run with
cwd=repoRoot and read the live tree themselves — for them, a path/diff
pointer is enough. The REST oracles (gemini, openai, gateway models) are
prompt-only — they see nothing but this file. So when REST providers are in
play, inline the relevant file/diff content into the prompt (fenced), within
reason. One prompt file is sent to every provider; the CLI oracles simply have
the extra ability to read beyond what you inlined.Run the runner (<skill-dir> resolves per _host-invocation.md;
the runner spawns the CLI oracles isolated + read-only, and calls the REST APIs; it
caps parallelism and never writes):
node "<skill-dir>/scripts/dispatch.mjs" read-only <repoRoot> <promptFile> [provider ...]
[provider ...] for the bare fan-out; pass the pinned provider(s) otherwise.{ results: [{provider, ok, text, costUsd, usage, evidenceScope, error}], skipped: [{provider, reason}], bare }.SDLC_COST_SLUG=<slug> and SDLC_COST_KEY=<stage key> on the command. The runner then appends each provider's usage as an external row to the cost ledger of the slug, <wf-dir>/cost-<yyyy-mm>.jsonl in the folder of that workflow (see _additive-write.md). Without the variable, no row is written.skipped names every known provider (codex, claude, gemini, openai) that it left out, with the reason.0 = well-formed (per-provider failures are inside results); 1 = no
provider was available, so the panel is empty (the reasons are in skipped and on
stderr: report them, do not present an empty panel); 2 = usage error.timeout
failure; SDLC_CONSULT_TIMEOUT_MS changes the limit.Build the panel per panel.md: one entry per ok provider with its evidence-scope badge, one-line verdict, and key points; every skipped or failed provider named with its reason and, for auth, its remedy. When fewer providers returned than were requested, lead with the degradation (Panel of 1 — treat it as one opinion, not a consensus); an auth failure is not an environmental wall, it is a login, and the dispatcher says which one. Add the consensus/divergence line, weighted by evidence scope.
End with the machine-readable block, then a short narrative summary:
CONSULT_RESULT:
providers: <comma-separated providers that returned an opinion>
skipped: <provider (reason), … | none>
failed: <provider (kind: reason), … | none> # ok:false — kind ∈ auth|sandbox|not-found|unknown
panel-size: <N of M requested> # N < M ⇒ degraded; say so in the narrative too
remedies: <provider: command, … | none> # actionable fixes for auth failures
verdict: <one-line synthesis — consensus, or the material divergence>
cost: <per-token note, see below>
Cost note. A bare fan-out bills the REST oracles (gemini, openai, gateway models) per token on every invocation; the subscription CLIs cost nothing per call. To stay free, pin one: /consult codex <question> or /consult claude <question>. To pin one paid model, name it: /consult openai <question> or /consult <provider>/<model> <question>.
What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub jayteealao/agent-skills --plugin sdlc-workflowOther plugins' skills for the same job
4 skills in this plugin
/diataxisWrite or review documentation using the Diátaxis framework. Use when the user asks for a tutorial, how-to guide, technical reference, explanation/conceptual doc, README, a documentation plan, or a review/audit of existing docs. Classifies the request into the right quadrant and enforces boundary discipline between them (learning vs task vs lookup vs understanding). For documentation produced as a stage of an /wf lifecycle workflow, use /wf docs instead./study-sourcesReads the real source of a library, framework or SDK at the version the project resolved, so code is written against the actual API instead of a remembered one. Use this skill before writing code that calls a dependency API you have not read in this repo; whenever a compile or type error names a library symbol (Unresolved reference, has no exported member, cannot find symbol, has no attribute, is not a function); when a stack trace leads into node_modules, site-packages or a cached JAR; when a version may be newer than you know; or when the user asks how a library works or to pull down a repo. Reads the copy already on disk first (node_modules, Gradle and Maven sources jars, Android SDK sources, Cargo, Go, NuGet, pub caches) and clones into a gitignored .scratch/ only when it is missing. Read-only.