Skip to main content

Module pane_execution

Module pane_execution 

Source
Expand description

Deterministic execution-policy selector for pane-history strategies (bd-1k7ek.6).

Three semantically-equivalent ways to drive pane undo/redo now exist — baseline (no history), the checkpointed PaneInteractionTimeline, and the persistent PaneVersionStore — proven byte-identical over lockstep histories (tests/pane_persistent_equivalence.rs). Once equivalent implementations exist, the system should pick the cheapest safe one for the observed workload rather than hard-coding one globally.

This module is that policy layer, and it is deliberately not opaque adaptive magic:

  • Selection is a pure, deterministic function of an observed PaneWorkloadProfile and explicit, documented thresholds — same inputs always yield the same PaneExecutionDecision.
  • Every decision carries a human-readable log and a PaneStrategyReason explaining why a strategy was chosen, so profiling and regressions stay explainable.
  • The checkpointed timeline is the conservative fallback (it is the certified production path and the differential oracle for the persistent spike); it is chosen whenever the persistent criteria are not all met.
  • Operators can force any strategy (PaneExecutionPolicy::forcing) or force the conservative path (PaneExecutionPolicy::conservative) for debugging and rollout — overrides bypass the adaptive logic entirely.
  • reselect applies hysteresis so the selector does not thrash when the workload jitters near a threshold.

Because the candidate strategies are proven equivalent, selecting among them can never change observable behavior — only cost. The selector emits the decision; wiring it to a live execution engine is downstream integration (the persistent store is still a prototype on no production path).

Structs§

PaneExecutionDecision
A deterministic, auditable strategy-selection decision.
PaneExecutionPolicy
Deterministic policy that selects among the three pane execution strategies.
PaneWorkloadProfile
Observed shape of a pane-interaction workload window — the deterministic input to strategy selection.

Enums§

PaneStrategyReason
Why a strategy was selected — the auditable rationale in every decision.