mirror of
https://github.com/Pasta-Devs/Marinara-Engine.git
synced 2026-12-03 19:00:50 +07:00
[PR #8872] [MERGED] feat(images): GPT Image 2.6 and the shared animated GIF option #8854
Labels
No labels
android
bug
bugfix
ci
client
code freeze pause
container
dependencies
docs
documentation
duplicate
enhancement
feature
feature
feature
feature-creep
fixed-in-refactor
fixed-in-staging
good first issue
help wanted
in-pr
in-pr
needs-codeowner-decision
normal-scope
old-codebase
old-codebase
pull-request
qol
question
refactor
regression
revisit later
roadmap
scope-risk
scope-risk
server
server
shared
soup
upstream
windows
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Pasta-Devs/Marinara-Engine#8854
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/Pasta-Devs/Marinara-Engine/pull/8872
Author: @SpicyMarinara
Created: 11/5/2026
Status: ✅ Merged
Merged: 11/5/2026
Merged by: @SpicyMarinara
Base:
staging← Head:feat/gpt-image-26-foundation📝 Commits (4)
fd7d6b7feat(images): GPT Image 2.6 and animated GIF output (foundation)3eeb28ffix(images): GPT Image 2.6 foundation review fixes502f399Merge remote-tracking branch 'origin/staging' into feat/gpt-image-26-foundation378abb8docs(images): say that Regenerate forwards a GIF in the feature that first saves one📊 Changes
17 files changed (+1128 additions, -101 deletions)
View changed files
📝
docs/development/optional-agent-packages.md(+33 -1)📝
docs/media/image-providers.md(+27 -3)➕
e2e/gpt-image-2-6.e2e.ts(+69 -0)📝
packages/client/src/localization/locales/en.json(+21 -1)📝
packages/server/src/routes/characters.routes.ts(+16 -2)📝
packages/server/src/services/capability-packages/capability-module-runtime.service.ts(+2 -0)📝
packages/server/src/services/image/image-generation.ts(+141 -62)📝
packages/server/src/services/media/toapis-media.ts(+8 -22)📝
packages/shared/src/constants/model-lists.ts(+73 -0)📝
packages/shared/src/schemas/capability-package.schema.ts(+8 -1)📝
packages/shared/src/types/capability-runtime.ts(+2 -0)📝
packages/shared/src/types/generation-integration.ts(+12 -0)📝
packages/shared/src/utils/chat-image-generation.ts(+29 -6)📝
packages/shared/src/utils/openai-image.ts(+47 -1)📝
scripts/regressions/capability-package-lifecycle.regression.ts(+2 -2)📝
scripts/regressions/capability-runtime-host-services.regression.ts(+2 -0)➕
scripts/regressions/gpt-image-2-6.regression.ts(+636 -0)📄 Description
Linked issue
Closes #8871. Part of #8870: the features that use this come as their own PRs, and the last one closes #8870.
Why this change
OpenAI's GPT Image 2.6 (Flare and Sunburst, 2026-11-04) makes animated GIFs from a prompt through the Images API. Marinara didn't recognize the 2.6 model ids, so they took the old DALL-E path. Nothing could request a GIF. This PR adds the models and one shared, guarded way to ask for a GIF. Animated expressions, Conversation GIFs, Illustrator GIFs and Otome Hearth's GIF stickers build on it.
What changed
ImageGenRequest.animation(frameCount,frameDurationMs). Frames are clamped to 2–12, at 20–2000 ms each in 10 ms steps, with defaults of 9 frames at 200 ms. Each frame is the smallest valid size, since OpenAI doesn't publish its total GIF pixel budget.imageConnectionMakesAnimatedGif, now in@marinara-engine/sharedso client and server agree, and enforced once ingenerateImage, before any paid call:gpt-image-2.6-*model on the native OpenAI backend may make GIFs.openai/…, NanoGPT, ToAPIs, 2.5, and a request that carries a picture (OpenAI's GIF output can't animate one).output_format: "gif"withframe_countandframe_duration_mson/v1/images/generationsonly, with a loop line added to the prompt.output_compression.image/gifthrough gallery, thumbnails and avatar saves. Backgrounds and video first frames stay stills.animationis available to packages throughimages.generate. The server runtime host now reportscapabilityApi, so a server package can tell an older Engine apart before paying. Older Engines refuse a package that requires 1.816.animation. A refusal is a 400 withcode: "animation-unsupported".docs/media/image-providers.mdcovers 2.6 and its GIF limits, anddocs/development/optional-agent-packages.mdcovers Capability API 1.816. English UI keys for the feature PRs are added toen.json; the canonical catalog only.Validation
pnpm checkpasses locallyCONTRIBUTING.mdManual verification notes
Agent-run checks:
New
scripts/regressions/gpt-image-2-6.regression.ts, with a fake OpenAI server, covers:A mutation pass showed it fails when any guard is removed or moved.
node ./scripts/run-regressions.mjswith theimage(30/30),gpt-image(3/3),avatar(27/27),capability-package-lifecycle,capability-runtime-host-servicesandchat-imagefilters: all pass.pnpm check: passed on the branch. After merging current staging: server and clienttsc --noEmitandpnpm localization:checkpass.e2e/gpt-image-2-6.e2e.ts: passed on desktop-chromium.Independent review from four angles (contract, OpenAI bodies, save paths, tests): 7 findings, all fixed in the second commit.
Already broken before this branch, out of scope:
e2e/gpt-image-2-5.e2e.tslooks for.mari-editor-panel, which the connection editor no longer has.Docs and release impact
docs-i18nbranch updated to match, or a[docs-i18n]follow-up issue opened (see CONTRIBUTING.md § Translated documentation)🤖 Generated with Claude Code
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.