# Understand: Codebase Knowledge Graph (understand)

> Analyzes a codebase into knowledge-graph.json under .ua/, with files, symbols, edges, layers and a guided tour for an interactive dashboard.

- Category: [Architecture Tuning](https://www.myskills.tools/en/categories/architecture-tuning/)
- Source: Community · Egonex-AI
- Repository: https://github.com/Egonex-AI/Understand-Anything/tree/main/understand-anything-plugin/skills/understand (commit 08d16bd)
- SKILL.md: https://github.com/Egonex-AI/Understand-Anything/blob/main/understand-anything-plugin/skills/understand/SKILL.md
- Install command: `npx skills add Egonex-AI/Understand-Anything --skill understand`
- License: MIT
- Compatible with: Claude Code, Codex, Cursor, Copilot, Gemini CLI
- Permissions: read-repo ✓, write-files ✓, shell ✓, network ✓
- Status: Scan passed
- A rule scan cannot catch every risk. Read this skill's SKILL.md and check its permissions before installing.
- ⚠ The first run executes pnpm install and a build in the plugin directory, and large codebases dispatch many sub-agents and take a long time.

## Core rule

Never silently drop errors; every failure must be visible in the final report.

## Execution Phases

1. **Pre-flight** — Resolve the project root and .ua/ data dir, build the plugin if needed, and choose full or incremental analysis from the existing graph.
2. **Scan and batch** — Scan files under .understandignore and --exclude rules, detect languages and frameworks, then compute semantic batches.
3. **Analyze files** — Up to five sub-agents analyze batches in parallel; results merge into nodes and edges and the assembled graph is reviewed.
4. **Layers and tour** — Identify architectural layers, build a guided tour, then validate the whole graph.
5. **Save and report** — Save the graph, fingerprint baseline and meta.json, clean up intermediates and report stats; launch the dashboard if validation passed.

## Permissions (summarised from SKILL.md)

| Capability | Needed | Details |
|---|---|---|
| File writes | Limited | Writes the graph, config and intermediate files only inside the project's .ua/ (or legacy .understand-anything/) directory; source is not modified. |
| Command execution | Required | Runs git, bundled Node and Python scripts, and pnpm install plus a build on first use. |
| Network outbound | Limited | Only pnpm install fetches dependencies when the plugin is not yet built; the analysis itself does not use the network. |

## SKILL.md frontmatter (YAML)

```yaml
---
name: understand
description: Analyze a codebase to produce an interactive knowledge graph for understanding architecture, components, and relationships
argument-hint: ["[path] [--full|--auto-update|--no-auto-update|--review|--language <lang>|--exclude <patterns>]"]
---
```

Home: https://www.myskills.tools/en/ · URL: https://www.myskills.tools/en/skills/understand/
