Skip to content

In development. Expect rough edges and changes. The source code is not public yet.

Booking.com Data Science 9 min read Case study mediumAdept

From Static Help Content to a RAG-Based Onboarding Agent for Partners

Booking.com's registration-flow chatbot for self-managed partners gave weak answers even though retrieval surfaced the right documents, and the cause turned out to be upstream data quality rather than the model. A manual audit of the embedding store found navigation and breadcrumb noise, chunks too small to carry needed context, and irrelevant partner-specific content. These fixes were built into the periodic ingestion script, and the agent was re-architected to choose among separate retrievers: general help articles, a registration-process knowledge base with rephrase-and-retry, and pre-approved templated answers for legally sensitive questions. In an A/B experiment scored across about 2,000 conversations, LLM-judged task completion rose 1.33x and answer relevance and refusal rate improved, with the lesson that automated judges flag weak retrieval but human inspection of retrieved chunks is needed to find the fix.

Assumes: retrieval-augmented generationembeddings and chunkingLLM-as-a-judge evaluation

Related posts

  • Expert Support case study: Bolstering a RAG app with LLM-as-a-Judge

    Hugging Face mediumAdept

    Digital Green's Farmer.chat, a GPT-4o ReAct agent backed by a RAG pipeline over ~46,000 agricultural research papers (semantic chunking, Qdrant), uses LLM-as-a-judge to evaluate prompt clarity, question type, answered rate and RAG faithfulness at scale. The faithfulness judge, a RAGAS-inspired binary NLI prompt that checks atomic statements against retrieved context, correlated well with human raters on ~360 questions. Benchmarking four LLMs on 700+ queries showed Gemini-1.5-Pro was most faithful (91%) but left 19.4% unanswered, so the team chose Gemini-1.5-Flash for its balance of 89% faithfulness and only 4.5% unanswered.

  • Beyond the Menu Tree: How Yelp Built a Smarter Customer Success Chatbot with AI

    Yelp Engineering mediumAdept

    Yelp replaced a menu-tree and fixed-phrase customer support chatbot with an LLM system. It routes each query to one of five workflows (QA, Billing, Refund, Cancel, Review), and high-risk intents get templated responses. The QA path retrieves whole Support Center articles, about 370 of them, without chunking. Retrieval runs against a vectorstore built only from article metadata: each title, summary and top header is embedded separately with text-embedding-ada-002, because embedding whole articles diluted the semantic signal and small chunks produced false matches. The roughly 8 MB index is loaded in memory with FAISS, rebuilt daily from S3, and retrieves the top 5 articles with a similarity threshold, reaching about 94% recall@5. Generated answers pass trust-and-safety, link-provenance and length checks to catch hallucinated URLs, and the system doubled the resolution rate in an A/B test.

  • Context engineering case studies: Etsy-specific question answering

    Etsy Code as Craft mediumAdept

    Etsy tested whether prompt engineering over embedding-based retrieval, without fine-tuning, could reliably answer Etsy-specific questions. On a 40-question Travel & Entertainment policy set the LLM answered about 86% correctly; on a 50-question seller-forum set it scored about 72%, with errors doubling on the more heterogeneous, opinionated data. Letting the model admit uncertainty and asking it to explain its answer (chain-of-thought) fixed some hallucinations, but adding a contextual preamble often did not help. Asking the model to cite specific source snippets proved the most useful way to flag potential hallucinations.

  • Context Engineering (Agent Memory) for AI Agents Starts with Retrieval

    LangChain mediumAdept

    Agent retrieval fails in three ways: inefficient searching, too much context at once, and irrelevant or stale context. The fix is to keep searches small and keep raw results out of the main agent's context window. Deep Agents does this with glob/grep before reads, paged read_file (100 lines by default with offset/limit), and automatic offloading of tool results over ~20k tokens to files with a preview. For custom RAG tools, the recommended pattern is "retrieve, offload, delegate": write results to files, return only paths, and have parallel subagents read each file and return key facts with sources and dates. Other advice covers using grep with synonyms before semantic search, agentic rather than single-shot retrieval, skills for progressive disclosure, and treating retrieved text as untrusted.

  • Aligning LLM-as-a-Judge with Human Preferences

    LangChain easyNovice

    LangSmith evaluators now store human corrections to LLM-as-a-Judge scores as few-shot examples, optionally with explanations, and inject them into the judge prompt on later runs so the evaluator aligns with team preferences without manual prompt engineering. LLM judges work because they can see information the generator lacked, such as reference answers, and because judging is easier than generating. Common uses are detecting RAG hallucinations, RAG correctness and toxic outputs, in both online and offline evaluation. The design draws on few-shot learning and Shreya Shankar's Berkeley paper "Who Validates the Validators?".

The quest for software engineering knowledge.

Look:
Layout: