Skip to content

Titan Text Embeddings V2

Titan Text Embeddings V2 is Amazon's text embedding model tuned for retrieval-augmented generation (RAG). Vectors only; no output token charge. You can choose 256-, 512-, or 1024-dimensional output vectors, with support for 100+ languages.

index.ts
import { embed } from 'ai';
const result = await embed({
model: 'amazon/titan-embed-text-v2',
value: 'Sunny day at the beach',
})

Frequently Asked Questions

  • What embedding dimensions are available?

    256, 512, or 1024. The default is 1024. Smaller dimensions reduce storage and index size. The 512-d option retains roughly 99% accuracy versus 1024-d, and 256-d retains roughly 97%.

  • What is the maximum input length?

    Up to 8,192 tokens or roughly 50,000 characters per input string. For retrieval tasks, segment documents into logical paragraphs or sections rather than using the full token budget per chunk.

  • Does the model support multilingual inputs?

    Yes. Titan Text Embeddings V2 supports 100+ languages, including Arabic, Chinese, French, German, Hindi, Japanese, Korean, Russian, and Spanish. You can mix languages in one index when your retrieval evaluations stay strong enough.

  • Should I normalize embeddings for RAG use cases?

    Yes. Normalization improves cosine similarity accuracy when comparing query and document embeddings.

  • Can I mix vector dimensions in the same index?

    No. All vectors in a given index must share the same dimension. Choose your dimension before initial indexing, as changing it requires reprocessing and reindexing all stored vectors.

  • How is the model priced?

    This page lists the current rates. Multiple providers can serve Titan Text Embeddings V2, so AI Gateway surfaces live pricing rather than a single fixed figure.

  • What use cases is V2 optimized for compared to V1?

    V2 is optimized for RAG, multilingual retrieval, and code embedding. It uses a 1024-dimension default versus V1's 1536 dimensions, which cuts vector storage with strong retrieval accuracy at the tested dimensions.