From 358f4179b969e7171ec724e403d1db0f7f3257a7 Mon Sep 17 00:00:00 2001 From: Weiming Liao Date: Thu, 3 Dec 2026 13:06:02 +0800 Subject: [PATCH 1/2] [feat] character-replacement (6/N): submit FastH3 segments with native guides Signed-off-by: Weiming Liao --- apps/api/src/opendirector_api/localization.py | 5 + .../multipart-receipts.json | 107 +++++++++++ .../application/creation_generation.py | 21 ++- .../application/model_availability.py | 4 +- .../domain/creation/generation.py | 53 +++++- .../opendirector/domain/video_capabilities.py | 23 +++ .../infrastructure/model_configs.py | 21 ++- .../opendirector/integrations/providers.py | 8 +- .../integrations/reference_inputs.py | 20 ++- .../opendirector/integrations/vllm_omni.py | 42 ++++- .../core/src/opendirector/media/processing.py | 15 ++ src/contracts/creation.schema.json | 166 ++++++++++++++++++ src/contracts/generated.ts | 16 ++ tests/test_h3_keyframes.py | 4 +- tests/test_vllm_omni_h3.py | 133 ++++++++++++++ 15 files changed, 611 insertions(+), 27 deletions(-) create mode 100644 feature-assets/fasth3-segment-guide/multipart-receipts.json diff --git a/apps/api/src/opendirector_api/localization.py b/apps/api/src/opendirector_api/localization.py index fd3d72d25..db80807e4 100644 --- a/apps/api/src/opendirector_api/localization.py +++ b/apps/api/src/opendirector_api/localization.py @@ -16,6 +16,11 @@ from opendirector.domain.capability_messages import english_capability_message, missing_tool_model_message ENGLISH_BY_CODE = { + "h3_timeline_guides_single_model": "Configure native timeline guides for one FastH3 model at a time.", + "h3_timeline_guides_mixed": "Use either generated-video guides or standalone keyframes for this segment.", + "h3_timeline_guides_unsupported": "This deployment or video mode does not support H3 segment timeline guides.", + "h3_timeline_guides_deployment": "Native timeline guide settings require a compatible self-hosted FastH3 endpoint.", + "h3_timeline_guides_source_limit": "Use only one source video for an H3 segment.", 'keyframe_unsupported': 'This model or mode does not support keyframes. Clear the keyframe times or choose another model.', 'keyframe_mode': 'Keyframes work in Universal reference mode only, not with first/last frames, continuation or structure control.', 'keyframe_kind': 'A keyframe must be an image.', diff --git a/feature-assets/fasth3-segment-guide/multipart-receipts.json b/feature-assets/fasth3-segment-guide/multipart-receipts.json new file mode 100644 index 000000000..72579ef65 --- /dev/null +++ b/feature-assets/fasth3-segment-guide/multipart-receipts.json @@ -0,0 +1,107 @@ +{ + "provider": "in-process double returning the synthetic fixture bytes", + "runs": { + "anchor": { + "sourceFrames": null, + "requestFields": { + "model": "FastH3-Omni", + "prompt": "Preserve the motion of the synthetic test pattern.\nsource.mp4\ufffd\ufffd\ufffd