project-estimation: add calibrated delivery estimates - #134
Conversation
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars. ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
ed34737 to
b11e3c5
Compare
Independent exact-head review receipt
The reviewer independently confirmed the three prior-head remediations: material-unpriced evidence remains semantically admissible but fail-closed at publication with distinct diagnostics and a direct regression; omitted Reviewer-executed verification included 113 focused estimator/maintenance tests, 68 project-estimation discovery tests, 15 archive/security-contract tests, release consistency, exact scope-hash probes, material-unpriced release-block probes, and schema-reference probes. All completed successfully. Observed direct-review usage: 115,744 input tokens, 4,288 output tokens, 3,445 reasoning tokens, 595,840 cache-read tokens; API-equivalent reviewer cost recorded by the runtime as $0.575806. This receipt is source-governance evidence only. It does not authorize a tag, release, publication, installation, activation, restart, or canary. |
|
You have reached your Codex usage limits for security reviews. Please try again later. |
Final current-head review inventory
Every available review surface was paginated and adjudicated:
Disposition at cutoff: 0 actionable findings; 3 historical findings resolved/outdated; no unresolved review thread; exact-head independent review approved with high confidence. The PR is eligible for the already-authorized normal source merge after final head/check/signature readback. This does not authorize any tag, release, publication, installation, activation, restart, or canary. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: af5e68fdb0
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
|
||
| def reconcile(prior_result: Mapping[str, object], actual: Mapping[str, object], pricing: Mapping[str, object]) -> dict[str, object]: | ||
| prior = validate_result(prior_result); actual2 = validate_actual(actual); pricing2 = validate_pricing(pricing) | ||
| if prior["result_kind"] != "estimate" or "detail" not in prior: raise EstimationError("prior result must be an available estimate") |
There was a problem hiding this comment.
Reject actuals from a different completion boundary
When an estimate targets one boundary, such as merged, but the actual document reports another, such as source_present or released, reconciliation accepts both and derives comparable duration, wait, and cost errors even though they cover different scopes of work. This can create false misses and contaminate later calibration, so require actual2["completion_boundary"] to match the prior estimate's headline completion boundary before calculating errors.
Useful? React with 👍 / 👎.
| total_tokens = sum(known_token_samples) + sum(unpriced_token_samples) | ||
| known_basis = 0 if total_tokens == 0 else sum(known_token_samples) * 10_000 // total_tokens | ||
| unpriced_basis = 0 if not token_rows else 10_000 - known_basis | ||
| known_cost_q = {"p50": None, "p80": None, "p95": None} if not routes or not token_rows or sum(known_token_samples) == 0 else _q(cost_samples) |
There was a problem hiding this comment.
Treat fully priced zero token usage as a known zero cost
When a valid published token prior has all-zero quantiles and the request has routes with unambiguous prices, total_tokens == 0 forces coverage to 0, unpriced coverage to 10000, and every cost quantile to null. Zero modeled usage is fully priced at zero rather than unpriced, so this case should return 10000 known basis points and zero cost while continuing to reserve the unavailable/null state for missing token priors or routes.
Useful? React with 👍 / 👎.
Summary
bootstrapandpromotedcalibration contracts, closed public schemas, maintenance verification, archive membership, README, and architecture documentation for unreleased source version 6.2.0.Linked workspace source
ebf821c60cb60c4aff566c55f08e25382cd412d7.1d19079c…, pricingfdc67cab…, quotacc0aabf0…, and notification0b098d20…; receipt9d104bacdbc251fd07a441b071b3111c6d274c07e1feddc18797ebf13eb22449.Validation
af5e68fdb03fffb8d286ab089184ca8d88281357over basec08e7efde157b67777cc231df978b8f62fd5f87b.git verify-commit.git diff --checkpass.ses_fd813746dffeBci1uIwDa7PESw).2026-08-22T05:30:35Z.Required checklist
Governance and release boundary
This remains a source-only PR. The exact reviewed head, fresh CI, and complete current-head review-surface inventory are satisfied. No tag, release, install, activation, restart, or canary is authorized.
author: Codex (OpenAI family), acting for repository owner John Osumi
standing_directives: public-source boundaries, signed commits, validation, independent review, privacy, and fail-closed release gating followed
tier: 3
cross_check: PROCEED — direct non-coordinator xAI/Grok review of exact base c08e7ef and head af5e68f returned APPROVE with HIGH confidence and no actionable findings; session ses_fd813746dffeBci1uIwDa7PESw; durable receipt #134 (comment); the operator expressly authorized this reviewer route and coordinator bypass, and no consumed operation was replayed or relabeled
post_condition: exact-head independent review, local validation, fresh remote CI, and the exhaustive current-head review inventory are complete; normal operator-authorized source merge is the only remaining gate; tag, release, install, restart, activation, and canary are prohibited
mcp_coverage_gap: NONE
contributor_rights: OWNER-AUTHORED
operator_reserved: yes - the operator authorized governed source work and merge only after this PR's own gates; every release and activation action remains separately controlled and currently prohibited