StructuredResult class

Parsed value plus the raw text and metrics of a structured generation.

Constructors

StructuredResult({required Uint8List value, required String raw, required bool valid, required GenerationResult metrics})
Build a structured result.
const
StructuredResult.fromProto(StructuredOutputResult proto, GenerationResult metrics)
Build from the generated structured-output result.
factory

Properties

hashCode int
The hash code for this object.
no setterinherited
metrics GenerationResult
Metrics for the generation that produced this value.
final
raw String
Raw model output before parsing.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
valid bool
True when the output satisfied the schema.
final
value Uint8List
Canonical JSON bytes of the parsed value.
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