code-explainer

GitHub

将代码片段解释为易懂的英文,提供一行总结、分步逻辑解析、非直观细节及潜在Bug。根据读者水平调整深度,避免逐行复述,强调意图与结构分析。

exports/openclaw/code-explainer/SKILL.md mohitagw15856/pm-claude-skills

Trigger Scenarios

请求解释代码含义 需要逐步 walkthrough 函数逻辑 理解陌生代码片段 新文件入职熟悉

Install

npx skills add mohitagw15856/pm-claude-skills --skill code-explainer -g -y
More Options

Non-standard path

npx skills add https://github.com/mohitagw15856/pm-claude-skills/tree/main/exports/openclaw/code-explainer -g -y

Use without installing

npx skills use mohitagw15856/pm-claude-skills@code-explainer

指定 Agent (Claude Code)

npx skills add mohitagw15856/pm-claude-skills --skill code-explainer -a claude-code -g -y

安装 repo 全部 skill

npx skills add mohitagw15856/pm-claude-skills --all -g -y

预览 repo 内 skill

npx skills add mohitagw15856/pm-claude-skills --list

SKILL.md

Frontmatter
{
    "name": "code-explainer",
    "homepage": "https:\/\/mohitagw15856.github.io\/pm-claude-skills\/skill\/code-explainer.html",
    "metadata": {
        "openclaw": {
            "emoji": "⚙️"
        }
    },
    "description": "Explain what a piece of code does in plain English, at the depth the reader needs. Use when asked to explain code, walk through a function, understand an unfamiliar snippet, or onboard to a file. Produces a one-line summary, a step-by-step walkthrough, the non-obvious parts called out, and any bugs or smells spotted along the way."
}

Code Explainer Skill

Make unfamiliar code understandable — fast — without dumbing it down.

Working from a brief

Infer the language and intent from the code itself; label assumptions (assumed — confirm). Always produce a complete explanation even from a fragment. Match depth to the apparent level of the question.

Input

The code snippet or file, plus (if given) the language, the reader's level, and what they're trying to understand. Infer the rest.

Output Structure

In one line

What this code does, in a single sentence a busy reader can repeat.

Step by step

A walkthrough of the logic in order — group by block/function. Explain why, not just what, for anything non-trivial. Reference line ranges where helpful.

Worth knowing

The non-obvious bits: clever tricks, gotchas, side effects, complexity, dependencies, or assumptions the code makes.

Anything off?

Bugs, edge cases, or smells you noticed while reading — with the fix. (If it's clean, say so.)

Quality Checks

  • The one-line summary stands alone
  • The walkthrough explains why, not just restating the code in words
  • Non-obvious behaviour (side effects, complexity, edge cases) is surfaced
  • Any bug/smell spotted is flagged with a fix

Anti-Patterns

  • Do not narrate line-by-line in English ("this line sets x to 5") — explain intent and structure
  • Do not skip the gotchas — the value is in the non-obvious parts
  • Do not assume expert level if the question reads like a beginner's (or vice-versa)
  • Do not ignore a bug you can see just because you weren't asked to review it

Version History

  • 54fad50 Current 2026-07-19 12:13

Same Skill Collection

exports/openclaw/360-feedback-template/SKILL.md
exports/openclaw/401k-plan-decoder/SKILL.md
exports/openclaw/ab-test-planner/SKILL.md
exports/openclaw/ab-test-readout/SKILL.md
exports/openclaw/accessibility-audit/SKILL.md
exports/openclaw/account-plan/SKILL.md
exports/openclaw/acquirer-red-team/SKILL.md
exports/openclaw/ad-copy/SKILL.md
exports/openclaw/aeo-optimizer/SKILL.md
exports/openclaw/agenda-or-cancel/SKILL.md
exports/openclaw/agent-design-review/SKILL.md
exports/openclaw/agent-observability-spec/SKILL.md
exports/openclaw/agent-spec/SKILL.md
exports/openclaw/ai-ethics-review/SKILL.md
exports/openclaw/ai-eval-plan/SKILL.md
exports/openclaw/ai-feature-prd/SKILL.md
exports/openclaw/ai-product-canvas/SKILL.md
exports/openclaw/air-quality/SKILL.md
exports/openclaw/altitude-shifter/SKILL.md
exports/openclaw/ambiguity-resolver/SKILL.md
exports/openclaw/analyst-relations-brief/SKILL.md
exports/openclaw/announcement-card/SKILL.md
exports/openclaw/api-docs-writer/SKILL.md
exports/openclaw/api-test-plan/SKILL.md
exports/openclaw/api-versioning-strategy/SKILL.md
exports/openclaw/apology-letter/SKILL.md
exports/openclaw/architecture-decision-record/SKILL.md
exports/openclaw/architecture-diagram/SKILL.md
exports/openclaw/archive-strategy/SKILL.md
exports/openclaw/assumption-bounty/SKILL.md
exports/openclaw/assumption-mapper/SKILL.md
exports/openclaw/async-update-format/SKILL.md
exports/openclaw/auto-repair-estimate-decoder/SKILL.md
exports/openclaw/autopilot-charter/SKILL.md
exports/openclaw/benefits-decoder/SKILL.md
exports/openclaw/bid-tender-review/SKILL.md
exports/openclaw/board-deck-narrative/SKILL.md
exports/openclaw/board-minutes/SKILL.md
exports/openclaw/board-pre-read/SKILL.md
exports/openclaw/bom-cost-review/SKILL.md
exports/openclaw/bookkeeping-categorization/SKILL.md
exports/openclaw/boolean-search-builder/SKILL.md
exports/openclaw/brag-doc/SKILL.md
exports/openclaw/brainstorming/SKILL.md
exports/openclaw/brief-builder/SKILL.md
exports/openclaw/briefing-note/SKILL.md
exports/openclaw/budget-builder/SKILL.md
exports/openclaw/budget-variance-analysis/SKILL.md
exports/openclaw/bug-diagnosis/SKILL.md
exports/openclaw/bug-report/SKILL.md

Metadata

Files
0
Version
471c606
Hash
ea24e814
Indexed
2026-07-19 12:13

- 위키
Copyright © 2011-2026 iteam. Current version is 2.155.2. UTC+08:00, 2026-07-30 14:07
浙ICP备14020137号-1 $방문자$