Skip to content

evidence(OMN-12491): prove savings_estimates materialization on stability-test - #1925

Merged
jonahgabriel merged 1 commit into
devfrom
jonahgabriel/omn-12491-savings-evidence-dev
May 30, 2026
Merged

jonahgabriel merged 1 commit into
devfrom
jonahgabriel/omn-12491-savings-evidence-dev

Conversation

@jonahgabriel

Copy link
Copy Markdown
Contributor

OMN-12491 — savings_estimates materialization proof (stability-test)

Root cause (confirmed)

The ticket premise (savings_estimates = 0 rows) was a database mis-target in recon. The runtime savings projection (node_projection_savings / HandlerProjectionSavings) and the projection API both use the omnibase_infra database — the contract declares db_io.db_tables[0].database = omnibase_infra and the runtime resolves OMNIBASE_INFRA_DB_URL (handler_wiring.py:668-669,939-949; api_server.py:84). There, savings_estimates already holds 31 positive-savings rows, total $1.2209. The empty table recon queried is a divergent, vestigial copy in omnidash_analytics that no writer targets.

Proof

Reprocessed three genuine recorded delegate-skill-completed events (real Qwen3.6-35B-A3B runs, measured tokens, savings>0) through the running runtime consumer at 2026-05-30T16:07. Each emitted onex.evt.omnimarket.projection-savings-applied.v1 {"projected":true} and upserted a row with correlation binding to delegation_events:

correlation_id savings_usd pricing_manifest_version
92a20588… 0.1023 1
a4fddc4e… 0.09126 1
66d33e65… 0.02406 1

All 31 rows distinct on the identity key; no duplicates.

Fix

  • No application code changed. No runtime rebuild/restart.
  • Defensively reconciled the vestigial omnidash_analytics.savings_estimates schema to canonical (idempotent DDL) so it cannot silently mis-route future writers.

Inference backend

Live bifrost overlay already routes code_generation to local-coder (.201:8000 Qwen3.6-35B-A3B, reachable) with cloud-sonnet fallback; .200:8101 DeepSeek present. No overlay change required.

Separate finding (out of scope)

Projection API cost.summary endpoint is degraded: syntax error at or near "window" (reserved-word SQL bug in the cost summary aggregation). Distinct from savings_estimates; should be filed separately.

Evidence: evidence/OMN-12491/ + contracts/OMN-12491.yaml + drift/dod_receipts/OMN-12491/.

…lity-test

Diagnosis: recon mis-targeted the DB. savings_estimates already materializes in
omnibase_infra (the DB the runtime savings projection and projection API use per
contract db_io.database=omnibase_infra / OMNIBASE_INFRA_DB_URL) -- 31 positive-savings
rows, total $1.2209. The empty table in recon is a vestigial omnidash_analytics copy
no writer targets. Reprocessed three genuine recorded delegate-skill-completed events
through the running runtime consumer; each emitted projection-savings-applied
{projected:true} with correlation binding to delegation_events. No code change, no
runtime restart. Defensively reconciled the vestigial omnidash_analytics schema.
@coderabbitai

coderabbitai Bot commented May 30, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@jonahgabriel, we couldn't start this review because you've reached your PR review rate limit.

More reviews will be available in 38 minutes and 40 seconds. Learn how PR review limits work.

Your organization has run out of usage credits. Purchase more in the billing tab.

⌛ How to resolve this issue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available.

Please see our Fair Usage Limits Policy for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 53775cfc-768e-4d32-ae40-09a382a430f6

📥 Commits

Reviewing files that changed from the base of the PR and between fd30815 and fad024e.

📒 Files selected for processing (5)
  • contracts/OMN-12491.yaml
  • drift/dod_receipts/OMN-12491/dod-savings-materialization-proof/command.yaml
  • evidence/OMN-12491/dod_report.json
  • evidence/OMN-12491/reconcile_omnidash_analytics_savings_estimates.sql
  • evidence/OMN-12491/savings_materialization_proof.md
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch jonahgabriel/omn-12491-savings-evidence-dev

Comment @coderabbitai help to get the list of available commands and usage tips.

@jonahgabriel
jonahgabriel added this pull request to the merge queue May 30, 2026
Merged via the queue into dev with commit 3bf0e85 May 30, 2026
28 of 30 checks passed
@jonahgabriel
jonahgabriel deleted the jonahgabriel/omn-12491-savings-evidence-dev branch May 30, 2026 16:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant