--- name: mobius-architecture-draw description: Analyze a Mobius project repository and generate a single-file HTML/SVG architecture diagram at .imac/generated_figures/arch.html, with optional image fallbacks. --- # Mobius Architecture Diagram Generator This is a Mobius built-in Skill. Do not ask the user to install or invoke Codex Skills, Claude Code Skills, or any assistant-side Memory/Skill system. Use only the project files and the Mobius context injected into the current Session. ## Goal Analyze the current project workspace and generate a polished architecture diagram as a self-contained file: - Primary output: `.imac/generated_figures/arch.html` - Optional fallback previews: `.imac/generated_figures/arch.svg`, `.imac/generated_figures/arch.png`, or `.imac/generated_figures/arch.jpg` The HTML file must contain embedded CSS and an embedded SVG diagram. It should open directly in a browser and should not require any build step, package install, external JavaScript, CDN, web font, or image generation service. ## Required Workflow 1. Inspect the repository before drawing. - Read `README*`, package manifests, config files, backend/frontend entry points, extension manifests, and key service/router/component files. - Prefer `rg --files`, `find` with bounded depth, and direct file reads. - Ignore noisy generated folders such as `.git`, `.imac/flags`, `.imac/generated_figures`, `node_modules`, `dist`, `build`, `coverage`, `.next`, `.nuxt`, `target`, `vendor`, and large asset directories. 2. Build a concise architecture model. - Identify user-facing entry points. - Identify frontend modules, backend routes/services, data stores, workers, external integrations, queues, caches, and generated artifacts. - Group related files into 5-10 meaningful components. Do not draw every file. - Add the most important data/control flows only. Prefer readable diagrams over exhaustive diagrams. 3. Generate `.imac/generated_figures/arch.html`. - Create the output directory if it does not exist. - Write valid UTF-8 HTML with inline CSS and inline SVG. - No `