Skip to content

Together AI embedder

Embeds through Together AI over its OpenAI-compatible /embeddings endpoint. Selected via EMBEDDING_PROVIDER=together.

Enable it

bash
EMBEDDING_PROVIDER=together
TOGETHER_API_KEY=...
EMBEDDING_DIMS=768

Configuration

VariableDefaultDescription
EMBEDDING_PROVIDERopenaiSet to together.
TOGETHER_API_KEYnoneBearer token for Together AI. Calls fail at runtime if unset.
EMBEDDING_DIMS768Vector dimension; must match the embedding model.

Notes

  • Talks to the OpenAI-compatible base URL https://api.together.xyz/v1.
  • The default model is togethercomputer/m2-bert-80M-8k-retrieval.
  • Shares the OpenAI-compatible request loop: 429 and 5xx and network errors retry with backoff, other 4xx fail fast, and a final failure raises for a clean 503.

The memory layer for AI agents.