SkillsGrove
SkillsGrove/Design & images/different-ai-studio/teamclu/image-gen

image-gen

Installation

$npx skills add https://github.com/different-ai-studio/teamclu --skill image-gen
$git clone --depth 1 https://github.com/different-ai-studio/teamclu.git /tmp/teamclu && mkdir -p ~/.claude/skills && cp -r /tmp/teamclu/skills/image-gen ~/.claude/skills/image-gen
Please install this Agent Skill for me: https://github.com/different-ai-studio/teamclu/tree/7b93cee77adc6af2487805755a8b12c4bee41ed3/skills/image-gen — read its SKILL.md and scripts first, and only install it into my skills folder once you have confirmed it is safe.

Summary

Original description · MIT生成图片:配图、插图、海报、头像、示意图、Logo 草稿、封面、banner。触发词:画一张、画个、生成图片、生成一张图、做张图、做个图、配图、出图、生图、AI 绘图、image、draw、illustration、poster。仅从零生成,不做已有图片的编辑或修改。
The SKILL.md below is reproduced from different-ai-studio/teamclu (commit 7b93cee) under the MIT license. The text is unchanged; only the file header metadata is omitted, images are shown as links, and very long files are truncated. Copyright 2026 TeamClu Contributors. License: LICENSE. Only the instructions file is shown; see the original repository for any scripts.

图片生成

通过团队 AI 网关生成图片。按张计入团队积分,所以不要为一次请求反复重试。

怎么用

node scripts/generate.mjs --prompt "一片红色枫叶,扁平矢量风格,白色背景"

可选参数:

参数 默认 说明
--n 1 张数。每张都单独计费,用户没明确要多张就别传
--size 1024x1024 还支持 1024x1536(竖)、1536x1024(横)
--quality 由网关决定 low / medium / high。high 是标准价的 3 倍,用户没要求就别传
--out-dir 当前目录 一般不要传,见下面第 1 条

脚本只往 stdout 打印文件名、尺寸和大小。

四条硬约束

1. 图片必须留在会话目录里,引用必须用相对路径。

桌面端渲染 ![](...) 时会把路径按会话目录解析,解析结果只要落在会话目录之外就直接渲染成空 —— 没有报错、没有占位图、控制台也没有任何东西。所以:

![一片红色枫叶](maple-leaf-20260909-231500.png)   ← 对
![一片红色枫叶](/tmp/x.png)                        ← 用户看到的是一段没有图的文字
![一片红色枫叶](file:///Users/…/x.png)             ← 同上

直接用脚本打印出来的文件名,不要加目录前缀、不要转成绝对路径。

2. 绝对不要读这个图片文件。

不要 cat、不要 base64、不要用读文件工具打开它。一张图是 1–3 MB 的 base64,把它读进上下文会直接撑爆会话的压缩机制,之后每一轮都在白烧。你需要知道的一切(文件名、尺寸、大小)脚本已经打印了。

3. 不要自己拼 HTTP 请求。

只调 scripts/generate.mjs。不要去读 TEAMCLU_TEAM_PROVIDER、更不要读 tc_gateway_token,也不要用 curl 直接打网关。

4. 失败就照实告诉用户,不要重试。

脚本已经把错误翻译成人话了(积分不足、额度超限、团队没开网关、尺寸不支持、内容被拦截)。把那句话转述给用户就行 —— 这些都是用户自己能解决的问题,重试只会再花一次钱。唯一值得重试一次的是超时。

提示词写法

英文和中文都可以。把风格、构图、背景写进去,模型会自己改写提示词(脚本会把改写后的版本打印出来):

  • 好:一片红色枫叶,扁平矢量风格,纯白背景,居中构图
  • 差:枫叶

生成一张大约需要 30 秒,属于正常,不要中途取消。

完整示例

$ node scripts/generate.mjs --prompt "一片红色枫叶,扁平矢量,白底"
maple-leaf-20260909-231500.png  (765 KB, 1024x1024)
  改写后的提示词: A single red maple leaf, flat vector illustration, white background

然后在回复里写:

![一片红色枫叶](maple-leaf-20260909-231500.png)
View full license text (MIT)
MIT License

Copyright (c) 2026 TeamClu Contributors

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.