Vectors (embeddings) generated from text.
Class Embeddings: 1 methods (0 in @owbase/web, 1 in @owbase/node). The examples use the object form of the parameters; replace the values between < and > with your own.
createTextEmbeddings
Section titled “createTextEmbeddings”Create Text Embedding
POST /embeddings/text · method page
SDK: @owbase/node only
Generate vector embeddings for an array of text using the selected embedding model. Use the returned vectors to power semantic search and similarity queries against your vector collections.
| Parameter | Type | Required | Description |
|---|---|---|---|
texts |
string[] |
yes | Array of text to generate embeddings. |
model |
EmbeddingModel |
no | The embedding model to use for generating vector embeddings. Values: nomic-embed-text, all-minilm. |
Access: API key with the embeddings.write scope or user session, or even no session (the resource’s permissions apply).
import { Client, Embeddings, EmbeddingModel } from '@owbase/node';
const client = new Client() .setEndpoint('https://cloud.owbase.dev/v1') // Your API Endpoint .setProject('<YOUR_PROJECT_ID>') // Your project ID .setKey('<YOUR_API_KEY>'); // Your secret API key
const embeddings = new Embeddings(client);
const result = await embeddings.createTextEmbeddings({ texts: [ 'Owbase helps developers build applications.', 'Find documents with semantic search.', ], model: EmbeddingModel.NomicEmbedText, // optional});The descriptions on this page come from the server API specification (BSD-3-Clause license), and the examples come from the SDK generator (MIT license). The full notices are in the NOTICE file of the @owbase/web and @owbase/node packages.