SShortSingh.
Back to feed

Naive RAG pipelines fail in production; seven architectures address specific retrieval failures

0
·1 views

A DEV Community article argues that the standard retrieve-and-stuff approach to retrieval-augmented generation works in demos but breaks on real questions, often pulling wrong or incomplete chunks. The author identifies recurring failure modes, including vocabulary mismatch, lost context from torn-out chunks, mismatched question and answer phrasing, and questions whose answers span whole documents. The piece presents seven distinct architectures, each designed to address one or two of these failures rather than being a single universal upgrade. It recommends hybrid search combining vector and keyword retrieval plus reranking as a baseline improvement before adopting more complex designs. Query rewriting techniques such as multi-query and HyDE are also covered as ways to bridge the gap between short questions and long answer passages.

Read the full story at DEV Community

This is an AI-generated summary. ShortSingh links to the original source for the complete article.

Discussion (0)

Log in to join the discussion and vote.

Log in

Related stories

0
ProgrammingDEV Community ·

AI Reshapes Job Titles and Work Methods, Shifting Value Toward Engineering Judgment

An opinion piece argues that artificial intelligence is changing both job titles and the way work gets done across industries. It contends that AI tools are now widely accessible, so the key differentiator is how users apply them, including their methodology and ability to steer the tools toward useful results. In software development, the author says writing code is becoming a cheap, routine step, with value moving toward engineers who understand the broader discipline and can guide AI toward real-world solutions. The piece notes that AI also creates new roles, citing examples such as prompt engineering, RAG engineering, agentic AI engineering, Chief AI Officer, and AI business translator. It concludes that people who resist adaptation risk falling behind, and that thoughtful, moderate adoption of AI can strengthen skills and professional capabilities.

0
ProgrammingDEV Community ·

Why coding agents turn CRLF files into whole-file diffs, and what Codex 0.162 changed

Coding agents that rewrite a Windows file with LF line endings can make git report every line as changed, even when only one word was edited. This happens because git stores the committed CRLF bytes, and the rewrite adds an invisible difference to each line. Developers have reported the problem with Claude Code, and Codex CLI's 0.162.0 release now preserves existing CRLF endings in its patch updates. The article includes a reproducible git demo showing that one changed word produces three deletions and three insertions. It explains how core.autocrlf and text attributes in .gitattributes decide where conversion occurs, and why files already committed with CRLF can escape normalization.

0
ProgrammingDEV Community ·

GraphGuard Uses a Graph Database to Link Security Alerts Into Attack Stories

Security teams often face alert fatigue because tools display each alert as an isolated record that hides its connections to other events. The author argues that security data is naturally a graph, so the context needed to spot attacks lies in relationships between users, devices, IP addresses, and incidents. GraphGuard uses FalkorDB, a graph-native database, as the backbone for an AI investigation agent that traverses these connections quickly. The system stores investigations and evidence as persistent nodes, allowing the agent to recall past cases across sessions. The model is built from eight node types and ten relationship types, seeded with three realistic attack scenarios.

0
ProgrammingDEV Community ·

Remote-support session logs must leave the appliance to survive a rebuild, experts say

Remote-support sessions are recorded mainly to document changes made during maintenance, but appliance-local logs sit on an encrypted partition and are not centralised unless forwarding is configured. CISA advises forwarding appliance syslog and session events to a SIEM immediately, along with web application firewall, reverse proxy and perimeter firewall logs covering the exposure window. The article stresses that usable records must leave the appliance, be time-synchronised with other systems, and be retained beyond the appliance's lifecycle. It also highlights that missing sessions can signal altered logging, not just inactivity. Mandiant warns that intervals between intrusion and discovery in the BeyondTrust case were measured in weeks, and additional organisations may have been compromised before disclosure.

Naive RAG pipelines fail in production; seven architectures address specific retrieval failures · ShortSingh