Skip to content

create_inference_profile

Operation

create_inference_profile

create_inference_profile(request: CreateInferenceProfileInput | CreateInferenceProfileInputDict | None = None, /, *, plugins: list[Plugin] | None = None, **kwargs: Unpack[CreateInferenceProfileInputDict]) -> CreateInferenceProfileOutput

Creates an application inference profile to track metrics and costs when invoking a model. To create an application inference profile for a foundation model in one region, specify the ARN of the model in that region. To create an application inference profile for a foundation model across multiple regions, specify the ARN of the system-defined inference profile that contains the regions that you want to route requests to. For more information, see Increase throughput and resilience with cross-region inference in Amazon Bedrock. in the Amazon Bedrock User Guide.

Parameters:

Name Type Description Default
request CreateInferenceProfileInput | CreateInferenceProfileInputDict | None

The input as a model or dictionary. Pass this or keyword arguments, not both.

None
plugins list[Plugin] | None

A list of callables that modify the configuration dynamically. Changes made by these plugins only apply for the duration of the operation execution and will not affect any other operation invocations.

None
**kwargs Unpack[CreateInferenceProfileInputDict]

The input fields as keyword arguments.

{}

Returns:

Type Description
CreateInferenceProfileOutput

An instance of CreateInferenceProfileOutput.

create_inference_profile async

create_inference_profile(request: CreateInferenceProfileInput | CreateInferenceProfileInputDict | None = None, /, *, plugins: list[Plugin] | None = None, **kwargs: Unpack[CreateInferenceProfileInputDict]) -> CreateInferenceProfileOutput

Creates an application inference profile to track metrics and costs when invoking a model. To create an application inference profile for a foundation model in one region, specify the ARN of the model in that region. To create an application inference profile for a foundation model across multiple regions, specify the ARN of the system-defined inference profile that contains the regions that you want to route requests to. For more information, see Increase throughput and resilience with cross-region inference in Amazon Bedrock. in the Amazon Bedrock User Guide.

Parameters:

Name Type Description Default
request CreateInferenceProfileInput | CreateInferenceProfileInputDict | None

The input as a model or dictionary. Pass this or keyword arguments, not both.

None
plugins list[Plugin] | None

A list of callables that modify the configuration dynamically. Changes made by these plugins only apply for the duration of the operation execution and will not affect any other operation invocations.

None
**kwargs Unpack[CreateInferenceProfileInputDict]

The input fields as keyword arguments.

{}

Returns:

Type Description
CreateInferenceProfileOutput

An instance of CreateInferenceProfileOutput.

Input

Pass the input as keyword arguments, a positional dictionary, or a positional model object. Pass plugins separately as a keyword argument.

CreateInferenceProfileInputDict

Bases: TypedDict

Dictionary form of CreateInferenceProfileInput.

Attributes

client_request_token instance-attribute
client_request_token: str | None

A unique, case-sensitive identifier to ensure that the API request completes no more than one time. If this token matches a previous request, Amazon Bedrock ignores the request, but does not return an error. For more information, see Ensuring idempotency.

This field is autopopulated if not provided.

description instance-attribute
description: str | None

A description for the inference profile.

inference_profile_name instance-attribute
inference_profile_name: Required[str]

A name for the inference profile.

model_source instance-attribute

The foundation model or system-defined inference profile that the inference profile will track metrics and costs for.

tags instance-attribute
tags: Sequence[Tag | TagDict] | None

An array of objects, each of which contains a tag and its value. For more information, see Tagging resources in the Amazon Bedrock User Guide.

CreateInferenceProfileInput dataclass

Bases: _SerdeShape

Dataclass for CreateInferenceProfileInput structure.

Attributes

client_request_token class-attribute instance-attribute
client_request_token: str | None = ...

A unique, case-sensitive identifier to ensure that the API request completes no more than one time. If this token matches a previous request, Amazon Bedrock ignores the request, but does not return an error. For more information, see Ensuring idempotency.

This field is autopopulated if not provided.

description class-attribute instance-attribute
description: str | None = ...

A description for the inference profile.

inference_profile_name class-attribute instance-attribute
inference_profile_name: str | None = ...

A name for the inference profile.

model_source class-attribute instance-attribute
model_source: InferenceProfileModelSource | None = ...

The foundation model or system-defined inference profile that the inference profile will track metrics and costs for.

tags class-attribute instance-attribute
tags: list[Tag] | None = ...

An array of objects, each of which contains a tag and its value. For more information, see Tagging resources in the Amazon Bedrock User Guide.

Output

CreateInferenceProfileOutput dataclass

Bases: _SerdeShape

Dataclass for CreateInferenceProfileOutput structure.

Attributes

inference_profile_arn instance-attribute
inference_profile_arn: str

The ARN of the inference profile that you created.

response_metadata class-attribute instance-attribute
response_metadata: ResponseMetadata = ...

Metadata about the response that produced this output. Use this to recover the request identifiers a service's support team needs in order to investigate a call. Members of the metadata are individually optional.

status class-attribute instance-attribute
status: str | None = ...

The status of the inference profile. ACTIVE means that the inference profile is ready to be used.