ModelDecision class
One decision returned by ModelProvider.decide.
Constructors
Properties
-
action
→ ({Map<
String, dynamic> args, String tool}) -
The action chosen this turn —
toolis a tool name,argsis the validated argument map for that tool.final - hashCode → int
-
The hash code for this object.
no setterinherited
-
modelMetadata
→ Map<
String, dynamic> -
Provider response metadata persisted with the trajectory turn.
Dartantic-backed providers include
served_model_idand an explicitprovider_request_identry; custom providers may leave this empty.final - providerRequestId → String?
-
Provider-side request id (e.g. Anthropic/swift-infer
message.idfrom the SSEmessage_startevent). Null when the provider did not emit one, or when the decision was synthesized in tests. Surfaced into the dogfood trace asdecision.provider_request_idso an operator can cross-reference swift-infer's/v1/trace/:idendpoint without manual time-correlation.final - rationale → String?
-
Optional rationale string (free-form; not used for control flow).
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- thinking → String?
-
Captured thinking/reasoning text for carry-forward to the next
turn's AssistantTurn. Providers populate this from native
thinking blocks (Anthropic),
<think>tags (SwiftInfer), or leave it null (OpenAI).final - waitStrategy → String?
-
Optional wait strategy hint (e.g.
'frame','idle').final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited