Skip to main content
skill Claude Code CX Codex Cursor GitHub Copilot

ce-explain — Claude Code skill: what it does, how to install

A skill that explains how a piece of code or a stretch of work ended up in its current shape, with the evidence it used. For the reasoning, not the recommendation.

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add EveryInc/compound-engineering-plugin --skill ce-explain -a claude-code
Open on GitHub

What ce-explain does

The skill answers one scoped question: why something is built the way it is, or what happened across a window of work. The subject comes from the request. Call it with no recoverable subject and you get a clarifying question instead of an invented topic. Verdicts and recommendations belong to ce-pov, a separate skill.

Under the hood it is a set of reference files. references/intake.md fixes the subject and the time window, references/orchestration.md covers evidence gathering and subagent tiers, references/explainer-html.md shapes the standalone write-up. Window recaps go to a subagent seeded with references/agents/work-recap-scout.md; it writes recap-evidence.md into the run directory, and no view of the period is formed before that file exists.

Explanations land in <root>/explainers/, learnings are read from <root>/solutions/. <root> is docs_root from .compound-engineering/config.yaml, resolved against git rev-parse --show-toplevel, so the run belongs in a git repo. Set docs_root to something invalid and the skill stops with an error naming the value — it will not quietly fall back to docs. Worth checking that line before the first run.

What it helps with

  • explain why a module is shaped the way it is, using source as evidence
  • recap what happened on a branch over a set window of work
  • separate documented rationale from inference and open questions
  • write an explanation for a named reader with a stated use
  • hand a calling agent the answer with its caveats, no separate file

Example prompts for the agent

  • `/ce-explain` why auth goes through middleware instead of decorators
  • `/ce-explain` what happened on `feature/billing` last week, reader is a new teammate
  • `/ce-explain` how discount calculation works in `pricing/`, reader is a backend dev

How to install ce-explain

1Skills CLI (Vercel)

npx skills add EveryInc/compound-engineering-plugin --skill ce-explain -a claude-code

2Manually: put the files in place

~/.claude/skills/ce-explain/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/ce-explain/

From the same set21

The whole set →
ce-brainstorm EveryInc Turns vague ideas into a structured requirements plan through dialogue. Separates product decisions from code. Claude Code CX Codex Cursor +1 3,900installs ce-compound EveryInc A skill that captures non-obvious reasoning from solved problems as durable project knowledge. Use it when the final code works but the logic behind it might vanish when the next person reads the code. Claude Code CX Codex Cursor +1 3,700installs ce-plan EveryInc Builds structured technical implementation plans without touching production code. Useful when scoping features before passing work to execution agents. Claude Code CX Codex Cursor +1 3,700installs ce-code-review EveryInc Reviews a named diff or pull request for bugs, regressions, tests, and project standards. Use it for a current branch review or a specific PR. Claude Code CX Codex Cursor +1 3,700installs ce-work EveryInc Executes a plan document or build spec end-to-end with local verification. Ideal for implementing features without reopening architectural debates. Claude Code CX Codex Cursor +1 3,600installs ce-doc-review EveryInc This skill reviews requirements, plans, and specs through role-based reviewers. Use it to catch consequential issues in an existing document and apply fixes within the granted authority. Claude Code CX Codex Cursor +1 3,600installs ce-debug EveryInc Finds the root cause of a bug from trigger to symptom and applies a test-first fix. Useful when investigating broken behavior or failing CI logs. Claude Code CX Codex Cursor +1 3,500installs lfg EveryInc Takes a request from intake to a finished result and opens a pull request for code changes. Use it when the user explicitly wants autonomous end-to-end work. Claude Code CX Codex Cursor +1 3,500installs

Similar

cost-summary ruvnet Extracts a single-shot cost snapshot across models, tiers, and sessions in JSON or markdown. Useful for scripts, bots, and budget tracking. Claude Code CX Codex Cursor +1 683installs cost-conversation ruvnet Groups LLM spending by session, displaying start time, message count, top model, and total cost. Helps evaluate long or expensive conversations. Claude Code CX Codex Cursor +1 682installs cost-export ruvnet Exports cost telemetry into Prometheus textfile or webhook JSON formats for external dashboards like Grafana or Datadog. Claude Code CX Codex Cursor +1 681installs figma-create-new-file figma A skill that tells the agent how to create a Figma Design, FigJam or Slides file with the MCP create_new_file tool, including which plan and editor type to use. Claude Code CX Codex Cursor +1 3,400installs gitnexus-pdg-query abhigyanpatwari Helps inspect control dependencies and data flow within functions via the GitNexus pdg_query tool. Useful for tracing variable definitions and discovering guard clauses. Claude Code CX Codex Cursor +1 320installs cost-booster-edit ruvnet Runs simple structural code edits through agent-booster's WASM engine with no LLM call and no token bill. Built for the same transform repeated across a project. Claude Code CX Codex Cursor +1 679installs setup-matt-pocock-skills Matt Pocock This skill configures a repository for Matt Pocock's engineering skills by setting its issue tracker, triage labels, and domain docs layout. Run it before using the other skills. Claude Code 1,052,851installs to-tickets Matt Pocock Turns a plan, spec, or conversation into small end-to-end tickets with explicit blockers. Use it to agree on the work breakdown before tickets go to a tracker. Claude Code 711,230installs

