When to use this
Use this pattern when your application:- Routes requests between providers for fallback or cost control
- Compares providers side by side in the same workflow
- Uses one provider for generation and another for classification or moderation
- Mixes direct provider SDKs with framework-level orchestration
Basic pattern
- Initialize HoneyHive once for the application.
- Instrument each provider library with the same tracer provider.
- Make calls through any instrumented client as usual.
Common patterns
Fallback routing
Try one provider first, then fall back if the primary provider errors or times out.Side-by-side evaluation
Send the same prompt to two providers, log both outputs, and compare them in experiments.Specialized provider roles
Use one provider for long-form generation and another for structured extraction, moderation, or classification.Best practices
- Use one HoneyHive tracer per application or worker process.
- Keep provider selection logic in metadata or span names if you want easier filtering later.
- Use Enriching Traces to record routing decisions such as
provider,fallback_used, ormodel_tier. - For cross-service provider routing, combine this pattern with Distributed Tracing.

