sandbox_id to supported APIs. VideoDB routes that job to your sandbox runtime instead of the default hosted path.
Sandbox is not only an indexing feature. It can power understanding analyzers, indexing pipelines, and generation workflows such as text-to-speech, image generation, audio generation, and text generation.
For hosted/default models, omit sandbox_id. For Sandbox Compute/open-weight models, pass sandbox_id explicitly.
When to use Sandbox Compute
Use Sandbox Compute when you want:- Open-weight model access for VLM, object detection, speech, audio, image, or text workflows.
- Specialized models such as Gemma, Qwen, Whisper, OmniVoice, FLUX, Stable Audio, or RT-DETR.
- Predictable routing by pinning a job to a specific sandbox ID.
- Runtime-based pricing for compatible workloads.
Create a sandbox
Choose a tier based on the largest model you plan to run. Creating a sandbox returns immediately while compute is provisioning.Submit sandbox-backed jobs only after the sandbox is active.
Pick a model
Sandbox supports VLMs, speech-to-text, text-to-speech, image generation, audio generation, object detection, and text generation models. Use the smallest sandbox tier that supports the largest model in your workflow.Sandbox Models
See the current model catalog and minimum tier for each model.
Route jobs to the sandbox
Passsandbox_id=sandbox.id to supported APIs.
If sandbox_id is omitted, VideoDB uses the hosted/default path. For production workflows with Sandbox models, pass the ID explicitly so routing is predictable.
Use Sandbox with Understanding and Indexing
Sandbox affects the understanding step: it controls where the model runs. The indexing step is unchanged: index the resulting artifact withvideo.index(...).
Use Sandbox for object detection
For sandbox-backed object detection, choose the detection model in the analyzer config. Configure object filters and aggregations when you create the index.Use Sandbox for generation workflows
Sandbox can also route supported generation jobs. These APIs usemodel_name plus sandbox_id.
OmniVoice text-to-speech
Voice design
Useconfig.instructions to guide the voice style.
Reusable voice clone
Create a voice clone once from a reference audio asset, then reuse it by passingvoice_clone_id.
FLUX image generation
Text generation
Validation and permissions
When you passsandbox_id, VideoDB validates that:
- the sandbox exists and belongs to your workspace/account,
- the sandbox is active,
- the sandbox tier supports the requested model,
- the sandbox was created with a matching
modelsormodel_categoriesvalue, when model selection was provided.
Manage sandboxes
Stop the sandbox
Sandbox billing is based on runtime. Stop the sandbox when your workload is complete.Pricing and limits
Sandbox billing is runtime-based. Billing is recorded when the sandbox stops and is calculated fromstarted_at to stopped_at, rounded to 2 decimal hours.
Best practices
- Create one sandbox per workflow and reuse it across compatible jobs.
- Use the smallest tier that supports your largest model.
- Use
models=[...]when you know the exact models your workflow needs. - Use
model_categories=[...]when your workflow may use several models in the same category. - Wait until the sandbox is active before submitting jobs.
- Pass
sandbox_id=sandbox.idexplicitly for production indexing and generation jobs. - Use
job.wait(timeout=900, interval=5)for long-running generation jobs. - Log
sandbox.idwith each job so runs can be debugged or retried. - Stop the sandbox when work is complete.
Sandbox Models
See supported models and minimum tiers.
Understanding Artifacts
Configure analyzers and model selection.
Create an Index
Index artifacts produced by hosted or sandbox models.