Building a RAG-Based Documentation Chatbot: Lessons from Fiddler's LLMOps Journey

fiddler · Tech · 2023 · source Agentic: no · promotional bias: high · source-backed · extracted with prompt 0.5.4 (schema v2)

Generated from extraction.json — do not edit by hand. Every claim cites verbatim source evidence; stated means the quote directly asserts the claim, implied means it supports it indirectly.

Problem

Domain: RAG documentation chatbot with LLMOps monitoring

Fiddler needed a documentation chatbot that could answer product questions from docs using GPT-3.5 while dealing with natural-language query ambiguity, context-window limits, retrieval quality, hallucinations, feedback collection, conversational memory, and trust-building UI.

Constraints:

Architecture

Fiddler built a GPT-3.5 RAG documentation chatbot using LangChain as the orchestration framework and Fiddler LLM Observability to evaluate and monitor prompts, responses, and knowledge-base improvements. The system processes and rewrites queries, chunks documents with metadata/continuity statements, performs multiple retrievals, ranks document relevance, iterates prompts, collects thumbs/comment feedback, stores embeddings for queries/responses/documents, adds caveats to reduce hallucinations, streams responses, and maintains conversational memory.

Diagram confidence: reconstructed (reconstructed from prose).

flowchart LR
  user[User] --> fiddler-chatbot[Fiddler Chatbot]
  fiddler-chatbot --> langchain-pipeline[LangChain Pipeline]
  langchain-pipeline --> question-processor[Question Processor]
  question-processor --> retriever[Retriever]
  documentation-knowledge-base[Documentation Knowledge Base] --> document-chunker[Document Chunker]
  document-chunker --> embedding-store[Embedding Store]
  embedding-store --> retriever
  retriever --> gpt-model[GPT Model]
  gpt-model --> fiddler-chatbot
  fiddler-chatbot --> streaming-ui[Streaming UI]
  fiddler-chatbot --> feedback-collector[Feedback Collector]
  langchain-pipeline --> conversational-memory[Conversational Memory]
  embedding-store --> llm-observability[LLM Observability]
  feedback-collector --> llm-observability
  llm-observability --> fiddler-chatbot
Drag to pan · scroll or use +/− to zoom · reconstructed from the source's described component topology

Components

Component Role Interacts with
User Fiddler user asking product documentation questions. Fiddler Chatbot
Fiddler Chatbot RAG chatbot that answers from Fiddler documentation. User, LangChain Pipeline, GPT Model, Streaming UI, Feedback Collector
LangChain Pipeline Framework plumbing for question preprocessing, retrieval, memory, and prompt experimentation. Fiddler Chatbot, Question Processor, Retriever, Conversational Memory
Question Processor Tokenization, normalization, context tracking, referential resolution, and LLM question-generation support. LangChain Pipeline, Retriever
Document Chunker Splits long documentation into coherent chunks with metadata and continuity statements. Documentation Knowledge Base, Embedding Store
Documentation Knowledge Base Fiddler documentation and caveat documents used as external knowledge. Document Chunker, Retriever
Embedding Store Stored embeddings for documents, queries, and responses used for retrieval and monitoring. Document Chunker, Retriever, LLM Observability
Retriever Runs multiple retrievals and ranks relevant chunks for answer generation. LangChain Pipeline, Embedding Store, GPT Model
GPT Model LLM that generates answers from retrieved context. Fiddler Chatbot, Retriever
Streaming UI Response presentation layer that streams answers for a more natural conversational feel. Fiddler Chatbot
Feedback Collector Thumbs and comment feedback mechanisms for user response quality signals. Fiddler Chatbot, LLM Observability
Conversational Memory Session memory and summarization layer for resolving follow-up references. LangChain Pipeline
LLM Observability Fiddler monitoring/evaluation layer for prompts, responses, hallucinations, embeddings, and knowledge-base improvement. Fiddler Chatbot, Embedding Store, Feedback Collector

Data flow

