@Generated(value="com.amazonaws:aws-java-sdk-code-generator") public interface AmazonBedrock
Note: Do not directly implement this interface, new methods are added to it regularly. Extend from
AbstractAmazonBedrock
instead.
Describes the API operations for creating, managing, fine-turning, and evaluating Amazon Bedrock models.
Modifier and Type | Field and Description |
---|---|
static String |
ENDPOINT_PREFIX
The region metadata service name for computing region endpoints.
|
Modifier and Type | Method and Description |
---|---|
CreateEvaluationJobResult |
createEvaluationJob(CreateEvaluationJobRequest createEvaluationJobRequest)
API operation for creating and managing Amazon Bedrock automatic model evaluation jobs and model evaluation jobs
that use human workers.
|
CreateGuardrailResult |
createGuardrail(CreateGuardrailRequest createGuardrailRequest)
Creates a guardrail to block topics and to implement safeguards for your generative AI applications.
|
CreateGuardrailVersionResult |
createGuardrailVersion(CreateGuardrailVersionRequest createGuardrailVersionRequest)
Creates a version of the guardrail.
|
CreateModelCustomizationJobResult |
createModelCustomizationJob(CreateModelCustomizationJobRequest createModelCustomizationJobRequest)
Creates a fine-tuning job to customize a base model.
|
CreateProvisionedModelThroughputResult |
createProvisionedModelThroughput(CreateProvisionedModelThroughputRequest createProvisionedModelThroughputRequest)
Creates dedicated throughput for a base or custom model with the model units and for the duration that you
specify.
|
DeleteCustomModelResult |
deleteCustomModel(DeleteCustomModelRequest deleteCustomModelRequest)
Deletes a custom model that you created earlier.
|
DeleteGuardrailResult |
deleteGuardrail(DeleteGuardrailRequest deleteGuardrailRequest)
Deletes a guardrail.
|
DeleteModelInvocationLoggingConfigurationResult |
deleteModelInvocationLoggingConfiguration(DeleteModelInvocationLoggingConfigurationRequest deleteModelInvocationLoggingConfigurationRequest)
Delete the invocation logging.
|
DeleteProvisionedModelThroughputResult |
deleteProvisionedModelThroughput(DeleteProvisionedModelThroughputRequest deleteProvisionedModelThroughputRequest)
Deletes a Provisioned Throughput.
|
ResponseMetadata |
getCachedResponseMetadata(AmazonWebServiceRequest request)
Returns additional metadata for a previously executed successful request, typically used for debugging issues
where a service isn't acting as expected.
|
GetCustomModelResult |
getCustomModel(GetCustomModelRequest getCustomModelRequest)
Get the properties associated with a Amazon Bedrock custom model that you have created.For more information, see
Custom models in the Amazon
Bedrock User Guide.
|
GetEvaluationJobResult |
getEvaluationJob(GetEvaluationJobRequest getEvaluationJobRequest)
Retrieves the properties associated with a model evaluation job, including the status of the job.
|
GetFoundationModelResult |
getFoundationModel(GetFoundationModelRequest getFoundationModelRequest)
Get details about a Amazon Bedrock foundation model.
|
GetGuardrailResult |
getGuardrail(GetGuardrailRequest getGuardrailRequest)
Gets details about a guardrail.
|
GetModelCustomizationJobResult |
getModelCustomizationJob(GetModelCustomizationJobRequest getModelCustomizationJobRequest)
Retrieves the properties associated with a model-customization job, including the status of the job.
|
GetModelInvocationLoggingConfigurationResult |
getModelInvocationLoggingConfiguration(GetModelInvocationLoggingConfigurationRequest getModelInvocationLoggingConfigurationRequest)
Get the current configuration values for model invocation logging.
|
GetProvisionedModelThroughputResult |
getProvisionedModelThroughput(GetProvisionedModelThroughputRequest getProvisionedModelThroughputRequest)
Returns details for a Provisioned Throughput.
|
ListCustomModelsResult |
listCustomModels(ListCustomModelsRequest listCustomModelsRequest)
Returns a list of the custom models that you have created with the
CreateModelCustomizationJob
operation. |
ListEvaluationJobsResult |
listEvaluationJobs(ListEvaluationJobsRequest listEvaluationJobsRequest)
Lists model evaluation jobs.
|
ListFoundationModelsResult |
listFoundationModels(ListFoundationModelsRequest listFoundationModelsRequest)
Lists Amazon Bedrock foundation models that you can use.
|
ListGuardrailsResult |
listGuardrails(ListGuardrailsRequest listGuardrailsRequest)
Lists details about all the guardrails in an account.
|
ListModelCustomizationJobsResult |
listModelCustomizationJobs(ListModelCustomizationJobsRequest listModelCustomizationJobsRequest)
Returns a list of model customization jobs that you have submitted.
|
ListProvisionedModelThroughputsResult |
listProvisionedModelThroughputs(ListProvisionedModelThroughputsRequest listProvisionedModelThroughputsRequest)
Lists the Provisioned Throughputs in the account.
|
ListTagsForResourceResult |
listTagsForResource(ListTagsForResourceRequest listTagsForResourceRequest)
List the tags associated with the specified resource.
|
PutModelInvocationLoggingConfigurationResult |
putModelInvocationLoggingConfiguration(PutModelInvocationLoggingConfigurationRequest putModelInvocationLoggingConfigurationRequest)
Set the configuration values for model invocation logging.
|
void |
shutdown()
Shuts down this client object, releasing any resources that might be held open.
|
StopEvaluationJobResult |
stopEvaluationJob(StopEvaluationJobRequest stopEvaluationJobRequest)
Stops an in progress model evaluation job.
|
StopModelCustomizationJobResult |
stopModelCustomizationJob(StopModelCustomizationJobRequest stopModelCustomizationJobRequest)
Stops an active model customization job.
|
TagResourceResult |
tagResource(TagResourceRequest tagResourceRequest)
Associate tags with a resource.
|
UntagResourceResult |
untagResource(UntagResourceRequest untagResourceRequest)
Remove one or more tags from a resource.
|
UpdateGuardrailResult |
updateGuardrail(UpdateGuardrailRequest updateGuardrailRequest)
Updates a guardrail with the values you specify.
|
UpdateProvisionedModelThroughputResult |
updateProvisionedModelThroughput(UpdateProvisionedModelThroughputRequest updateProvisionedModelThroughputRequest)
Updates the name or associated model for a Provisioned Throughput.
|
static final String ENDPOINT_PREFIX
CreateEvaluationJobResult createEvaluationJob(CreateEvaluationJobRequest createEvaluationJobRequest)
API operation for creating and managing Amazon Bedrock automatic model evaluation jobs and model evaluation jobs that use human workers. To learn more about the requirements for creating a model evaluation job see, Model evaluations.
createEvaluationJobRequest
- ResourceNotFoundException
- The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and
try your request again.AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.ConflictException
- Error occurred because of a conflict while performing an operation.InternalServerException
- An internal server error occurred. Retry your request.ServiceQuotaExceededException
- The number of requests exceeds the service quota. Resubmit your request later.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.CreateGuardrailResult createGuardrail(CreateGuardrailRequest createGuardrailRequest)
Creates a guardrail to block topics and to implement safeguards for your generative AI applications.
You can configure the following policies in a guardrail to avoid undesirable and harmful content, filter out denied topics and words, and remove sensitive information for privacy protection.
Content filters - Adjust filter strengths to block input prompts or model responses containing harmful content.
Denied topics - Define a set of topics that are undesirable in the context of your application. These topics will be blocked if detected in user queries or model responses.
Word filters - Configure filters to block undesirable words, phrases, and profanity. Such words can include offensive terms, competitor names etc.
Sensitive information filters - Block or mask sensitive information such as personally identifiable information (PII) or custom regex in user inputs and model responses.
In addition to the above policies, you can also configure the messages to be returned to the user if a user input or model response is in violation of the policies defined in the guardrail.
For more information, see Guardrails for Amazon Bedrock in the Amazon Bedrock User Guide.
createGuardrailRequest
- ResourceNotFoundException
- The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and
try your request again.AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.ConflictException
- Error occurred because of a conflict while performing an operation.InternalServerException
- An internal server error occurred. Retry your request.TooManyTagsException
- The request contains more tags than can be associated with a resource (50 tags per resource). The maximum
number of tags includes both existing tags and those included in your current request.ServiceQuotaExceededException
- The number of requests exceeds the service quota. Resubmit your request later.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.CreateGuardrailVersionResult createGuardrailVersion(CreateGuardrailVersionRequest createGuardrailVersionRequest)
Creates a version of the guardrail. Use this API to create a snapshot of the guardrail when you are satisfied with a configuration, or to compare the configuration with another version.
createGuardrailVersionRequest
- ResourceNotFoundException
- The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and
try your request again.AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.ConflictException
- Error occurred because of a conflict while performing an operation.InternalServerException
- An internal server error occurred. Retry your request.ServiceQuotaExceededException
- The number of requests exceeds the service quota. Resubmit your request later.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.CreateModelCustomizationJobResult createModelCustomizationJob(CreateModelCustomizationJobRequest createModelCustomizationJobRequest)
Creates a fine-tuning job to customize a base model.
You specify the base foundation model and the location of the training data. After the model-customization job completes successfully, your custom model resource will be ready to use. Amazon Bedrock returns validation loss metrics and output generations after the job completes.
For information on the format of training and validation data, see Prepare the datasets.
Model-customization jobs are asynchronous and the completion time depends on the base model and the
training/validation data size. To monitor a job, use the GetModelCustomizationJob
operation to
retrieve the job status.
For more information, see Custom models in the Amazon Bedrock User Guide.
createModelCustomizationJobRequest
- ResourceNotFoundException
- The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and
try your request again.AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.ConflictException
- Error occurred because of a conflict while performing an operation.InternalServerException
- An internal server error occurred. Retry your request.TooManyTagsException
- The request contains more tags than can be associated with a resource (50 tags per resource). The maximum
number of tags includes both existing tags and those included in your current request.ServiceQuotaExceededException
- The number of requests exceeds the service quota. Resubmit your request later.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.CreateProvisionedModelThroughputResult createProvisionedModelThroughput(CreateProvisionedModelThroughputRequest createProvisionedModelThroughputRequest)
Creates dedicated throughput for a base or custom model with the model units and for the duration that you specify. For pricing details, see Amazon Bedrock Pricing. For more information, see Provisioned Throughput in the Amazon Bedrock User Guide.
createProvisionedModelThroughputRequest
- ResourceNotFoundException
- The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and
try your request again.AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.InternalServerException
- An internal server error occurred. Retry your request.TooManyTagsException
- The request contains more tags than can be associated with a resource (50 tags per resource). The maximum
number of tags includes both existing tags and those included in your current request.ServiceQuotaExceededException
- The number of requests exceeds the service quota. Resubmit your request later.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.DeleteCustomModelResult deleteCustomModel(DeleteCustomModelRequest deleteCustomModelRequest)
Deletes a custom model that you created earlier. For more information, see Custom models in the Amazon Bedrock User Guide.
deleteCustomModelRequest
- ResourceNotFoundException
- The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and
try your request again.AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.ConflictException
- Error occurred because of a conflict while performing an operation.InternalServerException
- An internal server error occurred. Retry your request.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.DeleteGuardrailResult deleteGuardrail(DeleteGuardrailRequest deleteGuardrailRequest)
Deletes a guardrail.
To delete a guardrail, only specify the ARN of the guardrail in the guardrailIdentifier
field. If
you delete a guardrail, all of its versions will be deleted.
To delete a version of a guardrail, specify the ARN of the guardrail in the guardrailIdentifier
field and the version in the guardrailVersion
field.
deleteGuardrailRequest
- ResourceNotFoundException
- The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and
try your request again.AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.ConflictException
- Error occurred because of a conflict while performing an operation.InternalServerException
- An internal server error occurred. Retry your request.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.DeleteModelInvocationLoggingConfigurationResult deleteModelInvocationLoggingConfiguration(DeleteModelInvocationLoggingConfigurationRequest deleteModelInvocationLoggingConfigurationRequest)
Delete the invocation logging.
deleteModelInvocationLoggingConfigurationRequest
- AccessDeniedException
- The request is denied because of missing access permissions.InternalServerException
- An internal server error occurred. Retry your request.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.DeleteProvisionedModelThroughputResult deleteProvisionedModelThroughput(DeleteProvisionedModelThroughputRequest deleteProvisionedModelThroughputRequest)
Deletes a Provisioned Throughput. You can't delete a Provisioned Throughput before the commitment term is over. For more information, see Provisioned Throughput in the Amazon Bedrock User Guide.
deleteProvisionedModelThroughputRequest
- ResourceNotFoundException
- The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and
try your request again.AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.ConflictException
- Error occurred because of a conflict while performing an operation.InternalServerException
- An internal server error occurred. Retry your request.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.GetCustomModelResult getCustomModel(GetCustomModelRequest getCustomModelRequest)
Get the properties associated with a Amazon Bedrock custom model that you have created.For more information, see Custom models in the Amazon Bedrock User Guide.
getCustomModelRequest
- ResourceNotFoundException
- The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and
try your request again.AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.InternalServerException
- An internal server error occurred. Retry your request.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.GetEvaluationJobResult getEvaluationJob(GetEvaluationJobRequest getEvaluationJobRequest)
Retrieves the properties associated with a model evaluation job, including the status of the job. For more information, see Model evaluations.
getEvaluationJobRequest
- ResourceNotFoundException
- The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and
try your request again.AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.InternalServerException
- An internal server error occurred. Retry your request.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.GetFoundationModelResult getFoundationModel(GetFoundationModelRequest getFoundationModelRequest)
Get details about a Amazon Bedrock foundation model.
getFoundationModelRequest
- ResourceNotFoundException
- The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and
try your request again.AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.InternalServerException
- An internal server error occurred. Retry your request.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.GetGuardrailResult getGuardrail(GetGuardrailRequest getGuardrailRequest)
Gets details about a guardrail. If you don't specify a version, the response returns details for the
DRAFT
version.
getGuardrailRequest
- ResourceNotFoundException
- The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and
try your request again.AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.InternalServerException
- An internal server error occurred. Retry your request.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.GetModelCustomizationJobResult getModelCustomizationJob(GetModelCustomizationJobRequest getModelCustomizationJobRequest)
Retrieves the properties associated with a model-customization job, including the status of the job. For more information, see Custom models in the Amazon Bedrock User Guide.
getModelCustomizationJobRequest
- ResourceNotFoundException
- The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and
try your request again.AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.InternalServerException
- An internal server error occurred. Retry your request.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.GetModelInvocationLoggingConfigurationResult getModelInvocationLoggingConfiguration(GetModelInvocationLoggingConfigurationRequest getModelInvocationLoggingConfigurationRequest)
Get the current configuration values for model invocation logging.
getModelInvocationLoggingConfigurationRequest
- AccessDeniedException
- The request is denied because of missing access permissions.InternalServerException
- An internal server error occurred. Retry your request.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.GetProvisionedModelThroughputResult getProvisionedModelThroughput(GetProvisionedModelThroughputRequest getProvisionedModelThroughputRequest)
Returns details for a Provisioned Throughput. For more information, see Provisioned Throughput in the Amazon Bedrock User Guide.
getProvisionedModelThroughputRequest
- ResourceNotFoundException
- The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and
try your request again.AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.InternalServerException
- An internal server error occurred. Retry your request.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.ListCustomModelsResult listCustomModels(ListCustomModelsRequest listCustomModelsRequest)
Returns a list of the custom models that you have created with the CreateModelCustomizationJob
operation.
For more information, see Custom models in the Amazon Bedrock User Guide.
listCustomModelsRequest
- AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.InternalServerException
- An internal server error occurred. Retry your request.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.ListEvaluationJobsResult listEvaluationJobs(ListEvaluationJobsRequest listEvaluationJobsRequest)
Lists model evaluation jobs.
listEvaluationJobsRequest
- AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.InternalServerException
- An internal server error occurred. Retry your request.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.ListFoundationModelsResult listFoundationModels(ListFoundationModelsRequest listFoundationModelsRequest)
Lists Amazon Bedrock foundation models that you can use. You can filter the results with the request parameters. For more information, see Foundation models in the Amazon Bedrock User Guide.
listFoundationModelsRequest
- AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.InternalServerException
- An internal server error occurred. Retry your request.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.ListGuardrailsResult listGuardrails(ListGuardrailsRequest listGuardrailsRequest)
Lists details about all the guardrails in an account. To list the DRAFT
version of all your
guardrails, don't specify the guardrailIdentifier
field. To list all versions of a guardrail,
specify the ARN of the guardrail in the guardrailIdentifier
field.
You can set the maximum number of results to return in a response in the maxResults
field. If there
are more results than the number you set, the response returns a nextToken
that you can send in
another ListGuardrails
request to see the next batch of results.
listGuardrailsRequest
- ResourceNotFoundException
- The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and
try your request again.AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.InternalServerException
- An internal server error occurred. Retry your request.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.ListModelCustomizationJobsResult listModelCustomizationJobs(ListModelCustomizationJobsRequest listModelCustomizationJobsRequest)
Returns a list of model customization jobs that you have submitted. You can filter the jobs to return based on one or more criteria.
For more information, see Custom models in the Amazon Bedrock User Guide.
listModelCustomizationJobsRequest
- AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.InternalServerException
- An internal server error occurred. Retry your request.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.ListProvisionedModelThroughputsResult listProvisionedModelThroughputs(ListProvisionedModelThroughputsRequest listProvisionedModelThroughputsRequest)
Lists the Provisioned Throughputs in the account. For more information, see Provisioned Throughput in the Amazon Bedrock User Guide.
listProvisionedModelThroughputsRequest
- AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.InternalServerException
- An internal server error occurred. Retry your request.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.ListTagsForResourceResult listTagsForResource(ListTagsForResourceRequest listTagsForResourceRequest)
List the tags associated with the specified resource.
For more information, see Tagging resources in the Amazon Bedrock User Guide.
listTagsForResourceRequest
- ResourceNotFoundException
- The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and
try your request again.AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.InternalServerException
- An internal server error occurred. Retry your request.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.PutModelInvocationLoggingConfigurationResult putModelInvocationLoggingConfiguration(PutModelInvocationLoggingConfigurationRequest putModelInvocationLoggingConfigurationRequest)
Set the configuration values for model invocation logging.
putModelInvocationLoggingConfigurationRequest
- AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.InternalServerException
- An internal server error occurred. Retry your request.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.StopEvaluationJobResult stopEvaluationJob(StopEvaluationJobRequest stopEvaluationJobRequest)
Stops an in progress model evaluation job.
stopEvaluationJobRequest
- ResourceNotFoundException
- The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and
try your request again.AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.ConflictException
- Error occurred because of a conflict while performing an operation.InternalServerException
- An internal server error occurred. Retry your request.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.StopModelCustomizationJobResult stopModelCustomizationJob(StopModelCustomizationJobRequest stopModelCustomizationJobRequest)
Stops an active model customization job. For more information, see Custom models in the Amazon Bedrock User Guide.
stopModelCustomizationJobRequest
- ResourceNotFoundException
- The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and
try your request again.AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.ConflictException
- Error occurred because of a conflict while performing an operation.InternalServerException
- An internal server error occurred. Retry your request.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.TagResourceResult tagResource(TagResourceRequest tagResourceRequest)
Associate tags with a resource. For more information, see Tagging resources in the Amazon Bedrock User Guide.
tagResourceRequest
- ResourceNotFoundException
- The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and
try your request again.AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.InternalServerException
- An internal server error occurred. Retry your request.TooManyTagsException
- The request contains more tags than can be associated with a resource (50 tags per resource). The maximum
number of tags includes both existing tags and those included in your current request.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.UntagResourceResult untagResource(UntagResourceRequest untagResourceRequest)
Remove one or more tags from a resource. For more information, see Tagging resources in the Amazon Bedrock User Guide.
untagResourceRequest
- ResourceNotFoundException
- The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and
try your request again.AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.InternalServerException
- An internal server error occurred. Retry your request.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.UpdateGuardrailResult updateGuardrail(UpdateGuardrailRequest updateGuardrailRequest)
Updates a guardrail with the values you specify.
Specify a name
and optional description
.
Specify messages for when the guardrail successfully blocks a prompt or a model response in the
blockedInputMessaging
and blockedOutputsMessaging
fields.
Specify topics for the guardrail to deny in the topicPolicyConfig
object. Each GuardrailTopicConfig object in the topicsConfig
list pertains to one topic.
Give a name
and description
so that the guardrail can properly identify the topic.
Specify DENY
in the type
field.
(Optional) Provide up to five prompts that you would categorize as belonging to the topic in the
examples
list.
Specify filter strengths for the harmful categories defined in Amazon Bedrock in the
contentPolicyConfig
object. Each GuardrailContentFilterConfig object in the filtersConfig
list pertains to a harmful category.
For more information, see Content filters. For
more information about the fields in a content filter, see GuardrailContentFilterConfig.
Specify the category in the type
field.
Specify the strength of the filter for prompts in the inputStrength
field and for model responses in
the strength
field of the GuardrailContentFilterConfig.
(Optional) For security, include the ARN of a KMS key in the kmsKeyId
field.
updateGuardrailRequest
- ResourceNotFoundException
- The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and
try your request again.AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.ConflictException
- Error occurred because of a conflict while performing an operation.InternalServerException
- An internal server error occurred. Retry your request.ServiceQuotaExceededException
- The number of requests exceeds the service quota. Resubmit your request later.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.UpdateProvisionedModelThroughputResult updateProvisionedModelThroughput(UpdateProvisionedModelThroughputRequest updateProvisionedModelThroughputRequest)
Updates the name or associated model for a Provisioned Throughput. For more information, see Provisioned Throughput in the Amazon Bedrock User Guide.
updateProvisionedModelThroughputRequest
- ResourceNotFoundException
- The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and
try your request again.AccessDeniedException
- The request is denied because of missing access permissions.ValidationException
- Input validation failed. Check your request parameters and retry the request.InternalServerException
- An internal server error occurred. Retry your request.ThrottlingException
- The number of requests exceeds the limit. Resubmit your request later.void shutdown()
ResponseMetadata getCachedResponseMetadata(AmazonWebServiceRequest request)
Response metadata is only cached for a limited period of time, so if you need to access this extra diagnostic information for an executed request, you should use this method to retrieve it as soon as possible after executing a request.
request
- The originally executed request.