0.3.1 (latest) 0.3.0 0.2.0 0.1.0 Reference documentation and code samples for the Gemini Enterprise for Customer Experience V1BETA API class Google::Cloud::Ces::V1beta::Evaluation::GoldenExpectation.

Represents a single, checkable requirement.

## Inherits

- Object

## Extended By

- Google::Protobuf::MessageExts::ClassMethods

## Includes

- Google::Protobuf::MessageExts

## Methods

### #agent_response

    def agent_response() -> ::Google::Cloud::Ces::V1beta::Message

**Returns**

- ([::Google::Cloud::Ces::V1beta::Message](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-Message)) --- Optional. Check that the agent responded with the correct response. The role "agent" is implied.


  Note: The following fields are mutually exclusive: `agent_response`, `tool_call`, `tool_response`, `agent_transfer`, `updated_variables`, `mock_tool_response`, `no_tool_calls`. If a field in that set is populated, all other fields in the set will automatically be cleared.

### #agent_response=

    def agent_response=(value) -> ::Google::Cloud::Ces::V1beta::Message

**Parameter**

- **value** ([::Google::Cloud::Ces::V1beta::Message](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-Message)) --- Optional. Check that the agent responded with the correct response. The role "agent" is implied.


  Note: The following fields are mutually exclusive: `agent_response`, `tool_call`, `tool_response`, `agent_transfer`, `updated_variables`, `mock_tool_response`, `no_tool_calls`. If a field in that set is populated, all other fields in the set will automatically be cleared.
**Returns**

- ([::Google::Cloud::Ces::V1beta::Message](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-Message)) --- Optional. Check that the agent responded with the correct response. The role "agent" is implied.


  Note: The following fields are mutually exclusive: `agent_response`, `tool_call`, `tool_response`, `agent_transfer`, `updated_variables`, `mock_tool_response`, `no_tool_calls`. If a field in that set is populated, all other fields in the set will automatically be cleared.

### #agent_response_hallucination_metrics_config_override

    def agent_response_hallucination_metrics_config_override() -> ::Google::Cloud::Ces::V1beta::EvaluationMetricsConfig::HallucinationMetricsConfig

**Returns**

- ([::Google::Cloud::Ces::V1beta::EvaluationMetricsConfig::HallucinationMetricsConfig](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-EvaluationMetricsConfig-HallucinationMetricsConfig)) --- Optional. Overrides for agent_response hallucination metrics.

### #agent_response_hallucination_metrics_config_override=

    def agent_response_hallucination_metrics_config_override=(value) -> ::Google::Cloud::Ces::V1beta::EvaluationMetricsConfig::HallucinationMetricsConfig

**Parameter**

- **value** ([::Google::Cloud::Ces::V1beta::EvaluationMetricsConfig::HallucinationMetricsConfig](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-EvaluationMetricsConfig-HallucinationMetricsConfig)) --- Optional. Overrides for agent_response hallucination metrics.
**Returns**

- ([::Google::Cloud::Ces::V1beta::EvaluationMetricsConfig::HallucinationMetricsConfig](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-EvaluationMetricsConfig-HallucinationMetricsConfig)) --- Optional. Overrides for agent_response hallucination metrics.

### #agent_response_semantic_similarity_metrics_config_override

    def agent_response_semantic_similarity_metrics_config_override() -> ::Google::Cloud::Ces::V1beta::EvaluationMetricsConfig::SemanticSimilarityMetricsConfig

**Returns**

- ([::Google::Cloud::Ces::V1beta::EvaluationMetricsConfig::SemanticSimilarityMetricsConfig](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-EvaluationMetricsConfig-SemanticSimilarityMetricsConfig)) --- Optional. Overrides for agent_response semantic similarity metrics.

### #agent_response_semantic_similarity_metrics_config_override=

    def agent_response_semantic_similarity_metrics_config_override=(value) -> ::Google::Cloud::Ces::V1beta::EvaluationMetricsConfig::SemanticSimilarityMetricsConfig

**Parameter**

- **value** ([::Google::Cloud::Ces::V1beta::EvaluationMetricsConfig::SemanticSimilarityMetricsConfig](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-EvaluationMetricsConfig-SemanticSimilarityMetricsConfig)) --- Optional. Overrides for agent_response semantic similarity metrics.
**Returns**

