Skip to content

Multi-provider failover

DXPR AI Provider connects to the DXAI Kavya platform, which routes AI requests across five providers: OpenAI, Anthropic Claude, Google Gemini, XAI, and MistralAI. When one provider is unavailable or returns an error, Kavya automatically switches to the next provider in your configured priority order.

Available models

Model Default provider Fallback chain Use case
kavya-m1 Anthropic Claude OpenAI, Mistral, Gemini, XAI General use with maximum reliability
kavya-m1-eu Mistral Large Mistral Small EU data residency and GDPR compliance
kavya-m1-fast Gemini Flash Lite XAI Grok Low-latency and interactive use

kavya-m1 is the default, with the broadest failover coverage. kavya-m1-eu restricts processing to MistralAI's European infrastructure and never fails over to a non-EU provider. kavya-m1-fast prioritises low latency.

Configuring provider priority

Navigate to /admin/config/ai/providers/dxpr to open the DXPR AI Provider settings form. The Provider priority section shows a drag-and-drop table with a row for each provider, including its logo and name.

Provider failover ordering UI showing drag-and-drop reordering of AI providers

Each provider row can be dragged between two regions:

  • Enabled: providers in this region are available for failover, ordered from top (highest priority) to bottom.
  • Disabled: providers in this region are never used.

The top-most enabled provider is labelled Primary with a badge. Kavya tries this provider first on every request.

Selection mode

Two modes control how Kavya picks a provider:

  • Automatic: Kavya uses its default provider priority for the selected model (see the table above). The provider priority table is hidden.
  • Manual Override: shows the provider priority table so you can control the failover order. Kavya follows your ordering strictly.

Manual Override is useful when you want a specific provider (for example, one that handles tool calls or structured output best) to always be tried first.

How failover works

  1. A chat, image, or translation request arrives at Kavya.
  2. Kavya sends the request to the primary provider.
  3. If that provider returns an error or times out, Kavya retries with the next enabled provider in priority order.
  4. This continues until a provider succeeds or all enabled providers have been tried.
  5. If every provider fails, the module returns the last error to Drupal so it can be logged and displayed.

Failover is transparent to consuming modules: they receive a single response regardless of how many providers were tried. The response metadata includes the original_model field so you can see which provider actually handled the request.

EU data residency

Select kavya-m1-eu as your model to ensure all AI processing stays within European boundaries. The Kavya server runs in the Netherlands with a backup in Germany; requests are routed through MistralAI servers in France. It is designed for organisations subject to GDPR or other EU data residency requirements.

kavya-m1-eu uses a single provider (MistralAI) with model-level fallback: if Mistral Large is unavailable, Kavya falls back to Mistral Small. It never falls back to a non-EU provider.

Provider comparison

How DXPR AI Provider compares with other Drupal AI provider modules:

Reliability

Feature DXPR amazee.ai OpenAI Anthropic
Multi-provider failover ✅ Configurable Opaque ❌ ❌

Content quality

Feature DXPR amazee.ai OpenAI Anthropic
Em-dash post-processing ✅ 4 levels + per-language ❌ ❌ ❌
Long-form content (10k+ words) ✅ ❌ Model limit Model limit
HTML-aware generation ✅ Tag/class safeguards ❌ ❌ ❌
Built-in web research ✅ Perplexity AI ❌ ❌ ❌

Models and access

Feature DXPR amazee.ai OpenAI Anthropic
Models available 5 providers via Kavya GPT, Claude+ OpenAI only Claude only
EU data residency ✅ NL/DE/FR ✅ DE/CH ✅ EU endpoint ❌
Free tier ✅ 10k words/mo Dev trial BYO key BYO key

Capabilities

Feature DXPR amazee.ai OpenAI Anthropic
Image generation ✅ ✅ ✅ ❌
Image vision ✅ ✅ ✅ ✅
Structured output (JSON) ✅ ✅ ✅ ✅
Native translate_text ✅ Content-aware ❌ ❌ ❌
Semantic search / RAG ❌ ✅ Via VDB add-on ❌
Streaming ✅ ✅ ✅ ✅
Planning and reasoning ✅ ❌ ❌ ❌