Interface: BoundEmbeddingModel
@providerprotocol/ai / @providerprotocol/ai / BoundEmbeddingModel
Interface: BoundEmbeddingModel<TParams>
Section titled “Interface: BoundEmbeddingModel<TParams>”Defined in: src/types/provider.ts:337
Bound embedding model interface.
Represents an embedding model bound to a specific model ID, ready to generate embeddings.
Type Parameters
Section titled “Type Parameters”TParams
Section titled “TParams”TParams = unknown
Provider-specific parameter type
Properties
Section titled “Properties”dimensions
Section titled “dimensions”
readonlydimensions:number
Defined in: src/types/provider.ts:351
Output embedding dimensions
maxBatchSize
Section titled “maxBatchSize”
readonlymaxBatchSize:number
Defined in: src/types/provider.ts:345
Maximum number of inputs per batch request
maxInputLength
Section titled “maxInputLength”
readonlymaxInputLength:number
Defined in: src/types/provider.ts:348
Maximum length of input text in tokens
modelId
Section titled “modelId”
readonlymodelId:string
Defined in: src/types/provider.ts:339
The model identifier
provider
Section titled “provider”
readonlyprovider:EmbeddingProvider<TParams>
Defined in: src/types/provider.ts:342
Reference to the parent provider
Methods
Section titled “Methods”embed()
Section titled “embed()”embed(
request):Promise<EmbeddingResponse>
Defined in: src/types/provider.ts:359
Execute embedding request.
Parameters
Section titled “Parameters”request
Section titled “request”EmbeddingRequest<TParams>
The embedding request
Returns
Section titled “Returns”Promise<EmbeddingResponse>
Promise resolving to embedding response