Utilities as Legendre duals of probabilities
TLDR: In recent work, Roy Fox proposes to understand an agent’s capabilities in terms of the set of environment dynamics it can bring about.[1] This leads to an intriguing duality between probabilities and utilities via the Legendre-Fenchel transform.
Introduction
Some agents are more powerful than others. Indeed, some can yield a wider range of outcomes, maybe because they are capable long-term planners or because they have built rich world models. Being able to clearly delineate the capabilities of agents is an important challenge for AI alignment.
A natural place to start thinking about how to describe the capabilities of an agent is reinforcement learning (RL), or more generally, approaches that see behaviour as arising from the maximisation of expected utility. By taking this view, one can describe “capability” as the range of reward/utility functions that an agent can successfully maximise — as done e.g. in classic work by Legg & Hutter and also in more recent work.
Such a perspective is very useful, but I am not a big fan of rewards/utilities. Rewards are great in games and other settings where they come naturally, but real life often does not handle rewards on a silver plate. When absent, rewards are often defined artificially — but the design of rewards that give rise to desired behaviour without enabling Goodharting is extremely difficult. That said, reward-based frameworks are powerful,[2] and proposing alternative approaches that can compete with them is hard.[3]
Thus, while I am not a utility/reward fan, I am intrigued by situations where they arise naturally. One place where this happens is in the celebrated von Neumann-Morgenstern utility theorem (VNM), which states that preferences with specific properties can be described as if the agent is trying to maximise a specific utility function (see this great post for related discussions). Another interesting idea is the link between utility maximisation and description length minimisation presented by John Wentworth, which suggests a duality between utilities and probabilities.[4] A related perspective appears in Jeffrey–Bolker rotations as discussed by Abram Demski, where probability and value form vectors and certain linear transformations can move structure between them without changing the represented preferences.
I recently stumbled upon yet another way to see how utilities can naturally arise from probabilities, this time via the Legendre transform. In contrast with the settings discussed by VNM, Wentworth, and Demski, which assume a given preference or utility, here we simply start from achievable environmental dynamics to later derive utilities from them. The idea is simple and elegant — I’d not be surprised if it has been discussed before.[5] Moreover, I believe this perspective may be useful for various issues related to AI alignment, which is what pushed me to write about it here.
The rest of this post presents:
A general way to describe the “capability space” of an agent. This description uses probabilities and policies, but doesn’t use utilities or rewards.
An explanation of how this definition affords a dual description via the Legendre transform, which naturally establishes utilities as Legendre duals of probabilities.
Defining capability space
Let’s consider an agent that acts over an environment described by a variable
Denote by
Example: Controlled Markov processes
To make this more concrete, let us denote the actions of the agent by
where
In a recent paper, Roy Fox[6] defines the capability space of an agent as the collection of environment stochastic dynamics
The agent is free to choose any policy
, and thus it can choose among environmental dynamics .The agent can generate any mixture of realisable choices, so that
is convex.The agent can realise the limit of sequences of realisable choices, so that
is closed.
One can say that an agent’s capability can be assessed via the size and shape of its capability space. This is a general definition that does not rely on utilities or rewards — instead, it uses a credal set as in imprecise probability.

The Legendre-Fenchel transform
Our next step will be to re-express the capability space using the Legendre Transform. But before doing that, let me provide an overview of what this transform is.[7]
The Legendre-Fenchel transform was first introduced by Legendre in 1787, and was later extended by Fenchel in 1949. People are often more familiar with the Fourier transform, which takes a function in time domain
Concretely, for a given convex function
where the domain of
where
Algebraic interpretation of the Legendre transform
Consider a smooth and strictly convex function
Due to the bijection,
But there is another interesting question one can consider: would it be possible to build a function
The obvious candidate,
where
Geometric interpretation of the Legendre transform
Consider a smooth and strictly convex function
Thus,

Interestingly, thanks to the symmetry of the equation above, the intercept of the tangent of
This derivation shows that the information that constitutes a strictly convex function
is closed and convex if

