feat(estimation): add cost and risk estimation actor #1210

Closed
aditya wants to merge 1 commits from feature/m6-estimation into master

1 Commits

Author SHA1 Message Date
aditya 3f6b255747 feat(estimation): add cost and risk estimation actor
CI / build (pull_request) Successful in 18s
CI / helm (pull_request) Successful in 21s
CI / benchmark-publish (pull_request) Has been skipped
CI / security (pull_request) Successful in 59s
CI / lint (pull_request) Successful in 3m18s
CI / typecheck (pull_request) Successful in 4m7s
CI / quality (pull_request) Successful in 4m13s
CI / unit_tests (pull_request) Failing after 6m5s
CI / docker (pull_request) Has been skipped
CI / coverage (pull_request) Successful in 9m14s
CI / e2e_tests (pull_request) Failing after 15m31s
CI / integration_tests (pull_request) Successful in 24m14s
CI / status-check (pull_request) Failing after 2s
CI / benchmark-regression (pull_request) Successful in 55m20s
Add --no-estimate opt-out flag for plan use command and persist
EstimationSkipped reason when estimation is skipped or fails.

Add EstimationReport Pydantic domain model (identical to #649) with
spec-aligned multi-dimensional output: cost range (min/max USD),
expected steps, expected child plans, rollback risk (0.0-1.0),
estimated duration in minutes, confidence (0.0-1.0), rationale, and
optional historical basis.

Add EstimationSkipped domain model with reason, timestamp, and
optional actor_name fields for tracking when estimation is skipped
via --no-estimate or when the estimation actor fails.

Add estimation_produced to DecisionType enum and STRATEGIZE_TYPES.

Add Alembic migration m6_006 adding estimation_report_json and
estimation_skipped_json columns to v3_plans and updating the
ck_decisions_type CHECK constraint.

Wire --no-estimate through plan use CLI: when set, creates
EstimationSkipped with reason and clears the estimation actor.
Update _run_estimation() to persist EstimationSkipped on actor
failure instead of only logging.

Add docs/reference/estimation.md documenting the estimation feature,
EstimationReport schema, EstimationSkipped schema, and CLI examples.

Add benchmarks/estimation_actor_bench.py with ASV benchmarks for
EstimationReport and EstimationSkipped operations.

Add 13 Behave scenarios (estimation_skip.feature) and 6 Robot
integration tests (estimation_skip.robot) covering EstimationSkipped
model, EstimationReport model, plan field mutual exclusion, and
--no-estimate CLI behavior.

ISSUES CLOSED: #209
2026-04-02 10:26:22 +00:00