Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/openai/src/types.ts>EmbeddingsOptions

Unofficial Deno wrapper for the Open Ai api
Extremely Popular
Go to Latest
interface EmbeddingsOptions
import { type EmbeddingsOptions } from "https://deno.land/x/openai@1.4.2/src/types.ts";

Properties

model: string

ID of the model to use. You can use the List models API to see all of your available models, or see our Model overview for descriptions of them. https://platform.openai.com/docs/api-reference/embeddings/create#embeddings/create-model

input: string | string[]

Input text to get embeddings for, encoded as a string or array of tokens. To get embeddings for multiple inputs in a single request, pass an array of strings or array of token arrays. Each input must not exceed 8192 tokens in length. https://platform.openai.com/docs/api-reference/embeddings/create#embeddings/create-input

optional
user: string

A unique identifier representing your end-user, which can help OpenAI to monitor and detect abuse. https://platform.openai.com/docs/api-reference/embeddings/create#embeddings/create-user