Rathle says production requirements rise with the consequences of an error. Text summaries may be low stakes, while mistakes affecting money, reputation, health, safety or regulation demand a much higher bar. A human in the loop can make a higher-stakes application more manageable.
Understanding AI Stakes to Break Production Code
Speaker
Philip Rathle of Neo4j discusses the challenges of taking ambitious AI projects into production at an AI Engineer roundtable in Knüll.
Retrieval-augmented generation can bring in current, domain-specific information and help address hallucinations, but it may not meet the accuracy needs of every use case. Rathle contrasts vector search, which relies on statistical similarity, with knowledge graphs, which represent facts in a structured form that people can inspect and machines can reason over. Combined with an LLM, a graph can provide facts and reasoning while the model handles language.
Rathle recommends defining a project's stakes early, iterating, and focusing on work that can reach production. For questions with exact answers, a database or other deterministic tool can do the reasoning while an LLM turns the question into a query and explains the result for its audience. An audience member adds that an LLM can write code to solve a problem, then stay out of the runtime loop.
One audience member says customers reverted to keyword searches because the team assumed they would use natural language questions. Rathle and participants also discuss balancing model quality, speed and cost, and keeping implementation timelines short as models improve. Rathle advises validating whether a product works with a capable model before optimizing for smaller models or fine-tuning.
Rathle recommends creating an evaluation pipeline alongside the application and preparing suitable evaluation data from the start. In regulated behavioral health, his team keeps a human in the loop and shows source material beside generated summaries so users can review and edit them. The team also checks outputs against inputs and uses user feedback and clinical evaluation to assess quality and safety.
Takeaways
- Set the accuracy bar based on the harm a wrong answer could cause.
- Use deterministic systems for exact answers and LLMs for language tasks around them.
- Test whether users will use the interface as intended before committing to a search design.
- Validate the product with a capable model before optimizing for speed, cost or model size.
- Build evaluation data and user review into the product from the beginning.
Mentioned in this talk
Search inside this talk
What was claimed 6
- featureVector RAG: Provides enterprise domain knowledge and up-to-the-moment knowledge; can help solve hallucinations.
“this is what RAG solves”
YouTube Unverified1 source· Talk
- featureKnowledge graph: Can bring facts, reasoning, discernment, and long-term memory when combined with an LLM.
“when you combine it with an LLM, you can bring in facts, reasoning, discernment, and long-term memory”
YouTube Unverified1 source· Talk
- featureKnowledge graph: Provide a structured representation understandable to humans and usable for machine reasoning.
“a more structured representation that's understandable to humans and can be reasoned upon by machines”
YouTube Unverified1 source· Talk
- featurelarge language models: Can turn a question into a query, formulate the result as text, and adapt wording for an audience.
“take the question, turn it into a query, formulate that back into text”
YouTube Unverified1 source· Talk
- metricLlama 7B: Outperformed Bloomberg's fine-tuned Llama 2 model on the evaluations described.
“when Llama 3 came out that it actually outperformed the fine-tuned model”
YouTube Unverified1 source· Talk
- uses
“Bloomberg were training, I think it was Llama 2 at the time”
YouTube Unverified1 source· Talk













