Managed Inference and Agents API with Cohere Embed Multilingual
Last updated May 13, 2025
Table of Contents
Cohere Embed Multilingual is an advanced embedding model designed to convert text into dense vector representations across multiple languages. These resulting vectors can be compared to accomplish various goals like similarity.
- Model ID:
cohere-embed-multilingual
- Regions:
us
,eu
When to Use This Model
Cohere Embed Multilingual is ideal for Retrieval-Augmented Generation (RAG) tasks, where you need to search and retrieve relevant documents based on natural-language queries. This model is also useful for building recommendation systems and classification tools that require consistent text embeddings.
Usage
Cohere Embed Multilingual follows our Cohere v1/embeddings API schema.
To provision access to the model, attach cohere-embed-multilingual
to your app $APP_NAME
:
heroku ai:models:create -a $APP_NAME cohere-embed-multilingual --as EMBEDDING
Using config variables, you can invoke cohere-embed-multilingual
in a variety of ways:
- Heroku CLI
ai
plugin (heroku ai:models:call
) curl
- Python
- Ruby
- JavaScript
Example curl
Request
Get started quickly with an example request:
export EMBEDDING_MODEL_ID=$(heroku config:get -a $APP_NAME EMBEDDING_MODEL_ID)
export EMBEDDING_KEY=$(heroku config:get -a $APP_NAME EMBEDDING_KEY)
export EMBEDDING_URL=$(heroku config:get -a $APP_NAME EMBEDDING_URL)
curl $EMBEDDING_URL/v1/embeddings \
-H "Authorization: Bearer $EMBEDDING_KEY" \
-d @- <<EOF
{
"input": ["Hello, I am a blob of text.", "How's the weather in Portland?"],
"model": "$EMBEDDING_MODEL_ID",
"input_type": "search_document",
"encoding_format": "raw"
}
EOF