class LittleGhost::ModelRequest
Carries everything a provider needs for one model stream. Messages are normalized to Message objects, and required capabilities become unique symbols. The main request containers are frozen, but nested values are not defensively copied.
Treat settings, output schemas, and tool-choice values as immutable after construction. Create a separate copy before using mutable control data in another request or thread.
Attributes
The cooperative cancellation token shared with the provider.
The absolute request deadline, or nil when none was configured.
The normalized conversation in a frozen Array.
The requested structured-output schema, or nil for ordinary text. The caller-owned value is retained and must not be mutated afterward.
The normalized capabilities the selected model must support.
Trusted provider settings in the caller’s now-frozen Hash. Nested values remain mutable and must not change after construction.
The requested tool-selection policy, when one applies. The caller-owned value is retained and must not be mutated afterward.
The model-visible tool specifications in a frozen Array.
Public Class Methods
Source
# File lib/little_ghost/model_request.rb, line 61
Creates one normalized provider request with cooperative cancellation and deadline controls. Freezing is shallow; retained nested control values must not be mutated afterward.