image-gen
Skill11 starsChanged 12 days agoMITView on GitHub
image_gen 工具说明:用宿主自带的 image_gen 画图或改图,覆盖文生图、参考图编辑、多张参考图、size/quality/background/model 参数、返回与落盘、宿主差异、失败含义,以及 prompt 一律用英文(含图上文字)的规范。只描述工具接口与行为,不规定项目的审美、风格或出图流程。Use when the user asks for a picture, poster, illustration, icon or cover, or when you need the tool's exact parameters, host behavior or failure meanings.
- Reads credentials
49 other projects use a version of this.
Adopted by
Most recently taken up by
- lohi-ai/babysittheir own version, first seen Nov 8, 2026
- uprinter/ai-agents-teamtheir own version, first seen Nov 8, 2026
- artemmarketolog/image-gentheir own version, first seen Nov 8, 2026
- ITch8/customs-data-skillstheir own version, first seen Nov 8, 2026
- dotslashsimran/simcrafttheir own version, first seen Nov 8, 2026
- notque/vexjoy-agenttheir own version, first seen Nov 7, 2026
Used with
Projects with it also use spotify, trello and 10 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
QuixiAISkillspotify
Search Spotify, inspect current playback and devices, and control playback with explicit approval
Also in 3 projects that use this
QuixiAISkilltrello
List Trello boards, lists, and cards and create or update cards with explicit approval
Also in 3 projects that use this
AnthropicSkilldaily-briefing
Morning rundown - today's meetings with account context, opps closing soon with stale flags, waiting customer emails, and the day's top actions. Use when the user says "daily briefing", "daily brief", "morning briefing", "what's my day", "what's on my plate today", "prep my day", "start my day", "morning rundown", or on a schedule.
Also in 3 projects that use this
silvainfmSkillpaid-ads
When the user wants help with paid advertising campaigns on Google Ads, Meta (Facebook/Instagram), LinkedIn, Twitter/X, or other ad platforms. Also use when the user mentions 'PPC,' 'paid media,' 'ad copy,' 'ad creative,' 'ROAS,' 'CPA,' 'ad campaign,' 'retargeting,' or 'audience targeting.' This skill covers campaign strategy, ad creation, audience targeting, and optimization.
Also in 3 projects that use this
AnthropicSkillweather
The optional standing status report ("the weather"): compile open incidents, build health, merge-queue stats, and deploy lag into one always-current report page, and post to the channel only when a defined event fires. Use when the weather routine fires, or when someone asks to run/update the weather report.
Also in 3 projects that use this
mitsuhikoSkillsummarize
Fetch a URL or convert a local file (PDF/DOCX/HTML/etc.) into Markdown using `uvx markitdown`, optionally it can summarize
Also in 3 projects that use this
Other versions49 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 49
- ethereum/ethereum-org-website★ 6ksame name
- fastclaw-ai/fastclaw★ 1.4ksame name
- QuixiAI/agi-memory★ 623same name
- QuixiAI/Hexis★ 623same name
- notque/claude-code-toolkit★ 448same name
- notque/vexjoy-agent★ 448same name
- suitedaces/dorabot★ 247same name
- Sma1lboy/rove★ 184same name
- wpsnote/wpsnote-skills★ 184same name
- microsoft/Huabu★ 170same name
39 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository39 other files it gives its agents.
- accel-initSkill
- accel-platform-installSkill
- accel-pytorch-code-portingSkill
- accel-pytorch-pythonSkill
- accel-skill-templateSkill
- model-datasetsSkill
- platform-environment-skill-auditSkill
- agent-reach-installSkill
- code-reviewSkill
- consolidatorSkill
- diagnosing-bugsSkill
- distill-project-kbSkill
- domain-modelingSkill
- editable-vector-slidesSkill
- goal-firstSkill
- grillingSkill
- load-memSkill
- migrate-memSkill
- personal-ui-tasteSkill
- plan-briefSkill
- project-profileSkill
- quick-doSkill
- readable-docsSkill
- save-memSkill
- steady-doSkill
- tddSkill
- teachSkill
- writing-skillSkill
- kb-8bit-quantizationSkill
- kb-accel-sdkSkill
- nju-pptSkill
- exp-batchSkill
- exp-campaignSkill
- exp-discussSkill
- exp-probeSkill
- exp-workflowSkill
- kernel-workerSkill
- pytorch-perf-tuningSkill
- research-evidenceSkill
The file
Files
image-gen
工具:image_gen(prompt, reference?, size?, quality?, background?, model?),三宿主同名(Pi / OpenCode v2 / DSH)。凭据与默认值在 ~/.local/share/agent-skills/image-gen.json。
本 skill 只说明工具能力与行为。画什么、用什么风格、要不要画,由调用方(项目自己的规范或用户 prompt)决定。
1. 能做什么
| 能力 | 说明 |
| 文生图 | 给 prompt 即走 /images/generations,返回一张位图 |
| 参考图编辑 | 给 reference(绝对路径数组)即走 /images/edits,可传一张或多张 |
| 透明底 | background: "transparent" |
| 尺寸与画质 | size、quality 透传给渠道 |
| 指定模型 | model 覆盖默认模型 |
不能做:
- 只出位图,不是可编辑矢量/SVG;需要精确文字、公式、真实数据或二次编辑时,位图不合适
- 一次调用一张图(内部固定
n: 1);要几张就调几次 - 不保证图中文字正确 —— 生成模型自身的限制,调
quality或size都不改变这一点
2. 文生图
{ "prompt": "what the picture must show, in English" }prompt 一律用英文写,包括要出现在图上的文字:这些 gpt-image 模型对英文的理解明显好过中文,中文 prompt 更容易出错字、笔画畸形和中英混杂。
- 图上的标注默认也用英文(
text "Data Ingestion" in the top box) - 用户明确要中文标注时才在 prompt 里写中文字面量,并接受更高的出错率
- 只有传给模型的
prompt是英文;给用户看的回复、落盘文件名解释仍是中文 - prompt 里写清:主体、布局、必须出现的文字(用引号给原文)、风格与配色;不要把聊天内容整段粘进去
3. 参考图编辑
{ "prompt": "what to keep and exactly what to change", "reference": ["/abs/path/a.png", "/abs/path/b.png"] }多张参考图一起传;不给 reference 就是文生图。编辑的 prompt 同样一律用英文。编辑结果可能与原图有未要求的差异,原图请自行保留。
4. 参数
| 参数 | 类型与取值 | 说明 |
prompt | 字符串,必填 | 画面内容;参考图编辑时写修改要求 |
reference | 字符串数组(绝对路径) | 给了走参考图编辑 |
size | 如 1024x1024、1536x1024、2048x1152 | 默认取配置(1024x1024);本机实测可用到 3840x2160,实际支持范围由渠道决定 |
quality | auto / low / medium / high / xhigh / max | 默认取配置(medium);档位越高越慢越贵,不改变像素尺寸 |
background | transparent / opaque | 透明底用于图标、贴图 |
model | 字符串 | 默认:文生图 gpt-image-2.5-flare,有参考图时 gpt-image-2.5-sunburst |
5. 返回与落盘
返回三项:落盘路径、一行 模型 · 尺寸 · 画质 · 格式 · 体积 摘要、图片本身(宿主是否把它交给模型见第 6 节)。
- 目录:
output_dir,默认项目 cwd 下的images/,不存在则创建 - 文件名:ISO 时间戳 + prompt 前 40 字,扩展名取渠道返回的
output_format - 单图几百 KB,会进会话历史
6. 宿主差异
| 宿主 | 差异 |
| Pi | 当前模型 input 含 image 时把图作为附件返回;纯文本模型只拿到路径与摘要,会附一句提示 |
| OpenCode v2 | 图以 data: 文件附件进会话;TUI 里显示预览需 session.image_preview=true(默认关) |
| DSH | 同一 Pi 扩展经 pi2dsh 转成 DSH 原生附件 |
模型看不到图时,把路径交给用户自己打开,不要说"图在下面"。
7. 失败怎么读
工具不自动重试,失败即抛错,需要重试就自己再调一次。
| 报错 | 含义 |
图像接口 503 … 无可用渠道 / model_not_found | 网关没给这个 key 开该模型渠道,或模型名写错 |
图像接口 401 | key 无效 |
缺少图像接口凭据 | image-gen.json 缺 base_url 或 api_key |
图像接口返回非 JSON(HTTP …) | 渠道返回了 HTML/网关页,原文附在前 300 字 |
图像接口没返回图片 | 返回体里没有 data[0].b64_json,原文附在前 300 字 |
| 超时 / 中断 | 大尺寸或高画质;signal 取消或降档重试 |
8. 配置
~/.local/share/agent-skills/image-gen.json(0600,IMAGE_GEN_CONFIG 可改路径):
{
"base_url": "https://api.example.com/v1",
"api_key": "...",
"model": "gpt-image-2.5-flare",
"edit_model": "gpt-image-2.5-sunburst",
"output_dir": "images",
"size": "1024x1024",
"quality": "medium"
}- 文件不存在时,从
~/.pi/agent/models.json里挑第一个api以openai开头、凭据和baseUrl都填好的 provider 自动写入;挑不到就写空模板并报错 pi-setup.sh/opencode-setup.sh会补齐缺字段,已有的base_url/api_key一律保留- 无人值守可用
PI_IMAGE_GEN_API_KEY预填 - 参数优先级:单次调用参数 >
image-gen.json> 内置默认值
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

