Class: AWSCDK::Bedrock::CfnPromptVersion::PromptGenAiResourceProperty
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::Bedrock::CfnPromptVersion::PromptGenAiResourceProperty
- Defined in:
- bedrock/cfn_prompt_version.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::CfnPromptVersion::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.
836 837 838 839 |
# File 'bedrock/cfn_prompt_version.rb', line 836 def initialize(agent:) @agent = agent.is_a?(Hash) ? ::AWSCDK::Bedrock::CfnPromptVersion::PromptAgentResourceProperty.new(**agent.transform_keys(&:to_sym)) : agent Jsii::Type.check_type(@agent, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19iZWRyb2NrLkNmblByb21wdFZlcnNpb24uUHJvbXB0QWdlbnRSZXNvdXJjZVByb3BlcnR5In1dfX0=")), "agent") end |
Instance Attribute Details
#agent ⇒ AWSCDK::IResolvable, AWSCDK::Bedrock::CfnPromptVersion::PromptAgentResourceProperty (readonly)
Specifies an Amazon Bedrock agent with which to use the prompt.
845 846 847 |
# File 'bedrock/cfn_prompt_version.rb', line 845 def agent @agent end |
Class Method Details
.jsii_properties ⇒ Object
847 848 849 850 851 |
# File 'bedrock/cfn_prompt_version.rb', line 847 def self.jsii_properties { :agent => "agent", } end |
Instance Method Details
#to_jsii ⇒ Object
853 854 855 856 857 858 859 |
# File 'bedrock/cfn_prompt_version.rb', line 853 def to_jsii result = {} result.merge!({ "agent" => @agent, }) result.compact end |