Generate an architecture map with mermaid diagram
Generates comprehensive architecture documentation with mermaid diagrams in ARCHITECTURE/ directory.
/plugin marketplace add noodlbox/noodlbox-claude-plugin/plugin install noodlbox@noodlboxrepositoryCreate comprehensive architecture documentation in ARCHITECTURE/ directory with a main README and individual process files.
Look for .noodlbox/labels.json in the repository:
/noodlbox:init first, or proceed with auto-generated namesRead the map resource:
@noodlbox:map://$ARGUMENTS
Check stats.communities to determine approach:
| Communities | Strategy |
|---|---|
| < 10 | Generate inline - full exploration |
| >= 10 | Spawn codebase-analyst agent for isolated exploration |
Generate directly:
@noodlbox:map://$ARGUMENTS/community/{id}Spawn the codebase-analyst agent:
Task: map_generation for $ARGUMENTS
Input: Map overview and labels (if available)
Output: Structured JSON with modules, processes, cross-flows
The agent handles scale-appropriate exploration and returns summaries.
Create ARCHITECTURE/ in repository root with this structure:
ARCHITECTURE/
├── README.md # Main overview
├── {process-slug}.md # One file per key process
└── ...
# Architecture Overview
## Summary
[Brief description based on community labels and key symbols]
## Stats
- **Communities**: X modules
- **Symbols**: X functions, classes, etc.
- **Processes**: X execution flows
## Modules
### [Community Label]
**Purpose**: [Description from labels or inferred]
**Key Symbols**: Symbol1, Symbol2, Symbol3
**Cohesion**: X.XX
[Repeat for each major community]
## Data Flows
| From | To | Calls | Description |
|------|-----|-------|-------------|
| Module A | Module B | 47 | [What this flow does] |
## Key Processes
| Process | Entry Point | Description |
|---------|-------------|-------------|
| [Label](./process-slug.md) | FunctionName | Brief description |
## Architecture Diagram
```mermaid
graph TB
subgraph Auth["Authentication System"]
login[login]
validate[validateToken]
end
subgraph Payment["Payment Processing"]
checkout[checkout]
process[processPayment]
end
Auth -->|47 calls| Payment
### Process Files
Each `{process-slug}.md` contains:
```markdown
# [Process Label]
**Entry Point**: `FunctionName` in `src/path/to/file.ts:42`
## Description
[Description from labels or inferred from symbols]
## Execution Trace
1. `EntryPoint` (src/file.ts:42) - What this step does
2. `Step2` (src/other.ts:15) - What this step does
3. `Step3` (src/another.ts:88) - What this step does
## Cross-Community Connections
- Calls into: [Other Module]
- Called from: [Another Module]
## Related Processes
- [Related Process 1](./related-1.md)
- [Related Process 2](./related-2.md)
Naming: Slugify labels (e.g., "User Login Flow" → user-login-flow.md)
-->|47 calls|graph TB for top-to-bottom layoutConfirm completion with: