platforms/hermes/skills/creative/image-gen/SKILL.md
图片生成, 架构图, 流程图, 时序图, 泳道图, diagram, architecture, flowchart, sequence, swimlane, image generation, nano banana, 生图, 画图, 画一个, 生成图片, generate image, draw diagram
npx skillsauth add codingsamss/ai-dotfiles image-genInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
通用图片生成技能,支持自由生图和结构化图表生成(架构图、流程图、时序图、泳道图)。通过可配置的 API Provider 调用图片生成模型。
~/.codex/skills/image-gen/providers.json 填入 api_key)。CODEX_HOME="${CODEX_HOME:-$HOME/.codex}"
SCRIPT="${CODEX_HOME}/skills/image-gen/scripts/image-gen.py"
Triggers: "image-gen 配置", "查看生图配置", "image config"
python3 "$SCRIPT" config
Triggers: "切换生图 provider", "switch image provider"
python3 "$SCRIPT" config --switch <provider_key>
可选 provider_key: huan, undying, google
Triggers: "生成图片", "画一个", "generate image", "生图", "画图"
直接传入 prompt 生成图片:
python3 "$SCRIPT" generate "一个微服务架构图,包含网关、用户服务、订单服务和数据库"
可选参数:
--output <path>:指定输出路径(默认 /tmp/image-gen-<timestamp>.png)--ratio <16:9>:宽高比(默认 16:9)--style <clean>:风格 clean / detailed / minimal(默认 clean)--debug-raw:将原始请求/响应 JSON 落盘,便于排查接口返回问题--debug-dir <path>:调试文件目录(默认 /tmp/image-gen-debug)根据图表类型自动包装专业 prompt 模板,生成高质量技术图表。
Triggers: "画架构图", "architecture diagram", "系统架构"
python3 "$SCRIPT" diagram --type architecture --input "Client -> API Gateway -> Auth Service, User Service -> PostgreSQL"
Triggers: "画流程图", "flowchart", "流程"
python3 "$SCRIPT" diagram --type flowchart --input "用户注册流程:输入信息->验证邮箱->创建账号->发送欢迎邮件"
Triggers: "画时序图", "sequence diagram", "时序"
python3 "$SCRIPT" diagram --type sequence --input "Browser->Server: HTTP Request; Server->DB: Query; DB->Server: Result; Server->Browser: Response"
Triggers: "画泳道图", "swimlane diagram", "泳道"
python3 "$SCRIPT" diagram --type swimlane --input "前端: 发送请求; 网关: 鉴权转发; 服务: 业务处理; 数据库: 读写数据"
python3 "$SCRIPT" diagram --type architecture --file description.txt
--output <path>:指定输出路径(默认 /tmp/image-gen-<timestamp>.png)--ratio <16:9>:宽高比(默认 16:9)--style <clean>:风格 clean / detailed / minimal(默认 clean)--debug-raw:将原始请求/响应 JSON 落盘,便于排查接口返回问题--debug-dir <path>:调试文件目录(默认 /tmp/image-gen-debug)脚本成功后会输出图片文件路径,使用 Read 工具查看图片内容展示给用户。
generate / diagram 命令返回非 0、超时、或提示“未在响应中找到图片/只返回文本”,必须直接向用户报告失败原因。~/.codex/skills/image-gen/providers.json 填入 api_key。/tmp/ 目录。IMAGE_GEN_TIMEOUT 调整请求超时(默认 300 秒)。IMAGE_GEN_DEBUG_RAW=1 开启调试落盘;目录可用 IMAGE_GEN_DEBUG_DIR 指定。development
Query Midea MX / 美信 local message cache through the MX local HTTP query service from Codex. Use when the user asks to read MX sessions, search chat history, search messages globally or inside a group/session, list recent messages, or page message history. This is read-only and does not require send authorization. Never fall back to reading SQLite or app cache files directly.
development
Safely search MX users or groups and send Midea MX / 美信 IM messages from Codex. Use when the user asks to notify someone, send a message to a person or group, use a configured group alias, @ users, @ all, or send MX file/image messages. Read lookups need no extra authorization; every live send needs explicit user authorization for that exact target and message.
tools
MX channel output rules. Always active in MX conversations.
tools
Use the company WorkSpace `ws` CLI reliably as a delegated coding agent from Codex. Trigger when the user wants Codex to command `ws`, WorkSpace CLI, or the company opencode-derived coding tool to generate code, inspect a repo, run a bounded implementation task, or use a requested WorkSpace model while Codex reviews the output.