AgentStreamChunk constructor

AgentStreamChunk({
  1. ModelResponseChunk? modelChunk,
  2. List<JsonPatchOperation>? customPatch,
  3. Artifact? artifact,
  4. TurnEnd? turnEnd,
})

Implementation

AgentStreamChunk({
  ModelResponseChunk? modelChunk,
  List<JsonPatchOperation>? customPatch,
  Artifact? artifact,
  TurnEnd? turnEnd,
}) {
  _json = {
    'modelChunk': ?modelChunk?.toJson(),
    'customPatch': ?customPatch?.map((e) => e.toJson()).toList(),
    'artifact': ?artifact?.toJson(),
    'turnEnd': ?turnEnd?.toJson(),
  };
}