Class: AWSCDK::BedrockAgentCore::CfnHarness::HarnessBedrockModelConfigProperty
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::BedrockAgentCore::CfnHarness::HarnessBedrockModelConfigProperty
- Defined in:
- bedrock_agent_core/cfn_harness.rb
Overview
Instance Attribute Summary collapse
- #api_format ⇒ String? readonly
- #max_tokens ⇒ Numeric? readonly
- #model_id ⇒ String readonly
- #temperature ⇒ Numeric? readonly
- #top_p ⇒ Numeric? readonly
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(model_id:, api_format: nil, max_tokens: nil, temperature: nil, top_p: nil) ⇒ HarnessBedrockModelConfigProperty
constructor
A new instance of HarnessBedrockModelConfigProperty.
- #to_jsii ⇒ Object
Constructor Details
#initialize(model_id:, api_format: nil, max_tokens: nil, temperature: nil, top_p: nil) ⇒ HarnessBedrockModelConfigProperty
Returns a new instance of HarnessBedrockModelConfigProperty.
1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 |
# File 'bedrock_agent_core/cfn_harness.rb', line 1409 def initialize(model_id:, api_format: nil, max_tokens: nil, temperature: nil, top_p: nil) @model_id = model_id Jsii::Type.check_type(@model_id, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "modelId") @api_format = api_format Jsii::Type.check_type(@api_format, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "apiFormat") unless @api_format.nil? @max_tokens = max_tokens Jsii::Type.check_type(@max_tokens, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "maxTokens") unless @max_tokens.nil? @temperature = temperature Jsii::Type.check_type(@temperature, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "temperature") unless @temperature.nil? @top_p = top_p Jsii::Type.check_type(@top_p, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "topP") unless @top_p.nil? end |
Instance Attribute Details
#api_format ⇒ String? (readonly)
1427 1428 1429 |
# File 'bedrock_agent_core/cfn_harness.rb', line 1427 def api_format @api_format end |
#max_tokens ⇒ Numeric? (readonly)
1430 1431 1432 |
# File 'bedrock_agent_core/cfn_harness.rb', line 1430 def max_tokens @max_tokens end |
#model_id ⇒ String (readonly)
1424 1425 1426 |
# File 'bedrock_agent_core/cfn_harness.rb', line 1424 def model_id @model_id end |
#temperature ⇒ Numeric? (readonly)
1433 1434 1435 |
# File 'bedrock_agent_core/cfn_harness.rb', line 1433 def temperature @temperature end |
#top_p ⇒ Numeric? (readonly)
1436 1437 1438 |
# File 'bedrock_agent_core/cfn_harness.rb', line 1436 def top_p @top_p end |
Class Method Details
.jsii_properties ⇒ Object
1438 1439 1440 1441 1442 1443 1444 1445 1446 |
# File 'bedrock_agent_core/cfn_harness.rb', line 1438 def self.jsii_properties { :model_id => "modelId", :api_format => "apiFormat", :max_tokens => "maxTokens", :temperature => "temperature", :top_p => "topP", } end |
Instance Method Details
#to_jsii ⇒ Object
1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 |
# File 'bedrock_agent_core/cfn_harness.rb', line 1448 def to_jsii result = {} result.merge!({ "modelId" => @model_id, "apiFormat" => @api_format, "maxTokens" => @max_tokens, "temperature" => @temperature, "topP" => @top_p, }) result.compact end |