Skip to main content
Voyage AI provides high-quality embedding models optimized for search and retrieval. This guide shows you how to configure Meilisearch with Voyage AI embeddings using the REST embedder.

Requirements

  • A Meilisearch project
  • A Voyage AI account with an API key

Available models

Voyage AI offers the following embedding models:
ModelDimensionsUse case
voyage-4-large256, 512, 1,024, or 2,048Best general-purpose and multilingual retrieval quality
voyage-4256, 512, 1,024, or 2,048Balanced general-purpose and multilingual
voyage-4-lite256, 512, 1,024, or 2,048Optimized for latency and cost
voyage-code-3256, 512, 1,024, or 2,048Specialized for code retrieval
voyage-finance-21,024Specialized for finance
voyage-law-21,024Specialized for legal
All Series 4 models support 32,000 token context and flexible output dimensions.
The older voyage-3.5 and voyage-2 families are still supported but Voyage recommends upgrading to the Series 4 for better performance. See the Voyage AI documentation for the full model catalog.

Configure the embedder

Update your index settings with the Voyage AI embedder configuration:
{
  "voyage": {
    "source": "rest",
    "apiKey": "<VOYAGE_API_KEY>",
    "documentTemplate": "A product named '{{doc.name}}': {{doc.description}}",
    "url": "https://api.voyageai.com/v1/embeddings",
    "request": {
      "model": "voyage-4-lite",
      "input": ["{{text}}", "{{..}}"]
    },
    "response": {
      "data": [
        { "embedding": "{{embedding}}" },
        "{{..}}"
      ]
    }
  }
}
Send this configuration to Meilisearch:
curl \
  -X PATCH 'MEILISEARCH_URL/indexes/INDEX_NAME/settings' \
  -H 'Content-Type: application/json' \
  -H 'Authorization: Bearer MEILISEARCH_KEY' \
  --data-binary '{
    "embedders": {
      "voyage": {
        "source": "rest",
        "apiKey": "<VOYAGE_API_KEY>",
        "documentTemplate": "A product named '\''{{doc.name}}'\'': {{doc.description}}",
        "url": "https://api.voyageai.com/v1/embeddings",
        "request": {
          "model": "voyage-4-lite",
          "input": ["{{text}}", "{{..}}"]
        },
        "response": {
          "data": [
            { "embedding": "{{embedding}}" },
            "{{..}}"
          ]
        }
      }
    }
  }'
Replace <VOYAGE_API_KEY> with your actual Voyage AI API key. Adjust model depending on your quality and cost requirements. Meilisearch handles batching and rate limiting automatically. Monitor the tasks queue to track indexing progress.
{
  "q": "comfortable shoes for walking",
  "hybrid": {
    "semanticRatio": 0.5,
    "embedder": "voyage"
  }
}

Next steps