1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
//! **The last reading of a step, not its fold** (DESIGN §5.1 #35): the two
//! facts the context-fullness figure takes off a `response.json`, split off
//! [`super`] on the seam its header names — the fold of every attempt segment
//! is *spend*, the final reading is *fullness*, and only the second describes
//! the context as it now stands. Same bytes, same event vocabulary
//! ([`super::usage_events`]), two questions.
//!
//! **Numerator and denominator ride one line.** brazen states the resolved
//! model row's context window on every `Usage` event it emits (its
//! model-discovery §5.5), which is the number litany's own `window_percent`
//! compaction trigger divides by; yog reads the same one off the same record
//! and keeps no table of windows (bl-9c8a — the declaration it once kept was a
//! second representation of this fact, one the engine could not see).
use ;
/// The counters that describe the context as it now stands (§5.1 #35): the
/// **last** attempt segment's, merged **per field, last wins** — brazen's own
/// consumer rule, because a stream's usage events are partial (Anthropic's
/// `message_start` carries the prompt and its `message_delta` only the
/// output; taking the final line alone read that shape as a prompt of zero).
/// Summing segments answers *spend*; the last reading answers *fullness*,
/// and a step retried three times must not read as a context three times its
/// size. Zero when the payload carries no `Usage` line at all — the general
/// path with no inputs.
/// The context window the step's own usage lines carry — brazen stamps the
/// resolved model row's window on every `Usage` event it emits (its
/// model-discovery §5.5, 0.0.9), so the denominator of the §5.1 #35 figure is
/// read off the same line as its numerator, recorded per step, and yog keeps
/// no table of windows. The last one stated, by the rule above; `None` when
/// no line states one — the row served no window — or it is zero. Never a
/// default: a percentage against a number nobody published is capability
/// theater.