list_custom_models
¶
list_custom_models(
*,
config_overrides: Optional[BedrockClientConfig] = None,
creation_time_before: Optional[Timestamp] = None,
creation_time_after: Optional[Timestamp] = None,
name_contains: Optional[CustomModelName] = None,
base_model_arn_equals: Optional[ModelArn] = None,
foundation_model_arn_equals: Optional[FoundationModelArn] = None,
max_results: Optional[MaxResults] = None,
next_token: Optional[PaginationToken] = None,
sort_by: Optional[SortModelsBy] = None,
sort_order: Optional[SortOrder] = None,
is_owned: Optional[bool] = None,
model_status: Optional[ModelStatus] = None,
) -> ListCustomModelsResponse
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.
Parameters:
-
creation_time_before(Optional[Timestamp], default:None) –Return custom models created before the specified time.
-
creation_time_after(Optional[Timestamp], default:None) –Return custom models created after the specified time.
-
name_contains(Optional[CustomModelName], default:None) –Return custom models only if the job name contains these characters.
-
base_model_arn_equals(Optional[ModelArn], default:None) –Return custom models only if the base model Amazon Resource Name (ARN) matches this parameter.
-
foundation_model_arn_equals(Optional[FoundationModelArn], default:None) –Return custom models only if the foundation model Amazon Resource Name (ARN) matches this parameter.
-
max_results(Optional[MaxResults], default:None) –The maximum number of results to return in the response. If the total number of results is greater than this value, use the token returned in the response in the
nextTokenfield when making another request to return the next batch of results. -
next_token(Optional[PaginationToken], default:None) –If the total number of results is greater than the
maxResultsvalue provided in the request, enter the token returned in thenextTokenfield in the response in this field to return the next batch of results. -
sort_by(Optional[SortModelsBy], default:None) –The field to sort by in the returned list of models.
-
sort_order(Optional[SortOrder], default:None) –The sort order of the results.
-
is_owned(Optional[bool], default:None) –Return custom models depending on if the current account owns them (
true) or if they were shared with the current account (false). -
model_status(Optional[ModelStatus], default:None) –The status of them model to filter results by. Possible values include:
-
Creating- Include only models that are currently being created and validated. -
Active- Include only models that have been successfully created and are ready for use. -
Failed- Include only models where the creation process failed.
If you don't specify a status, the API returns models in all states.
-
Raises:
-
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.
-
ValidationException–Input validation failed. Check your request parameters and retry the request.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_bedrock/_services/bedrock.py
3807 3808 3809 3810 3811 3812 3813 3814 3815 3816 3817 3818 3819 3820 3821 3822 3823 3824 3825 3826 3827 3828 3829 3830 3831 3832 3833 3834 3835 3836 3837 3838 3839 3840 3841 3842 3843 3844 3845 3846 3847 3848 3849 3850 3851 3852 3853 3854 3855 3856 3857 3858 3859 3860 3861 3862 3863 3864 3865 3866 3867 3868 3869 3870 3871 3872 3873 3874 3875 3876 3877 3878 3879 3880 3881 3882 3883 3884 3885 3886 3887 3888 3889 3890 3891 3892 3893 3894 3895 3896 3897 3898 3899 | |