← Lab
Field note·Local LLM, GPU & Inference·4 min read

Cutting Multi-Agent Latency from 14s to 4s

The default assumption is that every step needs a language model. That assumption is what makes pipelines slow.

Cutting Multi-Agent Latency from 14s to 4s

Before changing anything, time every step on its own. The breakdown usually answers the question by itself: some steps need reasoning, and some are pattern matching wearing a costume.

Measure first, and the answer appears

01Classification 1.2sWhich document type is this? Pattern matching.
02Data extraction 2.2sPull names, dates, amounts. Named entity recognition.
03Clause analysis 4.2sGenuine reasoning. Keep the model.
04Risk assessment 2.2sGenuine reasoning. Keep the model.
05Summarisation 4.2sGenuine reasoning. Keep the model.

Run sequentially that is 14 seconds, and three of the five steps are using a language model for work a purpose-built model does faster and more accurately. Without measuring each step you would spend the week optimising the wrong ones.

Three changes, in order of payoff

  • Replace classification with a classifier — deciding between three document types is not reasoning.
  • Replace extraction with NER — pulling structured fields is a solved problem.
  • Parallelise what remains — risk and summary do not depend on each other, so they run together.

Done in that order, this approach can take a 14-second pipeline to roughly 4 seconds with no loss of output quality. Most of the gain comes from removing language models from steps that were never doing language work; parallelising is the smaller half.

What to take away
  • Time every step separately before optimising anything.
  • Classification and extraction rarely need a language model.
  • Parallelise only what genuinely has no dependency.
  • Removing unnecessary models beats speeding up necessary ones.

Field notes on building production AI systems — collected, verified and written up so they are useful to anyone working on the same problems.

smoke
“Innovation distinguishes between a leader and a follower.”

Need an AI system that holds up in production? Tell me what breaks today and I'll tell you what I'd build.

Call Me now !

mail

abdelmajidzaddi088@gmail.com

address

Mohammedia, Morocco

phone

+212 695 557 631