# Code Explainer

> Explain code at a high level and surface gotchas. Use when the user wants to understand what code does, its flow, dependencies, risks, or edge cases.

- Skill: `devclarityai/code-explainer-2` (Agent Skill)
- Install (CLI): `npx skillmds@latest add devclarityai/code-explainer-2`
- Raw SKILL.md: https://api.skillmd.com/api/skills/devclarityai/code-explainer-2/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Coding & Dev Tools
- Author: devclarityai (https://skillmd.com/u/devclarityai)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/devclarityai/code-explainer-2

---


Use this template to explain code at a high level and surface gotchas.

## INPUTS
- PROJECT_CONTEXT
- CODE
- (optional) FILE_PATH

## INSTRUCTIONS
1. Read code in the context of PROJECT_CONTEXT.
2. Describe what it does in clear, concise terms. Prefer bullets.
3. Summarize data flow, side effects, external calls, and I/O.
4. Note domain concepts relevant to the business/application context.
5. Call out risks, edge cases, and TODOs you would add.
6. Keep it actionable and brief. Avoid restating the code line-by-line.
7. When helpful, include a small sequence diagram or pseudo-code.
8. Keep lines ≤80 chars.

## OUTPUT FORMAT

### What this code does
- ...

### How it works (flow)
- **Inputs:**
- **Processing:**
- **Outputs:**
- **Side effects:**

### Dependencies & contracts
- **Frameworks/libraries used:**
- **Service/API calls:**
- **Databases/tables/queues touched:**

### Assumptions
- ...

### Gotchas & risks
- **Concurrency:**
- **Error handling:**
- **Performance:**
- **Security/compliance:**
- **Observability:**

### TODOs / improvements
- **Quick wins:**
- **Follow-ups:**

### Example trace (pseudo)
...

