2.2 KiB
0016: Add Kling 4.0 modes to the released K video node
- Status: Accepted
- Date: 2026-10-30
- Owners: Maintainers
Context
Kling 4.0 introduces separate text, keyframe, and Omni reference request
paths. The package already ships K3Video, and replacing it with a new node or
moving its widgets would invalidate saved workflows.
Decision
Keep the K3Video node ID and append a v4 DynamicCombo option. The v4 option
owns a 生成模式 selector with 文生视频, 关键帧, and 全能参考. New keyframe
and reference sockets are appended after the released input block. Request body
validation lives in clients/kling_video_client.py; the node continues to use
the shared upload, polling, cancellation, and download lifecycle.
Consequences
Existing v3, v2.6, and v3-omni workflows retain their positional widget values. Kling 4.0 supports 3–30 seconds, 720p/1080p, up to ten keyframes, ten reference images, and five reference videos through the new branch. Audio voice-profile inputs and named elements remain outside this first integration because the released node has no compatible AUDIO or element-ID sockets.
Alternatives considered
- A new
Kling4Videonode would avoid a larger schema, but would split the K video user experience and require a second registration and migration path. - Reusing the v3 Omni payload without a mode selector would make text-only and keyframe requests ambiguous and could send mutually exclusive media fields.
Validation
tests/test_kling_video.py covers all three payload shapes, capability limits,
mutual exclusions, endpoint selection, and the Kling 4.0 result envelope.
Official path update (2026-11-10)
The first integration used a proxy-compatible model_name / metadata
envelope and /kling/v1/videos/* paths. The published O1Key Kling 4.0 / Flash
docs now require official paths, contents / settings / options bodies,
and the {code, message, request_id, data} query envelope. The v4 option is
retained as the stored Kling 4.0 value; v4-flash is appended, and both are
shown with Chinese display names. Flash is limited to 720p and 3–20 seconds.
Element and voice management remain outside this integration unless the
caller already has IDs.