mermaid-architectlisted
Install: claude install-skill aksh-3141/claude-toolshed
# /mermaid-architect
User request: "$ARGUMENTS"
## Task
Analyze a codebase or project path and generate a relevant suite of Mermaid diagrams (typically 3-5 types based on what's found).
## Difference from /mermaid-diagram
- `/mermaid-diagram` generates **one diagram** from a **text description**
- `/mermaid-architect` generates **multiple diagrams** from **actual code/files** at a given path
## Process
### Step 1: Resolve Plugin Path
```bash
find "$HOME/.claude/plugins/cache" -type d -name "mermaid" -path "*/skills/mermaid" 2>/dev/null | head -1
```
If empty:
```bash
find "$HOME" -maxdepth 8 -type d -name "mermaid" -path "*/skills/mermaid" 2>/dev/null | head -1
```
### Step 2: Ensure Dependencies
```bash
bash "$PLUGIN_DIR/scripts/ensure-deps.sh"
```
If `.claude/mermaid.json` does **not** exist, display a one-time nudge before continuing:
> First time using the mermaid plugin? Run `/mermaid-config` to pick a theme and output settings. Using defaults for now (zinc-light, `./diagrams`).
### Step 3: Read Config
If `.claude/mermaid.json` exists, read `output_directory`, `theme`, `auto_validate`, `auto_render`.
**Resolve output path:**
- If `output_directory` is `"same"` AND an input path is known:
`OUTPUT_DIR=$(dirname {input_file})` (for a directory argument, use the directory itself)
- If `output_directory` is `"same"` AND no argument was provided:
`OUTPUT_DIR=./diagrams`
- Otherwise:
`OUTPUT_DIR=<output_directory from config>`
### Theme-First Rule
Resp