Fire In Belly

Agentic Workflows for Internal Operations: Deciding Which Steps Earn Autonomy

12 min read

Yellow railway switch levers beside diverging tracks in a rail yard

A proposal lands on your desk for an "agentic" invoice workflow. The demo was impressive: the agent read a messy supplier email, looked up the purchase order, noticed a partial delivery, and drafted the right adjustment. The question nobody in the room answered is which parts of your accounts payable process should be run by a model that chooses its own next step, and how you would know.

Agentic workflows fail in internal operations for a predictable reason. Autonomy gets granted to the whole process because one step needed judgment, and then the same kind of case runs thousands of times a month with no evidence that the agent handles it the same way twice. This guide gives you a way to grant autonomy one step at a time, test it before promotion, and keep the parts that write to your systems on fixed code paths.

What the answers already settle

The definitions are not in dispute. Anthropic's Building effective agents separates workflows, where models and tools are orchestrated through predefined code paths, from agents, where the model directs its own process and tool use. It recommends the simplest solution that works and warns that agentic systems trade latency and cost for task performance, with autonomy adding cost and the potential for compounding errors.

The decision guides also agree with each other. Flowgraph says to build a workflow if you can write the steps down, and to put an agent only in the step that needs judgment. Ergini runs a five-question client test and shows how per-step errors compound inside one run: at 97% accuracy per tool call, a ten-step trajectory ends near 73%. Redis uses the same flowchart test and adds turn limits and cost caps. Hauer Power claims that most B2B AI use cases are workflows in disguise, which is a consultancy's view rather than a measured figure.

The market signal points the same way. Gartner predicts that over 40% of agentic AI projects will be canceled by the end of 2027 because of escalating costs, unclear business value, or inadequate risk controls, and says that many use cases positioned as agentic today do not require agentic implementations.

You do not need another flowchart test. These sources do not say what evidence shows, before you pay for it, that a specific step in an internal process is ready for model-directed control.

Why autonomy fails differently inside internal operations

A research assistant that takes a different path on each run is fine. Nobody asks it the same question four thousand times. Internal operations are the opposite. An invoice exception, a refund request, or an access review arrives in near-identical form every day, and the business expects the same answer every time the facts are the same.

So reliability has to be measured across runs. Ergini's compounding arithmetic describes one run. The question an operations owner cares about is whether the same case, run again tomorrow, produces the same correct result. The τ-bench paper measured exactly that. Its authors ran each task several times and defined pass^k as the chance that all k trials succeed. A gpt-4o function-calling agent with more than 60% average success on the retail domain fell below 25% at pass^8. Those are 2024 models on simulated customer-service tasks, so treat the numbers as a demonstration of the gap, not a forecast for your workflow. The method carries over to your cases; the percentages do not.

Practitioners report the same pattern. In the Hacker News discussion of Brian Suh's post on control flow, one engineer describes a QA agent that worked through requirements files until it started missing some and re-testing others, and says a basic deterministic harness that fed it one case at a time made the system far more reliable. That is an author report, but it matches the failure you would predict when a model controls a loop that a for-loop could control.

Map the workflow into steps before choosing a pattern

Start with the process, not the architecture. Write every step a human or system performs today, then answer three questions for each one: can the next action be listed in advance, does the step write to a system of record, and what does a wrong result cost.

Here is a step map for a supplier invoice workflow:

StepNext action listable in advance?Writes to a system of record?Control
Receive invoice email and attachmentYesNoFixed
Extract supplier, totals, linesYes, fields are knownNoModel-assisted
Match to purchase order and receiptYes, lookup rules are knownNoFixed
Investigate a mismatch across orders, receipts, and supplier emailsNo, depends on what each lookup returnsNoAgent candidate
Propose an adjustment or a holdYes, from a fixed set of outcomesNoModel-assisted
Post the invoice or the holdYesYesFixed, with approval above a limit
Release paymentYesYesFixed, never agentic

Model-assisted means the model fills a field or picks from a known set, inside a fixed path. Agentic means the model chooses which lookup to run next and when to stop. In this map only one step earns that, and it reads but does not write. If a proposal marks the whole process agentic, ask which steps need the model to choose the next action.

Our deterministic workflow design guide covers the fallbacks around model-assisted steps, and multi-agent orchestration covers coordination when several agents are involved. This article stays with the narrower question of which step gets control.

Write an autonomy grant for every agentic step

Microsoft's guidance for agents in core business processes tells teams to document which decisions agents can make on their own before deployment, to start conservative, and to expand autonomy as trust is established. Make that concrete per step. An autonomy grant is a short record the business owner signs:

step: investigate_po_mismatch
owner: accounts-payable-lead
may_read:
  - purchase_orders
  - goods_receipts
  - supplier_email_thread
may_decide:
  - mismatch_reason: [partial_delivery, price_change, duplicate, unknown]
may_write: []          # proposes only; the posting step writes
limits:
  max_tool_calls: 12
  max_spend_eur: 0.40
  max_wall_time_s: 90
escalate_when:
  - mismatch_reason == unknown
  - limits reached
  - evidence conflicts between systems
promotion_evidence: consistency run 2026-10-01, 40 held cases, 5 runs each
rollback_to: fixed_rule_route_to_reviewer

Two fields do most of the work. may_write: [] keeps the agent out of the systems of record. promotion_evidence forces the team to say what justified the grant, which leads to the next two sections. Step and spend limits are covered in depth in our guide to stopping runaway agent tool loops.

Measure consistency across repeated runs before promotion

Before you promote a step to agent control, run the same held cases several times and count only the cases that pass every run, because an internal workflow repeats the same kind of case thousands of times and an average success rate hides inconsistency.

