๐Purpose
The Initiative Closer runs the four post-commit close-event hooks after the PUT handler commits a status change: flips the orion.bypass dispatch_queue lock on terminal status, rolls component actuals into running averages on close, runs quality scoring plus the rolling-average regression check on close, and runs the per-initiative audit plus follow-on filer on any terminal state - exactly as they ran inside the app before phase 3. Carries the write-side quality scoring engine so the scoring hook is self-contained.
๐Duties
- Triggered whenever an initiative status is committed through the initiatives app PUT handler. - Runs each of the four close-event hooks as a separate best-effort step; one failing never blocks the others. - On terminal status, flips the bypass dispatch lock and runs the audit plus follow-on filer. - On close, rolls up component actuals and computes and persists the quality score. - Records a session_event and a Palantir post on every close.
๐Constraints
- Owns and closes its own database connections; never relies on a callers connection. - Behavior is preserved exactly from the app (phase 3 is a relocation, not a refactor). - Does NOT hold the close gate (status guard, terminal-reopen guard, closure review-must-pass guard) - those stay in the app endpoint before the UPDATE. - Reached only through the initiatives apps shared shim, never imported by the app directly. - Does not touch the bypass book, cookbook, or initiative status rows beyond what the original hooks did.
๐คBelongs to
Source: Droid Families ยท Public information reflected here.