Class LlmAsAJudgeOptions.Builder
java.lang.Object
software.amazon.awscdk.services.bedrockagentcore.LlmAsAJudgeOptions.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<LlmAsAJudgeOptions>
- Enclosing interface:
LlmAsAJudgeOptions
@Stability(Stable)
public static final class LlmAsAJudgeOptions.Builder
extends Object
implements software.amazon.jsii.Builder<LlmAsAJudgeOptions>
A builder for
LlmAsAJudgeOptions-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionadditionalModelRequestFields(Map<String, ? extends Object> additionalModelRequestFields) Sets the value ofLlmAsAJudgeOptions.getAdditionalModelRequestFields()build()Builds the configured instance.inferenceConfig(EvaluatorInferenceConfig inferenceConfig) Sets the value ofLlmAsAJudgeOptions.getInferenceConfig()instructions(String instructions) Sets the value ofLlmAsAJudgeOptions.getInstructions()Sets the value ofLlmAsAJudgeOptions.getModelId()ratingScale(EvaluatorRatingScale ratingScale) Sets the value ofLlmAsAJudgeOptions.getRatingScale()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
instructions
Sets the value ofLlmAsAJudgeOptions.getInstructions()- Parameters:
instructions- The evaluation instructions that guide the language model in assessing agent performance. This parameter is required. These instructions define the evaluation criteria, context, and expected behavior. Instructions must contain placeholders appropriate for the evaluation level (e.g.,{context},{available_tools}for SESSION level).Note: Evaluators using reference-input placeholders (e.g.,
{expected_tool_trajectory},{assertions},{expected_response}) are only compatible with on-demand evaluation, not online evaluation.- Returns:
this
-
modelId
Sets the value ofLlmAsAJudgeOptions.getModelId()- Parameters:
modelId- The identifier of the Amazon Bedrock model to use for evaluation. This parameter is required. Accepts standard model IDs (e.g.,'anthropic.claude-sonnet-4-6') and cross-region inference profile IDs with region prefixes (e.g.,'us.anthropic.claude-sonnet-4-6','eu.anthropic.claude-sonnet-4-6').- Returns:
this
-
ratingScale
Sets the value ofLlmAsAJudgeOptions.getRatingScale()- Parameters:
ratingScale- The rating scale that defines how the evaluator should score agent performance. This parameter is required.- Returns:
this
-
additionalModelRequestFields
@Stability(Stable) public LlmAsAJudgeOptions.Builder additionalModelRequestFields(Map<String, ? extends Object> additionalModelRequestFields) Sets the value ofLlmAsAJudgeOptions.getAdditionalModelRequestFields()- Parameters:
additionalModelRequestFields- Additional model-specific request fields.- Returns:
this
-
inferenceConfig
@Stability(Stable) public LlmAsAJudgeOptions.Builder inferenceConfig(EvaluatorInferenceConfig inferenceConfig) Sets the value ofLlmAsAJudgeOptions.getInferenceConfig()- Parameters:
inferenceConfig- Optional inference configuration parameters that control model behavior during evaluation. When not specified, the foundation model uses its own default values for maxTokens, temperature, and topP.- Returns:
this
-
build
Builds the configured instance.- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<LlmAsAJudgeOptions>- Returns:
- a new instance of
LlmAsAJudgeOptions - Throws:
NullPointerException- if any required attribute was not provided
-