None of the decision guides above asks for this. They test whether an agent can do the task. An operations owner needs to know whether it does the task the same way each time. The τ-bench pass^k measure gives you a simple way to check. This is our recommendation, built on that paper's method rather than a vendor guarantee.

Take 40 resolved cases from the step you want to promote, with the correct outcome recorded by your own reviewers. Run the candidate agent on each case five times with production settings. Count, per case, how many runs reached the correct outcome. Then compute both the average and the all-runs rate:

from math import comb

def pass_hat_k(results, n, k):
    """results: list of correct-run counts per case, each run n times."""
    return sum(comb(c, k) / comb(n, k) for c in results) / len(results)

results = [5] * 30 + [4] * 6 + [2] * 4  # 30 cases 5/5, 6 cases 4/5, 4 cases 2/5
print(pass_hat_k(results, n=5, k=1))  # 0.91 average success
print(pass_hat_k(results, n=5, k=5))  # 0.75 correct on every run

The average says 91%. The all-runs rate says only 30 of 40 cases are handled correctly every time, and ten cases depend on which run you happen to get. In production those ten are the cases your reviewers will see flip between outcomes, and the ones auditors will ask about.

Set the promotion bar as an all-runs rate, not an average, and inspect every case that fails any run. If the failures cluster in one mismatch reason, narrow the grant so that reason escalates. If they are scattered, the step is not ready, whatever its average says. Rerun the same held set after every prompt, tool, or model change, alongside the regression suite described in our exception queue guide and its links.

Use the fixed version's exceptions to choose what to promote

Choose which step to promote from the exception classes of the fixed version: promote only a class where reviewers take a different sequence of lookups each time, and turn classes where reviewers repeat the same steps into rules instead.

This is our synthesis rather than an external finding, and it uses the same data as our exception guide for the opposite decision. Our exception queue guide uses resolved exceptions to write deterministic rules: when reviewers keep choosing the same resolution, encode it. The same data can tell you where a rule will never be enough.

Run the fixed workflow first and let it route anything unmatched to a reviewer. After a few weeks, group the exceptions by class and look at what reviewers actually did. For "missing PO number", reviewers probably searched by supplier and amount, found one candidate, and attached it. They took the same three steps every time, so encode that as a rule. For "price variance with a partial delivery split across two receipts", one reviewer checked the receipt first, another read the supplier thread, a third called the warehouse system. The path changed with what each lookup returned. That class is where an agent loop can earn its cost.

Microsoft's pattern lists exception rate and straight-through processing among the process metrics to track. Use them before and after promotion. A promoted class should show fewer reviewer touches without a rise in reopened cases. If reopenings go up, roll the class back to the reviewer queue.

This order also protects the business case. You spend agent tokens only on the exception classes that justify them, and the volume figures come from your own queue rather than a vendor estimate.

Keep writes and approvals on fixed code paths

The agentic step investigates and proposes. A fixed step validates the proposal against known outcomes and writes. Ergini describes a similar split, with an agent producing a structured plan that a workflow engine executes. A practitioner comment on Hacker News describes an AI-built plan that favours deterministic steps and escalates back to AI when it needs to (author report).

In the invoice example the agent returns {mismatch_reason, evidence_refs, proposed_action}. The posting step checks that proposed_action is one of the allowed actions, that the referenced documents exist, and that the amount is within the approval limit. Anything above the limit goes to a person, using the pattern in binding human approval to exact agent actions. Payment release never moves into the agent's grant.

Anthropic notes that agents need ground truth from the environment at each step and that stopping conditions, such as a maximum number of iterations, keep them under control. Give the agent read tools that return clear results, and keep the stop condition in code, not in the prompt.

Questions to ask about an agentic proposal

If a consultant or vendor proposes an agentic workflow, including us, ask for these before you agree a scope:

  1. The step map, with each step marked fixed, model-assisted, or agentic, and the reason for each agentic mark.
  2. The autonomy grant for each agentic step: what it reads, decides, and writes, its limits, and who signs it.
  3. The held cases for each agentic step, how many times each was run, and the all-runs rate, not just the average.
  4. The exception data that justified promotion, or a plan to collect it by running the fixed version first.
  5. Which steps write to systems of record, and confirmation that none of them is model-directed.
  6. The rollback for each agentic step, and the metric that triggers it.

Gartner's warning about "agent washing", the rebranding of assistants and automation as agentic without substantial agentic capability, is a reason to ask for the step map first. If a proposal cannot mark its agentic steps, ask what the agent does that a fixed path cannot.

Verify, monitor, and roll back a promoted step

Promotion is a release, so treat it like one. Before go-live, the held-set all-runs rate meets the bar the owner signed, every failed case has been read, and the rollback route has been exercised once. After go-live, track three things weekly: the exception rate for the promoted class, reopened or reversed outcomes, and the all-runs rate on the same held set rerun with current production settings.

Roll back when the all-runs rate drops below the signed bar, when reopenings rise, or when spend per case moves outside the grant. Rolling back means the class returns to the fixed route and the reviewer queue; nothing else in the workflow changes. Keep the grant and its evidence with the workflow's change history so the next reviewer can see why the step was promoted.

If you are still at the stage of finding which workflows are worth automating at all, our AI audit maps processes and ranks opportunities, and AI workflow automation covers the build.

Next action

Before you approve agentic workflows for an internal process, pick one workflow and write its step map this week. Mark each step fixed, model-assisted, or agentic. For every agentic mark, write down the evidence you have for it. If the answer is a demo, run the fixed version first, collect two weeks of exception classes, and repeat the exercise with that data.


About Fire In Belly: Independent senior engineering from Tallinn, Estonia. We design and build AI workflow automation, internal tools, and custom software with the step-level autonomy decisions, held-set promotion gates, and fixed write steps described above, at published fixed prices. Schedule a call to discuss your next project.