Phase 3 migration item from casehub-poc. Workers in the engine currently have no structured lifecycle scope — they are activated per binding trigger and complete independently. This issue tracks first-class lifecycle scoping.
Scope
Define and implement CASE, STAGE, and BINDING lifecycle scopes for workers:
BINDING scope — worker lives for the duration of a single binding activation (current implicit behaviour)
STAGE scope — worker is active for the lifetime of a containing stage; terminated when the stage exits
CASE scope — worker persists for the full case lifetime; receives all context change events within the case
Dependencies
- Nested stage events (stage activation/completion events must be reliable before scope teardown can be triggered)
- Worker execution lifecycle tracking in the engine
Notes
Module home TBD — likely casehub-blackboard/ for stage-scoped, engine/ for case-scoped.
Refs casehub-poc migration plan (Phase 3): docs/superpowers/specs/2026-04-14-casehub-engine-migration-plan.md
Phase 3 migration item from casehub-poc. Workers in the engine currently have no structured lifecycle scope — they are activated per binding trigger and complete independently. This issue tracks first-class lifecycle scoping.
Scope
Define and implement
CASE,STAGE, andBINDINGlifecycle scopes for workers:BINDINGscope — worker lives for the duration of a single binding activation (current implicit behaviour)STAGEscope — worker is active for the lifetime of a containing stage; terminated when the stage exitsCASEscope — worker persists for the full case lifetime; receives all context change events within the caseDependencies
Notes
Module home TBD — likely
casehub-blackboard/for stage-scoped,engine/for case-scoped.Refs casehub-poc migration plan (Phase 3):
docs/superpowers/specs/2026-04-14-casehub-engine-migration-plan.md