Package-neutral interface for generating embeddings across modalities.
Signature:
export declare interface EmbeddingProvider
Methods
| Method | Description |
|---|---|
| embedContent(content) | Generates a high-dimensional vector embedding for the given content parts. Returns null if the content parts are unsupported by this provider. |
EmbeddingProvider.embedContent()
Generates a high-dimensional vector embedding for the given content parts. Returns null if the content parts are unsupported by this provider.
Signature:
embedContent(content: readonly ContentPart[]): Promise<Float32Array | number[] | null> | Float32Array | number[] | null;
Parameters
| Parameter | Type | Description |
|---|---|---|
| content | readonly ContentPart[] |
Returns:
Promise<Float32Array | number[] | null> | Float32Array | number[] | null