What an embedding is
OpenAI's definition is compact: an embedding is a vector — a list — of floating-point numbers, and the distance between two vectors measures their relatedness; small distances suggest high relatedness. An embedding model is trained so that passages with similar meaning land near each other even when they share no words, which is what lets a search for cancel my plan find a help article titled ending a subscription.
Vectors have a fixed length set by the model. OpenAI's text-embedding-3-small returns 1,536 numbers by default and text-embedding-3-large 3,072, and both accept a dimensions parameter to return shorter vectors without losing their concept-representing properties — useful because storage and search cost scale with vector length. For comparing vectors, OpenAI recommends cosine similarity.
What embeddings are used for
- Retrieval for RAG — find the passages closest to a question and put them in the prompt; see RAG.
- Semantic search — rank documents by meaning rather than keyword overlap.
- Clustering and deduplication — group similar tickets, reviews or records.
- Classification and recommendation — compare items to labelled examples or to a user's history.
In every case the expensive step — reading the text with a model — happens once per item, and later comparisons are cheap arithmetic on stored vectors.
What embeddings cost
Embedding models bill only input: you pay for the tokens you send, and the vector you get back is free. OpenAI's guide notes that usage is priced per input token, with a maximum input of 8,192 tokens per item on its current models. Rates are a small fraction of a chat model's — the panel below lists the embedding models in our index and their current rates.
The real cost lies around the model. A corpus has to be embedded once and re-embedded whenever documents change — or entirely when you switch embedding models, since vectors from different models are not comparable. Vectors must be stored and searched, which a vector database prices by storage and queries rather than tokens. For a large one-off corpus, the batch API discounts embedding requests too: OpenAI's Batch API accepts the embeddings endpoint.
In our indexEmbedding models in our index
| Model | Vendor | Per 1M input tokens |
|---|---|---|
| text-embedding-3-small | OpenAI | $0.02 |
| Baichuan Text Embedding | Baichuan | $0.0744 |
| Hunyuan Embedding | Tencent (Hunyuan) | $0.104 |
| text-embedding-3-large | OpenAI | $0.13 |
Counted at build from our price index: current embedding models with a published rate, read between 2026-07-11 and 2026-08-31. How we collect prices.