User questions enter LangChain-based preprocessing for tokenization, normalization, context tracking, referential resolution, and optional LLM question generation. Original and processed queries can retrieve multiple candidate document sets. Documents are chunked with metadata so related chunks stay close in embedding space. Ranked retrieved context is passed to GPT-3.5, responses stream to the UI, feedback and embeddings are stored, and observability monitors prompts, responses, hallucinations, and knowledge-base gaps.

4 supporting quotes
“to help Fiddler users easily find answers from our documentation. We used OpenAI’s GPT-3.5 and augmented it with RAG to build the Fiddler Chatbot. With the help of Fiddler LLM Observability solutions, we have continuously evaluated and monitored the chatbot’s responses,”article, stated
“For instance, LangChain simplifies the complex task of integrating external knowledge sources into the chatbot. This integration is crucial for a RAG-based system, as it allows the chatbot to pull in relevant information from these sources to generate more informed and accurate responses.”article, stated
“This strategy may involve several layers, starting from basic preprocessing, like tokenization and normalization”article, stated
“In developing RAG-based chatbots, using multiple retrievals is crucial. This approach uses several searches instead of just one search to find the most relevant and complete information for accurate and helpful responses.”article, stated

Why this architecture

Fiddler used RAG because documentation answers needed external, current knowledge rather than model memory alone. LangChain provided reusable pipeline pieces for question preprocessing, retrieval, and memory, while observability closed the loop on hallucinations, prompt behavior, feedback, and knowledge-base gaps. Multiple retrievals and chunking addressed the two biggest retrieval risks: ambiguous queries and long documents.

4 supporting quotes
“RAG represents a paradigm shift from traditional NLP methods previously used in chatbot development. It enables chatbots to access and integrate external knowledge sources, thus enhancing their ability to provide accurate and contextually relevant responses.”article, stated
“It enables chatbots to access and integrate external knowledge sources, thus enhancing their ability to provide accurate and contextually relevant responses.”article, stated
“a tool like LangChain helps save considerable time and resources as developers can focus more on refining the chatbot’s capabilities and enhancing its conversational quality. LangChain can adapt to the evolving needs of the project, whether it involves tweaking the retrieval mechanisms,”article, stated
“With the help of Fiddler LLM Observability solutions, we have continuously evaluated and monitored the chatbot’s responses”article, stated

Models used: OpenAI GPT-3.5 · LLMs · machine learning models for intent

Scale

Alternatives considered (roads not taken)

Use only the processed/rephrased query for retrieval

Rejected because: Sometimes the original query retrieved more relevant documents.

“the original user query, without any preprocessing, might retrieve more relevant documents than a processed version”article, stated
“conducting multiple retrievals using different forms of the query — both the original and the processed versions.”article, stated

Pass entire documents to the LLM

Rejected because: Context windows limit how much text can be processed and long documents need coherent chunks.

“These models can process only a limited amount of text at a time, which means they cannot consider all available documents in their entirety for every query.”article, stated
“Chunking involves breaking down large documents into smaller, more manageable parts that the chatbot can process within the context window constraints.”article, stated

Static block-format answers

Rejected because: Static answers felt disjointed, while streaming increased perceived conversational trust.

“Initially, the responses were delivered in a static, block format, which, while accurate, sometimes felt disjointed and less interactive to users.”article, stated
“Initially, the responses were delivered in a static, block format, which, while accurate, sometimes felt disjointed and less interactive to users. To address this, we shifted to a streaming response format.”article, stated

Patterns

rag-retrieval (documentation-qa)

Fiddler retrieves documentation chunks and feeds them to GPT-3.5 for grounded answers.

“augmented it with RAG to build the Fiddler Chatbot.”article, stated
“pull in relevant information from these sources to generate more informed and accurate responses.”article, stated

query-rewriting (retrieval-preprocessing)

LangChain question generation and preprocessing resolve ambiguity before retrieval, while original queries are also considered.

“The question generator template in LangChain allows you to process your questions with yet another LLM”article, stated
“context tracking and referential resolution.”article, stated

retrieval-ranking (multi-retrieval)

The chatbot runs multiple retrievals and ranks top documents/chunks across results.

“using multiple retrievals is crucial.”article, stated
“ranking algorithms that assess the relevance of each retrieved document to the user's query.”article, stated

context-compaction (document-management)

