linoyts/repo-to-space-example-videos
Gradio Space Example Inputs — Videos A small, curated, freely-licensed pool of videos used as gr.Examples for Gradio Spaces that wrap video-input generation models (image-to-video, video-to-video, motion controls, etc.). Sister dataset for images: linoyts/repo-to-space-example-inputs. When a Space takes video input, the agent building the Space picks 2–3 clips whose caption + categories match the model's task, downloads them via hf_hub_download, runs any model-specific… See the full description on the dataset page: https://huggingface.co/datasets/linoyts/repo-to-space-example-videos.
Gradio Space Example Inputs — Videos
A small, curated, freely-licensed pool of videos used as gr.Examples for Gradio Spaces that wrap video-input generation models (image-to-video, video-to-video, motion controls, etc.). Sister dataset for images: `linoyts/repo-to-space-example-inputs`.
When a Space takes video input, the agent building the Space picks 2–3 clips whose caption + categories match the model's task, downloads them via hf_hub_download, runs any model-specific preprocessing (trim / resize to expected shapes), and wires them into gr.Examples. The Space ships the preprocessed copies; this dataset is the source of truth.
The set is intentionally diverse on subject, motion, framing, and style so a caller can pick examples that flatter a specific model without needing to source new media each time.
Schema
metadata.jsonl — one JSON object per line, one record per asset:
{
"file_name": "podcaster.mp4",
"type": "video",
"width": 720,
"height": 1280,
"duration_s": 9.6,
"fps": 25.0,
"categories": ["motion", "person", "indoor"],
"caption": "A young woman with long lavender-purple hair ...",
"source": "pexels-or-similar",
"license": "free-to-use (CC0-style)"
}The asset key is file_name (with underscore) — required by HF's folder_based_builder for the dataset viewer; other spellings (filename, path, ...) break it with SplitsNotFoundError.
categories are for cheap pre-filtering (drop dialogue for a pose-driven motion model, etc.). caption is for the finer matching step against the target model's task or example prompts.
Picking examples for a Space
- Soft filter by `categories` — drop tags that are clearly off-task for the target model.
- Rank by caption fit — read the surviving captions against the model's task description, trigger words, or example prompts; pick 2–3 the model will plausibly produce a good output on, not just any input that doesn't crash.
- Diversify the final picks — different subjects, framings, or motion types — so the Examples row teaches users the breadth of what the Space handles.
from huggingface_hub import hf_hub_download
import json
DATASET = "linoyts/repo-to-space-example-videos"
meta = [json.loads(l) for l in open(
hf_hub_download(DATASET, filename="metadata.jsonl", repo_type="dataset"))]
# ... filter + rank using `categories` and `caption` ...
chosen = ["podcaster.mp4", "man_dancing.mp4", "cat.mp4"]
paths = [hf_hub_download(DATASET, filename=f, repo_type="dataset") for f in chosen]
# preprocess paths (e.g. LTX wants 8k+1 frames, dims divisible by 32) and pass
# to gr.Examples in the Space.Pre-bake the preprocessed copies into the Space repo. Don't rely on the dataset at Space runtime, and don't set cache_examples=True on ZeroGPU.
Source-shape constraints
- Videos: max 720 px on the short edge, ≤10 s, libx264 CRF 23, no audio.
Callers resize / trim further per model (e.g. LTX wants 8k+1 frames and dimensions divisible by 32).
License
All assets are sourced from royalty-free providers (Pexels / Unsplash and similar) under licenses that permit redistribution and modification without attribution. Released here as CC0-1.0 for simplicity.
