primus.optimization.optimizer_dispatch module

At-most-once, TaskDispatcher-backed optimizer child launch state machine.

This module does not publish Reports. The portfolio runner owns publication and calls OptimizerTaskDispatchService.step() only after the current state has been committed to the living Report.

class primus.optimization.optimizer_dispatch.OptimizerTaskDispatchService(backend: Any)

Bases: object

Perform one read or mutation step after Report publication.

__init__(backend: Any) → None
step(request: Mapping[str, Any], state: Mapping[str, Any] | None, *, may_mutate: bool) → dict[str, Any]