- ([::Google::Cloud::Ces::V1beta::EvaluationMetricsConfig::SemanticSimilarityMetricsConfig](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-EvaluationMetricsConfig-SemanticSimilarityMetricsConfig)) --- Optional. Overrides for agent_response semantic similarity metrics.

### #agent_transfer

    def agent_transfer() -> ::Google::Cloud::Ces::V1beta::AgentTransfer

**Returns**

- ([::Google::Cloud::Ces::V1beta::AgentTransfer](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-AgentTransfer)) --- Optional. Check that the agent transferred the conversation to a different agent.


  Note: The following fields are mutually exclusive: `agent_transfer`, `tool_call`, `tool_response`, `agent_response`, `updated_variables`, `mock_tool_response`, `no_tool_calls`. If a field in that set is populated, all other fields in the set will automatically be cleared.

### #agent_transfer=

    def agent_transfer=(value) -> ::Google::Cloud::Ces::V1beta::AgentTransfer

**Parameter**

- **value** ([::Google::Cloud::Ces::V1beta::AgentTransfer](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-AgentTransfer)) --- Optional. Check that the agent transferred the conversation to a different agent.


  Note: The following fields are mutually exclusive: `agent_transfer`, `tool_call`, `tool_response`, `agent_response`, `updated_variables`, `mock_tool_response`, `no_tool_calls`. If a field in that set is populated, all other fields in the set will automatically be cleared.
**Returns**

- ([::Google::Cloud::Ces::V1beta::AgentTransfer](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-AgentTransfer)) --- Optional. Check that the agent transferred the conversation to a different agent.


  Note: The following fields are mutually exclusive: `agent_transfer`, `tool_call`, `tool_response`, `agent_response`, `updated_variables`, `mock_tool_response`, `no_tool_calls`. If a field in that set is populated, all other fields in the set will automatically be cleared.

### #comparison_type

    def comparison_type() -> ::Google::Cloud::Ces::V1beta::EvaluationMetricsConfig::ComparisonType

**Returns**

- ([::Google::Cloud::Ces::V1beta::EvaluationMetricsConfig::ComparisonType](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-EvaluationMetricsConfig-ComparisonType)) --- Optional. The comparison type to use for the expectation check.

### #comparison_type=

    def comparison_type=(value) -> ::Google::Cloud::Ces::V1beta::EvaluationMetricsConfig::ComparisonType

**Parameter**

- **value** ([::Google::Cloud::Ces::V1beta::EvaluationMetricsConfig::ComparisonType](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-EvaluationMetricsConfig-ComparisonType)) --- Optional. The comparison type to use for the expectation check.
**Returns**

- ([::Google::Cloud::Ces::V1beta::EvaluationMetricsConfig::ComparisonType](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-EvaluationMetricsConfig-ComparisonType)) --- Optional. The comparison type to use for the expectation check.

### #expectation_level_metrics_thresholds_override

    def expectation_level_metrics_thresholds_override() -> ::Google::Cloud::Ces::V1beta::EvaluationMetricsThresholds::GoldenEvaluationMetricsThresholds::ExpectationLevelMetricsThresholds

**Returns**

- ([::Google::Cloud::Ces::V1beta::EvaluationMetricsThresholds::GoldenEvaluationMetricsThresholds::ExpectationLevelMetricsThresholds](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-EvaluationMetricsThresholds-GoldenEvaluationMetricsThresholds-ExpectationLevelMetricsThresholds)) --- Optional. Overrides metrics at the step level.

### #expectation_level_metrics_thresholds_override=

    def expectation_level_metrics_thresholds_override=(value) -> ::Google::Cloud::Ces::V1beta::EvaluationMetricsThresholds::GoldenEvaluationMetricsThresholds::ExpectationLevelMetricsThresholds

**Parameter**

- **value** ([::Google::Cloud::Ces::V1beta::EvaluationMetricsThresholds::GoldenEvaluationMetricsThresholds::ExpectationLevelMetricsThresholds](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-EvaluationMetricsThresholds-GoldenEvaluationMetricsThresholds-ExpectationLevelMetricsThresholds)) --- Optional. Overrides metrics at the step level.
**Returns**

- ([::Google::Cloud::Ces::V1beta::EvaluationMetricsThresholds::GoldenEvaluationMetricsThresholds::ExpectationLevelMetricsThresholds](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-EvaluationMetricsThresholds-GoldenEvaluationMetricsThresholds-ExpectationLevelMetricsThresholds)) --- Optional. Overrides metrics at the step level.

### #mock_tool_response

    def mock_tool_response() -> ::Google::Cloud::Ces::V1beta::ToolResponse

**Returns**

- ([::Google::Cloud::Ces::V1beta::ToolResponse](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-ToolResponse)) --- Optional. The tool response to mock, with the parameters of interest specified. Any parameters not specified will be hallucinated by the LLM.


  Note: The following fields are mutually exclusive: `mock_tool_response`, `tool_call`, `tool_response`, `agent_response`, `agent_transfer`, `updated_variables`, `no_tool_calls`. If a field in that set is populated, all other fields in the set will automatically be cleared.

### #mock_tool_response=

    def mock_tool_response=(value) -> ::Google::Cloud::Ces::V1beta::ToolResponse

**Parameter**

- **value** ([::Google::Cloud::Ces::V1beta::ToolResponse](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-ToolResponse)) --- Optional. The tool response to mock, with the parameters of interest specified. Any parameters not specified will be hallucinated by the LLM.


  Note: The following fields are mutually exclusive: `mock_tool_response`, `tool_call`, `tool_response`, `agent_response`, `agent_transfer`, `updated_variables`, `no_tool_calls`. If a field in that set is populated, all other fields in the set will automatically be cleared.
**Returns**

- ([::Google::Cloud::Ces::V1beta::ToolResponse](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-ToolResponse)) --- Optional. The tool response to mock, with the parameters of interest specified. Any parameters not specified will be hallucinated by the LLM.


  Note: The following fields are mutually exclusive: `mock_tool_response`, `tool_call`, `tool_response`, `agent_response`, `agent_transfer`, `updated_variables`, `no_tool_calls`. If a field in that set is populated, all other fields in the set will automatically be cleared.

### #no_tool_calls

    def no_tool_calls() -> ::Boolean

**Returns**

- (::Boolean) --- Optional. Check that no tools were called during this turn.

  Note: The following fields are mutually exclusive: `no_tool_calls`, `tool_call`, `tool_response`, `agent_response`, `agent_transfer`, `updated_variables`, `mock_tool_response`. If a field in that set is populated, all other fields in the set will automatically be cleared.

### #no_tool_calls=

    def no_tool_calls=(value) -> ::Boolean

**Parameter**

- **value** (::Boolean) --- Optional. Check that no tools were called during this turn.


  Note: The following fields are mutually exclusive: `no_tool_calls`, `tool_call`, `tool_response`, `agent_response`, `agent_transfer`, `updated_variables`, `mock_tool_response`. If a field in that set is populated, all other fields in the set will automatically be cleared.
**Returns**

- (::Boolean) --- Optional. Check that no tools were called during this turn.

  Note: The following fields are mutually exclusive: `no_tool_calls`, `tool_call`, `tool_response`, `agent_response`, `agent_transfer`, `updated_variables`, `mock_tool_response`. If a field in that set is populated, all other fields in the set will automatically be cleared.

### #note

    def note() -> ::String

**Returns**

- (::String) --- Optional. A note for this requirement, useful in reporting when specific checks fail. E.g., "Check_Payment_Tool_Called".

### #note=

    def note=(value) -> ::String

**Parameter**

- **value** (::String) --- Optional. A note for this requirement, useful in reporting when specific checks fail. E.g., "Check_Payment_Tool_Called".
**Returns**

- (::String) --- Optional. A note for this requirement, useful in reporting when specific checks fail. E.g., "Check_Payment_Tool_Called".

### #skip_evaluation

    def skip_evaluation() -> ::Boolean

**Returns**

- (::Boolean) --- Optional. If set to true, this specific expectation will not be evaluated.

### #skip_evaluation=

    def skip_evaluation=(value) -> ::Boolean

**Parameter**

- **value** (::Boolean) --- Optional. If set to true, this specific expectation will not be evaluated.
**Returns**

- (::Boolean) --- Optional. If set to true, this specific expectation will not be evaluated.

### #tool_call

    def tool_call() -> ::Google::Cloud::Ces::V1beta::ToolCall

**Returns**

