DriftOSDriftOS
Guides

Choosing a Routing Engine

DriftOS Core vs DriftOS Embed - which one is right for you?

DriftOS offers two routing strategies: Core (LLM-based) and Embed (embedding-based). Here's how to choose.

Quick Decision

Use DriftOS Core if:

  • Accuracy matters more than speed
  • Users frequently switch between topics
  • You need nuanced semantic understanding
  • Your application handles complex, multi-topic conversations

Use DriftOS Embed if:

  • Speed is critical (need <50ms routing)
  • You want zero LLM costs for routing
  • Topics are generally distinct and sequential
  • You're handling high message volumes

Detailed Comparison

FeatureDriftOS CoreDriftOS Embed
Routing EngineLLM (Groq)Embeddings (local)
Latency~100ms~50ms
Cost per route~$0.001$0
AccuracyHigh (semantic reasoning)Good (similarity matching)
ROUTE action✅ Can return to old topics❌ Creates new branches
Handles sarcasm✅ Yes❌ No
Handles negation✅ Yes⚠️ Limited
Branch count (100 msgs)~5-8 branches~8-12 branches
Token savings70-85%75-90%

Example Scenarios

Scenario 1: Customer Support Chatbot

Use Case: Multi-issue support conversations

User: "My login isn't working"
→ Branch: login-issue

User: "Also, I can't find my invoice"
→ Branch: invoice-issue

User: "Back to the login thing—I tried resetting my password"
→ ROUTE back to login-issue (Core) or new branch (Embed)

Recommendation: DriftOS Core

  • Users frequently jump between issues
  • Need to track context for each issue separately
  • ROUTE action keeps branches clean

Scenario 2: High-Volume FAQ Bot

Use Case: Simple, sequential questions

User: "What are your hours?"
→ Branch: hours-info

User: "Do you deliver?"
→ Branch: delivery-info

User: "What's your return policy?"
→ Branch: return-policy

Recommendation: DriftOS Embed

  • Questions are distinct and sequential
  • Speed matters for high volume
  • No need for complex topic switching
  • Zero routing costs

Scenario 3: Research Assistant

Use Case: Complex, exploratory conversations

User: "Tell me about quantum computing"
→ Branch: quantum-computing

User: "Not that kind—I meant quantum mechanics in general"
→ Core detects clarification, Embed might create new branch

User: "Going back to quantum computing—what about qubits?"
→ ROUTE to quantum-computing (Core) or new branch (Embed)

Recommendation: DriftOS Core

  • Nuanced topic shifts and clarifications
  • User frequently circles back to topics
  • Semantic understanding critical

Performance Comparison

DriftOS Core

Strengths:

  • Understands "I don't want to talk about X" (negation)
  • Detects when "Back to X" means ROUTE, not new branch
  • Handles sarcasm and subtle context shifts
  • Lower branch count (cleaner conversation graph)

Limitations:

  • ~100ms latency (LLM inference)
  • Small cost per routing decision (~$0.001)

DriftOS Embed

Strengths:

  • Sub-50ms routing decisions
  • Zero API costs for routing
  • Deterministic and predictable
  • Great for distinct, obvious topics

Limitations:

  • Cannot detect topic returns—creates new branches instead
  • Struggles with sarcasm, negation, and synonyms
  • Higher branch count over time

Example limitation:

User: "I don't want to talk about dogs"
Embed: Matches "dogs" topic (high similarity)
Core: Understands negation, creates new branch

Switching Between Engines

You can switch routing engines without losing data:

// Start with Embed
const client = createDriftClient(
  'https://api.driftos.dev/api/v1/embed',
  'YOUR_API_KEY'
);

// Switch to Core later
const client = createDriftClient(
  'https://api.driftos.dev/api/v1/llm',
  'YOUR_API_KEY'
);

Existing branches and messages are preserved. New messages use the new routing strategy.

When in Doubt

Start with DriftOS Core.

It's the safer default for most applications. You can always switch to Embed later if you need more speed or lower costs.


Next Steps

On this page