Class: AWSCDK::Bedrock::CfnPrompt::PromptGenAiResourceProperty
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::Bedrock::CfnPrompt::PromptGenAiResourceProperty
- Defined in:
- bedrock/cfn_prompt.rb
Overview
Contains specifications for a generative AI resource with which to use the prompt.
For more information, see Create a prompt using Prompt management .
Instance Attribute Summary collapse
-
#agent ⇒ AWSCDK::IResolvable, AWSCDK::Bedrock::CfnPrompt::PromptAgentResourceProperty
readonly
Specifies an Amazon Bedrock agent with which to use the prompt.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(agent:) ⇒ PromptGenAiResourceProperty
constructor
A new instance of PromptGenAiResourceProperty.
- #to_jsii ⇒ Object
Constructor Details
#initialize(agent:) ⇒ PromptGenAiResourceProperty
Returns a new instance of PromptGenAiResourceProperty.
843 844 845 846 |
# File 'bedrock/cfn_prompt.rb', line 843 def initialize(agent:) @agent = agent.is_a?(Hash) ? ::AWSCDK::Bedrock::CfnPrompt::PromptAgentResourceProperty.new(**agent.transform_keys(&:to_sym)) : agent Jsii::Type.check_type(@agent, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19iZWRyb2NrLkNmblByb21wdC5Qcm9tcHRBZ2VudFJlc291cmNlUHJvcGVydHkifV19fQ==")), "agent") end |
Instance Attribute Details
#agent ⇒ AWSCDK::IResolvable, AWSCDK::Bedrock::CfnPrompt::PromptAgentResourceProperty (readonly)
Specifies an Amazon Bedrock agent with which to use the prompt.
852 853 854 |
# File 'bedrock/cfn_prompt.rb', line 852 def agent @agent end |
Class Method Details
.jsii_properties ⇒ Object
854 855 856 857 858 |
# File 'bedrock/cfn_prompt.rb', line 854 def self.jsii_properties { :agent => "agent", } end |
Instance Method Details
#to_jsii ⇒ Object
860 861 862 863 864 865 866 |
# File 'bedrock/cfn_prompt.rb', line 860 def to_jsii result = {} result.merge!({ "agent" => @agent, }) result.compact end |