GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — doc(#9572): C4 quota forecasting design — prediction record, scoring, methodology log by dezren39 · Pull Request #13268 · developing-today/code

Conversation

@dezren39

@dezren39 dezren39 commented Nov 23, 2026 •
edited by blacksmith-sh Bot
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

Refs #9572 (acceptance item 1 of 3; the issue stays open for items 2–3, filed as C4.1–C4.6 below).

What this is

The C4 component design, landed in the #9568 program folder beside the C7 design (c7-rollups-design.md): c4-forecasting-design.md.

Done check behind it (verified against origin/main 1edebd5)

The Stage-3 line already covers ONE C4 kind — per-pool exhaustion as a point projection, published per tick (S1 #12695 / PR #12724) and scored (S2 #12696: accuracy ledger + backtest, 5,028 forecasts). The design grounds itself in that product instead of restating it, and specifies what it does not cover:

  • a prediction record of record — mandatory singular basis (S2.14), range as a first-class value calibrated by the S2 error ledger, stored rendered string (S2.13 formats), methodology version, honesty states;
  • scoring rules per kind, incl. range coverage/width on top of S2's wall-error/precision/recall;
  • the methodology-change log format (S2.5) with an operational definition of "relatively accurate";
  • downtime windows (S2.4), reset durations (S2.13), day-type + spike-day adjustments (S2.6/S2.7 — models defined, admitted per-cell by the Stage-3 sufficiency gate, not waived), model/plan arrivals (S2.3, honesty-first), forecast push alerts (S2.12 C4 half, via the S5 alerts-ledger precedent).

Gate check: #9572 is NOT gated on the C3 chain (#9571 / PR #12226) — its substrate (gatherer, snapshot store, Stage-3 forecast product, alerts ledger) is live; the design records this explicitly.

Remainder, filed under #9572

  • C4.1 — Complete-downtime window prediction (all pools walled at once) #13257 C4.1 downtime-window prediction
  • C4.6 — Downtime-window demonstration against a known wall (Sunday-evening reopening set) #13262 C4.6 demonstration against a known wall (acceptance item 3; depends on C4.1)
  • C4.2 — Reset-duration predictions as ranges in Drew's formats #13258 C4.2 reset-duration ranges
  • C4.5 — Forecast push alerts (downtime + wall predictions to push notifications) #13261 C4.5 forecast push alerts
  • C4.3 — Day-type and spike-day adjustments for quota forecasts (data-gated) #13259 C4.3 day-type/spike adjustments (data-gated)
  • C4.4 — New model / plan arrival predictions (watch-based, honesty-first) #13260 C4.4 model/plan arrivals

Docs only; no code, no new dependencies, no schedule created or changed.


Prove it works
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
felix
doc(#9572): C4 quota forecasting design — prediction record schema, s…
a5785f3
…coring rules, methodology-change log

Acceptance item 1 of #9572. Grounds the design in the landed Stage-3
forecast product (S1 #12695, S2 #12696) and specifies what it does not
cover: downtime windows, reset-duration ranges, day-type/spike
adjustments (data-gated), model/plan arrivals, forecast push alerts.
Live-loop remainder filed as #13257, #13258, #13259, #13260, #13261,
#13262.
@coderabbitai

coderabbitai Bot commented Nov 23, 2026

Copy link
Copy Markdown

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 59 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 1fb2edd9-d9be-4ad0-b523-4ef05a6c8725
Commits

Reviewing files that changed from the base of the PR and between 795b240 and a5785f3.

Files selected for processing: 1

  • doc/2026-11-13T15-12-00Z_design_reporting-architecture-event-driven/c4-forecasting-design.md
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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.

Share

  • X
  • Mastodon
  • Reddit
  • LinkedIn
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 23, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-23T12:44:13.107016Z a5785f3 PR opened
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@dezren39 dezren39 mentioned this pull request Nov 23, 2026
C4 — Quota forecasting: exhaustion, downtime, and reset-duration predictions, tracked until accurate #9572
Open
3 tasks
@dezren39
dezren39 merged commit c1700bc into main Nov 23, 2026
2 checks passed

Uh oh!

There was an error while loading. Please reload this page.

@dezren39
dezren39 deleted the felix/9572-c4-design branch November 23, 2026 12:43
chatgpt-codex-connector[bot]
chatgpt-codex-connector Bot reviewed Nov 23, 2026
View reviewed changes

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: a5785f3bbf

ℹ️ 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".

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread doc/2026-11-13T15-12-00Z_design_reporting-architecture-event-driven/c4-forecasting-design.md
```jsonc
{
"record_version": 1,
"id": "c4:<kind>:<subject-key>:<issued-at-epoch-ms>",

@chatgpt-codex-connector chatgpt-codex-connector Bot Nov 23, 2026

Copy link
Copy Markdown

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Include the basis in prediction record IDs

When §2 publishes parallel since_last_reset and trailing_30d forecasts for the same pool/window on one gatherer tick, both records receive the same ID under this format. That makes ID-based supersession and attribution of scores to individual predictions ambiguous, undermining the stated head-to-head comparison of bases. Include the basis and any concurrently published model variant in the record identity, or use a unique ID independent of the subject and issuance timestamp.

Useful? React with 👍 / 👎.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread doc/2026-11-13T15-12-00Z_design_reporting-architecture-event-driven/c4-forecasting-design.md
Comment on lines +289 to +290
`postIncident` precedent, source `quota-prediction`, deduped on
the prediction record id, thresholded per S3.15's selectivity

@chatgpt-codex-connector chatgpt-codex-connector Bot Nov 23, 2026

Copy link
Copy Markdown

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Deduplicate forecast alerts by the predicted event

For a downtime or workhorse-wall forecast that persists across gatherer ticks, deduplicating on the prediction record ID creates a fresh alert each tick: §1 makes that ID issuance-time-specific, while AlertsStore.postIncident in pm-stack/aggregator/src/alerts.ts suppresses duplicates only for matching (source, incident_key). The selectivity threshold limits which forecast kinds alert, but does not suppress repeated alerts for the same impending outage. Use a stable event/episode key for alert deduplication and retain the prediction ID as supporting detail.

Useful? React with 👍 / 👎.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
This was referenced Nov 23, 2026
feat(quota): forecast-alert evaluation for C4 prediction records (#13261) #13276
Merged
C4.5 — Forecast push alerts (downtime + wall predictions to push notifications) #13261
Open
dezren39 added a commit that referenced this pull request Nov 23, 2026
@dezren39
feat(pm-stack): C4.1 complete-downtime window prediction records (#13257
6569d04
)

Publish downtime_window prediction records on gatherer ticks, in
the C4 design's record format (doc/2026-11-13T15-12-00Z_design_
reporting-architecture-event-driven/c4-forecasting-design.md §1/§7,
landed by PR #13268): appended to quota-predictions.jsonl beside
the forecast product and mirrored into the Turso ledger under the
C4 source "quota-prediction".

src/quota-downtime.ts derives each record from the tick's Stage-3
forecast product (#12695): per-pool wall intervals [wall, reset)
intersected across every routing pool (canonical provider id);
earliest = the last member wall, latest = the earliest member
reset; basis since_last_reset, named with its detail; the §4
range rendering stored at issuance; supersedes linked from the
log's tail. Honesty per §1 and #13257 criterion 3: providers the
forecast cannot project publish insufficient_history with a named
reason (and veto a no-window verdict); an overlap no member reset
bounds is an honesty state, not an unbounded prediction; a
defensible no-window tick publishes no record — absence is the
scored no-prediction signal. First methodology entry c4-meth:1
recorded in c4-methodology-log.jsonl (§6).

Acceptance: criteria 1 (records published on gatherer ticks) and
3 (honesty state) of #13257. Criterion 2 (scoring per §3 in the
accuracy ledger) is the next slice; the mirrored records are its
input.

Tests: src/quota-downtime.test.ts (15 tests: record shape,
intersection range, in-progress windows, union within a provider,
disjoint overlaps, honesty states, supersedes, §4 rendering,
ledger mirror), mutation-checked; the gather-quota integration
test now also asserts the tick appends the downtime record.
Oracle: the C4 design §1/§7 over the #12695 forecast product.
This was referenced Nov 23, 2026
feat(pm-stack): C4.1 complete-downtime window records on gatherer ticks (#13257) #13295
Merged
C4.1 — Complete-downtime window prediction (all pools walled at once) #13257
Closed
feat(pm-aggregator): C4.2 reset-duration prediction records (#13258 builder slice) #13352
Merged
dezren39 added a commit that referenced this pull request Nov 23, 2026
@dezren39
feat(pm-aggregator): C4.2 reset-duration prediction records
a0953e6
New pure module pm-stack/aggregator/src/quota-reset-duration.ts
implementing the builder slice of the C4.2 reset-duration kind,
per the C4 design (PR #13268, sections 1/4/7) and the prepared
scope recorded on the issue by Lane WC.

- ResetDurationRecord in the design's section-1 shape: kind
  reset_duration, subject pool+window, singular basis
  reset_cadence, methodology c4-meth:1, supersedes link.
- Reopening range: anchored on the published resetsAt when one
  exists, ranged by the reset jitter observed over completed
  reset periods (realized resets estimated at the midpoint of
  the bracketing readings); with no published reset, projected
  one observed cadence interval past the last published reset.
- earliest == latest refused: a degenerate spread widens to
  the observation resolution (half the median reading gap).
- Honesty states with named reasons: no_basis (no snapshot
  history) and insufficient_history (no completed period, or
  the ranged reopening already in the past — stale inputs).
- Rendered strings from the one shared section-4 formatter
  (renderPredictionRange in quota-downtime.ts), stored at
  issuance; ledger mirror rows under source quota-prediction.

Tests: quota-reset-duration.test.ts, 13 tests — jitter-spread
range construction from synthetic snapshot history, degenerate
spread widening, subject selection (walled + near-wall only),
both honesty states, stale-input guards, cadence projection,
the section-4 duration and calendar rendering forms, and the
ledger mirror.
@dezren39 dezren39 added the audit:partial PR partially implemented; gap filed label Nov 24, 2026
This was referenced Nov 24, 2026
AUDIT-7 Lane 4 — MERGED-PR-AUDIT: merged PRs since 2026-10-23 vs their spawning issues #13879
Open
C4.2 — Reset-duration predictions as ranges in Drew's formats #13258
Open
C4.4 — New model / plan arrival predictions (watch-based, honesty-first) #13260
Open
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@chatgpt-codex-connector chatgpt-codex-connector[bot] chatgpt-codex-connector[bot] left review comments

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

audit:partial PR partially implemented; gap filed

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

1 participant

@dezren39
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.