"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.EvaluatorConfig=exports.EvaluatorRatingScale=void 0;var jsiiDeprecationWarnings=()=>{var tmp=require("../../../.warnings.jsii.js");return jsiiDeprecationWarnings=()=>tmp,tmp};const JSII_RTTI_SYMBOL_1=Symbol.for("jsii.rtti");var validation_helpers_1=()=>{var tmp=require("./validation-helpers");return validation_helpers_1=()=>tmp,tmp};class EvaluatorRatingScale{static[JSII_RTTI_SYMBOL_1]={fqn:"aws-cdk-lib.aws_bedrockagentcore.EvaluatorRatingScale",version:"2.256.1"};static categorical(options){return(0,validation_helpers_1().throwIfInvalid)(validation_helpers_1().validateCategoricalRatingScale,options),new EvaluatorRatingScale({categorical:options})}static numerical(options){return(0,validation_helpers_1().throwIfInvalid)(validation_helpers_1().validateNumericalRatingScale,options),new EvaluatorRatingScale({numerical:options})}config;constructor(config){this.config=config}_bind(){return this.config}}exports.EvaluatorRatingScale=EvaluatorRatingScale;class EvaluatorConfig{static[JSII_RTTI_SYMBOL_1]={fqn:"aws-cdk-lib.aws_bedrockagentcore.EvaluatorConfig",version:"2.256.1"};static llmAsAJudge(options){try{jsiiDeprecationWarnings().aws_cdk_lib_aws_bedrockagentcore_LlmAsAJudgeOptions(options)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,this.llmAsAJudge),error}(0,validation_helpers_1().throwIfInvalid)(validation_helpers_1().validateInstructions,options.instructions);const modelConfig={bedrockEvaluatorModelConfig:{modelId:options.modelId,...options.inferenceConfig!==void 0?{inferenceConfig:{maxTokens:options.inferenceConfig.maxTokens,temperature:options.inferenceConfig.temperature,topP:options.inferenceConfig.topP}}:{},...options.additionalModelRequestFields!==void 0?{additionalModelRequestFields:options.additionalModelRequestFields}:{}}},cfnConfig={llmAsAJudge:{instructions:options.instructions,modelConfig,ratingScale:options.ratingScale._bind()}};return new EvaluatorConfig(cfnConfig)}static codeBased(options){try{jsiiDeprecationWarnings().aws_cdk_lib_aws_bedrockagentcore_CodeBasedOptions(options)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,this.codeBased),error}const timeoutInSeconds=options.timeout?.toSeconds(),cfnConfig={codeBased:{lambdaConfig:{lambdaArn:options.lambdaFunction.functionArn,...timeoutInSeconds!==void 0?{lambdaTimeoutInSeconds:timeoutInSeconds}:{}}}};return new EvaluatorConfig(cfnConfig,options.lambdaFunction)}lambdaFunction;cfnConfig;constructor(cfnConfig,lambdaFunction){this.cfnConfig=cfnConfig,this.lambdaFunction=lambdaFunction}_bind(){return this.cfnConfig}}exports.EvaluatorConfig=EvaluatorConfig;
