CfnApplicationInferenceProfileProps
- class aws_cdk.aws_bedrock.CfnApplicationInferenceProfileProps(*, inference_profile_name, description=None, model_source=None, tags=None)
Bases:
object
Properties for defining a
CfnApplicationInferenceProfile
.- Parameters:
inference_profile_name (
str
) – The name of the inference profile.description (
Optional
[str
]) – The description of the inference profile.model_source (
Union
[IResolvable
,InferenceProfileModelSourceProperty
,Dict
[str
,Any
],None
]) – Contains configurations for the inference profile to copy as the resource.tags (
Optional
[Sequence
[Union
[CfnTag
,Dict
[str
,Any
]]]]) – A list of tags associated with the inference profile.
- See:
- ExampleMetadata:
fixture=default infused
Example:
# Create or reference an existing L1 CfnApplicationInferenceProfile cfn_profile = aws_bedrock_cfn.CfnApplicationInferenceProfile(self, "CfnProfile", inference_profile_name="my-cfn-profile", model_source=aws_bedrock_cfn.CfnApplicationInferenceProfile.InferenceProfileModelSourceProperty( copy_from=bedrock.BedrockFoundationModel.ANTHROPIC_CLAUDE_3_5_SONNET_V1_0.invokable_arn ), description="Profile created via L1 construct" ) # Import the L1 construct as an L2 ApplicationInferenceProfile imported_from_cfn = bedrock.ApplicationInferenceProfile.from_cfn_application_inference_profile(cfn_profile) # Grant permissions to use the imported profile lambda_function = lambda_.Function(self, "MyFunction", runtime=lambda_.Runtime.PYTHON_3_11, handler="index.handler", code=lambda_.Code.from_inline("def handler(event, context): return "Hello"") ) imported_from_cfn.grant_profile_usage(lambda_function)
Attributes
- description
The description of the inference profile.
- inference_profile_name
The name of the inference profile.
- model_source
Contains configurations for the inference profile to copy as the resource.
- tags
A list of tags associated with the inference profile.