update-diagram

Updates existing diagram files to match the current state of the codebase.

Updated Dec 18, 2025
One-click install
npx skills add https://github.com/l0lxl0lw/dotfiles --skill update-diagram-l0lxl0lw
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: update-diagram
Source: https://github.com/l0lxl0lw/dotfiles/tree/main/ai/shared/skills/utilities/update-diagram
Command: npx skills add https://github.com/l0lxl0lw/dotfiles --skill update-diagram-l0lxl0lw

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Code changes constantly, but architecture, schema, and flow diagrams quickly become stale and misleading. This Skill scans the codebase and incrementally updates existing diagram files so documentation stays accurate without manual redrawing. ## Core Features & Use Cases - Diagram Discovery: Finds all files matching *diagram.md or *diagrams.md and identifies their type (architecture, database schema, call flow, component, API) and format (Mermaid, ASCII art, PlantUML, tables). - Codebase Diff Analysis: Compares documented entities against actual code to detect added, removed, or renamed components, tables, endpoints, and relationships. - Incremental Updates: Preserves existing format, styling, and naming conventions while adding or removing elements, including ASCII art alignment verification. - Use Case: After refactoring a service and adding a new database table, run this Skill to refresh all architecture and schema diagrams so they reflect the new code structure. ## Quick Start Scan this repository and update all existing diagram files to reflect the current codebase.

Frequently Asked Questions about update-diagram

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

FAQPage Schema
How do I update architecture diagrams after code changes?

Run this Skill to scan the codebase and refresh all diagram files matching *diagram.md or *diagrams.md. It detects added, removed, or renamed components and updates each diagram incrementally while preserving the original format and styling.

What diagram formats does this Skill support?

It supports Mermaid, ASCII art, markdown tables, and PlantUML diagrams stored in markdown files. The Skill detects the format of each file and always preserves it rather than converting between formats.

Can it create new diagrams if none exist?

No. The Skill only updates existing diagram files. If no files matching *diagram.md or *diagrams.md are found, it informs the user and does not create new diagrams.

Does it handle ASCII art diagram alignment?

Yes. After editing ASCII diagrams, it verifies that vertical bars align in columns, box borders connect properly, and text does not overflow cell boundaries, adjusting spacing as needed.

Will it remove diagram elements that no longer exist in code?

Yes, but conservatively. It removes elements only when they truly no longer exist in the codebase, and it never replaces entire diagrams—updates are always incremental to preserve existing structure.