Guide

Build or buy AI agents: the full cost of an internal build

A COO's guide to build or buy for AI agents: when RAG is enough, the full cost of building, and how to compare outputs on your own documents.

An unfinished concrete room with scaffolding, opening onto a finished, sunlit hall where people walk

COOs and business sponsors weighing an internal agent build against a platform should make the call one recurring decision at a time. Keep extending the internal build when retrieval and a summary give that decision everything it needs. Buy when the agent's answer has to enforce your rules, reconcile sources that disagree, and stay correct as facts change. That is the work where an internal build's cost piles up.

AI has made it dangerously easy to convince yourself that you should build something internally. A few good engineers with the right tools get a working version in front of the sponsor. Next to a vendor's license fee, a half-working build by your own people looks cheaper. The unfinished half costs you after launch, when your team is still checking every output by hand.

I'm Charlotte Werger, and I founded Saphenia, which builds decision logic for enterprise agents. Before Saphenia, I ran the data organization at H&M as Chief Data and AI Officer. Saphenia captures how an organization makes one recurring decision and checks every answer an agent produces against that decision's rules before the answer leaves. Below, for you and the technical evaluator beside you, is a step-by-step walkthrough of how I would price both paths today.

1. Name one recurring decision and what a correct answer carries

Pick one decision your team makes over and over, where a wrong answer costs money, a client, or a regulator's attention. Good candidates are the quarterly portfolio company performance review at a private equity firm, loan product matching at a broker, or a credit monitoring alert at a bank.

Judge every answer against the same standard. A decision-grade answer lands one of four ways: fulfilled with proof, refused by a rule, a named gap, or reserved for a human. Proof is the bundle behind the answer: the facts, the rule with its version, and the dates, with each piece of evidence pointing to an exact place in a source document. A refusal names the rule the answer would have broken, and a gap says what is missing.

Then count how often the decision runs. One that runs hundreds or thousands of times a year repays the work of getting it right, and every correction your experts make carries into the next run. See preparing a portfolio performance review for what that decision involves, and keeping lender criteria current for the broker case.

2. Test whether your existing RAG system is already enough

A retrieval-augmented generation (RAG) system holds up when its job is to find and summarize the right passages for a person who reads every output before anything happens. Four conditions keep it that way:

  • The sources it reads agree, or a person reconciles them before the answer is used.
  • The definitions behind your figures stay the same from one period to the next.
  • No rule has to be obeyed by the output itself.
  • An assistant drafts, and a person decides and acts.

The system has reached its limit when any of these show up in real use:

  • Two documents give different figures and the answer uses one of them without saying so.
  • A KPI definition changed between quarters and the answer mixes the old and the new.
  • A rule lives in a prompt and some outputs break it.
  • The answer needs facts from systems that were never built to be read together.
  • Someone on your team checks every output by hand, so the work never gets handed over.

The first four failures arrive looking like a correct answer, and the fifth is the cost of catching them. To run the test, take last quarter's real documents, including the messy ones, and a set of past decisions whose correct answers your experts already know. Run the system on them and mark every answer where a figure is untraceable, a disagreement is hidden, or a rule is broken. If the marks are rare and harmless, keep the RAG system for that decision and spend the budget elsewhere.

When to buy decision logic for enterprise agents instead of extending your RAG build

Three signs show a decision is beyond what RAG was designed to do:

  • The answer needs multi-hop reasoning across systems that don't connect.
  • Rules have to be enforced on the output itself.
  • Facts change over time, and the answer depends on what was true at a given date.

An internal team can build what each sign calls for, and step 3 prices that work. See deterministic AI agents for more on the second and third signs.

3. Count the full cost of the internal build

A full cost comparison counts the 10 lines below for both paths, over the same number of years. Companies underestimate two things in an internal build: the work between a working demo and a production system, and their own team's time. A system can look good when you're testing it internally. Running it reliably across hundreds or thousands of users inside an enterprise is a different problem. The internal cost runs well past the salaries of the people who built version one. I made that argument in a LinkedIn post in October 2026. The table below holds every cost line I would put in front of a COO.

Cost lineWhat to count
Engineers and internal headcountThe team that built version one, plus the share of data, platform, and security staff the build draws on
ConsultantsIntegration work, outside review, and any team brought in when the build stalls
Model and tooling costsModel calls per run at production volume, retrieval and orchestration tooling, and monitoring
MaintenanceNew source formats, changed systems, model upgrades, and the retesting each change triggers
People who keep it working after launchThe named owner, the engineer on call, and the experts who review outputs
Rule enforcementWriting each business rule as a check on the output, and versioning it when policy changes
Evaluation casesA set of past decisions with known answers, rerun after every change to rules, sources, or model
Proof recordsStoring, for each answer, the evidence, the rule version, and the dates an auditor will ask for
Expert correctionsThe workflow that turns a reviewer's correction into a rule every later answer follows
Manual checkingThe hours your team spends checking outputs by hand until the build earns trust

The first five lines appear in any AI software budget. The last five are specific to agents that act on decisions, and they're the lines a half-working demo leaves out. Zylo's build-versus-buy guide, written for software in general, puts it this way: "Total cost of ownership is where both paths get underestimated, usually by a factor of two to three." The same guide adds: "Faster build does not lower the maintenance bill."

On the vendor side, Zylo's guide notes: "Implementation often runs one to three times the annual license." Ask each vendor what implementation includes and which of the 10 lines above stay with your team after it ends.

