Notation for Intent
Saying what we mean to agents
By Leo GorodinskiPublished Nov 21, 2026Updated Nov 22, 2026
“Then you should say what you mean,” the March Hare went on.
“I do,” Alice hastily replied; “at least—at least I mean what I say—that’s the same thing, you know.”
“Not the same thing a bit!” said the Hatter.
Is Code Still Needed?
Ask an experienced engineer how they review a large change written by an agent, and the answer is often candid. They don’t read all of it. They look at which modules it touched, check that the architecture still makes sense, skim the diff for anything alarming, and run the tests. The change is too large to read line by line and most of it looks reasonable, so they take a bird’s eye view and hope that whatever matters shows up at that altitude. Call it a vibe check, the reviewing counterpart to vibe coding. It’s a reasonable response to more code than anyone can read, and it’s also an admission that nobody has read the code.
That habit raises a fair question. If agents write the code and agents can read it back, why should people care about code at all? Andrej Karpathy put the optimistic version in 2023 when he wrote that “the hottest new programming language is English.” If English is the interface, code becomes an intermediate artifact, something like the object files a build leaves behind.
The strongest form of this argument is the compiler analogy. Most programmers stopped reading assembly decades ago because compilers became good enough that nobody needed to. Agents are getting good at writing Python, so perhaps Python will go the way of assembly.
Look closer at the analogy, though. We stopped reading assembly because we gained something better to read. C and the languages after it gave us a precise notation and a compiler that translated it faithfully, so the program we read was the program that ran. People went on reading code, and the code they read moved up a level of abstraction, from registers and jumps to variables, functions, and control flow. Prose can’t fill that role. A compiler can emit different machine code for the same C function, at different optimization levels or for different processors, and every version preserves what the function means. C is precise in that whoever reads the source, person or tool, works from the same rules. A prompt like “ship after payment clears” leaves each reader to decide what counts as cleared. So the open question is what people will read in place of Python, the way they once started reading C in place of assembly. My answer is what I’ll call intent notation: a precise statement of what the system should do, written in the vocabulary of the problem and short enough for a person to read in full.
What We Read Instead
Mathematics went from prose to notation once already. Historians, following G. H. F. Nesselmann in 1842, describe algebra in three stages. Rhetorical algebra wrote problems and their solutions out in words, as al-Khwarizmi did in the ninth century. Syncopated algebra, going back to Diophantus, abbreviated recurring quantities and operations. Symbolic algebra arrived with Viète and Descartes in the late sixteenth and seventeenth centuries. As late as 1545, Cardano set out his solution of the cubic in Ars Magna largely in words, and following it takes an effort a modern reader can hardly imagine. Symbolic notation made general methods easier to state, follow, and check. Seen through that history, calling English the new programming language amounts to a return to rhetorical algebra.
“What must be the square which, when increased by ten of its own roots, amounts to thirty-nine?”
Al-Khwarizmi states the problem and its solution in words, about 820.
- Halve the number of the roots, which gives five.
- Multiply this by itself; the product is twenty-five.
- Add this to thirty-nine; the sum is sixty-four.
- Take the root of this, which is eight.
- Subtract from it half the number of the roots, five; the remainder is three. This is the root of the square you sought, and the square itself is nine.
Moreover, code is not just instructions for a machine. The preface to Structure and Interpretation of Computer Programs puts it directly: “programs must be written for people to read, and only incidentally for machines to execute.” Agents can take over the instructing. Code has also been, all along, a way for people to think through a system and explain it to one another.
Software has long had layers of this kind: a specification and its implementation, an interface and the code behind it, a query and its execution plan. What agents change is who works in each layer. Implementation becomes machine output, generated and regenerated and read mostly by other machines. Intent notation sits above it, and that is the layer people read.
Engineers who have been around a while will have heard this before. CASE tools in the 1980s, Model-Driven Architecture and UML in the 2000s, and BDD with tools like Cucumber in the 2010s each promised a layer of intent above the code, and formal specification has promised it for longer. None of them became the way most software gets written. The notation either couldn’t capture the messy cases real systems have, or it grew until it was a worse programming language. Either way, people had to write the specification and the implementation and keep the two in step, or accept whatever a rigid generator produced. Agents change that cost. When an agent generates the implementation, updates it as the intent changes, and reconciles the two, most of the work of maintaining both layers moves to the machine. The other failure came from asking the specification layer to describe the whole implementation, which pulled every concern of a general-purpose language into it. Intent notation doesn’t have to carry that load. It states what must be true in one domain and leaves how to the implementation. Giving up generality it doesn’t need is a deliberate trade, the one the section on the frontier takes up.
The closest predecessors come from formal methods. Leslie Lamport has long argued for thinking above the code, writing a precise specification, often in TLA+, before writing the program. Daniel Jackson’s Alloy, and his later work on concept design, make a related case for stating a system’s essential structure and rules apart from its implementation. Intent notation starts from the same premise. What agents add is a reason for the specification to be the layer people work in every day, rather than a design document written once and set aside.
Notation works together with prose. Take the Y combinator. What we want from it fits in one equation:
Applied to a function , gives a fixed point of , a value that maps back to itself. That is what lets a function be recursive without referring to itself by name. The equation is one line. Explaining why a fixed point gives you recursion, and how a function can recur with no name of its own to call, takes pages. The notation fixes what is meant, and the prose helps a reader get there. The two directions aren’t symmetric. Going from the notation to prose is translation: the equation has one meaning, and any explanation can be checked against it. Going from prose to notation means inventing whatever rules the prose left out, which is the position an agent is in whenever it works from a prompt.
The Trust Problem
Volume is only part of the problem. Code is often low in semantic density. The shipping rule later in this article is a three-line expression. Written as procedure, the same rule ends up spread through checkout, refunds, admin tools, and their tests, each enforcing part of it among handlers, mappings, and null checks, so even a careful reader has to reassemble the rule before judging it.
The low density comes from a mismatch of vocabulary more than from the agents in particular. General-purpose languages describe how a computation proceeds. Intent usually takes a different form. Part of it names the things in the domain and how they fit together: an order belongs to a customer, holds line items, and carries a payment. The rest says what must be true of those things: an order can’t ship before payment clears, and a refund can’t exceed the amount captured. When the only vocabulary available is operational, the structure dissolves into classes, tables, and mappings, and the rules have to be spelled out as procedure, which takes many more lines than the rules themselves. Agents write in the vocabulary they’re given.
Say What You Mean, Mean What You Say
The Hatter was right that saying what you mean and meaning what you say are different things, and a system built by agents needs both.
Saying what you mean is validation: the stated intent matches what we want. Only people can do this, because only people know what they want. They can try the system and see whether it behaves as they hoped, but that happens late and covers only what they thought to try. To validate intent up front, they need it written down in a form they can read in full, which means short and in the vocabulary of the problem. Otherwise they’ll skim it the way they skim diffs.
Meaning what you say is verification: whatever the notation states is binding, and machines hold the implementation to it. That requires a notation with a definite meaning, which prose lacks. A sentence can be checked only by someone interpreting it, and interpretations differ.
Verify to Trust surveys the evidence on how automated checks earn trust in agent output. Here the question is what verification checks against. We already have several mechanisms, and each checks code against part of the intent. Types check it against declarations, and tests against examples someone chose. Formal methods check it against a specification, linters against conventions, and BDD scenarios and architecture tests against behavior described in domain terms. Spec-driven development, a newer practice built around agents, checks it against a written specification, usually in prose.
Each offers something worth borrowing. Types give immediate feedback in the editor, before anything runs. Tests can express almost any expectation, because they’re ordinary code. Formal methods can establish a property across all the states of a model, beyond the cases someone thought to try. Linters are scrappy: quick to add, local, and useful on the first day. BDD and architecture tests work at the level of abstraction where intent lives. Spec-driven development puts the statement of intent first, before any code exists, though a prose specification binds the implementation only as far as someone interprets it.
There are also tradeoffs involved. Rigor is expensive, and its cost grows with the size of what you’re checking. Tests are expressive but cover only the cases someone wrote. Types are immediate, but the more you ask of them the harder they are to read. Applied to a large, low-density implementation, you can’t have all of these at once. Could one notation make intent readable and support several kinds of checking at once?
What We Want From a Language
Set aside the things that decide most language choices in practice, such as performance, libraries, and ecosystem. They matter, but they aren’t what makes a notation good for stating intent. Three other properties are, and they stay close to what Kenneth Iverson asked of a notation in his 1979 Turing lecture, Notation as a Tool of Thought, including ease of expressing the constructs that arise in problems and amenability to formal proof.
Expressivity is how directly a notation states the things you care about. A notation built on the vocabulary of intent lets you write the rule itself instead of a procedure that enforces it, so the statement stays short enough to read in full. Programming language theory often uses the word for the range of computations a language can express, which I’ll call generality instead.
Compositionality means the meaning of a larger expression follows from the meanings of its parts and a fixed rule for combining them, so knowing the parts and the rule is enough to understand the whole. Decimal notation is the classic case. The 3 in 300 and the 3 in 3 contribute different amounts, but one positional rule decides both, so anyone who knows the rule can read any numeral. A rule stated once about part of a system works the same way: it applies wherever that part is used, including in code written after the rule.
Reinterpretability means one expression supports many interpretations, each of them definite. You can compile it, run it, simulate it, test it, verify it, explain it, and draw it. Descartes’ coordinates did something like this for geometry, letting the same problem be read as a figure or as an equation and solved in whichever form was easier.
The verification mechanisms from the previous section, types, tests, formal methods, and linters, each interpret the code in their own way. A type checker reads a program as constraints on values, a test suite runs it on chosen inputs, a model checker explores its states, and a linter matches it against patterns. Today they are fitted one by one onto an implementation none of them was designed for. A notation with these three properties could support all of them from one statement of intent, and reading that statement to check that it says what we want is one more interpretation among them.
The Frontier
Reinterpretability trades against generality. The more computations a language can express, the fewer questions about its programs have answers in general. With a Turing-complete language most interesting properties of a program are undecidable. General-purpose languages are built for generality, and they pay for it in what can be known about the programs written in them.
Restriction has been defended before, at a different boundary. In EWD 667, his note on why programming in natural language is foolish, Dijkstra argued that the narrowness of a formal notation is an asset, because it rules out statements that are nonsense. Formal notation narrows natural language, and a domain notation can narrow general-purpose computation for a similar reason.
A notation for intent can make a different trade. It can give up generality its domain doesn’t need while staying direct about what the domain does need to say. The trade between generality and reinterpretability still holds, but a domain notation doesn’t pay for generality it never uses, and that is the sense in which it gets past the frontier general-purpose languages sit on.
SQL shows what this buys. Here is a query:
SELECT c.id, c.name, SUM(o.total) AS spent
FROM customers c
JOIN orders o ON o.customer_id = c.id
WHERE o.placed_at >= DATE '2026-01-01'
GROUP BY c.id, c.name;The query fixes the result: for each customer who placed an order since the start of 2026, the total of those orders. It says nothing about how to compute that. A database might choose either of these plans:
- Plan A uses an index on
orders.placed_atto find the recent orders, hash-joins them tocustomers, and sums with a hash table. - Plan B scans
customers, looks up each customer’s orders through an index onorders.customer_id, filters them by date, and sums as it goes.
Both plans produce the same rows. Plan A may be cheaper when few orders are recent, and Plan B when the customer table is small, though table sizes alone don’t settle the cost. The optimizer picks between them from statistics about the data, and it can change its choice when the data changes, without anyone editing the query. That freedom exists because SQL is restricted: a query states a result in a language narrow enough that the optimizer can build alternative plans through transformations known to preserve that result. The query is the intent, and the plans are implementations held to it.
The query also leaves a question for whoever asked for the report. Should a customer who placed no orders this year appear with a zero? This query leaves them out, because the inner join finds no qualifying orders for them. Both plans agree on that answer, since both are held to the query. The person who commissioned the report may want a different one, and then the query needs a LEFT JOIN, the date condition moved into the join, and a decision about how to show zero. Verification can’t catch that mistake, because the plans do exactly what the query says. Catching it falls to someone who knows what the report is for, and they can catch it because the query is short and says exactly which customers appear. That is the Hatter’s distinction in a few lines of SQL.
Where Cohesive Fits
What I’ve described is a wishlist, and Cohesive, a modeling language and compiler for software systems, is one attempt at it. It works under the operational constraints set aside above, within existing ecosystems, languages, and infrastructure. Within those constraints it is designed around expressivity, compositionality, and reinterpretability. A team describes a system once, in terms of its entities, transitions, and invariants, and a compiler builds a system graph from that description. Code, infrastructure, simulations, and the context agents receive are all realizations of the same model.
Invariants show how this works. Cohesive states an invariant as an expression attached to an entity. It is written as a C# lambda, but the lambda has to lower into Cohesive’s own portable expression language, and arbitrary method calls, hidden I/O, captured runtime state, loops, and mutation are rejected when the model is authored. What remains is a condition over the entity’s fields, narrow in the way a SQL query is narrow, which is what lets Cohesive validate, serialize, and interpret it consistently. Here is the shipping rule as it appears in Commoditizing Determinism, after the team decided that payment must be captured before an order ships:
Invariant(
"ShippedOrdersHaveCapturedPayment",
order => order.Status != OrderStatus.Shipped ||
order.Payment == PaymentStatus.Captured);This encodes a stricter policy than the sentence from the trust problem. “An order can’t ship before payment clears” governs the moment of shipment. The invariant constrains every state of the order, including the states after it ships, so a shipped order must have captured payment for as long as it stays shipped. A refund on Friday breaks the rule even if payment cleared before the order shipped on Tuesday. Whether that is the right policy is the team’s decision, and the expression is short enough that they can see they’ve made it.
Suppose an agent adds an express checkout path. ValidateState checks an order state against the order’s invariants however that state was produced, so a test can start with an order whose payment is pending, run checkout, and validate the result. If checkout marks the order shipped while payment is still pending, the validator raises InvariantViolationException and names the rule that failed, ShippedOrdersHaveCapturedPayment.
On its own, that looks like an assertion library. But the test is just one interpretation of the rule among several others. The same expression is part of the order’s definition, which is part of the context an agent receives when it works on orders, so the agent writing express checkout sees the rule before it writes the transition. The order’s declared transitions can be held to it the same way: validating the order state a transition produces catches any transition that would leave an order breaking the rule. And because the rule is a portable expression rather than compiled C#, it can go to tools that never run the order code at all. A model checker can explore combinations of states and transitions, looking for a sequence that breaks it, and a symbolic solver can check the constraint itself, such as whether any order state can satisfy it.
One rule, many interpretations
ShippedOrdersHaveCapturedPayment is the shared source for A test validates a checkout result, An agent receives it as context, Each transition’s result is validated against it, A model checker searches for a breaking sequence, A symbolic solver checks the constraint itself, A person reads it and decides the policy.
The rule also composes with transitions nobody had in mind when it was written. Months later, someone adds a refund transition. Each piece is sensible on its own: shipped orders keep captured payments, and refunds return money. Together they conflict over Friday’s refund, and because the invariant belongs to the order rather than to checkout, the refund transition can be checked against it like any other. A test that runs the refund transition on a shipped order and validates the resulting state fails with ShippedOrdersHaveCapturedPayment. Teams have to decide whether they route refunds through a return first, or narrow the rule.
Loops and Recursive Improvement
A notation for intent matters more as agent work becomes iterative. A development loop runs an agent until some outcome is reached, and agent graphs compose several such loops. Each one needs a statement of the outcome it’s working toward, and that statement is both its objective and its stopping condition.
When the outcome is written in prose, the loop optimizes against a vague target and finds some way to satisfy the letter of it. A change can slip through a gap and still pass the check. The loop keeps changing the code until the check passes, and it has no way to tell that kind of pass from one that does the job. When the outcome is written as properties the system must satisfy, the loop can check them on every iteration, and a person can read them once and know what the loop is aiming at.
Self-improving loops raise the stakes. Here I use recursive improvement for loops that refine a system or a codebase over many iterations, and sometimes refine their own prompts and graphs along the way. Recursion can only improve toward something, and a well-stated goal is how you tell whether it has. It doesn’t guarantee the loop gets there, since a loop can alternate indefinitely between two failing patches. The goal has to sit outside the loop and stay fixed while the loop changes everything else, since a loop that can rewrite its own target can always declare success. The goal may still change over time, but each change should go through a person, which makes the notation the place where people steer.
This sets a limit on agents verifying agents. A loop can check its output against the goal, and agents can review each other’s work against it, but none of that tells you whether the goal is the right one. A precise goal can still be the wrong one. Give a loop the shipping invariant as its stopping condition, and it can pass by disabling shipping, because a system that ships nothing never ships an unpaid order. Whoever reviews a stopping condition can ask a practical question: would this check also pass if the system stopped doing its job? If it would, the goal needs to say what the system must do as well as what it must never do. That question is validation, which is why a stopping condition deserves its own review.
Stopping condition
The system
Passes
Fails
Does its job
Does its job · Passes
Real progress
true positive
The goal is met and the system still works.
Does its job · Fails
Over-strict goal
false negative
The check rejects working changes, so the loop keeps going or gives up.
Has stopped
Has stopped · Passes
Hollow pass
false positive
The check passes because the system stopped doing its job.
- A loop given only the shipping invariant passes by disabling shipping
Has stopped · Fails
Caught regression
true negative
The check fails and the loop keeps working.
The Rising Sea
The first step is for teams to write the properties they want as executable checks, as a matter of routine: assertions and invariants for what must be true and what must never happen, and stopping conditions for the outcome a loop is working toward. Development loops already need that statement, and today it’s mostly prose in tickets, prompts, and reviewers’ heads. Few teams do this consistently yet.
Alexander Grothendieck, who rebuilt the foundations of algebraic geometry in the 1960s, described his way of working with an image of the sea advancing on hard ground. The water comes in so slowly and quietly that nothing seems to happen, yet it eventually surrounds the resistant ground until the ground no longer stands in the way. Today’s approach to agent code is closer to attacking the ground directly. We review more of the implementation, test more of it, and skim when there’s too much. The rising sea would be to raise the notation until checking the intent stops being the hard part. Each property a team writes down raises the water a little.
Sources
- Lewis Carroll (1865). Alice’s Adventures in Wonderland, chapter 7
- Andrej Karpathy (2023). “The hottest new programming language is English”
- G. H. F. Nesselmann (1842). Versuch einer kritischen Geschichte der Algebra, part 1: Die Algebra der Griechen
- Gerolamo Cardano (1545). Ars Magna
- Frederic Rosen (translator) (1831). The Algebra of Mohammed ben Musa
- Harold Abelson and Gerald Jay Sussman (1985). Structure and Interpretation of Computer Programs, preface to the first edition
- Leslie Lamport (2015). Who Builds a House without Drawing Blueprints?
- Daniel Jackson (2006). Software Abstractions: Logic, Language, and Analysis
- Daniel Jackson (2021). The Essence of Software: Why Concepts Matter for Great Design
- Kenneth E. Iverson (1979). Notation as a Tool of Thought
- Edsger W. Dijkstra (1978). On the foolishness of “natural language programming” (EWD 667)
- Colin McLarty (2007). The Rising Sea: Grothendieck on Simplicity and Generality
Links checked Nov 22, 2026.
Knowledge graph anchors
Open graphSupporting