Skip to content
v2.277.0

Experimental

@aws-cdk/aws-bedrock-alpha is an experimental (alpha) package: its API may change in any release, without a major version bump.

ApplicationInferenceProfileProps Struct ​

Properties for creating an Application Inference Profile.

Example ​

ts
// Create a cross-region inference profile
const crossRegionProfile = bedrock.CrossRegionInferenceProfile.fromConfig({
  geoRegion: bedrock.CrossRegionInferenceProfileRegion.US,
  model: bedrock.BedrockFoundationModel.ANTHROPIC_CLAUDE_3_5_SONNET_V2_0,
});

// Create an application inference profile across regions
const appProfile = new bedrock.ApplicationInferenceProfile(this, 'MyMultiRegionProfile', {
  applicationInferenceProfileName: 'claude-35-sonnet-v2-multi-region',
  modelSource: crossRegionProfile,
  description: 'Multi-region application profile for cost tracking',
});
python
# Create a cross-region inference profile
cross_region_profile = bedrock.CrossRegionInferenceProfile.from_config(
    geo_region=bedrock.CrossRegionInferenceProfileRegion.US,
    model=bedrock.BedrockFoundationModel.ANTHROPIC_CLAUDE_3_5_SONNET_V2_0
)

# Create an application inference profile across regions
app_profile = bedrock.ApplicationInferenceProfile(self, "MyMultiRegionProfile",
    application_inference_profile_name="claude-35-sonnet-v2-multi-region",
    model_source=cross_region_profile,
    description="Multi-region application profile for cost tracking"
)
java
// Create a cross-region inference profile
CrossRegionInferenceProfile crossRegionProfile = CrossRegionInferenceProfile.fromConfig(CrossRegionInferenceProfileProps.builder()
        .geoRegion(CrossRegionInferenceProfileRegion.US)
        .model(BedrockFoundationModel.ANTHROPIC_CLAUDE_3_5_SONNET_V2_0)
        .build());

// Create an application inference profile across regions
ApplicationInferenceProfile appProfile = ApplicationInferenceProfile.Builder.create(this, "MyMultiRegionProfile")
        .applicationInferenceProfileName("claude-35-sonnet-v2-multi-region")
        .modelSource(crossRegionProfile)
        .description("Multi-region application profile for cost tracking")
        .build();
csharp
// Install: dotnet add package Amazon.CDK.AWS.Bedrock.Alpha
// Create a cross-region inference profile
var crossRegionProfile = CrossRegionInferenceProfile.FromConfig(new CrossRegionInferenceProfileProps {
    GeoRegion = CrossRegionInferenceProfileRegion.US,
    Model = BedrockFoundationModel.ANTHROPIC_CLAUDE_3_5_SONNET_V2_0
});

// Create an application inference profile across regions
var appProfile = new ApplicationInferenceProfile(this, "MyMultiRegionProfile", new ApplicationInferenceProfileProps {
    ApplicationInferenceProfileName = "claude-35-sonnet-v2-multi-region",
    ModelSource = crossRegionProfile,
    Description = "Multi-region application profile for cost tracking"
});
go
// Install: go get github.com/aws/aws-cdk-go/awsbedrockalpha/v2
// Create a cross-region inference profile
crossRegionProfile := bedrock.CrossRegionInferenceProfile_FromConfig(&CrossRegionInferenceProfileProps{
	GeoRegion: bedrock.CrossRegionInferenceProfileRegion_US,
	Model: bedrock.BedrockFoundationModel_ANTHROPIC_CLAUDE_3_5_SONNET_V2_0(),
})

// Create an application inference profile across regions
appProfile := bedrock.NewApplicationInferenceProfile(this, jsii.String("MyMultiRegionProfile"), &ApplicationInferenceProfileProps{
	ApplicationInferenceProfileName: jsii.String("claude-35-sonnet-v2-multi-region"),
	ModelSource: crossRegionProfile,
	Description: jsii.String("Multi-region application profile for cost tracking"),
})

Properties ​

applicationInferenceProfileNamestringapplication_inference_profile_namestrapplicationInferenceProfileNameStringApplicationInferenceProfileNamestringApplicationInferenceProfileName*stringrequired#
The name of the application inference profile.

This name will be used to identify the inference profile in the AWS console and APIs.

  • Required: Yes
  • Maximum length: 64 characters
  • Pattern: ^([0-9a-zA-Z:.][ _-]?)+$
descriptionoptionalstringdescriptionoptionalstrdescriptionoptionalStringDescriptionoptionalstringDescriptionoptional*string#
Description of the inference profile. Provides additional context about the purpose and usage of this inference profile.

Default: No description is provided

  • Maximum length: 200 characters when provided
  • Pattern: ^([0-9a-zA-Z:.][ _-]?)+$
modelSourceIBedrockInvokablemodel_sourceIBedrockInvokablemodelSourceIBedrockInvokableModelSourceIBedrockInvokableModelSourceIBedrockInvokablerequired#
The model source for this inference profile.
notes

To create an application inference profile for one Region, specify a foundation model. Usage and costs for requests made to that Region with that model will be tracked.

To create an application inference profile for multiple Regions, specify a cross region (system-defined) inference profile. The inference profile will route requests to the Regions defined in the cross region (system-defined) inference profile that you choose. Usage and costs for requests made to the Regions in the inference profile will be tracked.

tagsoptional{ [key: string]: string }tagsoptionaltyping.Mapping[str, str]tagsoptionalMap<String, String>TagsoptionalIDictionary<string, string>Tagsoptional*map[string]*string#
A list of tags associated with the inference profile.

Default: No tags are applied

Tags help you organize and categorize your AWS resources.