understand

Analyze a codebase to produce an interactive knowledge graph for exploring architecture and components.

90.9k|7.8k|Updated Mar 15, 2026
Ready to run
npx skills add https://github.com/Lum1104/Understand-Anything --skill understand-lum1104
💬 Prompt for ChatGPT / Claude Chat▼
Please help me install this Agent Skill.
Skill: understand
Source: https://github.com/Lum1104/Understand-Anything/tree/main/understand-anything-plugin/skills/understand
Command: npx skills add https://github.com/Lum1104/Understand-Anything --skill understand-lum1104

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires @understand-anything/core, graphology, graphology-communities-louvain, and includes scripts (resource) and references (resource) components.

What problem does it solve? Developers joining a new team face overwhelming codebases with unclear architecture, scattered dependencies, and undocumented relationships between modules. This Skill automatically maps the entire codebase structure, revealing connections and patterns without manual exploration. ## Core Features & Use Cases - Automated Architecture Discovery: Detect modules, components, and their relationships through structural analysis and import resolution. - Incremental Updates: Run full analyses or update only changed files based on git history, avoiding redundant processing. - Multi-language Support: Parse TypeScript, JavaScript, Python, Go, Java, Rust, Swift, C#, and more to extract unified semantics. - Use Case: A developer joining a 200,000-line microservices repository can run /understand once and immediately explore which services depend on which, where the database layer lives, and which functions are tested. ## Quick Start Run /understand in your repository root to analyze all code and generate a knowledge graph stored in .ua/knowledge-graph.json.

Frequently Asked Questions about understand

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I analyze a large codebase without overwhelming the system?▼

The Skill automatically batches files using Louvain community detection on the import graph, splitting large codebases into manageable chunks. You can also use `--exclude` to ignore test directories and generated code, or run analysis on a specific subdirectory.

Can I update the graph when code changes without re-analyzing everything?▼

Yes. After the initial full analysis, subsequent runs detect changed files via git diff and only re-analyze those files, merging results with the existing graph. Use `--auto-update` to enable this automatically on commit.

What import resolution is supported for different languages?▼

The Skill resolves TypeScript path aliases via tsconfig.json, Go modules via go.mod, Java packages by suffix matching, relative imports across all languages, and non-code file cross-references. Tree-sitter extracts raw imports; language-specific rules map them to project-internal paths.

Does the Skill handle monorepos with multiple tsconfigs or go.mods?▼

Yes. It loads every tsconfig.json and go.mod in the project, then walks up from each importer to find the nearest enclosing config, matching how TypeScript and Go tools resolve nested packages correctly.

Why might analysis fail or produce incomplete graphs?▼

Common causes include unsupported file types (the Skill skips them silently), tree-sitter parser failures on malformed code (logged as warnings), or import resolution misses when external packages are mislabeled as internal. Use `--review` to run LLM-assisted validation and fix issues.

Can I output the knowledge graph in different languages or formats?▼

The JSON graph structure is fixed, but use `--language zh` (or `es`, `ja`, `ko`, etc.) to generate all descriptions, tags, and summaries in your preferred language. Custom export formats require post-processing the JSON output.