4. Compare a vendor's output with your internal build on the same documents

Run the vendor and your internal build on the same reporting period, the same document set, and the same questions, then score each answer against the four outcomes. At a private equity firm, the internal build is usually a retrieval pipeline on the firm's data platform.

Score every answer on these points:

  • Each figure carries proof, with evidence pointing to a page, table, or cell in a named source document and period.
  • When two reports disagree, the answer states which source wins and why. See when portfolio reports disagree for the rules.
  • When a KPI definition changed between periods, the answer says which definition it applied. See changed KPI definitions and missing facts.
  • A claim that breaks one of your rules is refused, and the refusal names the rule.
  • A missing fact appears as a named gap.
  • The calls your policy reserves for a person stop and wait for that person. Who signs off a portfolio figure sets out who those people are.
  • A correction made in one quarter's run carries into the next quarter's run.

Count an answer as wrong when it reads well and quietly picks one figure from two. Record the engineering hours each side spent to reach a result, because those hours belong in the cost table from step 3. Evaluating a portfolio review pilot gives the full scoring method.

When RAG summarization is enough for a portfolio review, and when it needs a governed workflow

A RAG summary is enough for a private equity portfolio review when a person reconciles every figure before it reaches the review pack, as with a board digest the operating partner reads before the meeting. Once the agent's figures go into the investment committee's review pack as written, the review needs a governed workflow.

Take a made-up portfolio company, a software business reporting third-quarter results to their private equity owner. Their documents and the fund's rules say this:

  • The September management accounts show annual recurring revenue (ARR) of $41.2M.
  • The board deck shows ARR of $42.0M, because it counts contracts signed and still awaiting go-live.
  • The fund changed their ARR definition in the second quarter to count live contracts alone.
  • The KPI pack is missing churn for August.
  • The company reports adjusted EBITDA without a schedule of the add-backs behind it, and the fund's rule says adjusted EBITDA is reported with that schedule attached.
  • Net leverage sits close to the threshold where the operating partner decides what goes to the investment committee.

A RAG summary of these documents produces a fluent paragraph: ARR grew to $42.0M, churn held steady, adjusted EBITDA improved, leverage is comfortable. It takes the deck's figure, papers over the missing month, and repeats the adjusted EBITDA as given, so every sentence reads as correct.

A governed workflow produces the same review with each claim landing on one of the four outcomes:

  • Fulfilled with proof. ARR is $41.2M, with evidence at the September management accounts, page 4, under the ARR definition in force since the second quarter. The answer reports the $0.8M difference from the board deck and the reason for it.
  • Refused by a rule. The adjusted EBITDA figure is refused, because the rule requires a schedule of add-backs and none was supplied.
  • A named gap. August churn is missing from the KPI pack, and the answer says so.
  • Reserved for a human. The leverage commentary goes to the operating partner, who makes that call.

5. Choose between a vendor, a consultancy, and an internal team

Choose by who will keep the decision correct after launch, since most lines in step 3's cost table run for as long as the build does.

Choose an internal team when your firm builds in house as standard practice, staffs maintenance for the long term, and the decision passes the RAG test in step 2. The engineers who built version one then stay on as the build's owners.

Choose a consultancy when the work is one project with an end date and your team is ready to own what the consultancy leaves behind. Price that handover as part of the internal build, because every line from maintenance downward in the cost table becomes yours on the day the engagement ends.

Choose a vendor when the decision recurs, the rules change during the year, and the build would need the agent-specific lines in the cost table. Ask every vendor to show that they can read the data your decision depends on, in the formats it arrives in. Ask them to show you a working decision on your documents this quarter. Then ask who owns the decision logic they build from your data, and whether you can export it.

Where Saphenia fits

Saphenia delivers one decision at a time, with the decision logic, rules, and approved expert corrections for that workstream. Saphenia builds the decision logic in days, and the first decision ships in weeks.

Saphenia reads your systems of record and extracts the logic the decision follows: what your terms mean, which source wins when two disagree, and where the thresholds sit. Your experts then review the agent's work, and every correction they approve becomes a rule the agent applies from then on. Every claim in an agent's output is checked before the answer goes out, so each claim lands on one of the four outcomes and carries its record. Three lines in the step 3 cost table come with Saphenia: rule enforcement, proof records, and expert corrections. Your team keeps ownership of the decision.

Everything Saphenia builds from your data belongs to you and leaves with you. Saphenia never trains on your data. Saphenia runs in the environment you choose and works with the model you choose. Each deployment is built to run without a standing team of consultants around it. See security, hosting, and data ownership for where it runs, and how Saphenia is priced for what sets the cost of a deployment.

If step 2 shows your RAG system already handles a decision, Saphenia is the wrong purchase for that decision. See what Saphenia does for the product in full.

FAQ

Will a more capable model learn how your company decides?

No. What an agent lacks is specific to your company: your terminology, which source outranks which, the exceptions to your rules, the precedent behind past decisions, and the calls that always need a person. No foundation model holds any of them, so a new model release leaves your decision logic where it was.

Who should own the decision once an agent makes it?

In firms deploying agents on a recurring decision, the business-line owner whose team makes the decision today owns its rules and approves the corrections. The data or AI leader owns the governance path, covering access, security review, and model risk. See who signs off a portfolio figure for how this works in a portfolio review.

Sources

Get started

Decision logic for enterprise agents.

Saphenia teaches agents how your organization decides. See it run on a decision your team already makes.

Book a demo