QConnect / Client / list_models
list_models¶
- QConnect.Client.list_models(**kwargs)¶
Lists the models available to an Amazon Q in Connect assistant in the assistant’s Amazon Web Services Region. The available models are determined by the region of the specified assistant.
See also: AWS API Documentation
Request Syntax
response = client.list_models( assistantId='string', aiPromptType='ANSWER_GENERATION'|'INTENT_LABELING_GENERATION'|'QUERY_REFORMULATION'|'SELF_SERVICE_PRE_PROCESSING'|'SELF_SERVICE_ANSWER_GENERATION'|'EMAIL_RESPONSE'|'EMAIL_OVERVIEW'|'EMAIL_GENERATIVE_ANSWER'|'EMAIL_QUERY_REFORMULATION'|'ORCHESTRATION'|'NOTE_TAKING'|'CASE_SUMMARIZATION', modelLifecycle='ACTIVE'|'LEGACY', nextToken='string', maxResults=123 )
- Parameters:
assistantId (string) –
[REQUIRED]
The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain the ARN. The assistant’s region determines which models are available.
aiPromptType (string) – The type of the AI Prompt to filter models by. When specified, only models that support the given AI Prompt type are returned.
modelLifecycle (string) – The lifecycle status of models to filter by. When specified, only models with the given lifecycle status are returned.
nextToken (string) – The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.
maxResults (integer) – The maximum number of results to return per page.
- Return type:
dict
- Returns:
Response Syntax
{ 'modelSummaries': [ { 'modelId': 'string', 'displayName': 'string', 'crossRegionStatus': 'NONE'|'REGIONAL'|'GLOBAL', 'supportsPromptCaching': True|False, 'supportedAIPromptTypes': [ 'ANSWER_GENERATION'|'INTENT_LABELING_GENERATION'|'QUERY_REFORMULATION'|'SELF_SERVICE_PRE_PROCESSING'|'SELF_SERVICE_ANSWER_GENERATION'|'EMAIL_RESPONSE'|'EMAIL_OVERVIEW'|'EMAIL_GENERATIVE_ANSWER'|'EMAIL_QUERY_REFORMULATION'|'ORCHESTRATION'|'NOTE_TAKING'|'CASE_SUMMARIZATION', ], 'modelLifecycle': 'ACTIVE'|'LEGACY', 'legacyTimestamp': datetime(2015, 1, 1), 'endOfLifeTimestamp': datetime(2015, 1, 1) }, ], 'nextToken': 'string' }
Response Structure
(dict) –
modelSummaries (list) –
The summaries of the models available to the assistant.
(dict) –
The summary of a model available to an Amazon Q in Connect assistant.
modelId (string) –
The identifier of the model.
displayName (string) –
The display name of the model.
crossRegionStatus (string) –
The cross-region availability status of the model.
NONEindicates the model is only available in a single region,REGIONALindicates the model is available through regional inference, andGLOBALindicates the model is available through global cross-region inference.supportsPromptCaching (boolean) –
Whether the model supports prompt caching.
supportedAIPromptTypes (list) –
The list of AI Prompt types that the model supports.
(string) –
modelLifecycle (string) –
The current lifecycle of the model.
ACTIVEindicates the model is recommended for use andLEGACYindicates the model is still usable but is deprecated.legacyTimestamp (datetime) –
The timestamp when the model lifecycle will transition from
ACTIVEtoLEGACY.endOfLifeTimestamp (datetime) –
The timestamp when the model will reach end of life and no longer be available for use.
nextToken (string) –
If there are additional results, this is the token for the next set of results.
Exceptions