Listing Models
Function
Lists models.
URI
GET /v1/{project_id}/applications/{application_id}/uni-search/models/search
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
project_id |
Yes |
String |
Definition: Project ID. For details about how to obtain the project ID, see Obtaining a Project ID. Constraints: N/A Value range: The value can contain 1 to 64 characters. Only digits, letters, hyphens (-), and underscores (_) are allowed. The value must start with a letter. Default value: N/A |
application_id |
Yes |
String |
Definition: Application ID. For details about how to obtain the application ID, see Obtaining an Application ID. Constraints: Character string Value range: The value can contain 1 to 64 characters. Only digits, letters, hyphens (-), and underscores (_) are allowed. The value must start with a letter. Default value: N/A |
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
model_name |
No |
String |
Definition: Model name. Constraints: N/A Value range: The value can contain 1 to 64 characters. It can only contain letters, digits, underscores (_), periods (.), and hyphens (-). Default value: N/A |
model_type |
No |
String |
Definition: Model type. Constraints: N/A Value range:
Default value: N/A |
model_status |
No |
String |
Definition: Model status. Constraints: N/A Value range: The value can contain only letters, hyphens (-), commas (,), and underscores (_). Default value: N/A |
page_num |
No |
Integer |
Definition: Page number of the current request, indicating the start page from data retrieval. The default value is 1, indicating to start from the first page. Constraints: N/A Value range: 1-65535 Default value: 1 |
page_size |
No |
Integer |
Definition: Number of records displayed on each page, indicating the number of records returned per request. The default value is 10, indicating that 10 records are displayed on each page. Constraints: N/A Value range: 1-65535 Default value: 10 |
create_user |
No |
String |
Definition: Creator filter. Constraints: N/A Value range: The value contains a maximum of 64 characters. Default value: N/A |
Request Parameters
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
X-Auth-Token |
Yes |
String |
Definition: Token used for API authentication. For details about how to obtain the token, see Obtaining an IAM User Token. Constraints: N/A Value range: N/A Default value: N/A |
Response Parameters
Status code: 200
Parameter |
Type |
Description |
---|---|---|
page_num |
Long |
Definition: Page number. Value range: N/A |
page_size |
Long |
Definition: Number of items. Value range: N/A |
total |
Long |
Definition: Total number of models. Value range: N/A |
models |
Array of ModelListInfo objects |
Definition: Model information. Value range: N/A |
Parameter |
Type |
Description |
---|---|---|
name |
String |
Definition: Model name. Value range: N/A |
project_id |
String |
Definition: Project ID. Value range: N/A |
alias |
String |
Definition: Name used in the Ascend model request. Value range: N/A |
detail |
String |
Definition: Model details. Value range: N/A |
type |
String |
Definition: Model type. Value range: N/A |
status |
String |
Definition: Model status. Value range: N/A |
endpoint |
String |
Definition: Model endpoint. Value range: N/A |
create_time |
String |
Definition: Model creation time. Value range: N/A |
update_time |
String |
Definition: Model update time. Value range: N/A |
extend_config |
ModelExtendConfig object |
Definition: Model extension configuration. Value range: N/A |
actions |
Array of strings |
Definition: Permissions. Value range: N/A |
Parameter |
Type |
Description |
---|---|---|
iam_info |
IamInfo object |
Definition: IAM authentication agency information Constraints: N/A Value range: N/A Default value: N/A |
custom_header |
map<string, object> |
Definition: Extended request header. Constraints: N/A Value range: N/A Default value: N/A |
deployment_id |
String |
Definition: Model deployment ID. Constraints: N/A Value range: N/A Default value: N/A |
vector_config |
VectorConfig object |
Definition: Vector model configuration. Constraints: N/A Value range: N/A Default value: N/A |
nlp_config |
NlpConfig object |
Definition: Configuration of the NLP foundation model. Constraints: N/A Value range: N/A Default value: N/A |
guard_enabled |
Boolean |
Definition: Whether to enable moderation. Constraints: N/A Value range: N/A Default value: N/A |
query_key |
String |
Definition: Key value of the query request body. Constraints: N/A Value range: N/A Default value: N/A |
custom_param |
Map<String,String> |
Definition: Request parameter. Constraints: N/A Value range: N/A Default value: N/A |
custom_enabled |
Boolean |
Definition: Custom field. Constraints: N/A Value range: N/A Default value: N/A |
custom_json_parse |
Map<String,String> |
Definition: Result parsing. Constraints: N/A Value range: N/A Default value: N/A |
proxy_enabled |
Boolean |
Definition: Whether to enable the proxy. This parameter is enabled when the web search engine is configured. Constraints: N/A Value range: N/A Default value: N/A |
time_detect_enabled |
Boolean |
Definition: Whether to enable periodic detection. This parameter is enabled when the web search engine is configured. Constraints: N/A Value range: N/A Default value: N/A |
agree_disclaimer |
String |
Definition: If the disclaimer has been agreed, AGREE is sent. By default, this parameter is left empty. Constraints: N/A Value range: N/A Default value: N/A |
Parameter |
Type |
Description |
---|---|---|
iam_enabled |
Boolean |
Definition: Indicates whether to enable authentication. Constraints: N/A Value range: N/A Default value: N/A |
agency_enabled |
Boolean |
Definition: Indicates whether to use an agency account for authentication Constraints: N/A Value range: N/A Default value: N/A |
project_id |
String |
Definition: Project ID of the IAM user. This parameter is mandatory when iam_enable is set to true. Constraints: N/A Value range: N/A Default value: N/A |
domain_name |
String |
Definition: Name of the agency account. Constraints: N/A Value range: N/A Default value: N/A |
agency_name |
String |
Definition: Agency name. Constraints: N/A Value range: N/A Default value: N/A |
Parameter |
Type |
Description |
---|---|---|
embedding_url |
String |
Definition: URL for calling the embedding or query2query model. Constraints: N/A Value range: N/A Default value: N/A |
rerank_url |
String |
Definition: URL for calling the reranking model. Constraints: N/A Value range: N/A Default value: N/A |
Parameter |
Type |
Description |
---|---|---|
context_length |
Integer |
Definition: Context length, that is, the maximum number of tokens that can be considered by the NLP foundation model during a specific inference. Constraints: N/A Value range: N/A Default value: N/A |
Status code: 400
Parameter |
Type |
Description |
---|---|---|
error_code |
String |
Definition: Value range: N/A |
error_msg |
String |
Definition: Error message. Value range: N/A |
Status code: 500
Parameter |
Type |
Description |
---|---|---|
error_code |
String |
Definition: Value range: N/A |
error_msg |
String |
Definition: Error message. Value range: N/A |
Example Requests
This API is used to list models.
/v1/b25446daeb1a41a7953c5deba2b2677a/applications/be9b19bf-4865-4fb8-b9f8-2fd1fea98d76/uni-search/models/search?page_num=1&page_size=10
Example Responses
Status code: 200
Model list.
{ "page_num" : 1, "page_size" : 1, "total" : 1, "models" : [ { "name" : "pangu_38b", "detail" : "pangu_38b", "type" : "nlp", "status" : "ready", "create_time" : "1716946517167", "update_time" : "1716946517167", "endpoint" : "http://10.0.0.169:31010", "extend_config" : { "deployment_id" : "123", "iam_info" : { "iam_enabled" : false, "agency_enabled" : false, "project_id" : "456" } } } ] }
Status Codes
Status Code |
Description |
---|---|
200 |
Model list. |
400 |
Incorrect request body. |
500 |
Internal error. |
Error Codes
See Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot