Class: Google::Apis::AiplatformV1::GoogleCloudAiplatformV1EvaluationPrompt

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/aiplatform_v1/classes.rb,
lib/google/apis/aiplatform_v1/representations.rb,
lib/google/apis/aiplatform_v1/representations.rb

Overview

Prompt to be evaluated. This can represent a single-turn prompt or a multi- turn conversation for agent evaluations.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudAiplatformV1EvaluationPrompt

Returns a new instance of GoogleCloudAiplatformV1EvaluationPrompt.



9465
9466
9467
# File 'lib/google/apis/aiplatform_v1/classes.rb', line 9465

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#prompt_template_dataGoogle::Apis::AiplatformV1::GoogleCloudAiplatformV1EvaluationPromptPromptTemplateData

Message to hold a prompt template and the values to populate the template. Corresponds to the JSON property promptTemplateData



9453
9454
9455
# File 'lib/google/apis/aiplatform_v1/classes.rb', line 9453

def prompt_template_data
  @prompt_template_data
end

#textString

Text prompt. Corresponds to the JSON property text

Returns:

  • (String)


9458
9459
9460
# File 'lib/google/apis/aiplatform_v1/classes.rb', line 9458

def text
  @text
end

#valueObject

Fields and values that can be used to populate the prompt template. Corresponds to the JSON property value

Returns:

  • (Object)


9463
9464
9465
# File 'lib/google/apis/aiplatform_v1/classes.rb', line 9463

def value
  @value
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



9470
9471
9472
9473
9474
# File 'lib/google/apis/aiplatform_v1/classes.rb', line 9470

def update!(**args)
  @prompt_template_data = args[:prompt_template_data] if args.key?(:prompt_template_data)
  @text = args[:text] if args.key?(:text)
  @value = args[:value] if args.key?(:value)
end