Questions about ce-explain

How do I install ce-explain in Claude Code?

Run npx skills add EveryInc/compound-engineering-plugin --skill ce-explain -a claude-code. The skill ends up at ~/.claude/skills/ce-explain/SKILL.md.

What does ce-explain do?

It explains how and why something has its current shape, or what happened over a window of work, and ties each claim to evidence. Judgements and recommendations are ce-pov territory.

Does it need anything set up first?

A git repository: the artifact root is resolved through git rev-parse --show-toplevel, and docs_root is read from .compound-engineering/config.yaml. An invalid docs_root fails the run with an error rather than falling back to docs.

Source text

SKILL.md · MIT
---
name: ce-explain
description: "Explain how and why something has its current shape, or what happened over a window of work, grounded in evidence. Use when the user asks for an explanation. Use ce-pov for a judgment or recommendation."
argument-hint: "[question, concept, change, or work window] [intended use or reader]"
---

# Explain How and Why

Produce an explanation that answers the scoped question and gives its consumer enough understanding for the intended use. The subject and purpose come from the request and available context, whether a person or another workflow supplied them. Ground project behavior in source evidence; distinguish documented rationale, inference, and unknowns.

**Done:** deliver the explanation with supporting evidence and material unanswered questions, or return the specific blocker. When an artifact is requested, deliver the artifact and its location. Publication is a separate action, not a condition of having explained the subject.

## Consumer and interaction

Adapt depth and presentation to the intended readers and use. A person may need a working answer; a calling agent may need a teaching artifact for someone else. Do not infer the output from the caller's identity alone. When contributing to an ongoing workflow, deliver the requested result and leave continuation to its owner, the calling workflow. Do not add destination menus or follow-up offers to that return.

Resolve discoverable facts before asking. Ask only when missing information materially changes the answer and cannot be resolved from the request or evidence. If interaction is unavailable, return the unresolved question and its consequence rather than waiting or inventing an answer. A result may explain verified behavior while reporting that its historical rationale is unknown.

**Read `references/orchestration.md` before grounding, the first blocking question, or subagent dispatch.** It defines evidence gathering, tool use, model tiers, and their fallbacks.

## Artifact Root

An explainer lands under `<root>/explainers/` only when archived to the repo, and learnings may be read under `<root>/solutions/`. Resolve `<root>` only when you compose such a path; a scratch-only or external-concept run never composes one. Pass the resolved path to any subagent, not the config.

<!-- ce-docs-root:start -->
**Resolve the CE artifact root `<root>` before composing any artifact path.**

- **Read** `docs_root` from `<repo-root>/.compound-engineering/config.yaml` only (`<repo-root>` = `git rev-parse --show-toplevel`). Do not read it from `config.local.yaml`. Unset -> `<root>` is `docs`, exactly as before.
- **Validate** a set value: a repo-relative directory whose real, symlink-resolved path stays inside the repo and is neither the repo root nor under `.git/`. Otherwise stop with an error naming `docs_root` and the value -- never fall back to `docs`.
- **Use** `<root>` as the sole artifact location: create it if absent, compose each path as `<root>/<subdir>` with this skill's own subdirectory, and never also read `docs`.
<!-- ce-docs-root:end -->

## Execution Flow

### Phase 1: Establish the question and use

Read `references/intake.md` now. It defines how the subject and time window are resolved, the input tokens, and how the delivery form is chosen. Explain only the requested subject. A bare invocation with no recoverable subject needs clarification under the interaction rule above, not an invented topic or default artifact.

### Phase 2: Ground

Follow `references/orchestration.md` for the scoped evidence pass. Use existing evidence when it is adequate and current; check claims whose support is missing, disputed, or affected by source changes.

Create a run directory only when an artifact or an evidence dossier needs one. Use this block before writing either; it rejects a symlink or a scratch root owned by another user:

