Skip to main content
Clients send the OpenAI embeddings body to /v1/embeddings on the application URL, with the same key they use for chat. Google’s SDKs can keep their own embeddings calls instead: see Gemini and Vertex AI shapes.

Which registries can serve it

Anthropic, Gemini AI Studio, and Bedrock’s chat models do not embed and are left out of the candidate pool automatically.

How it routes

The application’s registries are narrowed to those that advertise embeddings, then routing runs on that pool as usual. Two edges:
  • Pinning a registry that cannot embed — with @provider/model — is a 400, not a silent failover. You asked for something impossible; the gateway says so.
  • No capable registry at all is a 503. Attach one.
A pool that mixes chat and embeddings providers is the normal case. Chat uses every chat-capable member; embeddings skip the rest. Use the Capability filter in Registry to see which providers qualify.

Gemini and Vertex AI shapes

The Gemini and Vertex AI model paths that serve chat also take the embeddings actions Google’s SDKs send:
curl
The model comes from the path, and project and location are ignored, as for chat. These calls route like /v1/embeddings: any registry that can embed serves them, not only Vertex AI, and the gateway translates in both directions.
  • The response follows the action called. :embedContent returns {"embedding": …}. :batchEmbedContents returns {"embeddings": [...]}, even for a single request. :predict returns predictions[].embeddings.values.
  • :predict is for embedding models only: gemini-embedding-*, text-embedding-* and text-multilingual-embedding-*. Any other :predict, and :predict on /v1beta/models/…, is a 404, as are :countTokens, :rawPredict and unknown actions.
  • One content is one vector. Its text parts are joined. A request with non-text parts or no text, or a batch that mixes taskType or outputDimensionality values, is a 400 in the Gemini error format.
  • Options are carried where the provider has them. taskType and title reach Vertex AI, and taskType becomes Cohere’s input_type. outputDimensionality becomes dimensions on OpenAI and Azure OpenAI and is dropped for Mistral, OpenAI-compatible, Titan and Cohere.