Skip to content

fix(video): seedance-2.5 takes reference clips; per-model reference ceiling - #166

Merged
VickyXAI merged 1 commit into
mainfrom
fix/seedance-2.5-reference-clips
Oct 2, 2026
Merged

VickyXAI merged 1 commit into
mainfrom
fix/seedance-2.5-reference-clips

Conversation

@VickyXAI

@VickyXAI VickyXAI commented Oct 2, 2026

Copy link
Copy Markdown
Contributor

Why

The gateway now serves reference video/audio on bytedance/seedance-2.5, and the clip ceiling is per model. blockrun_video still refused clips on 2.5 and reserved every clip at a flat 15.2s.

Gateway evidence

BlockRunAI/enterprise origin/main @ 87ffed0e, file src/vendor/gateway/lib/models.ts. The change landed in e072ab36 (#297 / #311, 2026-09-25):

  • seedance-2.5 entry: supportsReferenceMedia: true ("On since 2026-09-26 (enterprise#297): ceiling 30.2s probed, rate measured at the same 21,600 tok/s as 2.0"). Description: "up to 30 reference images, and reference video/audio clips up to 30s each (billed per reference second)".
  • REFERENCE_CEILING_SECONDS: seedance-2.0, -2.0-fast and -2.0-mini are 15.2. seedance-2.5 is 30.2. 1.5-pro has no entry (upstream: "supports at most 0 reference_videos").
  • app/api/v1/videos/generations/route.ts: reference_videos / reference_audios are .max(3) each, and every clip is quoted at its model's ceiling. A model with no ceiling refuses clips.
  • Wallet rails are unchanged. blockrun (src/app/api/v1/videos/generations/route.ts:180) and blockrun-sol (route.ts:157) both still call checkReferenceMediaIsEnterpriseOnly, which returns a 400 for every reference_* field. So reference media stays account-rail only, 2.5 included.

Changes

  • src/tools/video.ts
    • Adds REFERENCE_CEILING_SECONDS, which mirrors the gateway map. The set of models that take reference clips is derived from it, so 2.5 is now in that set.
    • Exports referenceCeilingSeconds().
    • estimateVideoCost prices each clip at its model's ceiling. For a token-priced model with no ceiling (1.5-pro) it throws instead of borrowing another model's ceiling.
    • Tool and field descriptions now name 2.5 for clips and give each family its ceiling.
  • docs/seedance-capabilities.md: the matrix row for 2.5 now allows clips. Adds a ceiling table and 2.5 reserve examples ($1.58 / $11.07 / $38.59).
  • README.md: the tools table now gives the per-model ceiling.
  • README.md and docs/mcp-schema-overhead.md: the schema token rows are re-measured (full 14,046, media 6,827). The card stays 14.0K / 61%.
  • CHANGELOG.md: adds an Unreleased entry. There is no version bump.

Tests

test/video-reference-media.test.ts:

  • The ceiling is per model: 15.2 on the 2.0 family, 30.2 on 2.5, none for 1.5-pro, grok, sora or prototype keys.
  • A 2.5 clip is reserved at 30.2s: ~$11.07 for 5s 720p with one video. That is at or above the gateway's whole-second (30s) charge. Audio is 0.3x video. The clip-seconds ratio to 2.0 is 30.2/15.2.
  • 1.5-pro with references throws in the estimator. 1.5-pro and sora clips are still refused by the handler.
  • 2.5 forwards video+audio clips, and 3+3 clips alongside 30 images. 2.5 audio-only and 2.5 clip + image_url are still refused.
  • 2.5 reference clips are refused on both wallet rails.
  • On the account rail, the budget gate reserves the 30.2s-ceiling price for a 2.5 job.
  • The schema descriptions name 2.5 and the per-model ceilings.

test/video-models.test.ts: renamed the 2.0 ceiling test.

Results: npm run build, npm run typecheck, npm test (1372/1372) and sync-brand-numbers --check all pass. The repo has no lint script.

🤖 Generated with Claude Code

…eiling

The gateway enabled reference video/audio on seedance-2.5 on 2026-09-26
(enterprise#297): supportsReferenceMedia is true and the clip ceiling was
probed at 30.2s, twice the 2.0 family's 15.2s. blockrun_video still refused
reference_videos / reference_audios on 2.5 and reserved every clip at a flat
15.2s, which would have under-reserved a 2.5 clip by half on the account
rail, where the reserve is the only pre-payment budget control.

- REFERENCE_CEILING_SECONDS mirrors the gateway map (2.0 / 2.0-fast /
  2.0-mini 15.2s, 2.5 30.2s); the reference-clip model set is derived from it.
- estimateVideoCost prices clips at the model's own ceiling and throws for a
  token-priced model with no ceiling (1.5-pro) instead of borrowing one.
- Tool description, field descriptions, README and seedance-capabilities doc
  name 2.5 for clips and give each family its ceiling.
- Wallet-rail rule unchanged: both wallet gateways still 400 every reference
  field, 2.5 included.
- Schema token table updated for the description change (14,046 full).
@VickyXAI
VickyXAI merged commit 32be985 into main Oct 2, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant