struct

Smith::Context::Result

Inherits Struct < Value < Object

Constructors

new(messages : Array(Smith::LLM::Message), strategy : Smith::Context::Strategy, before_tokens : Int32, after_tokens : Int32, budget : Smith::Context::Budget, stages : Array(String) = [] of String)
Source

Instance methods

after_tokens
Source
before_tokens

Both are the cost of the request, not of the history alone.

Source
budget
Source
compacted?
Source
exhausted?

Over the ceiling with nothing left to reclaim. The caller stops the run rather than letting the provider reject the request.

Source
messages
Source
reached_target?
Source
stages

Which stages actually changed something. Reported so a compaction line reads as an intention rather than an accident.

Source
strategy
Source