explain
Use when user invokes /explain with a file path, directory path, function/class name, or natural language concept. Also triggers on "explain this", "how does X work", "walk me through". Produces a structured, layered explanation of what the code does, how it connects, and where to start if you need to change it. Do NOT use when the user wants to trace data flow through a pipeline — use /lineage instead.
npx skills add majiayu000/claude-skill-registry --skill explain-harnessprotocol-harness-kit --agent claude-code
Same command for any agent — swap --agent for codex, cursor, copilot.
Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.
# Structured Code Explainer ## Overview Produce layered explanations of code — files, directories, functions, classes, or cross-cutting concepts. Designed for developers working in unfamiliar parts of a codebase. **Core principles:** 1. **Adaptive depth.** A single function gets a focused deep-dive. A directory gets a map first, then the user picks where to zoom. 2. **Project-aware.** If the project has a CLAUDE.md, reference its Architecture section to ground explanations in the project's own terminology. 3. **Conversation output.** Explanations go to the conversation, not files. The user can ask to save if they want. ## When to Use User types `/explain` followed by: - **File path** → explain that file - **Directory path** → map the directory structure, then explain key components - **Function or class name** → find the definition, explain it in context - **Natural language concept** → search the codebase for relevant files and explain the concept/flow ## Invocation Examples ``` /explain src/auth/middleware.ts /explain the payment processing flow /explain src/services/ /explain OrderProcessor.process /explain how webhooks get dispatched ``` ## Workflow Order (MANDATORY) **You MUST
- Overview
- When to Use
- Invocation Examples
- Workflow Order (MANDATORY)
- Step 1: Parse Input
- Step 2: Gather Context
- Step 3: Check for CLAUDE.md
- Step 4: Analyze Scope
- Step 5: Produce Explanation
- Step 6: Offer Follow-Up
- Adaptive Behavior
- Small target (single function, < 50 lines)
- Medium target (single file, 50-500 lines)
- Large target (directory, multi-file concept)
What does the explain skill do?
Use when user invokes /explain with a file path, directory path, function/class name, or natural language concept. Also triggers on "explain this", "how does X work", "walk me through". Produces a structured, layered explanation of what the code does, how it connects, and where to start if you need to change it. Do NOT use when the user wants to trace data flow through a pipeline — use /lineage instead.
How do I install it?
Run `npx skills add majiayu000/claude-skill-registry --skill explain-harnessprotocol-harness-kit --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.
Where does this skill come from?
From majiayu000/claude-skill-registry, a repository with 534 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.
Is a popular skill a good skill?
Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.
