Combining deterministic code with targeted AI reasoning

Effective automations use deterministic code for predictable steps and reserve AI reasoning strictly for steps that require judgment.


Wade Foster has a simple rule for anyone building automations: use regular, predictable code for every step that doesn't need judgment, and bring in AI only for the steps that do. As he puts it:

"You really only want the AI to reason over the things that you need it to reason for."

The idea is worth unpacking, because it cuts against how a lot of people first approach AI tools. When an assistant can do almost anything, the temptation is to hand it the whole job: fetch the data, sort it, decide what matters, write the reply, send it. Every step goes through the model.

Foster's point is that this is the expensive, fragile way to do it. If a step has a fixed, predictable answer — moving a file, copying a value from one system to another, checking whether a date has passed — ordinary code already does it perfectly, instantly, and for fractions of a penny. Sending that same step through an AI model costs more, runs slower, and introduces a small chance of a wrong answer every single time. Multiply a small failure rate across ten or twenty steps and the workflow breaks often enough that someone has to babysit it, which defeats the purpose of automating it in the first place.

The better pattern is a division of labor. Code handles the plumbing: gathering inputs, enforcing formats, routing outputs. The AI is called in narrowly, at the one or two points where a human would otherwise have to read something and make a call — summarizing a messy email, deciding which category a request falls into, drafting a response that needs to sound right. Judgment is what the model is good at and what code can't do. Everything else is a waste of the model's strengths and an invitation for it to make a mistake it never needed the opportunity to make.

Who is this for? The brief answer is anyone automating business or administrative workflows — the sort of person who might use a tool like Zapier (which Foster co-founded and runs) to connect their email, spreadsheets, and scheduling without writing code themselves. You do not need to be a developer to apply the rule. When you build an automation, the practical question is the same either way: which steps have one correct answer, and which steps genuinely require reading, interpreting, or deciding? Give the first kind to deterministic logic and the second kind to the AI.

Is this usable today? Yes — it is not a proposal or a research direction. It describes an approach that is already shipping in automation products, and the underlying principle (don't pay for reasoning you don't need) applies to any workflow you assemble yourself, whether or not you use Foster's platform.

Two honest limits. First, this is a design principle, not a product — it tells you how to structure a workflow, not which tool to use, and applying it still requires you to map your own process and identify where judgment actually lives. Second, the framing naturally favors the automation-platform model Foster's company sells; someone whose work is almost entirely judgment calls, with little repetitive plumbing, may find the "reserve AI for judgment" advice describes nearly all of their steps rather than a few. The rule is most valuable where workflows are long, repetitive, and mostly mechanical — which, to be fair, is where most automation budgets go.

automationproductsvideoefficiency
Source: youtube.com