mcpField
A
architecture-diagram-gpt-imagegen

architecture-diagram-gpt-imagegen

github.com/arthurzakirov创意与媒体0167 次安装4 周前更新
代码仓库

关于 architecture-diagram-gpt-imagegen

用于生成架构图或工作流图像提示词的 Agent Skill,适合希望将系统描述转化为图像生成指令的用户。它将完整提示词写入指定文件,并要求聊天回复仅提供文件路径。

主要功能

  1. 01根据描述构建图像提示词
  2. 02默认横向左至右布局
  3. 03默认 16:9 横向画布
  4. 04生成 Mermaid 结构骨架
  5. 05将提示词写入指定文件
  6. 06支持后续 Codex 图像生成

适用场景

  1. 01将服务清单整理为架构图提示词
  2. 02把 Mermaid 图改写为图像生成指令
  3. 03为当前项目生成工作流图提示词

安装

复制下面的命令,在终端中运行。

$npx skills add https://github.com/arthurzakirov/proofstack --skill architecture-diagram-gpt-imagegen

安装后在 Claude Code 中输入/architecture-diagram-gpt-imagegen确认已加载。

详细介绍

架构图 GPT 图像生成器

生成一段 GPT 提示词,粘贴到聊天模型后即可生成精美的架构图或工作流图像。将提示词写入文件。聊天回复中只保留文件路径。

输出规范

此技能触发时:

  1. 将完整提示词写入 ~/diagram-prompts/<slug>.md。如果目录不存在,则创建该目录。<slug> 是根据主题推断出的简短 kebab-case 名称。
  2. 文件内容必须且只能包含提示词。
  3. 聊天回复必须严格为:
Prompt -> /home/arthur/diagram-prompts/<slug>.md
Open the file, copy all, paste into GPT.
  1. 写入提示词后,不要在聊天中再次回显提示词正文。

最少输入要求

用户可以提供:

  • Mermaid 图
  • 粗略的语音笔记式描述
  • 服务及其连接关系列表
  • 绘制当前项目示意图的请求

如果关键的流程方向或系统意图确实不明确,请提出一个简短的澄清问题。否则,使用以下默认值补全信息。

强制默认值

除非用户明确另有要求,否则始终采用以下默认值:

  1. 默认采用从左到右的横向布局。
  2. 图像宽高比默认为横向 16:9。
  3. 提示词必须完整自足,可在全新的聊天会话中直接使用。
  4. 提示词中的 Mermaid 源码默认使用 flowchart LR。

提示词模板

按照以下结构编写提示词文件,并根据具体图示调整内容:

Create a polished enterprise architecture diagram image. Render the image in 16:9 horizontal landscape aspect ratio. Do NOT output Mermaid code. Do NOT explain the diagram. Your task is to GENERATE AN IMAGE based on the specification below.

## Layout & system boundary

- Image canvas: 16:9 horizontal landscape
- Horizontal left-to-right layout
- [system-boundary containers and spatial arrangement]

## Visual style

- Clean, modern, enterprise-grade architecture diagram
- Rounded containers, soft shadows, generous spacing
- Crisp directional arrows; label branches on every decision diamond
- Minimal text inside nodes — use icons or emojis for meaning
- Prioritize clarity over technical detail

## Logos & icon mapping

Use recognizable logos for:
- [services that appear in the diagram]

Use visual metaphors:
- [emojis used in the diagram]

## Flow structure

[numbered left-to-right stages, grouping nodes and decisions]

## Color guidance

- System container: [platform tint]
- Entry points or triggers: warm red or amber
- Inputs or read tools: green
- AI or prompt nodes: purple or blue
- Decisions or retry loops: neutral blue-gray
- Output channels: green
- Per-service nodes use brand colors

## Semantic constraints

- [topology, ordering, and decision rules]

## Source structure (for reference only, do not output)

```mermaid
[mermaid source from the user or inferred from the description]

## Default Logo Library

Map products and systems to recognizable logos when relevant:

- Jira
- Bitbucket
- Slack
- Databricks
- AWS
- Kubernetes
- Datadog
- Confluence
- OpenAI
- Claude
- GitHub
- Google Sheets
- Java or backend services

If a service is not covered, use a plain rounded box with a fitting emoji.

## Default Visual Metaphors

Use emojis only when a concept has no natural product logo. Useful defaults include:

- `📄` prompt or document
- `🏷️` classification or label
- `💬` rationale or comment
- `⚙️` decision logic or processing
- `🛠️` fix or modification
- `🔒` validation
- `📣` routing
- `🚨` alert or failure
- `✅` success
- `❌` failure
- `⏰` schedule
- `🔁` retry loop
- `🔍` search or lookup
- `📊` metrics
- `🧠` AI or agent
- `🗄️` storage
- `📥` input
- `📤` output

## Parsing The User's Input

1. Identify services and products, then map them to logos.
2. Identify flow direction. Default to horizontal LR except genuine hierarchy-heavy exceptions.
3. Identify containers or subgraphs.
4. Identify decision diamonds and label both branches.
5. Identify retry loops and label them clearly.
6. Apply colors by role.
7. Build a Mermaid source block so the generator has a spatial spine.

## File Writing

Create `~/diagram-prompts` if it does not exist, then write the full prompt to `~/diagram-prompts/<slug>.md`. Do not add timestamps unless the user explicitly asks.

## Final Chat Reply

After the file is written, the chat reply must be exactly:

```text
Prompt -> /home/arthur/diagram-prompts/<slug>.md
Open the file, copy all, paste into GPT — or reply "imagegen" to render it directly via Codex CLI.

可选的 Codex 图像生成

如果用户明确回复 imagegen、yes generate、render it 或其他清晰的肯定答复,则运行本地辅助工具,将提示词转换为图像,并且只返回图像路径和一行打开命令。

评论

支持 Markdown