feat: add 16:9 and 2K size presets for gpt-image-2
- Add 1536x864, 864x1536, 2048x1152, 1152x2048, 2560x1440 to the size dropdown. 2560x1440 is the OpenAI cookbook's recommended upper widescreen reliability boundary - Note that sizes above 2560x1440 are experimental and the max-edge rule is strictly <3840 (3840x2160 is out, use 3824x2144 instead) - 1920x1080 is invalid because 1080 isn't a multiple of 16 — captured in AGENTS.md alongside the full constraint set so future agents stop proposing it
This commit is contained in:
@@ -91,6 +91,14 @@ Three files do everything:
|
||||
- Targets the **gpt-image series only** (gpt-image-2 default). Do not
|
||||
reintroduce DALL·E-only fields like `response_format` — gpt-image
|
||||
always returns `b64_json`.
|
||||
- `gpt-image-2` size constraints (per the OpenAI cookbook): both edges
|
||||
multiple of 16, max edge **< 3840**, long/short ≤ 3:1, total pixels
|
||||
in 655,360–8,294,400, `auto` not supported. Exact 16:9 requires
|
||||
`16k × 9k` with `k` a multiple of 16 (so `1280×720`, `1536×864`,
|
||||
`2048×1152`, `2560×1440`, …). Sizes above 2560×1440 are
|
||||
experimental — the popular 4K target `3840×2160` violates the
|
||||
`< 3840` rule, round down to `3824×2144` if you need it. Common
|
||||
misses: `1920×1080` is **not valid** (1080 % 16 ≠ 0).
|
||||
- `client.ts` — browser entry, loaded via `<script type="module"
|
||||
src="./client.ts">` in `index.html`. Bun's bundler resolves the import,
|
||||
inlines `@microsoft/fetch-event-source`, and serves the bundle from
|
||||
|
||||
Reference in New Issue
Block a user