Long documents are chunked into context-window-sized pieces with continuity metadata.

“where the concept of 'chunking' becomes crucial.”article, stated
“each chunk should contain metadata or continuity statements that logically link it to the other parts of the document.”article, stated

observability-tracing (llmops)

Fiddler monitors prompts, responses, embeddings, feedback, and hallucination patterns through LLM Observability.

“continuously evaluated and monitored the chatbot’s responses, user prompts, and improved its knowledge base”article, stated
“LLM Observability represents the backbone of responsible and efficient AI implementations.”article, stated

Tradeoffs

Use LangChain plumbing

Chose LangChain for RAG orchestration over custom-building every retrieval, memory, and preprocessing component.

Rationale: LangChain let developers focus on chatbot quality rather than infrastructure.

“It serves as the foundational 'plumbing'”article, stated
“developers can focus more on refining the chatbot’s capabilities”article, stated

Use multiple retrievals

Chose original and processed query retrieval paths over single best query rewriting path.

Rationale: Different query forms can retrieve different relevant evidence, especially for ambiguous language.

“This approach uses several searches instead of just one search”article, stated
“different interpretations or aspects of the question might lead to different sets of relevant documents.”article, stated

Stream responses

Chose real-time typing-like response display over static block responses.

Rationale: Streaming made the bot feel more conversational and increased user trust.

“Streaming responses from the LLM in real-time, as if the chatbot is typing them out”article, stated
“significantly enhanced the user's perception of having a natural, conversational interaction”article, stated

Gotchas (what bit them)

Query rewriting can hurt retrieval.

Root cause: A processed version of a question may lose terms or framing that matched relevant docs.

Resolution: Run multiple retrievals over original and processed query forms.

“the original user query, without any preprocessing, might retrieve more relevant documents than a processed version”article, stated
“both the original and the processed versions.”article, stated

Chunking can break document coherence.

Root cause: Chunks are smaller than full documents, and related content may be separated.

Resolution: Add metadata or continuity statements linking chunks.

“it's also about maintaining the coherence and continuity between these chunks.”article, stated
“This linkage is essential”article, stated

Hallucinations exposed documentation gaps.

Root cause: The bot interpreted LLM as local linear model because the knowledge base lacked clarifying LLM/LLMOps docs.

Resolution: Fiddler added caveats and richer docs to the knowledge repository.

“interpreted 'LLM' as 'local linear model' instead of 'large language model.'”article, stated
“we introduced the concept of adding "caveats" — additional, clarifying information — into our knowledge repository”article, stated

User feedback can be negatively skewed.

Root cause: Satisfied users are less likely to leave detailed feedback than dissatisfied users.

Resolution: Offer multiple lightweight and detailed feedback mechanisms.

“users tend to provide more detailed feedback when they are dissatisfied or encounter issues.”article, stated
“offer a simple and quick feedback option, like a thumbs up/thumbs down (👍👎) button”article, stated

Evaluation

Fiddler evaluated and improved the chatbot through LLM Observability, prompt/response monitoring, user feedback, embeddings analysis, hallucination inspection, caveat additions, prompt iteration, and knowledge-base refinement.

Metrics: user prompts · chatbot responses · feedback thumbs/comments · hallucination instances · retrieval relevance · embedding alignment · knowledge-base gaps · user trust/engagement signals

3 supporting quotes
“we have continuously evaluated and monitored the chatbot’s responses, user prompts, and improved its knowledge base”article, stated
“By storing these embeddings, developers can track how well the chatbot's responses align with the user's queries and the source documents.”article, stated
“closely monitoring the chatbot's responses, identifying instances of hallucination, and understanding the underlying causes.”article, stated

Outcomes

The article is a lessons-learned guide rather than a numeric deployment report; the concrete scope is a GPT-3.5 RAG chatbot over Fiddler documentation with ten documented LLMOps lessons.

3 supporting quotes
“we deployed our own RAG-based documentation chatbot”article, stated
“This project has helped us explore new AI possibilities, overcome unique challenges, and gain valuable insights.”article, stated
“The development of conversational memory and summarization capabilities in AI chatbots represents a significant step”article, stated