← 返回 Skills 市场
120
总下载
0
收藏
0
当前安装
2
版本数
在 OpenClaw 中安装
/install image-gen-cheap
功能描述
低成本图片生成与编辑。使用老张 API,最低 $0.01/张。支持文生图、图片编辑。触发词:生成图片、画图、AI 作图、文生图、图片编辑。
使用说明 (SKILL.md)
Image Gen Cheap - 低成本图片生成
快速开始
1. 获取 API Token
访问 https://api.laozhang.ai/register/?aff_code=lfa0 注册,在控制台获取 token。新注册自动获得 $0.5 开发测试额度。
保存 token:
echo "sk-your-token" > ~/.laozhang_api_token
2. 文生图
# 使用默认模型(sora_image,$0.01/张)
python scripts/generate_image.py "一只可爱的猫咪在花园里玩耍"
# 指定比例(2:3竖版/3:2横版/1:1正方形)
python scripts/generate_image.py "夕阳下的海滩" --ratio 3:2
# 保存到指定路径
python scripts/generate_image.py "可爱的小狗" --output dog.png
# 使用其他模型
python scripts/generate_image.py "未来城市" --model gpt-4o-image
3. 图片编辑
# 基础编辑
python scripts/edit_image.py "https://example.com/cat.jpg" "把猫咪的毛色改成彩虹色"
# 使用预设风格
python scripts/edit_image.py "https://example.com/photo.jpg" --style 卡通
# 多图融合
python scripts/edit_image.py "https://a.jpg,https://b.jpg" "将两张图片融合"
模型与价格
文生图模型
| 模型 | 模型ID | 价格 | 返回格式 |
|---|---|---|---|
| Sora Image | sora_image | $0.01/张 | URL |
| GPT-4o Image | gpt-4o-image | $0.01/张 | URL |
| Nano Banana | gemini-2.5-flash-image | $0.025/张 | base64 |
| Nano Banana2 | gemini-3.1-flash-image-preview | $0.03/张 | base64 |
| Nano Banana Pro | gemini-3-pro-image-preview | $0.05/张 | base64 |
图片编辑模型
| 模型 | 模型ID | 价格 | 返回格式 |
|---|---|---|---|
| GPT-4o Image | gpt-4o-image | $0.01/张 | URL |
| Sora Image | sora_image | $0.01/张 | URL |
| Nano Banana | gemini-2.5-flash-image | $0.025/张 | base64 |
推荐:默认使用 sora_image(文生图)和 gpt-4o-image(图片编辑),都是 $0.01/张且返回 URL。
预设风格
- 卡通 - 迪士尼卡通风格
- 油画 - 古典油画风格
- 水墨 - 中国水墨画风格
- 赛博朋克 - 霓虹灯光效果
- 素描 - 铅笔素描风格
- 水彩 - 水彩画风格
参数说明
generate_image.py
--model, -m 使用的模型(默认: sora_image)
--ratio, -r 图片比例:2:3/3:2/1:1(仅 sora_image 支持)
--output, -o 保存图片到指定路径
--token, -t 指定 API token
--verbose, -v 显示详细信息
--json 输出完整 API 响应
--no-save 不保存图片(仅显示URL)
edit_image.py
--model, -m 使用的模型(默认: gpt-4o-image)
--style, -s 预设风格(卡通/油画/水墨/赛博朋克/素描/水彩)
--output, -o 保存图片到指定路径
--token, -t 指定 API token
--verbose, -v 显示详细信息
--json 输出完整 API 响应
--no-save 不保存图片(仅显示URL)
依赖
pip install requests
注意事项
- 返回 URL 的模型(sora_image / gpt-4o-image)可直接发送到飞书等平台
- 返回 base64 的模型会自动解码保存到本地
- 建议控制在 10 请求/分钟以内
安全使用建议
This skill appears to do what it claims (cheap image gen/edit via LaoZhang). Before installing or running it: 1) Verify the LaoZhang service (https://api.laozhang.ai) is trustworthy for your data — prompts and image URLs are sent to that third party. 2) Be aware the scripts read a local token file (~/.laozhang_api_token) or accept --token; the skill manifest does not declare this credential — consider storing tokens securely and not reusing high‑privilege keys. 3) The scripts download images from arbitrary URLs you provide — avoid passing internal or sensitive endpoints to prevent unintended network access (SSRF risk). 4) Check billing/pricing and the affiliate link in the README (aff_code) if you care about referral behavior. 5) If you want stronger guarantees, request the author add an explicit primary credential field to the manifest, support reading a token from a secure env var or secret store, and document exactly what is transmitted to the LaoZhang API. If you trust the LaoZhang provider and accept the token/storage model, this skill is coherent and usable.
功能分析
Type: OpenClaw Skill
Name: image-gen-cheap
Version: 1.0.1
The skill provides a legitimate interface for image generation and editing via the third-party 'LaoZhang API'. The included Python scripts (generate_image.py and edit_image.py) are well-implemented, using standard libraries like requests and argparse to interact with the API. They include proper filename sanitization to prevent path traversal and store API tokens in a dedicated file (~/.laozhang_api_token) as is common for CLI tools. While the documentation (SKILL.md, README.md) includes an affiliate registration link, there is no evidence of malicious intent, data exfiltration, or unauthorized execution.
能力评估
Purpose & Capability
Name/description (low-cost image generation/editing via LaoZhang) matches the included scripts and SKILL.md. The scripts call the LaoZhang endpoint (api.laozhang.ai) and implement text->image and image-edit functionality as described. Minor manifest mismatch: skill.json/version and registry version differ (1.0.0 vs 1.0.1) but this is cosmetic.
Instruction Scope
SKILL.md and README instruct the user to store an API token in ~/.laozhang_api_token or pass it via --token; the scripts read that file. The scripts make outbound network requests to the LaoZhang API and will also download user-supplied image URLs. This behavior is expected for an image-edit/ generation skill, but it means running the skill will transmit prompts and (potentially) image URLs to a third party and fetch arbitrary URLs provided by user input (possible SSRF if untrusted inputs are used).
Install Mechanism
There is no automated install spec; this is essentially instruction + small Python scripts. The only dependency is 'requests' (documented). No remote archives or executable installs are pulled automatically.
Credentials
The registry metadata lists no required credentials, but the runtime instructions and both scripts require an API token (either via --token or the file ~/.laozhang_api_token). The skill therefore needs a secret (LaoZhang API token) even though no primary credential is declared in the manifest. Storing the token in a plaintext file in the home directory (as suggested) is functional but has confidentiality implications — the skill will read that file if present.
Persistence & Privilege
Skill does not request always:true, does not modify other skills or system configuration, and does not create persistent system services. It runs as CLI scripts and only writes files under the current working directory (generated-images) unless a different path is provided.
如何使用
- 确保已安装 OpenClaw(本地或 Docker 部署)
- 在对话框中输入安装命令:
/install image-gen-cheap - 安装完成后,直接呼叫该 Skill 的名称或使用
/image-gen-cheap触发 - 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.1
- 新用户注册后将自动获得 $0.5 开发测试额度(在快速开始部分新增说明)。
- 其余内容无变化。
v1.0.0
Initial release. Low-cost image generation via LaoZhang API (/bin/zsh.01/img). Supports text-to-image and image editing.
元数据
常见问题
Image Gen Cheap 是什么?
低成本图片生成与编辑。使用老张 API,最低 $0.01/张。支持文生图、图片编辑。触发词:生成图片、画图、AI 作图、文生图、图片编辑。 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 120 次。
如何安装 Image Gen Cheap?
在 OpenClaw 或 Claude Code 对话框中运行命令「/install image-gen-cheap」即可一键安装,无需额外配置。
Image Gen Cheap 是免费的吗?
是的,Image Gen Cheap 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。
Image Gen Cheap 支持哪些平台?
Image Gen Cheap 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。
谁开发了 Image Gen Cheap?
由 enihsago(@enihsago)开发并维护,当前版本 v1.0.1。
推荐 Skills