agentleFS
sejassejas/skills/skills/explain/SKILL.md

explain

Skill2 starsChanged 8 months agoMITView on GitHub

Search the codebase for function source code and explain it like for a junior developer

143 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use debug-fix, socratic and 8 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • zebbernSkill

    debug-fix

    Find and fix a bug or issue — from any source (GitHub issue, error message, user report, or observed behavior)

    Also in 3 projects that use this

  • neurofooSkill

    socratic

    Socratic questioning to examine beliefs, uncover assumptions, and develop deeper understanding. Use to challenge thinking, evaluate proposals, or teach without lecturing.

    Also in 4 projects that use this

  • ralphkraussSkill

    resolve-conflicts

    Resolve git merge conflicts or re-apply changes from a stale branch onto current main. Use when user says "resolve conflicts", "merge conflicts", "rebase branch", "branch is behind", "re-apply changes", "port branch", or a branch is too far behind main to merge cleanly.

    Also in 4 projects that use this

  • VercelSkill

    next

    Next.js renderer for json-render that turns JSON specs into full Next.js applications with routes, layouts, SSR, and metadata. Use when working with @json-render/next, building Next.js apps from JSON specs, or creating AI-generated multi-page applications.

    Also in 5 projects that use this

  • AntaresYuanSkill

    iterate

    Meta-skill for skill self-improvement. After another skill finishes a run, /iterate analyzes the run's logs (friction events, retries, sub-agent rejections, pacing mismatches, bugs), produces a structured retrospective report, accumulates per-class friction counts, and — when a class crosses the configured threshold — opens a PR to that skill's open-source repo with a proposed SKILL.md diff. NEVER auto-merges; the human always reviews. Target skills opt in by declaring an `iteration:` block in their frontmatter. Invoke when the user says "iterate this skill", "iterate /devloop", "run a retro on the last skill run", "/iterate <skill-name>", or when a target skill auto-hands-off at end of its run.

    Also in 3 projects that use this

  • MicrosoftSkill

    discover

    Also in 6 projects that use this

The file

We split this skill into the rules it gives an agent

11 rules. 0 are common, 11 are distinctive, and 0 are very specific to this project.

  • 0

    Common

    Most of the 126 edited versions we read keep these.

  • 11

    Distinctive

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Ask for clarification if the function name is ambiguous

    line 14
  2. Distinctive:

    If they mention multiple functions, handle them one at a time

    line 15
  3. Distinctive:

    Use the Explore agent for fast searching across the codebase

    line 18
  4. Distinctive:

    Read the complete function implementation

    line 23
  5. Distinctive:

    Look at how it's used in the codebase for context

    line 25
  6. Distinctive:

    Start with what the function does in simple terms

    line 28
  7. Distinctive:

    Use analogies or examples when helpful

    line 31
  8. Distinctive:

    Create an HTML file with the explanation

    line 41
  9. Distinctive:

    Use code syntax highlighting for the source code

    line 42
  10. Distinctive:

    Use simple language, avoid jargon when possible

    line 51
  11. Distinctive:

    Ask follow-up questions if the user needs more clarification

    line 55

“Common” is measured: kept by at least 6 in 10 of the 126 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Explain Function

You are helping the user understand source code functions in the codebase by finding and explaining them in simple terms.

Workflow

  1. Get the function name from the user
    • Ask for clarification if the function name is ambiguous
    • If they mention multiple functions, handle them one at a time
  2. Search the codebase efficiently
    • Use the Explore agent for fast searching across the codebase
    • Find the function definition and its location
    • Note the file path and line number
  3. Read the source code
    • Read the complete function implementation
    • Understand its purpose, parameters, and return value
    • Look at how it's used in the codebase for context
  4. Explain like for a junior developer
    • Start with what the function does in simple terms
    • Break down the logic step-by-step
    • Explain technical terms when introducing them
    • Use analogies or examples when helpful
    • Mention edge cases or important details
    • Explain the "why" behind the implementation choices
  5. Provide context
    • Show where the function is defined (file:line format)
    • Mention how it's commonly used
    • Link to related functions if relevant
  6. Generate HTML documentation
    • Create an HTML file with the explanation
    • Use code syntax highlighting for the source code
    • Highlight key parts with background colors and emphasis
    • Mark "tricky parts" with special visual indicators (badges/alerts)
    • Include an interactive table of contents
    • Save the file as {function_name}_explanation.html in ~/claude.nosync/questions/
    • Open the file in the user's default browser

Key Principles

  • Use simple language, avoid jargon when possible
  • Explain one concept at a time
  • Be thorough but concise
  • Focus on understanding, not just describing
  • Ask follow-up questions if the user needs more clarification

HTML Features

The generated HTML includes:

  • Syntax-highlighted code - Shows the complete function with proper formatting
  • Highlighted key parts - Important lines marked with colored backgrounds
  • Tricky parts badges - Special visual markers for complex or error-prone sections
  • Interactive TOC - Quick navigation between sections
  • Parameter documentation - Explains each parameter and return value
  • Usage examples - Shows how the function is typically used
  • Edge cases section - Warns about potential pitfalls
  • Responsive design - Works on desktop and mobile
  • Dark/light theme support - Professional styling with CSS

Example Response Format

The HTML file generated will include:

  1. Header Section with function name and location
  2. Quick Summary - One sentence description
  3. Source Code - Syntax-highlighted with annotations
  4. How It Works - Step-by-step breakdown
  5. Parameters & Returns - Documented input/output
  6. Key Concepts - Explains important parts with highlights
  7. ⚠️ Tricky Parts - Edge cases and gotchas marked clearly
  8. Common Usage - Examples of how it's used
  9. Related Functions - Links to connected code

The file is saved as ~/claude.nosync/questions/{function_name}_explanation.html and automatically opened in your browser.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.