code-to-diagram
仓库创建 2025年6月22日最近提交 1 天前SkillHot 收录 20 天前
▸ 精选理由
快速将复杂代码库可视化,便于理解模块与调用关系。
▸ 风险提示
需要访问代码库文件,可能暴露敏感信息。
这个 Skill 做什么
解析代码依赖并自动生成架构、流程与层级图。
自动解析代码里的依赖关系并画出架构图、流程图或目录层级图,支持通过 AST 理解 Python、JS/TS、Go、Java 的 import 调用链。想把代码库的模块关系、调用流程或文件结构可视化时派上用场,输出 Mermaid 或 SVG,方便嵌入文档或进一步编辑。
▸ 展开 SKILL.md 英文原文
Analyze codebases and automatically generate architecture diagrams, flowcharts, and org charts. Uses AST parsing to map import dependencies for Python, JS/TS, Go, and Java, outputting Mermaid or SVG files. Triggered when users ask to visualize code architecture, understand dependencies, draw a flowchart, or create a module diagram from source code.
4.4k
Stars
448
Forks
40
仓库内 Skill
+70
7 日增星
安装 / 使用
给你的 Agent 一句话(通用)
帮我安装这个 skill:https://raw.githubusercontent.com/zebbern/claude-code-guide/main/skills/code-to-diagram/SKILL.md或 curl 直取 SKILL.md
curl -fsSL "https://raw.githubusercontent.com/zebbern/claude-code-guide/main/skills/code-to-diagram/SKILL.md"SKILL.MD 节选查看完整文件 ↗
# Code to Diagram Extract import and dependency relationships from a codebase via AST parsing, and automatically generate three types of diagrams: 1. **Architecture Diagram** — Module/directory-level dependency relationships 2. **Flowchart** — File-level import call chains 3. **Org Chart** — Directory/file hierarchy structure Supported languages: Python, JavaScript, TypeScript, Go, Java Output formats: Mermaid text (`.mmd`) or SVG images (requires `mmdc` installed on the system) ## Usage ### Basic: Analyze an Entire Project ```bash python3 scripts/analyze_codebase.py /path/to/project ``` Outputs three Mermaid diagrams to stdout and writes `.mmd` files to the current directory. ### S
via SKILL·HOT · 数据来自 GitHub 公开信息 · 原文版权归作者所有