LLMGenerateRequest constructor

LLMGenerateRequest({
  1. String? prompt,
  2. bool? emitThoughts,
  3. String? requestId,
  4. String? modelId,
  5. String? conversationId,
  6. Iterable<MapEntry<String, String>>? metadata,
  7. LLMGenerationOptions? options,
  8. Iterable<ChatMessage>? history,
})

Implementation

factory LLMGenerateRequest({
  $core.String? prompt,
  $core.bool? emitThoughts,
  $core.String? requestId,
  $core.String? modelId,
  $core.String? conversationId,
  $core.Iterable<$core.MapEntry<$core.String, $core.String>>? metadata,
  $0.LLMGenerationOptions? options,
  $core.Iterable<$1.ChatMessage>? history,
}) {
  final result = create();
  if (prompt != null) result.prompt = prompt;
  if (emitThoughts != null) result.emitThoughts = emitThoughts;
  if (requestId != null) result.requestId = requestId;
  if (modelId != null) result.modelId = modelId;
  if (conversationId != null) result.conversationId = conversationId;
  if (metadata != null) result.metadata.addEntries(metadata);
  if (options != null) result.options = options;
  if (history != null) result.history.addAll(history);
  return result;
}