Pinky EEE: dual-window real-source quota + self-throttle (v1.66.0) #96

Closed
ClaudiuSchuster wants to merge 2 commits from oss-oo/pinky-eee-quota into main
Owner

Steer #65 — luck retires, math takes the wheel.

D1/D2 — real dual windows: the z.ai monitor API (the cinnamon-z-usage applet's own endpoint and key chain — ZDO_QUOTA_API_KEY > ZAI_API_KEY > applet key file > ZCode provider cache) feeds a 5 h + 7 d gauge; background slow refresh (default 300 s, ≥ the applet's cadence band), the poll path serves the cache only; per-window states on the existing time-to-empty ladder with the covered-hours floor and the refill-wins cap; key hygiene (only the chain step name crosses the API surface — rig-proven by grep over every surface + logs); honest unarmed fallback, manual ZDO_QUOTA_* model intact.

D3 — self-throttle (advisory): one steer per session per level-escalation per window-episode to ACTIVE brain-class sessions; owner-model wording (5 h auto-resets / 7 d stop consciously before 0 %); durable episodes; hard refusals remain the only enforcement.

D4 (S-42): compact ⏉ ideal-window snap in the collapsed slim header reusing snapIdealWindow — idempotent, one-row geometry unregressed (S-41).

D5 (S-43): the owner-conversation lane gates the ONE unread computation everywhere — obs- steer evidence (guardian/throttle machine notices durably excluded) or owner-TYPED words (never the dispatched task prompt, never steer-window deliveries).

D6 (HHH-V3): the suite never writes the checkout root.

Suite 955 green (38 new round legs + 6 harness legs); Super-Linter station recipe green; rig 1 (server: mapping/cadence/hygiene/throttle episodes/unarmed/manual) and rig 2 (Xvfb CDP: chip/panel/slim dual rendering, S-42 exact-1177 snap + idempotence, the mixed-fleet lane gate incl. launcher rows + transcript halos, unarmed rendering) all green.

Steer #65 — luck retires, math takes the wheel. **D1/D2 — real dual windows**: the z.ai monitor API (the cinnamon-z-usage applet's own endpoint and key chain — ZDO_QUOTA_API_KEY > ZAI_API_KEY > applet key file > ZCode provider cache) feeds a 5 h + 7 d gauge; background slow refresh (default 300 s, ≥ the applet's cadence band), the poll path serves the cache only; per-window states on the existing time-to-empty ladder with the covered-hours floor and the refill-wins cap; key hygiene (only the chain step name crosses the API surface — rig-proven by grep over every surface + logs); honest unarmed fallback, manual ZDO_QUOTA_* model intact. **D3 — self-throttle (advisory)**: one steer per session per level-escalation per window-episode to ACTIVE brain-class sessions; owner-model wording (5 h auto-resets / 7 d stop consciously before 0 %); durable episodes; hard refusals remain the only enforcement. **D4 (S-42)**: compact ⏉ ideal-window snap in the collapsed slim header reusing snapIdealWindow — idempotent, one-row geometry unregressed (S-41). **D5 (S-43)**: the owner-conversation lane gates the ONE unread computation everywhere — obs- steer evidence (guardian/throttle machine notices durably excluded) or owner-TYPED words (never the dispatched task prompt, never steer-window deliveries). **D6 (HHH-V3)**: the suite never writes the checkout root. Suite 955 green (38 new round legs + 6 harness legs); Super-Linter station recipe green; rig 1 (server: mapping/cadence/hygiene/throttle episodes/unarmed/manual) and rig 2 (Xvfb CDP: chip/panel/slim dual rendering, S-42 exact-1177 snap + idempotence, the mixed-fleet lane gate incl. launcher rows + transcript halos, unarmed rendering) all green.
D1/D2 — the z.ai monitor API behind a 5h+7d dual-window model, resolved
through the cinnamon-z-usage applet's own key chain (ZDO_QUOTA_API_KEY >
ZAI_API_KEY > applet key file > ZCode provider cache); background slow
refresh (300 s default, >= the applet's cadence band), the poll path
serves the cache only (quotaApi source-key identity flips it); per-window
states on the existing time-to-empty ladder with the covered-hours floor
and the refill-wins cap; key hygiene (only the chain step name crosses
the API surface); honest unarmed fallback to the manual ZDO_QUOTA_* model.

D3 — the self-throttle: one advisory steer per session per
level-escalation per window-episode to ACTIVE brain-class sessions
(owner-model wording: 5h auto-resets / 7d stop before 0%), state
durable in quota-throttle.json, ZDO_THROTTLE=0 disables; hard refusals
remain the only enforcement.

D4 (S-42) — compact ideal-window snap in the collapsed slim header
reusing snapIdealWindow; idempotent at ideal; folds on phone widths.

D5 (S-43) — the owner-conversation lane gates the ONE unread
computation everywhere: obs- steer evidence (guardian/throttle machine
notices durably excluded) or owner-TYPED words (real-owner-class message
outside every delivered-steer window, never the dispatched task prompt).

D6 (HHH-V3) — suite env-redirect for the expectation store; the booted-
server test env pins it too; regression test added.

Suite: 955 green (38 new round legs + 6 harness/audit legs).
EEE follow-up: persist throttle episode CLOSES (rig-proven) + version markers
All checks were successful
Checks / Functional checks (pull_request) Successful in 35s
7009569b56
Rig1 caught it live: a recovery phase closed the episode in memory only
(throttle_tick's save condition missed pure-close transitions), so every
tick reloaded the stale open episode from disk and swallowed the next
episode's notices. throttle_pass now flags 'changed' on open/close/
notify and the tick saves on it; regression pinned in the suite.

Version markers bumped to v1.66.0.
ClaudiuSchuster closed this pull request 2026-10-12 20:29:12 +00:00
All checks were successful
Checks / Functional checks (pull_request) Successful in 35s

Pull request closed

Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
OSS-Singularity/zcode-dispatch-observatory!96
No description provided.