For an epigraph, the above property takes the following form:
where
Under what conditions is the Legendre-Fenchel transform a “proper” conjugation — i.e., an involution? The Fenchel-Moreau theorem states that if
Utilities as Legendre duals of probabilities
We are now ready for the central idea. Consider describing the capability space
Note that
Thus,
Moreover, the assumptions of convexity and closedness on
This has various interesting implications: [10]
The Legendre-Fenchel transform states that the convex conjugate of the indicator function of the capability space is the maximal expected utility that such an agent can achieve.
The coordinates of the indicator function are probabilities; the dual coordinates of its convex conjugate
are real-valued functions on trajectories, which formally look exactly like utility functions.
Conclusion
We have explored how the capability space of an agent can be defined in two alternative ways:
As the set of stochastic dynamics that the agent can elicit in its environment. Here, the capability is evaluated by providing a candidate distribution
to , which then says if belongs to the possibilities of the agent or not.As the range of expected utility values that the agent can achieve on a variety of tasks. Note that by highlighting the maximum,
is delineating the possible values that are attainable. Here, capabilities are evaluated by testing various utility functions and checking how much expected utility the agent can attain.
What I find most fascinating is how utilities naturally emerge as duals of probability via the Legendre-Fenchel formalism. In this context, utilities don’t have the semantics that we normally attribute to them: they just highlight a dual domain that can be used to convey the same information regarding the dynamics of the environment that the agent can elicit. Mathematically, the duality is a consequence of the fact that convex sets of probabilities can be expressed as intersections of half-spaces, and utilities are a natural way to index such half-spaces.
Why this matters for alignment. A substantial portion of alignment is, in one way or another, about characterising what an agent could do rather than what it happens to do. The capability space turns comparing agents’ capabilities into set inclusion, and a safety property (“the agent cannot steer the world into region
This suggests an interesting possibility: since
that must contain
- ^
I came across Roy’s work during the Finding the Frame workshop at the RL Conference. I strongly recommend this workshop to anyone interested in the foundations of reinforcement learning.
- ^
In the context of RL, I very much recommend the series of six talks on the RL Debate Series, which exhibit various arguments for and against modelling behaviour in terms of reward maximisation.
- ^
I really like empowerment and other approaches to intrinsic motivation, but it is still early days.
- ^
This link between probabilities and utilities has been generalised in this recent paper, about which I’ll write another post sometime soon.
- ^
If you have seen related ideas elsewhere, please let me know!
- ^
It would be great if Roy could write a blog here presenting this work.
- ^
Further discussions about the Legendre transform can be found in this paper and this paper.
- ^
See Theorem 11.5 in Rockafellar’s book.
- ^
Below, the sup turns into a max because
is a closed subset of a probability simplex (which is compact). - ^
Another, perhaps more anecdotal implication is that
inherits the structure of the von Neumann–Morgenstern theorem for free. It is direct to see that for any and .That is,
carries the same information for and for any positive affine transformation of it. In VNM, utilities being “unique up to positive affine transformations” is a consequence of axioms on preferences. Here, the same invariance falls out of the geometry: affine rescalings of don’t change which face of is selected, so they cannot be distinguished by what the agent can achieve. The dual coordinates are not just utility-like in name — they come with the equivalence classes that utilities have.
If I understand the basic idea correctly, it’s that a convex set can be represented by its maxima for all linear functions on the vector space containing that set, and under these assumptions, that amounts to “the set of achievable outcome distributions can be represented by its maximal attainable utility for all utility functions”.
I’m curious what changes when looking at games of imperfect recall (general background discussed in this section; see also this paper for a connection between CDT+GT and KKT conditions).
For example, in the absent-minded driver problem, there are 2 intersections, and 3 different destinations; if you turn at the first, you get to A; if you go straight on first and turn on second, you get to B; if you go straight twice, you get C. Your policy is your probability of turning (since due to amnesia, there is no way to distinguish between the intersections). The set of achievable outcome distributions is not convex, since 100% A and 100% C are achievable, but 50% A, 50% C is not achievable. So we can’t describe the feasible region with utility attainment, as in the convex case.
Making a ‘finite number of time steps’ assumption, we can describe the outcome distribution as a polynomial of the policy probabilities; the policy space can be described as a product of simplices. When running a product of simplices through a polynomial, we get a non convex shape. To apply linear algebra, we could consider representing a degree-d polynomial on a vector space (such as a space containing all policies) as a linear function of , and now it looks like we may be able to represent such games using utility functions on a sequence (or multiset?) of independent runs of the imperfect-recall game.
This makes me wonder about reflective consistency. Say I’m a UDT agent and anticipate being faced with self-coordination problems in the future. Then maybe I should generate a bunch of random numbers today and store them in my mind, so that future copies of me can use them for randomized but self-correlated play. Maybe it can even deal with Wichardt-like examples where the UDT player is faced with other players, if we assume that other players can’t read the random numbers from the UDT player’s mind and can only respond to the “use random numbers” policy in general. Though yeah, I’m not sure how much sense these assumptions make.
Interesting!
Nitpick: The example below indicates that is a real number (a probability of the sequence arising if policy is implemented?), not a probability distribution. I.e., , but . Is that right?
Indeed: https://www.lesswrong.com/posts/YAa4qcMyoucRS2Ykr/basic-inframeasure-theory#Legendre_Fenchel_Duality