- ([::Google::Cloud::Ces::V1beta::ToolCall](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-ToolCall)) --- Optional. Check that a specific tool was called with the parameters.


  Note: The following fields are mutually exclusive: `tool_call`, `tool_response`, `agent_response`, `agent_transfer`, `updated_variables`, `mock_tool_response`, `no_tool_calls`. If a field in that set is populated, all other fields in the set will automatically be cleared.

### #tool_call=

    def tool_call=(value) -> ::Google::Cloud::Ces::V1beta::ToolCall

**Parameter**

- **value** ([::Google::Cloud::Ces::V1beta::ToolCall](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-ToolCall)) --- Optional. Check that a specific tool was called with the parameters.


  Note: The following fields are mutually exclusive: `tool_call`, `tool_response`, `agent_response`, `agent_transfer`, `updated_variables`, `mock_tool_response`, `no_tool_calls`. If a field in that set is populated, all other fields in the set will automatically be cleared.
**Returns**

- ([::Google::Cloud::Ces::V1beta::ToolCall](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-ToolCall)) --- Optional. Check that a specific tool was called with the parameters.


  Note: The following fields are mutually exclusive: `tool_call`, `tool_response`, `agent_response`, `agent_transfer`, `updated_variables`, `mock_tool_response`, `no_tool_calls`. If a field in that set is populated, all other fields in the set will automatically be cleared.

### #tool_response

    def tool_response() -> ::Google::Cloud::Ces::V1beta::ToolResponse

**Returns**

- ([::Google::Cloud::Ces::V1beta::ToolResponse](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-ToolResponse)) --- Optional. Check that a specific tool had the expected response.


  Note: The following fields are mutually exclusive: `tool_response`, `tool_call`, `agent_response`, `agent_transfer`, `updated_variables`, `mock_tool_response`, `no_tool_calls`. If a field in that set is populated, all other fields in the set will automatically be cleared.

### #tool_response=

    def tool_response=(value) -> ::Google::Cloud::Ces::V1beta::ToolResponse

**Parameter**

- **value** ([::Google::Cloud::Ces::V1beta::ToolResponse](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-ToolResponse)) --- Optional. Check that a specific tool had the expected response.


  Note: The following fields are mutually exclusive: `tool_response`, `tool_call`, `agent_response`, `agent_transfer`, `updated_variables`, `mock_tool_response`, `no_tool_calls`. If a field in that set is populated, all other fields in the set will automatically be cleared.
**Returns**

- ([::Google::Cloud::Ces::V1beta::ToolResponse](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Cloud-Ces-V1beta-ToolResponse)) --- Optional. Check that a specific tool had the expected response.


  Note: The following fields are mutually exclusive: `tool_response`, `tool_call`, `agent_response`, `agent_transfer`, `updated_variables`, `mock_tool_response`, `no_tool_calls`. If a field in that set is populated, all other fields in the set will automatically be cleared.

### #updated_variables

    def updated_variables() -> ::Google::Protobuf::Struct

**Returns**

- ([::Google::Protobuf::Struct](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Protobuf-Struct)) --- Optional. Check that the agent updated the session variables to the expected values. Used to also capture agent variable updates for golden evals.


  Note: The following fields are mutually exclusive: `updated_variables`, `tool_call`, `tool_response`, `agent_response`, `agent_transfer`, `mock_tool_response`, `no_tool_calls`. If a field in that set is populated, all other fields in the set will automatically be cleared.

### #updated_variables=

    def updated_variables=(value) -> ::Google::Protobuf::Struct

**Parameter**

- **value** ([::Google::Protobuf::Struct](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Protobuf-Struct)) --- Optional. Check that the agent updated the session variables to the expected values. Used to also capture agent variable updates for golden evals.


  Note: The following fields are mutually exclusive: `updated_variables`, `tool_call`, `tool_response`, `agent_response`, `agent_transfer`, `mock_tool_response`, `no_tool_calls`. If a field in that set is populated, all other fields in the set will automatically be cleared.
**Returns**

- ([::Google::Protobuf::Struct](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-ces-v1beta/latest/Google-Protobuf-Struct)) --- Optional. Check that the agent updated the session variables to the expected values. Used to also capture agent variable updates for golden evals.


  Note: The following fields are mutually exclusive: `updated_variables`, `tool_call`, `tool_response`, `agent_response`, `agent_transfer`, `mock_tool_response`, `no_tool_calls`. If a field in that set is populated, all other fields in the set will automatically be cleared.