Skip to content

Demo Scenarios

The demo includes 9 scenarios — 5 cancellation cases and 4 flight-modification cases (see the Cancellation Matrix and Modification Matrix below) — covering every cell of the airline booking policy.

Terminal window
make demo
# Member Insurance Expected Command
1 Regular No DENY make scenario-1
2 Regular Yes ALLOW make scenario-2
3 Silver No DENY make scenario-3
4 Silver Yes ALLOW make scenario-4
5 Gold No ALLOW make scenario-5

John Doe (regular member) tries to cancel reservation RKLA42 which has no travel insurance.

The policy denies cancel_reservation. The agent explains that insurance is required for non-gold members.

Emma Kim (gold member) cancels without insurance. The policy allows it — gold overrides the insurance requirement.

# Member Cabin Expected Command
6 Regular Basic economy DENY make scenario-6
7 Silver Basic economy ALLOW make scenario-7
8 Regular Economy ALLOW make scenario-8
9 Gold Basic economy ALLOW make scenario-9

John Doe tries to change flights on a basic economy reservation. The policy denies update_reservation_flights — regular members cannot modify basic economy.

Try modifying the policy and re-running:

Terminal window
# Edit policy_english.md (e.g., remove insurance requirement)
make translate # ~5-15 minutes
make upload-translated
make demo-translated # See the new rules in action

Or edit the Datalog directly:

Terminal window
# Edit policy.dl
make upload
make scenario-1 # Check the change