Towards Data Science

RAG Is Burning Money — I Built a Cost Control Layer to Fix It

Most RAG systems are optimized for answer quality, not cost—and that blind spot gets expensive fast. In this article, I break down a production-ready cost control layer combining semantic caching, query routing, token budgeting, and circuit breaking, achieving an 85% reduction in LLM costs without sacrificing answer quality.

Towards Data Science
Jul 24

Loop Engineering for RAG Generation: An LLM Cascade from a Cheap Local Model Up to a Hosted Flagship

Enterprise Document Intelligence [Vol. 1 #8quater] - Two angles on the cascade, cost and a validation loop, backed by a real sweep of twenty local models against a hosted flagship The post Loop Engineering for RAG Generation: An LLM Cascade from a Cheap Local Model Up to a Hosted Flagship appeared first on Towards Data Science .

By Kezhan Shi
Simon Willison
Sep 14

Quoting Laurie Voss

Laurie Voss argues that while the cost of writing code has fallen dramatically, the costs of reviewing, fixing, and operating software are rising and will continue to do so. She emphasizes that the true expense lies in understanding user needs, precisely defining requirements, and ensuring a pleasant user experience—costs that are unique to each software product and do not scale with reuse. As software demand grows without an upper limit, these user‑centric costs will dominate the overall development effort.

Towards Data Science
Aug 20

Three Kinds of RAG Corpus, and What It Costs to Build for the Wrong One

The article explains that enterprise document intelligence can be categorized into three distinct corpus types, each requiring a specific architecture. It outlines how to determine the shape of a document collection through three key questions. The piece also discusses the costs associated with building a system for the incorrect corpus type.

By angela shi
Towards Data Science
Jul 22

Loop Engineering for RAG Generation: Iterate top-k One at a Time

Enterprise Document Intelligence [Vol. 1 #8bis] - Two regimes for sending retrieved candidates to the generation brick, the sufficiency signal that picks between them, and the per-question type dispatch that makes it cheap The post Loop Engineering for RAG Generation: Iterate top-k One at a Time appeared first on Towards Data Science .

By Kezhan Shi
Towards Data Science
Aug 20

How to Fine-Tune an LLM: An End-to-End Guide

The article "How to Fine-Tune an LLM: An End-to-End Guide" offers a practical, hands‑on walkthrough for fine‑tuning large language models in real‑world scenarios. It covers the entire process from data preparation to deployment, providing readers with actionable steps to adapt LLMs to specific tasks. The guide is aimed at practitioners looking to implement fine‑tuning in a structured, end‑to‑end manner.

By Sam Black