understand-domain

Extract business domains and flows from a codebase into an interactive domain graph.

Updated Jun 28, 2026
One-click install
npx skills add https://github.com/AO-HyS/aohys.com --skill understand-domain-ao-hys
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: understand-domain
Source: https://github.com/AO-HyS/aohys.com/tree/main/.agents/skills/understand-domain
Command: npx skills add https://github.com/AO-HyS/aohys.com --skill understand-domain-ao-hys

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve? Understanding the business logic of an unfamiliar codebase requires hours of manual exploration. This Skill automates the extraction of domains, business flows, and process steps from source code and renders them as an interactive horizontal flow graph in a dashboard. ## Core Features & Use Cases - Dual Analysis Paths: Derives domain knowledge from an existing knowledge graph (cheap, no file scanning) or performs a lightweight scan of the file tree, entry points, and file signatures when no graph exists. - Entry Point Detection: The bundled Python scanner detects HTTP routes, CLI commands, event handlers, cron jobs, GraphQL resolvers, and gRPC services across many languages. - Dashboard Visualization: Saves a validated domain-graph.json and auto-launches the dashboard to display the domain view. - Use Case: Onboard onto a legacy monorepo by running the skill to generate a domain flow graph showing how business processes connect across services, without reading every file. ## Quick Start Ask the AI to run the understand-domain skill on the current project to extract business domains and visualize them in the dashboard.

Frequently Asked Questions about understand-domain

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

FAQPage Schema
How do I extract business domain knowledge from a codebase?▼

Run the understand-domain skill on the project root. It either derives domains from an existing knowledge graph or performs a lightweight scan of the file tree, entry points, and file signatures, then produces a domain-graph.json visualized in a dashboard.

What entry points does the domain scanner detect?▼

The scanner detects HTTP routes (Express, Flask, FastAPI, Next.js), CLI commands, event listeners, cron schedules, GraphQL resolvers, gRPC services, and exported handler functions across languages including TypeScript, Python, Go, Rust, and Java.

Does understand-domain work without an existing knowledge graph?▼

Yes. When no knowledge-graph.json exists, it runs a lightweight Python scan that builds a domain-context.json from the file tree, entry points, and metadata. Use the --full flag to force a fresh scan even when a graph exists.

Why does the skill redirect output when running in a git worktree?▼

Worktrees managed by Claude Code are ephemeral, so output written there is destroyed when the session ends. The skill detects worktrees by comparing git-dir and git-common-dir and redirects output to the main repository root.

What are the limitations of the lightweight codebase scan?▼

The scan samples at most 40 files, 200 entry points, and 80 lines per file, capping output at 512 KB. Very large or unusual codebases may have incomplete coverage, and test files are excluded from entry point detection.