```bash
SCRATCH_ROOT="/tmp/compound-engineering-$(id -u)";
[ ! -L "$SCRATCH_ROOT" ] && (umask 077; mkdir -p "$SCRATCH_ROOT") 2>/dev/null && [ ! -L "$SCRATCH_ROOT" ] && [ -O "$SCRATCH_ROOT" ] && [ -w "$SCRATCH_ROOT" ] || SCRATCH_ROOT="${TMPDIR:-/tmp}/compound-engineering-$(id -u)";
if [ -L "$SCRATCH_ROOT" ]; then echo "unsafe scratch root symlink: $SCRATCH_ROOT" >&2; exit 1; fi;
(umask 077; mkdir -p "$SCRATCH_ROOT") || exit 1;
if [ -L "$SCRATCH_ROOT" ] || [ ! -O "$SCRATCH_ROOT" ]; then echo "scratch root is not owned by the current user: $SCRATCH_ROOT" >&2; exit 1; fi;
chmod 700 "$SCRATCH_ROOT" || exit 1;
RUN_DIR="$SCRATCH_ROOT/ce-explain/$(date +%Y%m%d)-$(openssl rand -hex 3)";
(umask 077; mkdir -p "$RUN_DIR") || exit 1; chmod 700 "$RUN_DIR" || exit 1;
echo "$RUN_DIR";
```

A behavior trace that splits across ownership boundaries writes scout dossiers. Create this run directory before dispatching those scouts.

- **Diff mode.** **Empty range** or missing subject: do not silently explain something else. Report that before explaining an adjacent thing. Use a substitute only when the request permits it or the user agrees; name the substitution in the result and artifact `Subject` when present. Otherwise return the unresolved scope to the caller.
- **Recap mode.** Do not pre-scan, count, or characterize the window in the main conversation. Instead dispatch a generic subagent directly at the extraction tier, seeded with `references/agents/work-recap-scout.md` and passed the resolved window, repo root, and `$RUN_DIR`. **Empty window:** report the absence of activity and finish without an explainer artifact. **When the harness exposes no subagent primitive**, run the scout inline with its prompt's sources and budgets, still write `recap-evidence.md`, and form no view of the window until it is done. If dispatch fails, follow the fallback rule in `references/orchestration.md`.

### Phase 3: Compose the explanation

Answer the question using the evidence, preserving material constraints and uncertainty. Before delivery, check every factual claim against its source. A function call does not establish guarantees about its uninspected implementation. Remove unsupported claims or state their uncertainty where they appear, including in diagrams and exercise answers. Choose prose, code, tables, or visuals when they improve understanding; no particular arrangement is required. Keep attribution accurate when explaining work by multiple people. When selecting from more evidence than the requested scope or depth can hold, disclose the selection; never silently present a partial account as exhaustive.

For an answer or material another workflow will incorporate, return that content directly. Each passage must carry the qualifications needed to use it accurately without separate notes. When another workflow will use the answer, that return includes the evidence, the constraints that still apply, and the unanswered questions. Do not create a standalone artifact unless the intended use needs one.

For a standalone artifact, read `references/explainer-html.md` or `references/explainer-markdown.md` at compose time for the selected format's compatibility and metadata requirements. For teaching artifacts, also read `references/check-in.md`. The run never blocks on the check-in; any exercises are static content in the artifact. Write `$RUN_DIR/explainer.html` or `explainer.md`, then deliver an inline summary plus the file path.

### Phase 4: Deliver

A delivered answer or local artifact completes the explanation. Do not require a destination choice or manufacture follow-on work. If a destination was requested, read `references/destinations.md` before acting; it defines each destination and the consent publishing needs. When a calling workflow owns the surrounding document, return the content to it rather than placing or publishing it yourself.

Publishing to ht-ml.app is never headless and never inferred. Naming it is a choice of destination rather than confirmation after its public-publishing warning. If confirmation cannot be obtained, do not publish; preserve the canonical HTML and report its local `$RUN_DIR/explainer.html` path.

## Boundaries

- Use `ce-pov` to judge whether an approach should be adopted or changed. Explaining a historical choice is not endorsing it today.
- Use `ce-compound` to capture durable project learning. Producing an explanation does not authorize maintaining repo memory.
- Explain an idea as supplied; generating alternatives and scoping implementation belong to `ce-ideate`, `ce-brainstorm`, and `ce-plan`.
- A reported failure to diagnose or fix belongs to `ce-debug`; a factual explanation of current behavior remains here.

© EveryInc · MIT · EveryInc/compound-engineering-plugin

See also

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor