charts-flow
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
Chinesecharts-flow
charts-flow
Purpose
用途
The skill automates creation and management of Mermaid diagrams for technical documentation. It separates diagram source files from main documents to improve rendering performance, provides automatic SVG conversion for human viewing, and maintains traceability between parent documents and diagram files.
charts-flowKey Benefits:
- Performance: Separate diagram files load faster in documentation viewers
- Dual Format: Mermaid source for AI assistants, SVG preview for humans
- Traceability: Diagrams linked to parent documents with proper ID naming
- Migration: Extract existing inline diagrams to separate files
- Consistency: Standardized diagram file structure and metadata
charts-flow核心优势:
- 性能: 独立的图表文件在文档查看器中加载速度更快
- 双格式: Mermaid源码供AI助手使用,SVG预览供人类查看
- 可追溯性: 通过规范的ID命名将图表与父文档关联
- 迁移: 将现有内嵌图表提取到独立文件中
- 一致性: 标准化的图表文件结构和元数据
When to Use This Skill
何时使用本技能
Use charts-flow when:
- Creating architecture diagrams for PRD, BRD, ADR, SYS, or other technical documents
- Migrating existing inline Mermaid diagrams to separate files
- Main document becomes slow to render due to complex diagrams
- Diagram needs to be reused across multiple documents
- Creating flowcharts, component diagrams, deployment diagrams, sequence diagrams, state machines, or class diagrams
Do NOT use charts-flow when:
- Creating simple tables or text-based lists (use markdown)
- Diagram is < 20 lines and main document renders fast
- Creating data visualization charts (use appropriate charting libraries)
- Working with non-architecture diagrams (Gantt, pie charts - outside scope)
在以下场景使用charts-flow:
- 为PRD、BRD、ADR、SYS或其他技术文档创建架构图
- 将现有内嵌Mermaid图表迁移到独立文件
- 主文档因复杂图表导致渲染缓慢
- 图表需要在多个文档中复用
- 创建流程图、组件图、部署图、序列图、状态机图或类图
请勿在以下场景使用charts-flow:
- 创建简单表格或基于文本的列表(使用Markdown即可)
- 图表少于20行且主文档渲染速度快
- 创建数据可视化图表(使用专用图表库)
- 处理非架构类图表(甘特图、饼图不在支持范围内)
Skill Inputs
技能输入参数
Required Inputs
必填输入参数
| Input | Description | Example |
|---|---|---|
| Parent File Path | Absolute path to main document | |
| Diagram Description | Short name for diagram | |
| Diagram Type | Architecture diagram type | |
| 输入项 | 说明 | 示例 |
|---|---|---|
| 父文档路径 | 主文档的绝对路径 | |
| 图表描述 | 图表的简短名称 | |
| 图表类型 | 架构图类型 | |
Optional Inputs
可选输入参数
| Input | Description | Default |
|---|---|---|
| Migration Mode | Extract existing diagrams from document | |
| Diagram Title | Human-readable title | Derived from description |
| Styling Preferences | Color scheme, layout direction | Project defaults |
| 输入项 | 说明 | 默认值 |
|---|---|---|
| 迁移模式 | 从文档中提取现有图表 | |
| 图表标题 | 人类可读的图表标题 | 从图表描述自动生成 |
| 样式偏好 | 配色方案、布局方向 | 项目默认配置 |
Skill Workflow
技能工作流
Mode 1: Create New Diagram
模式1:创建新图表
Step 1: Parse Parent Document
- Extract parent document ID from filename (e.g., from
PRD-01)PRD-01_multi_agent_system_architecture.md - Identify parent document type (PRD, BRD, ADR, SYS, etc.)
- Determine correct subfolder location
diagrams/
Step 2: Generate Diagram File Path
- Format:
{parent_folder}/diagrams/{PARENT-ID}-diag_{description}.md - The subfolder is created in the same directory as the parent document
diagrams/ - Examples by document type:
- BRD:
docs/BRD/diagrams/BRD-01-diag_workflow.md - PRD:
docs/PRD/diagrams/PRD-01-diag_3_tier_agent_hierarchy.md - ADR:
docs/ADR/diagrams/ADR-005-diag_cloud_deployment.md - SYS:
docs/SYS/diagrams/SYS-002-diag_data_flow.md - IMPL:
docs/IMPL/diagrams/IMPL-010-diag_implementation_phases.md
- BRD:
- Create folder if it doesn't exist
diagrams/
Step 3: Create Diagram File
- Use diagram file template (see Templates section below)
- Include Document Control section linking to parent
- Add diagram type metadata
- Create Mermaid code block with syntax appropriate for diagram type
Step 4: Generate SVG
- Attempt CLI conversion:
mmdcmmdc -i diagram.md -o diagram.svg - Fallback: Use Mermaid Live API if CLI unavailable
- Validate SVG output (check for errors, size < 1MB)
Step 5: Encode SVG as Base64
- Read generated SVG file
- Convert to Base64 string
- Prepare data URI:
data:image/svg+xml;base64,{BASE64_STRING}
Step 6: Update Parent Document
- Add reference link to diagram file
- Embed Base64 SVG in collapsible block
<details> - Place in appropriate section of parent document
Step 7: Validate
- Verify diagram file exists and is readable
- Check Mermaid syntax validity
- Confirm SVG renders correctly
- Validate cross-references resolve
步骤1:解析父文档
- 从文件名中提取父文档ID(例如从中提取
PRD-01_multi_agent_system_architecture.md)PRD-01 - 识别父文档类型(PRD、BRD、ADR、SYS等)
- 确定正确的子文件夹位置
diagrams/
步骤2:生成图表文件路径
- 格式:
{parent_folder}/diagrams/{PARENT-ID}-diag_{description}.md - 子文件夹与父文档位于同一目录
diagrams/ - 按文档类型划分的示例:
- BRD:
docs/BRD/diagrams/BRD-01-diag_workflow.md - PRD:
docs/PRD/diagrams/PRD-01-diag_3_tier_agent_hierarchy.md - ADR:
docs/ADR/diagrams/ADR-005-diag_cloud_deployment.md - SYS:
docs/SYS/diagrams/SYS-002-diag_data_flow.md - IMPL:
docs/IMPL/diagrams/IMPL-010-diag_implementation_phases.md
- BRD:
- 如果文件夹不存在则自动创建
diagrams/
步骤3:创建图表文件
- 使用图表文件模板(见下方模板章节)
- 包含指向父文档的文档控制章节
- 添加图表类型元数据
- 创建符合图表类型语法的Mermaid代码块
步骤4:生成SVG
- 尝试使用CLI转换:
mmdcmmdc -i diagram.md -o diagram.svg - 备选方案:如果CLI不可用,使用Mermaid Live API
- 验证SVG输出(检查错误,文件大小<1MB)
步骤5:将SVG编码为Base64
- 读取生成的SVG文件
- 转换为Base64字符串
- 准备数据URI:
data:image/svg+xml;base64,{BASE64_STRING}
步骤6:更新父文档
- 添加指向图表文件的引用链接
- 在可折叠的块中嵌入Base64格式的SVG
<details> - 将内容插入父文档的对应章节
步骤7:验证
- 验证图表文件存在且可读取
- 检查Mermaid语法有效性
- 确认SVG可正常渲染
- 验证交叉引用可正常解析
Mode 2: Migrate Existing Diagrams
模式2:迁移现有图表
Step 1: Scan Parent Document
- Search for ````mermaid` code blocks
- Extract each diagram with surrounding context
- Preserve diagram content and styling
Step 2: Create Diagram Files
- For each extracted diagram, follow Steps 1-4 from Mode 1
- Auto-generate description from diagram content or context
- Number multiple diagrams: ,
_diagram_1, etc._diagram_2
Step 3: Replace in Parent Document
- Remove original ````mermaid` blocks
- Insert SVG + reference link in same location
- Maintain document flow and readability
Step 4: Validate Migration
- Confirm all diagrams extracted
- Verify no broken references
- Check visual fidelity (SVG matches original Mermaid)
步骤1:扫描父文档
- 搜索````mermaid`代码块
- 提取每个图表及其上下文
- 保留图表内容和样式
步骤2:创建图表文件
- 对每个提取的图表,遵循模式1中的步骤1-4
- 从图表内容或上下文自动生成描述
- 对多个图表进行编号:,
_diagram_1等_diagram_2
步骤3:替换父文档内容
- 删除原始的````mermaid`块
- 在同一位置插入SVG和引用链接
- 保持文档的流程和可读性
步骤4:验证迁移结果
- 确认所有图表已提取
- 验证无无效引用
- 检查视觉一致性(SVG与原始Mermaid图表一致)
Templates
模板
Diagram File Template
图表文件模板
markdown
undefinedmarkdown
undefined{PARENT-ID}-diag: {Diagram Title}
{PARENT-ID}-diag: {图表标题}
Document Control
文档控制
| Item | Details |
|---|---|
| Diagram ID | {PARENT-ID}-diag |
| Parent Document | {PARENT-ID}: {Parent Title} |
| Diagram Type | {flowchart |
| Status | Active |
| Version | 1.0.0 |
| Created | {YYYY-MM-DD} |
| Last Updated | {YYYY-MM-DD} |
| Maintained By | {Role} |
| 项 | 详情 |
|---|---|
| 图表ID | {PARENT-ID}-diag |
| 父文档 | {PARENT-ID}: {父文档标题} |
| 图表类型 | {flowchart |
| 状态 | 活跃 |
| 版本 | 1.0.0 |
| 创建时间 | {YYYY-MM-DD} |
| 最后更新时间 | {YYYY-MM-DD} |
| 维护人 | {角色} |
Overview
概述
{Brief description of what this diagram represents}
{本图表的简要说明}
{Diagram Title}
{图表标题}
mermaid
{Mermaid diagram code}mermaid
{Mermaid图表代码}Diagram Description
图表说明
{Detailed explanation of diagram elements, flows, and purpose}
{图表元素、流程和用途的详细解释}
Key Elements
核心元素
{List or table of important nodes, components, actors, states, or flows}
{重要节点、组件、参与者、状态或流程的列表或表格}
References
参考资料
- Parent Document: {PARENT-ID}: {Parent Title}
- Related Diagrams: {Links to related diagram files if applicable}
- Related Documents: {Links to related requirements, ADRs, strategy docs}
Diagram Version: 1.0.0
Created: {YYYY-MM-DD}
Maintained By: {Role}
undefined- 父文档: {PARENT-ID}: {父文档标题}
- 相关图表: {相关图表文件链接(如有)}
- 相关文档: {相关需求、ADR、战略文档的链接}
图表版本: 1.0.0
创建时间: {YYYY-MM-DD}
维护人: {角色}
undefinedParent Document Reference Template
父文档引用模板
markdown
**Visual Diagram**: [{PARENT-ID}-diag: {Diagram Title}](diagrams/{PARENT-ID}-diag_{description}.md)
<details>
<summary>View Diagram (SVG Preview)</summary>

</details>markdown
**可视化图表**: [{PARENT-ID}-diag: {图表标题}](diagrams/{PARENT-ID}-diag_{description}.md)
<details>
<summary>查看图表(SVG预览)</summary>

</details>Supported Diagram Types
支持的图表类型
Flowchart / Graph
流程图 / 图形
mermaid
graph TB
A[Start] --> B{Decision}
B -->|Yes| C[Action 1]
B -->|No| D[Action 2]Use for: Process flows, decision trees, workflows
mermaid
graph TB
A[开始] --> B{决策}
B -->|是| C[操作1]
B -->|否| D[操作2]适用场景: 流程流、决策树、工作流
Sequence Diagram
序列图
mermaid
sequenceDiagram
Actor->>System: Request
System->>Database: Query
Database-->>System: Result
System-->>Actor: ResponseUse for: Agent interactions, API calls, message flows
mermaid
sequenceDiagram
Actor->>System: 请求
System->>Database: 查询
Database-->>System: 结果
System-->>Actor: 响应适用场景: Agent交互、API调用、消息流
Class Diagram
类图
mermaid
classDiagram
class Agent {
+state: State
+execute()
+validate()
}
Agent <|-- StrategyAgentUse for: Object relationships, system components
mermaid
classDiagram
class Agent {
+state: State
+execute()
+validate()
}
Agent <|-- StrategyAgent适用场景: 对象关系、系统组件
State Diagram
状态图
mermaid
stateDiagram-v2
[*] --> SCANNING
SCANNING --> ACTIVE
ACTIVE --> DEFENSE
DEFENSE --> [*]Use for: State machines, lifecycle flows
mermaid
stateDiagram-v2
[*] --> SCANNING
SCANNING --> ACTIVE
ACTIVE --> DEFENSE
DEFENSE --> [*]适用场景: 状态机、生命周期流
Component Diagram (using flowchart)
组件图(使用流程图语法)
mermaid
graph LR
subgraph "Level 1"
SO[System Orchestrator]
end
subgraph "Level 2"
IS[Item Selection]
end
SO --> ISUse for: System architecture, component relationships
mermaid
graph LR
subgraph "层级1"
SO[系统编排器]
end
subgraph "层级2"
IS[项目选择模块]
end
SO --> IS适用场景: 系统架构、组件关系
Deployment Diagram (using flowchart)
部署图(使用流程图语法)
mermaid
graph TB
subgraph "Cloud Run"
A[Agent Container]
end
subgraph "Cloud SQL"
B[(Database)]
end
A --> BUse for: Infrastructure architecture, deployment topology
mermaid
graph TB
subgraph "Cloud Run"
A[Agent容器]
end
subgraph "Cloud SQL"
B[(数据库)]
end
A --> B适用场景: 基础设施架构、部署拓扑
Tool Usage
工具使用方法
Check for Mermaid CLI
检查Mermaid CLI是否安装
bash
which mmdcIf not installed:
bash
npm install -g @mermaid-js/mermaid-cliAlternative: Use Puppeteer
bash
npm install -g puppeteerbash
which mmdc如果未安装:
bash
npm install -g @mermaid-js/mermaid-cli备选方案: 使用Puppeteer
bash
npm install -g puppeteerGenerate SVG from Mermaid
从Mermaid生成SVG
bash
mmdc -i input.md -o output.svg -b transparentParameters:
- : Input file (Mermaid markdown)
-i - : Output file (SVG)
-o - : Background color (
-brecommended)transparent
bash
mmdc -i input.md -o output.svg -b transparent参数说明:
- : 输入文件(Mermaid格式的Markdown)
-i - : 输出文件(SVG格式)
-o - : 背景颜色(推荐使用
-b)transparent
Convert SVG to Base64
将SVG转换为Base64
bash
base64 -w 0 diagram.svgmacOS:
bash
base64 -i diagram.svgbash
base64 -w 0 diagram.svgmacOS系统:
bash
base64 -i diagram.svgQuality Gates (Definition of Done)
质量验收标准(完成定义)
- File Created: Diagram file exists in correct subfolder
diagrams/ - Naming Convention: File name follows pattern
{PARENT-ID}-diag_{description}.md - Document Control: Metadata section present with parent link back-reference
- Mermaid Syntax: Diagram syntax validates without errors
- SVG Generated: SVG file created successfully (if using file method)
- SVG Embedded: Base64 SVG embedded in parent document
- Reference Added: Link to diagram file added in parent document
- Cross-References: All links resolve correctly (bidirectional)
- Rendering: Diagram displays correctly in GitHub, VS Code, and documentation sites
- Accessibility: Collapsible block used for SVG preview
<details> - File Size: SVG < 1MB, Base64 string < 1.5MB
- 文件已创建: 图表文件已在正确的子文件夹中生成
diagrams/ - 命名规范: 文件名符合格式
{PARENT-ID}-diag_{description}.md - 文档控制: 包含元数据章节及指向父文档的反向引用
- Mermaid语法: 图表语法验证通过,无错误
- SVG已生成: SVG文件已成功创建(如果使用文件方式)
- SVG已嵌入: Base64格式的SVG已嵌入父文档
- 引用已添加: 父文档中已添加指向图表文件的链接
- 交叉引用: 所有链接可正常解析(双向)
- 渲染正常: 图表可在GitHub、VS Code和文档站点中正常显示
- 可访问性: 使用可折叠的块展示SVG预览
<details> - 文件大小: SVG文件<1MB,Base64字符串<1.5MB
Skill Constraints
技能约束
What NOT to Do
禁止操作
- Do NOT create diagrams in archived folders without explicit permission
- Do NOT modify existing diagram files without checking version history
- Do NOT embed large binary images (use SVG only)
- Do NOT use Gantt charts, pie charts, or git graphs (outside scope - architecture diagrams only)
- Do NOT create diagrams for simple lists or tables (use markdown)
- Do NOT skip Document Control metadata
- Do NOT use generic filenames like (use descriptive names)
diagram1.md
- 请勿在未获得明确许可的情况下在归档文件夹中创建图表
- 请勿在未查看版本历史的情况下修改现有图表文件
- 请勿嵌入大型二进制图片(仅使用SVG格式)
- 请勿创建甘特图、饼图或Git图(不在支持范围内,仅支持架构类图表)
- 请勿为简单列表或表格创建图表(使用Markdown即可)
- 请勿省略文档控制元数据
- 请勿使用这类通用文件名(使用描述性名称)
diagram1.md
File Organization Rules
文件组织规则
- Always create subfolder in same directory as parent document
diagrams/ - Always use parent document ID as diagram file prefix
- Always maintain traceability with cross-references
- Always follow template structure for consistency
- 必须在父文档同一目录下创建子文件夹
diagrams/ - 必须使用父文档ID作为图表文件的前缀
- 必须通过交叉引用维护可追溯性
- 必须遵循模板结构以保证一致性
Error Handling
错误处理
Error: mmdc
command not found
mmdc错误: mmdc
命令未找到
mmdcCause: Mermaid CLI not installed
Resolution:
bash
npm install -g @mermaid-js/mermaid-cli原因: Mermaid CLI未安装
解决方案:
bash
npm install -g @mermaid-js/mermaid-cliOR
或
Provide manual instructions to use Mermaid Live (https://mermaid.live)
手动使用Mermaid Live(https://mermaid.live)
undefinedundefinedError: Invalid Mermaid syntax
错误: Mermaid语法无效
Cause: Syntax error in diagram code
Resolution:
- Validate syntax at https://mermaid.live
- Check for missing quotes, brackets, or keywords
- Review Mermaid documentation for diagram type
Error: SVG file too large (> 1MB)
错误: SVG文件过大(>1MB)
Cause: Diagram too complex
Resolution:
- Split into multiple diagrams
- Simplify diagram (remove redundant elements)
- Use subgraphs to organize complexity
原因: 图表过于复杂
解决方案:
- 将图表拆分为多个子图表
- 简化图表(移除冗余元素)
- 使用子图组织复杂内容
Error: Cannot determine parent document ID
错误: 无法确定父文档ID
Cause: Filename doesn't follow standard naming (e.g., no ID prefix)
Resolution:
- Prompt user to specify parent ID manually
- Suggest renaming parent file to follow conventions
原因: 文件名不符合标准命名规范(例如缺少ID前缀)
解决方案:
- 提示用户手动指定父文档ID
- 建议重命名父文档以遵循规范
Error: diagrams/
folder creation failed
diagrams/错误: diagrams/
文件夹创建失败
diagrams/Cause: Permission issues or invalid path
Resolution:
- Check file permissions
- Verify parent directory exists
- Use absolute paths
原因: 权限问题或路径无效
解决方案:
- 检查文件权限
- 验证父目录是否存在
- 使用绝对路径
Example Usage
使用示例
Example 1: Create New Flowchart Diagram for BRD
示例1:为BRD创建新流程图
User Request:
"Create a flowchart diagram showing the user workflow for BRD-01"
Skill Actions:
- Parse parent:
{project_root}/docs/BRD/BRD-01_project_requirements.md - Extract ID:
BRD-01 - Create file: (in BRD subfolder)
docs/BRD/diagrams/BRD-01-diag_user_workflow.md - Generate Mermaid flowchart with user journey steps
- Convert to SVG using
mmdc - Embed Base64 SVG in BRD-01
- Add reference link
Result:
- Diagram file created in (document type-specific subfolder)
docs/BRD/diagrams/ - SVG preview visible in parent document
- Cross-references working in both directions
用户请求:
"为BRD-01创建展示用户工作流的流程图"
技能执行动作:
- 解析父文档:
{project_root}/docs/BRD/BRD-01_project_requirements.md - 提取ID:
BRD-01 - 创建文件: (位于BRD子文件夹)
docs/BRD/diagrams/BRD-01-diag_user_workflow.md - 生成包含用户旅程步骤的Mermaid流程图
- 使用转换为SVG
mmdc - 将Base64格式的SVG嵌入BRD-01
- 添加引用链接
执行结果:
- 图表文件已创建在(按文档类型划分的子文件夹)
docs/BRD/diagrams/ - 父文档中可查看SVG预览
- 双向交叉引用可正常工作
Example 2: Migrate Existing Diagram
示例2:迁移现有图表
User Request:
"Migrate the state machine diagram from strategy_state_machine.md to a separate file"
Skill Actions:
- Scan
{project_root}/strategy/strategy_state_machine.md - Find ```mermaid block (state diagram)
- Extract diagram code
- Create
{project_root}/strategy/diagrams/SSM-001-diag_state_transitions.md - Generate SVG
- Replace original block with SVG + reference
- Validate migration
Result:
- Original Mermaid moved to separate file
- SVG preview embedded in main document
- Main document renders faster
用户请求:
"将strategy_state_machine.md中的状态机图表迁移到独立文件"
技能执行动作:
- 扫描
{project_root}/strategy/strategy_state_machine.md - 找到````mermaid`块(状态图)
- 提取图表代码
- 创建
{project_root}/strategy/diagrams/SSM-001-diag_state_transitions.md - 生成SVG
- 用SVG和引用链接替换原始代码块
- 验证迁移结果
执行结果:
- 原始Mermaid图表已迁移到独立文件
- 主文档中嵌入了SVG预览
- 主文档渲染速度提升
Example 3: Create Sequence Diagram for ADR
示例3:为ADR创建序列图
User Request:
"Create a sequence diagram showing the agent communication flow for ADR-003"
Skill Actions:
- Parent:
docs/ADR/ADR-003_agent_communication.md - Create: (in ADR subfolder)
docs/ADR/diagrams/ADR-003-diag_agent_communication_sequence.md - Generate sequence diagram: System Orchestrator → Selection Service → Strategy Agent → Risk Service
- Add swimlanes for timing (A2A Protocol patterns)
- Convert to SVG
- Embed in ADR-003
Result:
- Sequence diagram in (document type-specific subfolder)
docs/ADR/diagrams/ - Message flow with <50ms SLA annotations visible
- SVG preview in ADR document
用户请求:
"为ADR-003创建展示Agent通信流程的序列图"
技能执行动作:
- 父文档:
docs/ADR/ADR-003_agent_communication.md - 创建文件: (位于ADR子文件夹)
docs/ADR/diagrams/ADR-003-diag_agent_communication_sequence.md - 生成序列图:系统编排器 → 选择服务 → 策略Agent → 风险服务
- 添加时间轴泳道(A2A协议模式)
- 转换为SVG
- 嵌入到ADR-003中
执行结果:
- 序列图已创建在(按文档类型划分的子文件夹)
docs/ADR/diagrams/ - 包含<50ms SLA标注的消息流清晰可见
- ADR文档中可查看SVG预览
Output Format
输出格式
Generated Artifacts
生成的产物
-
Diagram File ()
{PARENT-ID}-diag_{description}.md- Location:
{parent_folder}/diagrams/ - Format: Markdown with Mermaid code block
- Includes: Document Control, diagram code, description, references
- Location:
-
SVG File (optional, if using file-based approach)
- Location: Same as diagram file, extension
.svg - Format: Scalable Vector Graphics
- Used for Base64 encoding
- Location: Same as diagram file,
-
Updated Parent Document
- Reference link added in appropriate section
- SVG preview embedded in block
<details> - Original content preserved
-
图表文件 ()
{PARENT-ID}-diag_{description}.md- 位置:
{parent_folder}/diagrams/ - 格式: 包含Mermaid代码块的Markdown文件
- 内容: 文档控制、图表代码、说明、参考资料
- 位置:
-
SVG文件(可选,若使用文件方式)
- 位置: 与图表文件同一目录,扩展名为
.svg - 格式: 可缩放矢量图形
- 用途: 用于Base64编码
- 位置: 与图表文件同一目录,扩展名为
-
更新后的父文档
- 对应章节已添加引用链接
- SVG预览已嵌入块
<details> - 原始内容保留
File Organization After Execution
执行后的文件组织结构
Each document type has its own diagrams subfolder:
docs/
├── BRD/
│ ├── BRD-01_project_requirements.md ← Updated with SVG + link
│ └── diagrams/
│ ├── BRD-01-diag_user_workflow.md ← BRD diagrams
│ └── BRD-01-diag_business_rules.md
├── PRD/
│ ├── PRD-01_multi_agent_system.md ← Updated with SVG + link
│ └── diagrams/
│ ├── PRD-01-diag_3_tier_hierarchy.md ← PRD diagrams
│ └── PRD-01-diag_cloud_architecture.md
├── ADR/
│ ├── ADR-005_deployment_strategy.md ← Updated with SVG + link
│ └── diagrams/
│ └── ADR-005-diag_deployment_flow.md ← ADR diagrams
├── SYS/
│ ├── SYS-002_data_pipeline.md ← Updated with SVG + link
│ └── diagrams/
│ └── SYS-002-diag_data_flow.md ← SYS diagrams
└── IMPL/
├── IMPL-010_phase_1_plan.md ← Updated with SVG + link
└── diagrams/
└── IMPL-010-diag_implementation.md ← IMPL diagrams每种文档类型都有独立的图表子文件夹:
docs/
├── BRD/
│ ├── BRD-01_project_requirements.md ← 已更新,包含SVG和链接
│ └── diagrams/
│ ├── BRD-01-diag_user_workflow.md ← BRD类图表
│ └── BRD-01-diag_business_rules.md
├── PRD/
│ ├── PRD-01_multi_agent_system.md ← 已更新,包含SVG和链接
│ └── diagrams/
│ ├── PRD-01-diag_3_tier_hierarchy.md ← PRD类图表
│ └── PRD-01-diag_cloud_architecture.md
├── ADR/
│ ├── ADR-005_deployment_strategy.md ← 已更新,包含SVG和链接
│ └── diagrams/
│ └── ADR-005-diag_deployment_flow.md ← ADR类图表
├── SYS/
│ ├── SYS-002_data_pipeline.md ← 已更新,包含SVG和链接
│ └── diagrams/
│ └── SYS-002-diag_data_flow.md ← SYS类图表
└── IMPL/
├── IMPL-010_phase_1_plan.md ← 已更新,包含SVG和链接
└── diagrams/
└── IMPL-010-diag_implementation.md ← IMPL类图表Integration with Project Workflow
与项目工作流的集成
Traceability Chain
可追溯链
Product Strategy ({project_root}/strategy/*.md)
↓
Requirements (docs/reqs/*.md)
↓
Architecture Decisions (docs/adrs/*.md) ← diagrams support ADRs
↓
System Specifications (docs/sys/*.md) ← diagrams show architecture
↓
BDD Scenarios (docs/BDD/*.feature)
↓
Code ImplementationDiagrams enhance: ADRs, SYS, PRD, BRD documents with visual architecture representations
产品战略 ({project_root}/strategy/*.md)
↓
需求文档 (docs/reqs/*.md)
↓
架构决策文档 (docs/adrs/*.md) ← 图表支持ADR文档
↓
系统规格文档 (docs/sys/*.md) ← 图表展示系统架构
↓
BDD场景 (docs/BDD/*.feature)
↓
代码实现图表增强作用: 为ADR、SYS、PRD、BRD文档提供可视化的架构展示
Relationship to Other Skills
与其他技能的关联
- doc-flow: Creates specification documents; charts-flow adds diagrams to those documents
- google-adk: Defines agent framework; charts-flow visualizes agent hierarchies
- project-mngt: Creates implementation plans; charts-flow shows dependency graphs
- doc-flow: 创建规格文档;charts-flow为这些文档添加图表
- google-adk: 定义Agent框架;charts-flow可视化Agent层级结构
- project-mngt: 创建实施计划;charts-flow展示依赖关系图
References
参考资料
Internal Documentation
内部文档
- Claude Code Skills README
- SDD Framework Guide
- Claude Code Skills README
- SDD框架指南
External Resources
外部资源
Related Templates
相关模板
- BRD Template
- PRD Template
- ADR Template
- SYS Template
- IMPL Template
Skill Version: 1.0.0
Created: 2025-01-04
Last Updated: 2025-01-04
Maintained By: Development Team
- BRD模板
- PRD模板
- ADR模板
- SYS模板
- IMPL模板
技能版本: 1.0.0
创建时间: 2025-01-04
最后更新时间: 2025-01-04
维护团队: 开发团队