Spaces:
Running on Zero
Download README.md from hugging-apps/temporal-context-routing: direct link, hf CLI and curl.
- Browser
- Download file 2.38 kB
-
https://huggingface.co/spaces/hugging-apps/temporal-context-routing/resolve/main/README.md
- Command line
-
hf download hf://spaces/hugging-apps/temporal-context-routing/README.md
-
curl -L -o README.md https://huggingface.co/spaces/hugging-apps/temporal-context-routing/resolve/main/README.md
A newer version of the Gradio SDK is available: 6.30.0
title: Temporal Context Routing
emoji: 🎬
colorFrom: gray
colorTo: indigo
sdk: gradio
sdk_version: 6.8.0
python_version: '3.12'
app_file: app.py
short_description: Script-timed multi-shot video with synced audio
startup_duration_timeout: 1h
pinned: false
license: other
The Missing Temporal Link: Temporal Context Routing for Script-Driven Audio-Video Generation
Demo of TCR (paper · model · code).
You write a script: a JSON object whose shots and events carry explicit
time_range fields in seconds. TCR turns those intervals into an additive bias on the
text cross-attention logits, so each text token only routes to the video/audio tokens
that fall inside its own time window. The result is a multi-shot clip that cuts where
the script says it cuts, with dialogue/SFX/music landing on the beat.
What runs here
| Component | Weights |
|---|---|
| Base video+audio DiT | Lightricks/LTX-2.3 ltx-2.3-22b-dev.safetensors (fp8-cast) |
| TCR adapter | starry0929/Temporal-Context-Routing rank-128 LoRA, fused at strength 1.0 |
| Text encoder | google/gemma-3-12b-it |
Sampling matches the authors' scripts/infer.sh: 30 steps, CFG 4.0, STG 1.0 on block 29
(stg_av), temporal_mode=tcr, tcr_beta=5.0, 24 fps. The clip length is derived from
the script's own latest time_range end time (capped at 10 s / 241 frames), because the
TCR bias is expressed in absolute seconds.
Everything is resident on GPU at once (ZeroGPU xlarge, 96 GB), so the reference
pipeline's single-card CPU-offload shuffling is disabled.
Examples
The three bundled scripts come from the authors' own release: clip_32845.json is the
example shipped in the GitHub repo (and used by infer.sh), and clip_22172.json /
clip_24584.json are taken from test_prompts_200.json in the model repo.
License
The LTX-2.3 weights and the TCR adapter are released under the LTX-2 Community License; Gemma is under the Gemma Terms of Use.