Repository navigation
A cut answer is censored evidence: one cut raises her next room - #5812
Merged
Merged
Conversation
A turn cut at max_tokens mid-answer pushed its answer DOUBLED into the p90 ring of 16, where one sample (the largest) is never read: one cut left the room unchanged and only a second wasted act grew it (the M5, fe91c2b, rooms of 853, 288 and 435). - The answer ring holds ChannelSample (Observed<u32>): Exact when she ended it, AtLeast when the cap cut it. The record writes no factor; the peak is what was written. - need::answer_need reads the answer p90 by the one censored estimator (product_limit) and keeps the largest live cut bound beside it; OutputNeed::answer_room is the larger of the p90 and the median past the bound (cut_answer_median: twice what was written, derived from a scale-free cut position; a bound alone grants the cap that cut her, the replay shows Aris cut six times at 241). It ages out with the ring. - act_room, ActRoom's answer share (so the think budget leaves it) and total() read answer_room. - The emission read moves to one owner (working_set/emission.rs, ResponseEmission::of): EmissionStop, the channel split and answer bytes, shared by the faculty and the replay. A cut with an open tool call is CutMidAnswer, and call bytes count as answer even without mirrored parts. - examples/act_room_replay.rs: the validator, replaying real captures through the registry. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…the censored p90 Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
What this does for the residents: when a resident's answer is cut at
max_tokenspartway through, her very next turn now gets more room. Today it takes a second wasted turn before the room grows. This serves the path's Fast step (wasted acts) and goal 7 (one budget).The defect
On the live M5 (fe91c2b), turns were cut at
max_tokensmid-answer at rooms of 853, 288 and 435 tokens. The cause was inworking_set.rsrecord_emission_in_memory.CutMidAnswerpushedanswer.saturating_mul(2)into the answer ring as if it were an exact sample.need_ofreads the p90 of 16 samples, which is the second-largest. So one doubled cut, being the largest sample, was never read.The change
ChannelSample(Observed<u32>, the one censoring type already used by held need). A landed answer is stored asExact, a cut answer asAtLeast. The record no longer applies any factor. The peak is what was actually written.need::answer_needcomputes the answer p90 withproduct_limit, the same Kaplan–Meier estimator the reasoning and held window already use. It also keeps the largest cut bound still in the ring asOutputNeed::answer_at_least.OutputNeed::answer_roomis the larger of two values:cut_answer_median).answer_roomis read:act_room;ActRoom's answer share, sothink_withinleaves room for the answer;total(), the want of a pass.answer_room(), so the cut answer gets no second factor.working_set/emission.rs(ResponseEmission::of). It holdsEmissionStop, the channel split and the answer bytes, moved out ofworking_set.rsandverdict/mod.rs. The faculty and the replay both call it.CutMidAnswer. The call's bytes count as answer even when the response carries no mirroredToolUsepart.ActRoom::think_withinis shared byact_reasoning_budgetand the replay.reached_p90is named once.NEED_SAMPLESis now pub.Measured
Validator:
core/continuum-cognition/examples/act_room_replay.rs.~/.continuum/fixtures/prompt-captures/<id>.pidx+.prev), copied read-only at 2026-11-07 01:26 CST from the live M5, read through the capture store's own playback reader (continuum_capture::prompt_capture::{page, detail}, newest header per request).ResponseEmission::ofandrecord_emission_in_memory.act_room(), the reply claim's floor. Passes (cognition/deliberation, where the live cuts were) are replayed attotal().think_within(room). A turn whose demand reaches the room is a would-be cut and is recorded as that cut. A turn cut live whose room is now above its cap is counted as unknown.Exactsample, which is what canary does).Run:
cargo run -p continuum-cognition --features metal --example act_room_replay -- <dir> 200(about 4 s).The opposite failure, a room that grows too much, also shows in this table:
Each bound leaves the ring after 16 turns. The test
uncut_acts_bring_the_room_back_down_after_a_cutcovers this.What the replay does not model:
Live acts were sent with a median
maxTokensof 17–28k, which is the window room. So on live acts the floor binds only when the window is full. The live cuts in these captures are passes (purposecognition/deliberation, carrying tools; for example Aiko'smaxTokens853 cut).A bound-only variant (no median past the bound) was measured first, on the act-only replay: 31 act cuts, against 28 for the old rule. That result is why
cut_answer_medianexists.Live receipt: not taken. No deploy or live read was done; this needs the 15-minute live read after merge. The check is the cut rate (
delib.emission.cut_mid_answer) and finished work per hour on the M5. Owner: whoever deploys.Tests
Each test has a
// what this catches:note. All are in the existing test mods.one_cut_answer_raises_the_next_room_above_the_cuts_demanduncut_acts_bring_the_room_back_down_after_a_cuta_cut_inside_an_open_tool_call_is_a_cut_answera_cut_answer_floor_holds_its_median_past_the_bound(reply claim)a_capped_emission_records_its_bound_and_an_uncapped_one_verbatimreply_reserve(d)/(e)capacity_and_wirea_writing_turn_after_a_cut_gets_its_reply_on_a_46848_window(that test now also assertsanswer_room= 10,808)Results:
cargo test -p continuum-cognition --features metal,test-fixtures --lib --examples: 957 passed, 0 failed.cargo test -p continuum-core --features metal --lib -- test_env::mind_integration::registry::deliberation: 17 passed, 1 failed. The failure ispinned_act_result_reaches_the_prompt_even_with_an_empty_broadcast, which panics atLivePin::retain(..).handle().expect("saved inventory"). That is the spill store's disk write, not this change. I did not rerun it on canary to confirm it fails there too.cargo run -p source-hygiene --bin ratchets -- fe91c2b55: passed.tools/scripts/oversized-edits.sh origin/canary: passed. The largest touched file isverdict/contribute.rsat 974 lines; it was 999 before.17 files, +650/−273 (the replay example accounts for 197 of the added lines).
🤖 Generated with Claude Code
https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo