mulchMulch Self Improver — Let your agents grow 🌱. Captures learnings with Mulch so expertise compounds across sessions. Use when: command/tool fails, user corre...
Install via ClawdBot CLI:
clawdbot install RuneweaverStudios/mulchGenerate self-contained HTML files for technical diagrams, visualizations, and data tables. Always open the result in the browser. Never fall back to ASCII art when this skill is loaded.
Proactive table rendering. When you're about to present tabular data as an ASCII box-drawing table in the terminal (comparisons, audits, feature matrices, status reports, any structured rows/columns), generate an HTML page instead. The threshold: if the table has 4+ rows or 3+ columns, it belongs in the browser. Don't wait for the user to ask — render it as HTML automatically and tell them the file path. You can still include a brief text summary in the chat, but the table itself should be the HTML page.
Before writing HTML, commit to a direction. Don't default to "dark theme with blue accents" every time.
Who is looking? A developer understanding a system? A PM seeing the big picture? A team reviewing a proposal? This shapes information density and visual complexity.
What type of diagram? Architecture, flowchart, sequence, data flow, schema/ER, state machine, mind map, data table, timeline, or dashboard. Each has distinct layout needs and rendering approaches (see Diagram Types below).
What aesthetic? Pick one and commit:
handDrawn mode, wiggly lines, informal whiteboard feel)Vary the choice each time. If the last diagram was dark and technical, make the next one light and editorial. The swap test: if you replaced your styling with a generic dark theme and nobody would notice the difference, you haven't designed anything.
Read the reference template before generating. Don't memorize it — read it each time to absorb the patterns.
./templates/architecture.html./templates/mermaid-flowchart.html./templates/data-table.htmlFor CSS/layout patterns and SVG connectors, read ./references/css-patterns.md.
For pages with 4+ sections (reviews, recaps, dashboards), also read ./references/responsive-nav.md for section navigation with sticky sidebar TOC on desktop and horizontal scrollable bar on mobile.
Choosing a rendering approach:
| Diagram type | Approach | Why |
|---|---|---|
| Architecture (text-heavy) | CSS Grid cards + flow arrows | Rich card content (descriptions, code, tool lists) needs CSS control |
| Architecture (topology-focused) | Mermaid | Visible connections between components need automatic edge routing |
| Flowchart / pipeline | Mermaid | Automatic node positioning and edge routing; hand-drawn mode available |
| Sequence diagram | Mermaid | Lifelines, messages, and activation boxes need automatic layout |
| Data flow | Mermaid with edge labels | Connections and data descriptions need automatic edge routing |
| ER / schema diagram | Mermaid | Relationship lines between many entities need auto-routing |
| State machine | Mermaid | State transitions with labeled edges need automatic layout |
| Mind map | Mermaid | Hierarchical branching needs automatic positioning |
| Data table | HTML | Timeline | CSS (central line + cards) | Simple linear layout doesn't need a layout engine | | Dashboard | CSS Grid + Chart.js | Card grid with embedded charts | Mermaid theming: Always use Mermaid zoom controls: Always add zoom controls (+/−/reset buttons) to every AI-generated illustrations (optional). If surf-cli is available, you can generate images via Gemini and embed them in the page for creative, illustrative, explanatory, educational, or decorative purposes. Check availability with See When to use: Hero banners that establish the page's visual tone. Conceptual illustrations for abstract systems that Mermaid can't express (physical infrastructure, user journeys, mental models). Educational diagrams that benefit from artistic or photorealistic rendering. Decorative accents that reinforce the aesthetic. When to skip: Anything Mermaid or CSS handles well. Generic decoration that doesn't convey meaning. Data-heavy pages where images would distract. Always degrade gracefully — if surf isn't available, skip images without erroring. The page should stand on its own with CSS and typography alone. Prompt craft: Match the image to the page's palette and aesthetic direction. Specify the style (3D render, technical illustration, watercolor, isometric, flat vector, etc.) and mention dominant colors from your CSS variables. Use Apply these principles to every diagram: Typography is the diagram. Pick a distinctive font pairing from Google Fonts. A display/heading font with character, plus a mono font for technical labels. Never use Inter, Roboto, Arial, or system-ui as the primary font. Load via Color tells a story. Use CSS custom properties for the full palette. Define at minimum: Surfaces whisper, they don't shout. Build depth through subtle lightness shifts (2-4% between levels), not dramatic color changes. Borders should be low-opacity rgba ( Backgrounds create atmosphere. Don't use flat solid colors for the page background. Subtle gradients, faint grid patterns via CSS, or gentle radial glows behind focal areas. The background should feel like a space, not a void. Visual weight signals importance. Not every section deserves equal visual treatment. Executive summaries and key metrics should dominate the viewport on load (larger type, more padding, subtle accent-tinted background zone). Reference sections (file maps, dependency lists, decision logs) should be compact and stay out of the way. Use Surface depth creates hierarchy. Vary card depth to signal what matters. Hero sections get elevated shadows and accent-tinted backgrounds ( Animation earns its place. Staggered fade-ins on page load are almost always worth it — they guide the eye through the diagram's hierarchy. Mix animation types by role: Output location: Write to Open in browser: Tell the user the file path so they can re-open or share it. Two approaches depending on what matters more: Text-heavy overviews (card content matters more than connections): CSS Grid with explicit row/column placement. Sections as rounded cards with colored borders and monospace labels. Vertical flow arrows between sections. Nested grids for subsystems. The reference template at Topology-focused diagrams (connections matter more than card content): Use Mermaid. A Use Mermaid. Automatic node positioning and edge routing produces proper diagrams with connecting lines, decision diamonds, and parallel branches — dramatically better than CSS flexbox with arrow characters. Use Use Mermaid. Lifelines, messages, activation boxes, notes, and loops all need automatic layout. Use Mermaid's Use Mermaid. Data flow diagrams emphasize connections over boxes — exactly what Mermaid excels at. Use Use Mermaid. Relationship lines between entities need automatic routing. Use Mermaid's Use Mermaid. Use Use Mermaid. Use Use a real Use proactively. Any time you'd render an ASCII box-drawing table in the terminal, generate an HTML table instead. This includes: requirement audits (request vs plan), feature comparisons, status reports, configuration matrices, test result summaries, dependency lists, permission tables, API endpoint inventories — any structured rows and columns. Layout patterns: Status indicators (use styled Cell content: Vertical or horizontal timeline with a central line (CSS pseudo-element). Phase markers as circles on the line. Content cards branching left/right (alternating) or all to one side. Date labels on the line. Color progression from past (muted) to future (vivid). Card grid layout. Hero numbers large and prominent. Sparklines via inline SVG Every diagram is a single self-contained Before delivering, verify: Generated Mar 1, 2026 A development team needs to visualize a new microservices architecture before implementation. The skill generates an HTML page with Mermaid diagrams showing component connections, data flow, and deployment topology, using a blueprint aesthetic for technical clarity. A project manager requests a visual overview of a product roadmap with timelines and milestones. The skill creates an HTML dashboard with CSS-based timeline cards and Chart.js graphs, styled in an editorial theme for stakeholder presentations. During a code review, a developer asks for a visual comparison of changes between two versions. The skill proactively renders an HTML data table with styled rows and columns, using a monochrome terminal aesthetic for readability, instead of ASCII art. A data engineer needs to document ETL pipelines for a new data warehouse. The skill generates an HTML page with Mermaid sequence diagrams and data flow charts, applying a gradient mesh aesthetic for a modern, engaging look. An instructor wants to create interactive learning materials for a computer science course. The skill produces HTML pages with hand-drawn Mermaid mind maps and embedded AI-generated illustrations via surf-cli, using a paper/ink aesthetic for a friendly feel. Offer a free tier for basic HTML generation with limited themes and templates, and a paid subscription for advanced features like AI image integration, custom branding, and priority support. Revenue comes from monthly or annual subscriptions. License the skill to large organizations for internal use in documentation, training, and project management. Provide custom integrations, dedicated support, and compliance features. Revenue is generated through one-time licenses or annual contracts. Offer services to tailor the skill for specific client needs, such as creating custom templates, integrating with proprietary systems, or developing bespoke visualizations. Revenue comes from project-based fees or hourly rates. 💬 Integration Tip Ensure the AI agent has access to a browser for viewing HTML files and consider installing surf-cli for optional image generation to enhance visual appeal. Captures learnings, errors, and corrections to enable continuous improvement. Use when: (1) A command or operation fails unexpectedly, (2) User corrects Clau... Helps users discover and install agent skills when they ask questions like "how do I do X", "find a skill for X", "is there a skill that can...", or express interest in extending capabilities. This skill should be used when the user is looking for functionality that might exist as an installable skill. Search and analyze your own session logs (older/parent conversations) using jq. Typed knowledge graph for structured agent memory and composable skills. Use when creating/querying entities (Person, Project, Task, Event, Document), linking related objects, enforcing constraints, planning multi-step actions as graph transformations, or when skills need to share state. Trigger on "remember", "what do I know about", "link X to Y", "show dependencies", entity CRUD, or cross-skill data access. Ultimate AI agent memory system for Cursor, Claude, ChatGPT & Copilot. WAL protocol + vector search + git-notes + cloud backup. Never lose context again. Vibe-coding ready. Headless browser automation CLI optimized for AI agents with accessibility tree snapshots and ref-based element selection | Semantic markup, accessibility, copy-paste behavior |
theme: 'base' with custom themeVariables so colors match your page palette. Use look: 'handDrawn' for sketch aesthetic or look: 'classic' for clean lines. Use layout: 'elk' for complex graphs (requires the @mermaid-js/layout-elk package — see ./references/libraries.md for the CDN import). Override Mermaid's SVG classes with CSS for pixel-perfect control. See ./references/libraries.md for full theming guide.
.mermaid-wrap container. Complex diagrams render at small sizes and need zoom to be readable. Include Ctrl/Cmd+scroll zoom on the container. See the zoom controls pattern in ./references/css-patterns.md and the reference template at ./templates/mermaid-flowchart.html.
which surf. If available:
# Generate to a temp file (use --aspect-ratio for control)
surf gemini "descriptive prompt" --generate-image /tmp/ve-img.png --aspect-ratio 16:9
# Base64 encode for self-containment (macOS)
IMG=$(base64 -i /tmp/ve-img.png)
# Linux: IMG=$(base64 -w 0 /tmp/ve-img.png)
# Embed in HTML and clean up
# <img src="data:image/png;base64,${IMG}" alt="descriptive alt text">
rm /tmp/ve-img.png
./references/css-patterns.md for image container styles (hero banners, inline illustrations, captions).
--aspect-ratio 16:9 for hero banners, --aspect-ratio 1:1 for inline illustrations. Keep prompts specific — "isometric illustration of a message queue with cyan nodes on dark navy background" beats "a diagram of a queue."
3. Style
in . Include a system font fallback in the font-family stack for offline resilience.
--bg, --surface, --border, --text, --text-dim, and 3-5 accent colors. Each accent should have a full and a dim variant (for backgrounds). Name variables semantically when possible (--pipeline-step not --blue-3). Support both themes. Put your primary aesthetic in :root and the alternate in the media query:
/* Light-first (editorial, paper/ink, blueprint): */
:root { /* light values */ }
@media (prefers-color-scheme: dark) { :root { /* dark values */ } }
/* Dark-first (neon, IDE-inspired, terminal): */
:root { /* dark values */ }
@media (prefers-color-scheme: light) { :root { /* light values */ } }
rgba(255,255,255,0.08) in dark mode, rgba(0,0,0,0.08) in light) — visible when you look, invisible when you don't.
for sections that are useful but not primary — the collapsible pattern is in ./references/css-patterns.md.
node--hero pattern). Body content stays flat (default .node). Code blocks and secondary content feel recessed (node--recessed). See the depth tiers in ./references/css-patterns.md. Don't make everything elevated — when everything pops, nothing does.
fadeUp for cards, fadeScale for KPIs and badges, drawIn for SVG connectors, countUp for hero numbers. Hover transitions on interactive-feeling elements make the diagram feel alive. Always respect prefers-reduced-motion. CSS transitions and keyframes handle most cases. For orchestrated multi-element sequences, anime.js via CDN is available (see ./references/libraries.md).
4. Deliver
~/.agent/diagrams/. Use a descriptive filename based on content: modem-architecture.html, pipeline-flow.html, schema-overview.html. The directory persists across sessions.
open ~/.agent/diagrams/filename.htmlxdg-open ~/.agent/diagrams/filename.html
Diagram Types
Architecture / System Diagrams
./templates/architecture.html demonstrates this pattern. Use when cards need descriptions, code references, tool lists, or other rich content that Mermaid nodes can't hold.
graph TD or graph LR with custom themeVariables produces proper diagrams with automatic edge routing. Use look: 'handDrawn' for informal feel or look: 'classic' for clean lines. Use when the point is showing how components connect rather than describing what each component does in detail.
Flowcharts / Pipelines
graph TD for top-down or graph LR for left-right. Use look: 'handDrawn' for sketch aesthetic. Color-code node types with Mermaid's classDef or rely on themeVariables for automatic styling.
Sequence Diagrams
sequenceDiagram syntax. Style actors and messages via CSS overrides on .actor, .messageText, .activation classes.
Data Flow Diagrams
graph LR or graph TD with edge labels for data descriptions. Thicker, colored edges for primary flows. Source/sink nodes styled differently from transform nodes via Mermaid's classDef.
Schema / ER Diagrams
erDiagram syntax with entity attributes. Style via themeVariables and CSS overrides on .er.entityBox and .er.relationshipLine.
State Machines / Decision Trees
stateDiagram-v2 for states with labeled transitions. Supports nested states, forks, joins, and notes. Use look: 'handDrawn' for informal state diagrams. Decision trees can use graph TD with diamond decision nodes.
stateDiagram-v2 label caveat: Transition labels have a strict parser — colons, parentheses, , HTML entities, and most special characters cause silent parse failures ("Syntax error in text"). If your labels need any of these (e.g., cancel(), curate: true, multi-line labels), use flowchart LR instead with rounded nodes and quoted edge labels (|"label text"|). Flowcharts handle all special characters and support for line breaks. Reserve stateDiagram-v2 for simple single-word or plain-text labels.
Mind Maps / Hierarchical Breakdowns
mindmap syntax for hierarchical branching from a root node. Mermaid handles the radial layout automatically. Style with themeVariables to control node colors at each depth level.
Data Tables / Comparisons / Audits
element — not CSS Grid pretending to be a table. Tables get accessibility, copy-paste behavior, and column alignment for free. The reference template at
./templates/data-table.html demonstrates all patterns below.
so headers stay visible when scrolling long tables
tr:nth-child(even) (subtle, 2-3% lightness shift)overflow-x: auto for tables wider than the viewport or th widths — let text-heavy columns breathe
elements, never emoji):
for technical references within cells with dimmed colortabular-nums
Timeline / Roadmap Views
Dashboard / Metrics Overview
. Progress bars via CSS linear-gradient on a div. For real charts (bar, line, pie), use Chart.js via CDN (see ./references/libraries.md). KPI cards with trend indicators (up/down arrows, percentage deltas).
File Structure
.html file. No external assets except CDN links (fonts, optional libraries). Structure:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Descriptive Title</title>
<link href="https://fonts.googleapis.com/css2?family=...&display=swap" rel="stylesheet">
<style>
/* CSS custom properties, theme, layout, components — all inline */
</style>
</head>
<body>
<!-- Semantic HTML: sections, headings, lists, tables, inline SVG -->
<!-- No script needed for static CSS-only diagrams -->
<!-- Optional: <script> for Mermaid, Chart.js, or anime.js when used -->
</body>
</html>
Quality Checks
min-width: 0. Side-by-side panels need overflow-wrap: break-word. Never use display: flex on for marker characters — it creates anonymous flex items that can't shrink, causing lines with many inline badges to overflow. Use absolute positioning for markers instead. See the Overflow Protection section in ./references/css-patterns.md..mermaid-wrap container must have zoom controls (+/−/reset buttons), Ctrl/Cmd+scroll zoom, and click-and-drag panning. Complex diagrams render too small without them. The cursor should change to grab when zoomed in and grabbing while dragging. See ./references/css-patterns.md for the full pattern.AI Usage Analysis
💡 Application Scenarios
💼 Business Models
More Agent Frameworks Skills
View all →