Initial commit with translated description

This commit is contained in:
2026-03-29 14:25:10 +08:00
commit 683bfe09fe
3 changed files with 268 additions and 0 deletions

35
SKILL.md Normal file
View File

@@ -0,0 +1,35 @@
---
name: openai-image-gen
description: "通过OpenAI Images API批量生成图像。"
---
# OpenAI Image Gen
Generate a handful of “random but structured” prompts and render them via OpenAI Images API.
## Setup
- Needs env: `OPENAI_API_KEY`
## Run
From any directory (outputs to `~/Projects/tmp/...` when present; else `./tmp/...`):
```bash
python3 ~/Projects/agent-scripts/skills/openai-image-gen/scripts/gen.py
open ~/Projects/tmp/openai-image-gen-*/index.html
```
Useful flags:
```bash
python3 ~/Projects/agent-scripts/skills/openai-image-gen/scripts/gen.py --count 16 --model gpt-image-1.5
python3 ~/Projects/agent-scripts/skills/openai-image-gen/scripts/gen.py --prompt "ultra-detailed studio photo of a lobster astronaut" --count 4
python3 ~/Projects/agent-scripts/skills/openai-image-gen/scripts/gen.py --size 1536x1024 --quality high --out-dir ./out/images
```
## Output
- `*.png` images
- `prompts.json` (prompt ↔ file mapping)
- `index.html` (thumbnail gallery)