small gleam coding and persistent agent daemon with a detachable cli and a canvas ui forked from okami.mom/albedo

fix(context): size the last call's rebuild by the input its provider reported

The context inspector rebuilds the last turn's request between turns through loop.rebuild_observed, which projected it with no provider numbers, so the observation showed an estimate of a request whose size the provider had reported. session_last_call now passes the turn row's reported input, and the rebuild projects once to learn what that call sent, then again with the reported size for exactly that projection; anything else the strategy sizes (the prompt alone, a candidate fold), and the rows, stay estimated. Other rebuilds (the start-of-turn usage check, cache warming) pass none, as before. Reported by gentle.


Author bunny.fae.mom
Committer Tangled Date Commit Parent 5e2ae9eb
+48 -14
3 changed files
+48 -14
3 changed files