重要前提
安装AI Skills的关键前提是:必须科学上网,且开启TUN模式,这一点至关重要,直接决定安装能否顺利完成,在此郑重提醒三遍:科学上网,科学上网,科学上网。查看完整安装教程 →
patent-diagram-generator by robthepcguy/claude-patent-creator
npx skills add https://github.com/robthepcguy/claude-patent-creator --skill patent-diagram-generator使用 Graphviz 创建专利风格的技术图表,包括流程图、框图以及系统架构图。
当用户要求以下操作时,可调用此技能:
* 方法步骤流程图
* 决策树
* 带分支的流程
* 专利风格的步骤编号
2. 框图创建 :
* 系统组件图
* 硬件架构图
* 软件模块图
* 组件互连
3. 自定义图表渲染 :
* 渲染 Graphviz DOT 代码
* 支持多种格式(SVG、PNG、PDF)
* 多种布局引擎(dot、neato、fdp、circo、twopi)
4. 专利风格格式化 :
* 添加参考编号(10、20、30 等)
* 使用清晰的标签和连接
* 符合 USPTO 提交要求的专业格式
广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
此技能需要安装 Graphviz:
Windows :
choco install graphviz
Linux :
sudo apt install graphviz
Mac :
brew install graphviz
Python 包 :
pip install graphviz
调用此技能时:
加载图表生成器 :
import sys sys.path.insert(0, os.path.join(os.environ.get('CLAUDE_PLUGIN_ROOT', '.'), 'python')) from python.diagram_generator import PatentDiagramGenerator
generator = PatentDiagramGenerator()
根据步骤创建流程图:
steps = [ {"id": "start", "label": "Start", "shape": "ellipse", "next": ["step1"]}, {"id": "step1", "label": "Initialize System", "shape": "box", "next": ["decision"]}, {"id": "decision", "label": "Is Valid?", "shape": "diamond", "next": ["step2", "error"]}, {"id": "step2", "label": "Process Data", "shape": "box", "next": ["end"]}, {"id": "error", "label": "Handle Error", "shape": "box", "next": ["end"]}, {"id": "end", "label": "End", "shape": "ellipse", "next": []} ]
diagram_path = generator.create_flowchart( steps=steps, filename="method_flowchart", output_format="svg" )
创建框图 :
blocks = [ {"id": "input", "label": "Input\nSensor", "type": "input"}, {"id": "cpu", "label": "Central\nProcessor", "type": "process"}, {"id": "memory", "label": "Memory\nStorage", "type": "storage"}, {"id": "output", "label": "Output\nDisplay", "type": "output"} ]
connections = [ ["input", "cpu", "raw data"], ["cpu", "memory", "store"], ["memory", "cpu", "retrieve"], ["cpu", "output", "processed data"] ]
diagram_path = generator.create_block_diagram( blocks=blocks, connections=connections, filename="system_diagram", output_format="svg" )
渲染自定义 DOT 代码 :
dot_code = """ digraph PatentSystem { rankdir=LR; node [shape=box, style=rounded];
Input [label="User Input\\n(10)"];
Processor [label="Processing Unit\\n(20)"];
Output [label="Display\\n(30)"];
Input -> Processor [label="data"];
Processor -> Output [label="result"];
} """
diagram_path = generator.render_dot_diagram( dot_code=dot_code, filename="custom_diagram", output_format="svg", engine="dot" )
添加参考编号 :
reference_map = { "Input Sensor": 10, "Central Processor": 20, "Memory Storage": 30, "Output Display": 40 }
annotated_path = generator.add_reference_numbers( svg_path=diagram_path, reference_map=reference_map )
获取常用模板:
templates = generator.get_diagram_templates()
# 可用模板:
# - simple_flowchart: 基本流程
# - system_block: 系统架构
# - method_steps: 顺序方法
# - component_hierarchy: 层次结构
ellipse: 开始/结束点box: 处理步骤diamond: 决策点parallelogram: 输入/输出操作cylinder: 数据库/存储input: 输入设备/传感器output: 输出设备/显示器process: 处理单元storage: 内存/存储decision: 控制逻辑default: 通用组件dot: 分层布局(自上而下/从左到右)neato: 弹簧模型布局fdp: 力导向布局circo: 圆形布局twopi: 径向布局svg: 可缩放矢量图形(最适合编辑)png: 光栅图像(适合查看)pdf: 便携式文档格式(兼容 USPTO)约定:
示例标签:
"Input Sensor (10)"
" - Detector Element (12)"
" - Signal Processor (14)"
"Central Unit (20)"
" - CPU Core (22)"
" - Cache (24)"
创建图表时:
描述将要生成的内容:"正在为包含 5 个步骤的身份验证方法创建流程图..."
生成图表:运行 Python 代码以创建 SVG/PNG/PDF
显示文件位置:"图表已创建:${CLAUDE_PLUGIN_ROOT}/python\diagrams\method_flowchart.svg"
列出参考编号(如果已添加):
Reference Numbers:
* 显示顺序步骤
* 包含决策分支
* 编号步骤(S1、S2、S3...)
2. 系统权利要求 → 框图
* 显示组件和连接
* 使用参考编号
* 指示数据流方向
3. 架构图 → 自定义 DOT
* 复杂的系统布局
* 多重互连
* 层次结构
如果 Graphviz 未安装:
dot -Vpip show graphvizpython scripts/test_diagrams.py每周安装次数
62
代码仓库
GitHub 星标数
47
首次出现
2026年1月22日
安全审计
安装于
opencode60
gemini-cli57
codex56
github-copilot55
kimi-cli54
amp54
Create patent-style technical diagrams including flowcharts, block diagrams, and system architectures using Graphviz.
Invoke this skill when users ask to:
Flowchart Generation :
Block Diagram Creation :
Custom Diagram Rendering :
Patent-Style Formatting :
This skill requires Graphviz to be installed:
Windows :
choco install graphviz
Linux :
sudo apt install graphviz
Mac :
brew install graphviz
Python Package :
pip install graphviz
When this skill is invoked:
Load diagram generator :
import sys
sys.path.insert(0, os.path.join(os.environ.get('CLAUDE_PLUGIN_ROOT', '.'), 'python'))
from python.diagram_generator import PatentDiagramGenerator
generator = PatentDiagramGenerator()
Create flowchart from steps:
steps = [
{"id": "start", "label": "Start", "shape": "ellipse", "next": ["step1"]},
{"id": "step1", "label": "Initialize System", "shape": "box", "next": ["decision"]},
{"id": "decision", "label": "Is Valid?", "shape": "diamond", "next": ["step2", "error"]},
{"id": "step2", "label": "Process Data", "shape": "box", "next": ["end"]},
{"id": "error", "label": "Handle Error", "shape": "box", "next": ["end"]},
{"id": "end", "label": "End", "shape": "ellipse", "next": []}
]
diagram_path = generator.create_flowchart(
steps=steps,
filename="method_flowchart",
output_format="svg"
)
Create block diagram :
blocks = [
{"id": "input", "label": "Input\\nSensor", "type": "input"},
{"id": "cpu", "label": "Central\\nProcessor", "type": "process"},
{"id": "memory", "label": "Memory\\nStorage", "type": "storage"},
{"id": "output", "label": "Output\\nDisplay", "type": "output"}
]
connections = [
["input", "cpu", "raw data"],
["cpu", "memory", "store"],
["memory", "cpu", "retrieve"],
["cpu", "output", "processed data"]
]
diagram_path = generator.create_block_diagram(
blocks=blocks,
connections=connections,
filename="system_diagram",
output_format="svg"
)
Get common templates:
templates = generator.get_diagram_templates()
# Available templates:
# - simple_flowchart: Basic process flow
# - system_block: System architecture
# - method_steps: Sequential method
# - component_hierarchy: Hierarchical structure
ellipse: Start/End pointsbox: Process stepsdiamond: Decision pointsparallelogram: Input/Output operationscylinder: Database/Storageinput: Input devices/sensorsoutput: Output devices/displaysprocess: Processing unitsstorage: Memory/storagedecision: Control logicdefault: General componentsdot: Hierarchical (top-down/left-right)neato: Spring model layoutfdp: Force-directed layoutcirco: Circular layouttwopi: Radial layoutsvg: Scalable Vector Graphics (best for editing)png: Raster image (good for viewing)pdf: Portable Document Format (USPTO compatible)Convention:
Example labeling:
"Input Sensor (10)"
" - Detector Element (12)"
" - Signal Processor (14)"
"Central Unit (20)"
" - CPU Core (22)"
" - Cache (24)"
When creating diagrams:
Describe what will be generated : "Creating a flowchart for the authentication method with 5 steps..."
Generate the diagram : Run Python code to create SVG/PNG/PDF
Show file location : "Diagram created: ${CLAUDE_PLUGIN_ROOT}/python\diagrams\method_flowchart.svg"
List reference numbers (if added):
Reference Numbers:
- Input Module (10)
- Processing Unit (20)
- Output Interface (30)
Method Claims → Flowcharts
System Claims → Block Diagrams
Architecture Diagrams → Custom DOT
If Graphviz is not installed:
dot -Vpip show graphvizpython scripts/test_diagrams.pyWeekly Installs
62
Repository
GitHub Stars
47
First Seen
Jan 22, 2026
Security Audits
Gen Agent Trust HubWarnSocketPassSnykPass
Installed on
opencode60
gemini-cli57
codex56
github-copilot55
kimi-cli54
amp54
文档查找工具:实时获取库、框架和API最新文档,替代训练数据
1,200 周安装
Azure资源查找工具:跨订阅查询、发现孤立资源、审计标签配置
152,400 周安装
Azure合规性安全审计工具 - 密钥保管库过期检查与资源配置评估
152,500 周安装
Azure AI 服务指南:AI Search、Speech、OpenAI、文档智能功能与SDK
152,500 周安装
Azure云迁移工具:AWS Lambda到Azure Functions自动评估与代码迁移指南
152,500 周安装
Azure 托管 GitHub Copilot SDK 部署指南 - 微软官方技能模板
152,100 周安装
Azure部署指南:从验证到执行的完整流程与最佳实践
152,700 周安装
Render custom DOT code :
dot_code = """
digraph PatentSystem {
rankdir=LR;
node [shape=box, style=rounded];
Input [label="User Input\\n(10)"];
Processor [label="Processing Unit\\n(20)"];
Output [label="Display\\n(30)"];
Input -> Processor [label="data"];
Processor -> Output [label="result"];
}
"""
diagram_path = generator.render_dot_diagram(
dot_code=dot_code,
filename="custom_diagram",
output_format="svg",
engine="dot"
)
Add reference numbers :
# After creating a diagram, add patent-style reference numbers
reference_map = {
"Input Sensor": 10,
"Central Processor": 20,
"Memory Storage": 30,
"Output Display": 40
}
annotated_path = generator.add_reference_numbers(
svg_path=diagram_path,
reference_map=reference_map
)