← Back to FAQ

Can 0xDoktor Handle Multi-Turn Conversations?

Verified answer

What is a multi-turn conversation?

A multi-turn conversation is one where the user asks follow-up questions that reference earlier turns. For example:

User: "How do I reset my password?" Bot: "Go to Settings → Security → Reset password." User: "What if I don't see that option?"

Without multi-turn context, the second question would be answered in isolation. With context, the AI understands "that option" refers to the reset password flow described in the first answer.

How does 0xDoktor implement conversation context?

Pass a conversationId in your API request:

{
  "tenantId": "your-tenant-id",
  "question": "What if I don't see that option?",
  "conversationId": "conv_abc123"
}

On the first request with a new conversationId, 0xDoktor creates a new session. On subsequent requests with the same ID, it includes the prior turns as context for both retrieval and generation.

The widget handles conversationId automatically — you do not need to manage session IDs in the browser.

How much history is included?

By default, up to the most recent turns are included, subject to a token budget. When the conversation history grows large, older turns are trimmed from the context window to stay within model limits. The most recent turns are always preserved.

Where is conversation context stored?

In V1, conversation context is held in-memory on the API server. It is ephemeral: context is lost on server restart or after a session inactivity timeout (typically 30 minutes).

For deployments requiring persistent multi-turn context across restarts, enterprise options are available.

Does multi-turn affect confidence scoring?

Multi-turn context may improve confidence for follow-up questions by giving the retrieval step richer query context. However, it can also reduce confidence when the user's latest question is terse ("What about that?") without enough context for good semantic retrieval. The widget is designed to handle this gracefully.

Can I disable multi-turn?

Yes. Omit the conversationId field from API requests and each question will be answered in isolation. This is useful for simple one-shot FAQ deflection where conversation continuity is not needed.

See 0xDoktor in action — ask anything about this page: