agentic-intent-model

Proposal (AIM 6.4) — the process, filled in: races, an interrupting deadline, steps over a collection, timed waits, criteria as rules

Status: agreed and written into the specification (AIM 6.4), 2026-11-08 — drafted 2026-11-07, revised twice after a second model’s reviews of the execution semantics (2026-11-07, 2026-11-08) · Author: Michael & Claude working session · Affects: §6.2 (Operation — Contract as renamed by 6.3 Part 5: ### Criteria), §6.3 (Process — Flow as renamed by 6.3 Part 4; what a case is; Steps: what a wait hears, waits on several Events, for each, after: / until; Ends on), §6.7 (Trigger: ### Ends), §10 (diagnostics), the Paths and BPMN projections

Where this comes from

The NASA example (examples/nasa, written against 6.3) holds three real processes: lifecycle gates with a rework loop, a launch countdown with a hold and a window, anomaly resolution entered by an Event. Set beside BPMN 2 and DMN, each of them had a place where the language ran out and the commitment was left in prose or in the realization:

The owner: do not adopt BPMN; fill the gaps the AIM way, so more real-world cases can be said. A second model reviewed the first draft and found five places where two realizations could both follow the text and behave differently; this revision fixes each, and two of its forks were decided by the owner (see Decided).

The AIM way

Part 0 — what a case is, and what a wait hears (rules 6.2 left unsaid)

§6.6 and §6.7 speak of “the case” and never say what one is; §6.3 says a waiting step “continues with the next step when the Event arrives for this case” and does not say whether an Event that arrived before the step was reached counts. The NASA countdown shows both gaps: SpaceX may report the lander ready while the weather is still being polled, and a step over the stations runs several things at once. Every fill below rests on these rules.

A case is one run of one process — a Process facet or a promoted process — started by an entry: an actor invoking it, a Trigger, a subscription at its top, or a step of another case invoking it.

Part 1 — a wait on several Events is a race; continues: says which go on

§6.3 Steps, Waiting. A step with several subscribes waits for whichever of those Events comes first in the case’s order (Part 0). The first ends the wait; the others are not taken by this step. After the edges, — continues: <Event>, <Event> names the Events that go on to the next step; an Event not named ends the case at this step — its own subscribers elsewhere still run, as for any Event. Without continues:, every one of them goes on: the step waited for any of them. Events are named by facet name, as outcomes are.

A race is for genuine alternatives: two things that may happen, of which the case wants the first — an offer accepted or declined, a part delivered or back-ordered. An Event that must end the case whenever it comes is not an alternative; it is written once, under Ends on (Part 2), never as a side of a race. The reason is Part 0: a race takes the earliest Event in the case’s order, so a readiness that came early would win over a scrub that came later, and the case would go on into a scrubbed countdown.

4. Wait for the customer's answer — [subscribes](aim:juice.sales#Event:OfferAccepted), [subscribes](aim:juice.sales#Event:OfferDeclined) — continues: OfferAccepted

(A sales process, not NASA: the countdown’s wait for the lander has no genuine alternative, which is itself a finding — most “whichever comes first” in real processes are a wait and a cancellation.)

Diagnostics. Hard error: a continues: naming an Event the step does not subscribe to. Informational: a single-subscription step with continues: (nothing to choose); a race whose Events can never belong to one case (none is emitted within the case or references its record, §6.6); an Event subscribed at a step and also listed under Ends on (the step’s side is dead: the case ends first).

Projection. An event-based gateway with one catching event per subscription; the Events not continued lead to an end event.

Part 2 — what ends a case: an Event under Ends on, a deadline with ### Ends

An Event that ends the case

§6.3 Process, new sub-block ### Ends on; on a promoted process, top-level ## Ends on. Bullets of Event addresses in the bracket form a Trigger’s Schedule uses: - [<intent>#Event:<Name>]. When such an Event belonging to the case is placed in the case’s order, the case ends at that point, at once: nothing after it in the order advances the case, no step starts, no wait completes, and its child cases and item runs end with it (Part 0). There is no cleanup: the Event is already the record of what happened — a scrub was done by Scrub before it emitted LaunchScrubbed. Anything that must happen on ending is the emitter’s work.

## Ends on

- [nasa.esdmd.artemis3.countdown#Event:LaunchScrubbed]

With this the countdown’s wait for the lander subscribes to LanderReady alone, and a scrub — called by the launch director at any step, or by the weather, the range, the go poll or the window — ends the case wherever it is, before or after the readiness came.

Diagnostics. Hard error: an Ends on address that is not an Event. Informational: an Ends on Event that can never belong to the case (never emitted within it and never referencing its record); an Ends on Event also subscribed at a step (the step’s side is dead).

Projection. An interrupting boundary message event on the whole process, leading to an end event.

A deadline that ends the case

§6.7 Trigger, new sub-block ### Ends. On a Trigger of kind deadline, one bullet: the case. When the deadline expires for a case:

  1. The case is interrupted at once. No Event advances it, no step starts, no wait completes; nothing of the case runs but what the deadline triggers.
  2. The triggered work runs, as the cleanup: it records what must be recorded and moves the case’s record where a State requires (the scrub marks the countdown scrubbed).
  3. When the triggered work completes, the case ends. It hears no further Events.
  4. If the triggered work does not complete, the case stays interrupted and a realization MUST show it as such — like owed work with no performer, a question for the owner, never silent. Recovery is explicit: the realization offers to run the triggered work again or to end the case by hand; neither happens on its own. A case ended by hand with its triggered work incomplete carries a run-time finding, cleanup incomplete, kept with the case and shown with it; it is a fact of that run, not a diagnostic of the graph, and no static check reports it.
  5. Child cases and item runs end with it (Part 0): the ones its steps started, at once, their own cleanup not run; the parent’s join never completes.

A deadline without ### Ends behaves as today: it starts work and interrupts nothing.

## Trigger: WindowCloses

### Summary

Three hours after the call to stations the window has closed; the count is interrupted, scrubbed, and ends.

### Kind

- deadline

### Schedule

- 3 hours after [nasa.esdmd.artemis3.countdown#Event:CountdownStarted] — unless [nasa.esdmd.artemis3.countdown#Event:Liftoff]

### Fires

- [triggers](aim:nasa.esdmd.artemis3.countdown#Operation:Scrub)

### Ends

- the case

The review-closure deadline keeps no ### Ends: it escalates and the review goes on. The anomaly deadline keeps none either: escalation, not abandonment.

Ending a step is not in this version. A first draft offered the step — abandon the current step and go on. A deadline anchored on a case’s start cannot tell which step it governs: the anomaly timer starts at detection and would abandon triage, proposal or the director’s decision, whichever happened to be current; a process with phases has several active steps. Step interruption arrives when a deadline can name the step activation it bounds — a wait that carries its own limit — and not before.

Rules. ### Ends is allowed only on a deadline (per case); a schedule has no case to end. unless disarms it as any deadline’s.

Diagnostics. Hard error: ### Ends on a Trigger whose kind is not deadline; a bullet other than the case. Informational: ### Ends with no unless Event (it will always fire; ask whether that is meant).

Projection. An interrupting boundary timer on the whole process, leading through the triggered work to a terminate end event.

Part 3 — a step over a collection

§6.3 Steps, new words.

<n>. <words> — for each [<address>] [as <input>] [in order | in order of [<field address>]] — <edges>
7. Poll every station — for each [nasa.esdmd.artemis3.countdown#Record:Countdown.stations] as station — [invokes](aim:nasa.esdmd.artemis3.countdown#Operation:PollStation)
8. Go/No-Go — [invokes](aim:nasa.esdmd.artemis3.countdown#Operation:PollGoNoGo) — continues: Go

with stations: list(string) required on the countdown, PollStation taking station: string required and writing the station’s answer, and PollGoNoGo reading the answers and deciding Go (every station answered go) or NoGo. Closing every action of a review is the same word over [nasa.esdmd.artemis3.lifecycle#Record:Action] with CloseAction taking actionId: string required ref(nasa.esdmd.artemis3.lifecycle#Action.id); asking every supplier for a certificate is the same word over the suppliers of an order.

Diagnostics. Hard error: an address that is neither a list field of the case’s record nor a Record referencing it; a Record referencing it through several fields with no by; in order on a Record, or in order of naming a field not of that Record; continues: on a step over a collection; an invoked operation with no Input field that can take the item, or several and no as; as naming a field that cannot take it. Informational: a step over a collection with no operation (a human step per item is valid and shown per item).

Projection. A multi-instance activity, parallel or sequential, over the collection.

Part 4 — a timed wait

§6.3 Steps, new words — after: <n> <unit> and — until [<address>]. Either delays the step’s start.

3. The board conducts the system requirements review — [invokes](aim:nasa.esdmd.artemis3.lifecycle#Operation:ConductGateReview) — after: 10 business-days — continues: Proceed

The board has ten working days with the package before it sits. A countdown resuming at a planned moment is — until [nasa.esdmd.artemis3.countdown#Record:Countdown.resumeAt]; a cooling-off period, a statutory waiting time, a reminder a week later are the same two words.

Rules. after: and until are written after the edges and before continues:. A step may carry one of them, not both.

Diagnostics. Hard error: until naming a field that is not date or datetime, or not a field of the case’s record; after: without a unit the Schedule grammar knows; both words on one step. Informational: a timed wait with no timezone in reach, or business-days with no calendar in reach (ask which).

Projection. A timer intermediate event before the activity.

Part 5 — criteria as rules

§6.2 Operation and §6.3 Process, new sub-block ### Criteria. Allowed only beside ### Decides. A criteria fence, one rule per line:

<Outcome> when <input> <op> <value>[, <input> <op> <value>]...
otherwise <Outcome>
## Operation: PollWeather

### Input

```schema
countdownId: string required ref(nasa.esdmd.artemis3.countdown#Countdown.id)
wind: number required label("Wind at the pad, knots")
lightningWithinTenMiles: boolean required
ceiling: integer required label("Cloud ceiling, feet")
clearingForecastInWindow: boolean required label("The weather officer's forecast: clears inside the window")
```

### Decides

- **Green** — the launch commit criteria for weather are met, or will be inside the window
- **Red** — a criterion is violated and the forecast does not clear it inside the window — [invokes](aim:nasa.esdmd.artemis3.countdown#Operation:Scrub)

### Criteria

```criteria
Red when wind > 30, clearingForecastInWindow = false
Red when lightningWithinTenMiles = true, clearingForecastInWindow = false
Red when ceiling < 1500, clearingForecastInWindow = false
otherwise Green
```

The weather officer’s forecast is a judgement; it is made before the poll and arrives as an Input, so the rules can read it. This is DMN’s idea — inputs, rules, a hit policy — without its language: no expressions beyond a comparison, no functions, nothing a parser cannot check against the schema.

Diagnostics. Hard error: a rule naming an outcome not declared under Decides; an input that is not an Input field; a value not of the input’s type; no otherwise, or two; ### Criteria without ### Decides. Informational: a rule no input combination can reach because an earlier rule covers it; an outcome no rule names (declared but undecidable).

Projection. A decision table with first-hit policy, one row per rule.

What is deliberately not filled

Acceptance example

Written: examples/nasa/6.4/, the countdown in 6.4 form beside its 6.3 form, with eleven scenarios: a lander reported ready before the wait is reached (Part 0); a scrub called during the wait, and a readiness followed by a scrub before the wait is reached (Part 2, Ends on); the window expiring while a station’s poll is still running, at the same instant as a readiness, and once with a scrub that does not complete (Part 2); the stations list changed after the poll started, one station whose poll fails, and item runs ending with their step (Parts 0 and 3); a resume moment written only after the hold is reached and changed while the case still waits (Part 4); a forecast that clears a violated criterion inside the window (Part 5). No step of the countdown invokes a process, so the child-case rule is stated by the scenarios and not exercised.

Existing models stay valid

Every 6.3 file is valid 6.4 source, unchanged. The fills are additive words and sub-blocks; a step with one subscribes, a deadline without ### Ends, a Decides without ### Criteria mean what they meant. The facet is written Process here, as 6.3 Part 4 renames it; Flow reads the same under the old spelling. Part 0 states a behaviour that 6.2 left to the realization; a realization that discarded early Events was within the old text and is outside the new one.

Decided (owner, 2026-11-07)

Decided while building it into Amy (owner, 2026-11-08: the open points taken as proposed)