I cut a RAG pipeline’s response time from 90 seconds to 4. Never touched the model
I cut a RAG pipeline’s response time from 90 seconds to 4. Never touched the model

I cut a RAG pipeline’s response time from 90 seconds to 4. Never touched the model

Last year I worked with an AI startup, an Oxford spinout. Their product answered research questions through a RAG pipeline. It worked, but every query took around 90 seconds. Long enough that users were bailing before the answer even loaded.

The obvious move is to blame the model and go bigger. That wasn't it. The retrieval layer was doing way more work than it needed to on every single query: bloated embeddings, no caching, redundant calls stacking up as the document set grew.

I stripped that layer down. Response time went from 90 seconds to about 4, and cost dropped roughly 95%, mostly because the pipeline stopped repeating work it never needed to do in the first place.

Separately, I also rebuilt the retrieval on Weaviate. That part wasn't about speed, it fixed accuracy issues in what the pipeline was actually retrieving.

Same lesson as most AI performance problems I run into: it's rarely the model. It's the layer nobody's looking at.

submitted by /u/ezzeddinabdallah
[link] [comments]