SyniChatResponse class

A completed Syni response.

Parses the runtime's tagged EngineResponse envelope — {"type":"coach","data":{...}} — into a clean typed surface. Callers use message / suggestions / displayText and never touch raw JSON.

Constructors

SyniChatResponse.fromCloudReply(String reply, {required String personaId, required String runtimeVersion})
Build a response from a cloud reply string.
factory
SyniChatResponse.fromRuntimeJson(String rawJson, {required String personaId, required String runtimeVersion})
Parse the runtime's final EngineResponse JSON string. Tolerant of unexpected shapes — falls back to SyniResponseKind.unknown.
factory

Properties

displayText String
Best-effort display string — message if present, else the first suggestion, else a neutral placeholder. UI can render this directly.
no setter
hashCode int
The hash code for this object.
no setterinherited
kind SyniResponseKind
Which EngineResponse variant this is.
final
message String?
Primary reply text. Present for coach and chat; null for a pure suggestions response.
final
personaId String
The persona that produced this response.
final
rawJson String
The runtime's raw final JSON — kept for debugging / telemetry. UI code should use message / suggestions / displayText, not this.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
runtimeVersion String
Runtime semver reported by libsyni_ffi.
final
suggestions List<String>
Suggestion texts. Populated for coach and suggestions.
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