Skip to main content

Model Constraints

Some models have rules about their input — a max audio length, a fixed image size, or "exactly one face per query". If you break one, you get a clear error. Here's what to watch for per family.

Audio Models (CLAP)

ConstraintValueNotes
Max duration10 secondsLonger clips will error with AudioTooLongError
Sample rate48 kHzAudio is automatically resampled
Max samples480,00048,000 Hz × 10 seconds
PreprocessingRequiredNoPreprocessing not supported - always use ModelPreprocessing

Face Models (Buffalo_L, SFace+YuNet)

ConstraintValueNotes
Input size640x640 pxImages are resized internally
Face alignment112x112 pxStandard ArcFace alignment
Embedding modeOneToManyReturns one embedding per detected face
PreprocessingRequiredNoPreprocessing not supported
Query constraintSingle faceQuery images must contain exactly 1 face

Cross-modal pairs

Certain text and media encoders share a dimension so you can search across modalities — see Cross-modal pairs on the Models page.