Optimization

For Both Executive and Technical Readers

Inference tells you what is true. Inquiry tells you what to learn next. Optimization searches over everything you could observe or do, and returns the combination that best meets your objective under your constraints.

Inference tells you what is true. It doesn’t tell you what to do.

Inference and information value both stop at knowledge. A system that can tell you what is true and what to measure next, but cannot tell you what to do about it, hands the most consequential step back to human intuition, unsupported, unjustified, and unauditable.

Optimization crosses into action. It is the layer that turns an explicit model into a recommended course of action, with the objective stated, the constraints respected, and the rejected alternatives recorded. The constraints are the point: “maximise survival” is a goal; “maximise survival for under a thousand dollars” is a decision.

Searches over actions and returns the best one, constrained and justified.

Optimization is a Cognitive Primitives, Action component. It searches over combinations of observations and, in causal models, of actions, against an explicit objective under explicit constraints, and returns an OptimizationResult: the best feasible bundle, the objective value achieved, and what was rejected and why.

Optimization Result best action, stated objective, explicit constraints
FieldWhat it holds
Objective & constraintStated in plain terms, what's being maximized, and what boundary it can't cross
RecommendedThe action set chosen, its cost, and the outcome distribution it produces
RejectedEvery alternative considered and turned down, each with the specific reason, not silently discarded
Objective achieved: how close the recommended action gets to the stated goal, stated as a number, not a claim.

The rejected field is required. A recommendation without a record of what was considered and why it was not chosen is not auditable. The optimizer must show its work.

Three levels: observe, intervene, constrain.

Three levels of reasoning, in order of ambition:

Inference. What is true? Reads the current posterior. Rung 1.

Value of Information. What should I learn next? Ranks candidate observations by expected decision impact. Rung 1 over the model structure.

Evidence Optimization. What actions best achieve the objective, under constraints? Searches over combinations of observations and interventions. Rung 2 and Rung 3, do() queries in a constrained search.

Optimization generalises Inquiry in two directions: it searches combinations (not just single probes), and it includes actions (not just observations). The search respects the model’s causal structure, it cannot recommend an action that is not represented as an intervention node.

The model deciding, not predicting.

Optimization is the brains deciding what to do, constrained, justified, and auditable.

There is no .bayes file for Optimization, it operates on any domain-specific domain model. The OptimizationResult is appended to the AuditRecord. The objective and constraints are stated inputs, not hidden assumptions.

Optimization Result sepsis_model · worked example
FieldValue
Objective & constraintMaximize P(Survival), total cost ≤ $1,000
RecommendedEarlyAntibiotics ($200) + Lactate test ($50), P(Survival) = 0.87
RejectedICU Admission, exceeds the budget constraint

What should we do?

Optimization answers the question after the posterior: what should we do?

P(Sepsis) is 0.62 and we have a thousand dollars. What is the best treatment strategy?
AnyChatOptimization · constrained action search
Searching over combinations of diagnostics and interventions under $1,000. Recommended: Early antibiotics ($200) + lactate ($50) = $250, achieving P(Survival) = 0.87. Rejected: ICU admission ($800), exceeds remaining budget after antibiotics. Blood culture ($180), high information value but does not change tonight’s treatment action given current posterior.
Why not blood culture?
AnyChatOptimization · rejected action
Blood culture has high diagnostic value but the posterior is already above the treatment threshold (0.62 > 0.55). Knowing the result would not change the treatment decision tonight, antibiotics are warranted regardless. The optimizer correctly deprioritises tests that would not change the action under the current objective and constraints.
How do you know this is the best combination?
AnyChatProvenance
I don’t, the model does. The optimizer searched over all feasible combinations of the stated actions under the cost constraint, evaluating each via do() queries on the domain model. The search is exhaustive over the action space, not a heuristic. The rejected actions and their reasons are recorded in the OptimizationResult attached to the AuditRecord.
Couldn't our pharmacists just follow the clinical protocol and use their judgment on resource constraints?
AnyChatRung 3 · counterfactual optimisation
Protocol and judgment address the average patient. The optimization query addresses this patient, with this posterior, this budget, and these treatment options. A protocol cannot compute expected utility across a joint treatment space while respecting resource constraints. Clinical judgment cannot enumerate the interaction effects between empirical antibiotics and fluid resuscitation under a given probability of organ failure. The model computes the combination that maximizes expected outcome for the actual posterior you have right now. That is not a replacement for judgment, it is what judgment looks like when it is made explicit and auditable.

The audit trail is the OptimizationResult, including rejected alternatives.

Downstream of Scenarios. The decision layer of the Action cluster.

Optimization is the decision layer of the Cognitive Primitives, Action cluster. It sits downstream of Scenarios (09, which maps the landscape) and upstream of the governance handoff (12 BPMN Integration, which receives the recommendation as a certified artifact).

Upstream: the current posterior (from Execute), the ScenarioComparison (from 09 Scenarios), and the stated objective and constraints from the analyst. Downstream: the OptimizationResult is appended to the AuditRecord and consumed by 12 BPMN Integration. It interacts closely with 05 Inquiry (which VoI calculation it extends) and 11 Monitoring (which tracks whether the recommended action had the expected effect).