doc-exports/docs/modelarts/api-ref/modelarts_03_0077.html
Lai, Weijian 2f0818cf3d ModelArts API 22.3.0 version-20240311
Reviewed-by: Pruthi, Vineet <vineet.pruthi@t-systems.com>
Co-authored-by: Lai, Weijian <laiweijian4@huawei.com>
Co-committed-by: Lai, Weijian <laiweijian4@huawei.com>
2024-04-05 09:35:42 +00:00

422 lines
34 KiB
HTML

<a name="modelarts_03_0077"></a><a name="modelarts_03_0077"></a>
<h1 class="topictitle1">Querying a Model List</h1>
<div id="body1536546870203"><div class="section" id="modelarts_03_0077__section1644091944412"><h4 class="sectiontitle">Function</h4><p id="modelarts_03_0077__p49947236445">This API is used to query the models that meet the search criteria.</p>
</div>
<div class="section" id="modelarts_03_0077__section181341535122619"><h4 class="sectiontitle">URI</h4><p id="modelarts_03_0077__p390312213242">GET /v1/{project_id}/models</p>
<div class="p" id="modelarts_03_0077__p416020471952"><a href="#modelarts_03_0077__table16518993181628">Table 1</a> describes the required parameters.
<div class="tablenoborder"><a name="modelarts_03_0077__table16518993181628"></a><a name="table16518993181628"></a><table cellpadding="4" cellspacing="0" summary="" id="modelarts_03_0077__table16518993181628" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameters</caption><thead align="left"><tr id="modelarts_03_0077__row41524868181628"><th align="left" class="cellrowborder" valign="top" width="18%" id="mcps1.3.2.3.2.2.5.1.1"><p id="modelarts_03_0077__p30350749181639">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="16%" id="mcps1.3.2.3.2.2.5.1.2"><p id="modelarts_03_0077__p42491604181639">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="13%" id="mcps1.3.2.3.2.2.5.1.3"><p id="modelarts_03_0077__p19267891181639">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="53%" id="mcps1.3.2.3.2.2.5.1.4"><p id="modelarts_03_0077__p17195363181639">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="modelarts_03_0077__row6770181628"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.2.3.2.2.5.1.1 "><p id="modelarts_03_0077__p8780885181639">project_id</p>
</td>
<td class="cellrowborder" valign="top" width="16%" headers="mcps1.3.2.3.2.2.5.1.2 "><p id="modelarts_03_0077__p40163046181639">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="13%" headers="mcps1.3.2.3.2.2.5.1.3 "><p id="modelarts_03_0077__p31981288181639">String</p>
</td>
<td class="cellrowborder" valign="top" width="53%" headers="mcps1.3.2.3.2.2.5.1.4 "><p id="modelarts_03_0077__p40347522181639">Project ID. For details about how to obtain a project ID, see <a href="modelarts_03_0147.html">Obtaining a Project ID and Name</a>.</p>
</td>
</tr>
</tbody>
</table>
</div>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="modelarts_03_0077__table2918868102420" frame="border" border="1" rules="all"><caption><b>Table 2 </b>Search parameters</caption><thead align="left"><tr id="modelarts_03_0077__row46282814102420"><th align="left" class="cellrowborder" valign="top" width="18%" id="mcps1.3.2.3.3.2.5.1.1"><p id="modelarts_03_0077__p58767362102449">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="16%" id="mcps1.3.2.3.3.2.5.1.2"><p id="modelarts_03_0077__p62535864102449">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="13%" id="mcps1.3.2.3.3.2.5.1.3"><p id="modelarts_03_0077__p32240260102449">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="53%" id="mcps1.3.2.3.3.2.5.1.4"><p id="modelarts_03_0077__p61324235102449">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="modelarts_03_0077__row55399715102420"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.2.3.3.2.5.1.1 "><p id="modelarts_03_0077__p032273713366">model_name</p>
</td>
<td class="cellrowborder" valign="top" width="16%" headers="mcps1.3.2.3.3.2.5.1.2 "><p id="modelarts_03_0077__p73258373366">No</p>
</td>
<td class="cellrowborder" valign="top" width="13%" headers="mcps1.3.2.3.3.2.5.1.3 "><p id="modelarts_03_0077__p232723763614">String</p>
</td>
<td class="cellrowborder" valign="top" width="53%" headers="mcps1.3.2.3.3.2.5.1.4 "><p id="modelarts_03_0077__p173291637153620">Model name. Fuzzy match is supported.</p>
<div class="note" id="modelarts_03_0077__note389714933115"><span class="notetitle"> NOTE: </span><div class="notebody"><p id="modelarts_03_0077__p6897164913318">If a model name contains an underscore (_), add the <strong id="modelarts_03_0077__b530211261292">exact_match</strong> parameter to the request and set the parameter value to <strong id="modelarts_03_0077__b109110125182">true</strong> because the underscore needs to be escaped. This ensures that the query operation can be performed properly.</p>
</div></div>
</td>
</tr>
<tr id="modelarts_03_0077__row17457519102420"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.2.3.3.2.5.1.1 "><p id="modelarts_03_0077__p633310373369">model_version</p>
</td>
<td class="cellrowborder" valign="top" width="16%" headers="mcps1.3.2.3.3.2.5.1.2 "><p id="modelarts_03_0077__p10334153763618">No</p>
</td>
<td class="cellrowborder" valign="top" width="13%" headers="mcps1.3.2.3.3.2.5.1.3 "><p id="modelarts_03_0077__p10337173753615">String</p>
</td>
<td class="cellrowborder" valign="top" width="53%" headers="mcps1.3.2.3.3.2.5.1.4 "><p id="modelarts_03_0077__p153391237143610">Model version</p>
</td>
</tr>
<tr id="modelarts_03_0077__row18276139113012"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.2.3.3.2.5.1.1 "><p id="modelarts_03_0077__p1427689133019">model_status</p>
</td>
<td class="cellrowborder" valign="top" width="16%" headers="mcps1.3.2.3.3.2.5.1.2 "><p id="modelarts_03_0077__p1346282320309">No</p>
</td>
<td class="cellrowborder" valign="top" width="13%" headers="mcps1.3.2.3.3.2.5.1.3 "><p id="modelarts_03_0077__p124651223153017">String</p>
</td>
<td class="cellrowborder" valign="top" width="53%" headers="mcps1.3.2.3.3.2.5.1.4 "><p id="modelarts_03_0077__p157675915266">Model status. You can query models based on the model status. Options:</p>
<ul id="modelarts_03_0077__ul25511217271"><li id="modelarts_03_0077__li8429259272"><strong id="modelarts_03_0077__b159471913114819">Publishing</strong></li><li id="modelarts_03_0077__li1256119815273"><strong id="modelarts_03_0077__b68371617204813">Published</strong></li><li id="modelarts_03_0077__li175516212716"><strong id="modelarts_03_0077__b10500133104820">Failed</strong></li><li id="modelarts_03_0077__li1211171715519"><strong id="modelarts_03_0077__b17908246184814">Building</strong></li><li id="modelarts_03_0077__li282772395113"><strong id="modelarts_03_0077__b19692755164813">Building_failed</strong></li></ul>
</td>
</tr>
<tr id="modelarts_03_0077__row1822114174564"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.2.3.3.2.5.1.1 "><p id="modelarts_03_0077__p10222017205610">model_type</p>
</td>
<td class="cellrowborder" valign="top" width="16%" headers="mcps1.3.2.3.3.2.5.1.2 "><p id="modelarts_03_0077__p222211712560">No</p>
</td>
<td class="cellrowborder" valign="top" width="13%" headers="mcps1.3.2.3.3.2.5.1.3 "><p id="modelarts_03_0077__p1922291714567">String</p>
</td>
<td class="cellrowborder" valign="top" width="53%" headers="mcps1.3.2.3.3.2.5.1.4 "><p id="modelarts_03_0077__p20222161785617">Model type. The models of this type are queried. <strong id="modelarts_03_0077__b1834819179212">model_type</strong> and <strong id="modelarts_03_0077__b1446915211621">not_model_type</strong> are mutually exclusive and cannot co-exist.</p>
</td>
</tr>
<tr id="modelarts_03_0077__row19667547566"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.2.3.3.2.5.1.1 "><p id="modelarts_03_0077__p15663545561">not_model_type</p>
</td>
<td class="cellrowborder" valign="top" width="16%" headers="mcps1.3.2.3.3.2.5.1.2 "><p id="modelarts_03_0077__p7663543562">No</p>
</td>
<td class="cellrowborder" valign="top" width="13%" headers="mcps1.3.2.3.3.2.5.1.3 "><p id="modelarts_03_0077__p9669541568">String</p>
</td>
<td class="cellrowborder" valign="top" width="53%" headers="mcps1.3.2.3.3.2.5.1.4 "><p id="modelarts_03_0077__p86645410560">Model type. A list of models of types except for this type are queried.</p>
</td>
</tr>
<tr id="modelarts_03_0077__row14692786102420"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.2.3.3.2.5.1.1 "><p id="modelarts_03_0077__p4343143713369">description</p>
</td>
<td class="cellrowborder" valign="top" width="16%" headers="mcps1.3.2.3.3.2.5.1.2 "><p id="modelarts_03_0077__p183451737133617">No</p>
</td>
<td class="cellrowborder" valign="top" width="13%" headers="mcps1.3.2.3.3.2.5.1.3 "><p id="modelarts_03_0077__p1934783743610">String</p>
</td>
<td class="cellrowborder" valign="top" width="53%" headers="mcps1.3.2.3.3.2.5.1.4 "><p id="modelarts_03_0077__p1435093723618">Description. Fuzzy match is supported.</p>
</td>
</tr>
<tr id="modelarts_03_0077__row64535694102420"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.2.3.3.2.5.1.1 "><p id="modelarts_03_0077__p7353143716365">offset</p>
</td>
<td class="cellrowborder" valign="top" width="16%" headers="mcps1.3.2.3.3.2.5.1.2 "><p id="modelarts_03_0077__p63561237183614">No</p>
</td>
<td class="cellrowborder" valign="top" width="13%" headers="mcps1.3.2.3.3.2.5.1.3 "><p id="modelarts_03_0077__p193582037143618">Integer</p>
</td>
<td class="cellrowborder" valign="top" width="53%" headers="mcps1.3.2.3.3.2.5.1.4 "><p id="modelarts_03_0077__p15361137193610">Index of the page to be queried. Default value: <strong id="modelarts_03_0077__b1811210588269">0</strong></p>
</td>
</tr>
<tr id="modelarts_03_0077__row32737003102420"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.2.3.3.2.5.1.1 "><p id="modelarts_03_0077__p193633378362">limit</p>
</td>
<td class="cellrowborder" valign="top" width="16%" headers="mcps1.3.2.3.3.2.5.1.2 "><p id="modelarts_03_0077__p12366113711366">No</p>
</td>
<td class="cellrowborder" valign="top" width="13%" headers="mcps1.3.2.3.3.2.5.1.3 "><p id="modelarts_03_0077__p1368173713364">Integer</p>
</td>
<td class="cellrowborder" valign="top" width="53%" headers="mcps1.3.2.3.3.2.5.1.4 "><p id="modelarts_03_0077__p33701437133612">Maximum number of records returned on each page. The default value is <span class="parmname" id="modelarts_03_0077__parmname37221194272"><b>100</b></span>. The recommended value ranges from 10 to 50.</p>
</td>
</tr>
<tr id="modelarts_03_0077__row21262393102420"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.2.3.3.2.5.1.1 "><p id="modelarts_03_0077__p19826207163712">sort_by</p>
</td>
<td class="cellrowborder" valign="top" width="16%" headers="mcps1.3.2.3.3.2.5.1.2 "><p id="modelarts_03_0077__p1682827203720">No</p>
</td>
<td class="cellrowborder" valign="top" width="13%" headers="mcps1.3.2.3.3.2.5.1.3 "><p id="modelarts_03_0077__p28301979378">String</p>
</td>
<td class="cellrowborder" valign="top" width="53%" headers="mcps1.3.2.3.3.2.5.1.4 "><p id="modelarts_03_0077__p1983417703719">Sorting mode. The value can be <strong id="modelarts_03_0077__b14250512793">create_at</strong>, <strong id="modelarts_03_0077__b112503128915">model_version</strong>, or <strong id="modelarts_03_0077__b20250612597">model_size</strong>. Default value: <strong id="modelarts_03_0077__b225016121392">create_at</strong></p>
</td>
</tr>
<tr id="modelarts_03_0077__row770125319364"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.2.3.3.2.5.1.1 "><p id="modelarts_03_0077__p583714716371">order</p>
</td>
<td class="cellrowborder" valign="top" width="16%" headers="mcps1.3.2.3.3.2.5.1.2 "><p id="modelarts_03_0077__p683967153712">No</p>
</td>
<td class="cellrowborder" valign="top" width="13%" headers="mcps1.3.2.3.3.2.5.1.3 "><p id="modelarts_03_0077__p684214743715">String</p>
</td>
<td class="cellrowborder" valign="top" width="53%" headers="mcps1.3.2.3.3.2.5.1.4 "><p id="modelarts_03_0077__p7845157183717">Sorting order. The value can be <strong id="modelarts_03_0077__b75531419288">asc</strong> or <strong id="modelarts_03_0077__b455316442814">desc</strong>, indicating ascending or descending order. Default value: <strong id="modelarts_03_0077__b155317412813">desc</strong></p>
</td>
</tr>
<tr id="modelarts_03_0077__row204631612191016"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.2.3.3.2.5.1.1 "><p id="modelarts_03_0077__p134631412111013">workspace_id</p>
</td>
<td class="cellrowborder" valign="top" width="16%" headers="mcps1.3.2.3.3.2.5.1.2 "><p id="modelarts_03_0077__p11463512151015">No</p>
</td>
<td class="cellrowborder" valign="top" width="13%" headers="mcps1.3.2.3.3.2.5.1.3 "><p id="modelarts_03_0077__p44631112201017">String</p>
</td>
<td class="cellrowborder" valign="top" width="53%" headers="mcps1.3.2.3.3.2.5.1.4 "><p id="modelarts_03_0077__en-us_topic_0129882788_p20547154811">ID of the workspace to which a service belongs. The default value is <span class="parmname" id="modelarts_03_0077__parmname88931452152410"><b>0</b></span>, indicating the default workspace. </p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
<div class="section" id="modelarts_03_0077__section71456147333"><h4 class="sectiontitle">Request Body</h4><p id="modelarts_03_0077__p532504891913">None</p>
</div>
<div class="section" id="modelarts_03_0077__section54078976"><h4 class="sectiontitle">Response Body</h4><div class="p" id="modelarts_03_0077__p1074317586198"><a href="#modelarts_03_0077__table1954662185412">Table 3</a> describes the response parameters.
<div class="tablenoborder"><a name="modelarts_03_0077__table1954662185412"></a><a name="table1954662185412"></a><table cellpadding="4" cellspacing="0" summary="" id="modelarts_03_0077__table1954662185412" frame="border" border="1" rules="all"><caption><b>Table 3 </b>Parameters</caption><thead align="left"><tr id="modelarts_03_0077__row555142175415"><th align="left" class="cellrowborder" valign="top" width="18%" id="mcps1.3.4.2.2.2.4.1.1"><p id="modelarts_03_0077__p1155315211549">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="18%" id="mcps1.3.4.2.2.2.4.1.2"><p id="modelarts_03_0077__p1355662195410">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="64%" id="mcps1.3.4.2.2.2.4.1.3"><p id="modelarts_03_0077__p1055820214544">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="modelarts_03_0077__row141584191611"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.2.2.4.1.1 "><p id="modelarts_03_0077__p2041594201612">total_count</p>
</td>
<td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.2.2.4.1.2 "><p id="modelarts_03_0077__p1541514441617">Integer</p>
</td>
<td class="cellrowborder" valign="top" width="64%" headers="mcps1.3.4.2.2.2.4.1.3 "><p id="modelarts_03_0077__p184151649168">Total number of models that meet the search criteria when no paging is implemented</p>
</td>
</tr>
<tr id="modelarts_03_0077__row1560152115412"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.2.2.4.1.1 "><p id="modelarts_03_0077__p1656210235418">count</p>
</td>
<td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.2.2.4.1.2 "><p id="modelarts_03_0077__p2056412225411">Integer</p>
</td>
<td class="cellrowborder" valign="top" width="64%" headers="mcps1.3.4.2.2.2.4.1.3 "><p id="modelarts_03_0077__p15651629549">Number of models</p>
</td>
</tr>
<tr id="modelarts_03_0077__row17566112185418"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.2.2.4.1.1 "><p id="modelarts_03_0077__p956913235417">models</p>
</td>
<td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.2.2.4.1.2 "><p id="modelarts_03_0077__p145716225416"><strong id="modelarts_03_0077__b7161256173120">model</strong> array</p>
</td>
<td class="cellrowborder" valign="top" width="64%" headers="mcps1.3.4.2.2.2.4.1.3 "><p id="modelarts_03_0077__p1657311215420">Model metadata. For details, see <a href="#modelarts_03_0077__table1198992710540">Table 4</a>.</p>
</td>
</tr>
</tbody>
</table>
</div>
<div class="tablenoborder"><a name="modelarts_03_0077__table1198992710540"></a><a name="table1198992710540"></a><table cellpadding="4" cellspacing="0" summary="" id="modelarts_03_0077__table1198992710540" frame="border" border="1" rules="all"><caption><b>Table 4 </b><strong id="modelarts_03_0077__b139837123219">model</strong> parameters</caption><thead align="left"><tr id="modelarts_03_0077__row129943277545"><th align="left" class="cellrowborder" valign="top" width="18%" id="mcps1.3.4.2.3.2.4.1.1"><p id="modelarts_03_0077__p13997192714544">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="14.000000000000002%" id="mcps1.3.4.2.3.2.4.1.2"><p id="modelarts_03_0077__p120128155419">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="68%" id="mcps1.3.4.2.3.2.4.1.3"><p id="modelarts_03_0077__p1821528145411">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="modelarts_03_0077__row1252028165418"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.3.2.4.1.1 "><p id="modelarts_03_0077__p87228135417">model_id</p>
</td>
<td class="cellrowborder" valign="top" width="14.000000000000002%" headers="mcps1.3.4.2.3.2.4.1.2 "><p id="modelarts_03_0077__p8101228145417">String</p>
</td>
<td class="cellrowborder" valign="top" width="68%" headers="mcps1.3.4.2.3.2.4.1.3 "><p id="modelarts_03_0077__p711182814549">Model ID</p>
</td>
</tr>
<tr id="modelarts_03_0077__row012112817546"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.3.2.4.1.1 "><p id="modelarts_03_0077__p6148282540">model_name</p>
</td>
<td class="cellrowborder" valign="top" width="14.000000000000002%" headers="mcps1.3.4.2.3.2.4.1.2 "><p id="modelarts_03_0077__p31602825420">String</p>
</td>
<td class="cellrowborder" valign="top" width="68%" headers="mcps1.3.4.2.3.2.4.1.3 "><p id="modelarts_03_0077__p161852845411">Model name</p>
</td>
</tr>
<tr id="modelarts_03_0077__row16191728145416"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.3.2.4.1.1 "><p id="modelarts_03_0077__p192172820548">model_version</p>
</td>
<td class="cellrowborder" valign="top" width="14.000000000000002%" headers="mcps1.3.4.2.3.2.4.1.2 "><p id="modelarts_03_0077__p622528175416">String</p>
</td>
<td class="cellrowborder" valign="top" width="68%" headers="mcps1.3.4.2.3.2.4.1.3 "><p id="modelarts_03_0077__p624172818545">Model version</p>
</td>
</tr>
<tr id="modelarts_03_0077__row8908533586"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.3.2.4.1.1 "><p id="modelarts_03_0077__p391853195813">model_status</p>
</td>
<td class="cellrowborder" valign="top" width="14.000000000000002%" headers="mcps1.3.4.2.3.2.4.1.2 "><p id="modelarts_03_0077__p139135395814">String</p>
</td>
<td class="cellrowborder" valign="top" width="68%" headers="mcps1.3.4.2.3.2.4.1.3 "><p id="modelarts_03_0077__p1391145395815">Model status</p>
</td>
</tr>
<tr id="modelarts_03_0077__row1525142811547"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.3.2.4.1.1 "><p id="modelarts_03_0077__p327728165415">model_type</p>
</td>
<td class="cellrowborder" valign="top" width="14.000000000000002%" headers="mcps1.3.4.2.3.2.4.1.2 "><p id="modelarts_03_0077__p1329428145418">String</p>
</td>
<td class="cellrowborder" valign="top" width="68%" headers="mcps1.3.4.2.3.2.4.1.3 "><p id="modelarts_03_0077__p160204118332">Model type. The value can be <strong id="modelarts_03_0077__b88101433194713">TensorFlow</strong> or <strong id="modelarts_03_0077__b74741936104717">Image</strong>.</p>
</td>
</tr>
<tr id="modelarts_03_0077__row132128115411"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.3.2.4.1.1 "><p id="modelarts_03_0077__p533528195413">model_size</p>
</td>
<td class="cellrowborder" valign="top" width="14.000000000000002%" headers="mcps1.3.4.2.3.2.4.1.2 "><p id="modelarts_03_0077__p337528165418">Long</p>
</td>
<td class="cellrowborder" valign="top" width="68%" headers="mcps1.3.4.2.3.2.4.1.3 "><p id="modelarts_03_0077__p203813280543">Model size, in bytes</p>
</td>
</tr>
<tr id="modelarts_03_0077__row133919286541"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.3.2.4.1.1 "><p id="modelarts_03_0077__p9416286543">tenant</p>
</td>
<td class="cellrowborder" valign="top" width="14.000000000000002%" headers="mcps1.3.4.2.3.2.4.1.2 "><p id="modelarts_03_0077__p114362817541">String</p>
</td>
<td class="cellrowborder" valign="top" width="68%" headers="mcps1.3.4.2.3.2.4.1.3 "><p id="modelarts_03_0077__p1445228205417">Tenant to which a model belongs</p>
</td>
</tr>
<tr id="modelarts_03_0077__row246122815417"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.3.2.4.1.1 "><p id="modelarts_03_0077__p848112835416">project</p>
</td>
<td class="cellrowborder" valign="top" width="14.000000000000002%" headers="mcps1.3.4.2.3.2.4.1.2 "><p id="modelarts_03_0077__p1849202845413">String</p>
</td>
<td class="cellrowborder" valign="top" width="68%" headers="mcps1.3.4.2.3.2.4.1.3 "><p id="modelarts_03_0077__p1951528105412">Project to which a model belongs</p>
</td>
</tr>
<tr id="modelarts_03_0077__row1052028205417"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.3.2.4.1.1 "><p id="modelarts_03_0077__p20542289540">owner</p>
</td>
<td class="cellrowborder" valign="top" width="14.000000000000002%" headers="mcps1.3.4.2.3.2.4.1.2 "><p id="modelarts_03_0077__p256328145419">String</p>
</td>
<td class="cellrowborder" valign="top" width="68%" headers="mcps1.3.4.2.3.2.4.1.3 "><p id="modelarts_03_0077__p659122855415">User to which a model belongs</p>
</td>
</tr>
<tr id="modelarts_03_0077__row66052812541"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.3.2.4.1.1 "><p id="modelarts_03_0077__p106262895412">create_at</p>
</td>
<td class="cellrowborder" valign="top" width="14.000000000000002%" headers="mcps1.3.4.2.3.2.4.1.2 "><p id="modelarts_03_0077__p2645289548">Long</p>
</td>
<td class="cellrowborder" valign="top" width="68%" headers="mcps1.3.4.2.3.2.4.1.3 "><p id="modelarts_03_0077__p26692819547">Time when a model is created, in milliseconds calculated from 1970.1.1 0:0:0 UTC</p>
</td>
</tr>
<tr id="modelarts_03_0077__row16717283548"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.3.2.4.1.1 "><p id="modelarts_03_0077__p1469152895410">description</p>
</td>
<td class="cellrowborder" valign="top" width="14.000000000000002%" headers="mcps1.3.4.2.3.2.4.1.2 "><p id="modelarts_03_0077__p271192865410">String</p>
</td>
<td class="cellrowborder" valign="top" width="68%" headers="mcps1.3.4.2.3.2.4.1.3 "><p id="modelarts_03_0077__p272102895411">Model description</p>
</td>
</tr>
<tr id="modelarts_03_0077__row157447751519"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.3.2.4.1.1 "><p id="modelarts_03_0077__p97448712154">workspace_id</p>
</td>
<td class="cellrowborder" valign="top" width="14.000000000000002%" headers="mcps1.3.4.2.3.2.4.1.2 "><p id="modelarts_03_0077__p12744276159">String</p>
</td>
<td class="cellrowborder" valign="top" width="68%" headers="mcps1.3.4.2.3.2.4.1.3 "><p id="modelarts_03_0077__p16744127141519">Workspace ID</p>
</td>
</tr>
<tr id="modelarts_03_0077__row115831227142320"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.3.2.4.1.1 "><p id="modelarts_03_0077__p4892440122314">model_source</p>
</td>
<td class="cellrowborder" valign="top" width="14.000000000000002%" headers="mcps1.3.4.2.3.2.4.1.2 "><p id="modelarts_03_0077__p55848277230">String</p>
</td>
<td class="cellrowborder" valign="top" width="68%" headers="mcps1.3.4.2.3.2.4.1.3 "><p id="modelarts_03_0077__p761173813256">Model source. Options:</p>
<ul id="modelarts_03_0077__ul153321841152519"><li id="modelarts_03_0077__li1154795832511"><strong id="modelarts_03_0077__b158318147182">algos</strong>: built-in algorithm</li><li id="modelarts_03_0077__li1533284114255"><strong id="modelarts_03_0077__b17441132101817">custom</strong>: custom model</li></ul>
</td>
</tr>
<tr id="modelarts_03_0077__row178886301232"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.3.2.4.1.1 "><p id="modelarts_03_0077__p11888130112319">tunable</p>
</td>
<td class="cellrowborder" valign="top" width="14.000000000000002%" headers="mcps1.3.4.2.3.2.4.1.2 "><p id="modelarts_03_0077__p108889307237">Boolean</p>
</td>
<td class="cellrowborder" valign="top" width="68%" headers="mcps1.3.4.2.3.2.4.1.3 "><p id="modelarts_03_0077__p43016243269">Whether a model can be tuned. Options:</p>
<ul id="modelarts_03_0077__ul2729142515267"><li id="modelarts_03_0077__li12469732162614"><strong id="modelarts_03_0077__b166241650141910">true</strong>: yes</li><li id="modelarts_03_0077__li7729425102615"><strong id="modelarts_03_0077__b175867162013">false</strong>: no</li></ul>
</td>
</tr>
<tr id="modelarts_03_0077__row17482193515231"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.3.2.4.1.1 "><p id="modelarts_03_0077__p13482203582316">market_flag</p>
</td>
<td class="cellrowborder" valign="top" width="14.000000000000002%" headers="mcps1.3.4.2.3.2.4.1.2 "><p id="modelarts_03_0077__p448283532314">Boolean</p>
</td>
<td class="cellrowborder" valign="top" width="68%" headers="mcps1.3.4.2.3.2.4.1.3 "><p id="modelarts_03_0077__p330104432617">Whether a model is subscribed from the marketplace. Options:</p>
<ul id="modelarts_03_0077__ul74991746182614"><li id="modelarts_03_0077__li468914528260"><strong id="modelarts_03_0077__b191161514201">true</strong>: yes</li><li id="modelarts_03_0077__li2499154662612"><strong id="modelarts_03_0077__b878194172120">false</strong>: no</li></ul>
</td>
</tr>
<tr id="modelarts_03_0077__row18384143852313"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.3.2.4.1.1 "><p id="modelarts_03_0077__p15573114620241">publishable_flag</p>
</td>
<td class="cellrowborder" valign="top" width="14.000000000000002%" headers="mcps1.3.4.2.3.2.4.1.2 "><p id="modelarts_03_0077__p11384173816231">Boolean</p>
</td>
<td class="cellrowborder" valign="top" width="68%" headers="mcps1.3.4.2.3.2.4.1.3 "><p id="modelarts_03_0077__p19581422273">Whether a model can be published to the marketplace. Options:</p>
<ul id="modelarts_03_0077__ul16436548273"><li id="modelarts_03_0077__li148121812152718"><strong id="modelarts_03_0077__b16875115011214">true</strong>: yes</li><li id="modelarts_03_0077__li134368432714"><strong id="modelarts_03_0077__b98337013222">false</strong>: no</li></ul>
</td>
</tr>
<tr id="modelarts_03_0077__row052696165817"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.3.2.4.1.1 "><p id="modelarts_03_0077__p13996514588">install_type</p>
</td>
<td class="cellrowborder" valign="top" width="14.000000000000002%" headers="mcps1.3.4.2.3.2.4.1.2 "><p id="modelarts_03_0077__p6399165195819">String array</p>
</td>
<td class="cellrowborder" valign="top" width="68%" headers="mcps1.3.4.2.3.2.4.1.3 "><p id="modelarts_03_0077__p15550934579">Model deployment type, determining which service a model can be deployed as. Possible values are <span class="parmname" id="modelarts_03_0077__parmname483912391673"><b>real-time</b></span> (real-time service) and <span class="parmname" id="modelarts_03_0077__parmname1010223015312"><b>batch</b></span> (batch service).</p>
</td>
</tr>
<tr id="modelarts_03_0077__row15787510264"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.3.2.4.1.1 "><p id="modelarts_03_0077__p1557855115262">subscription_id</p>
</td>
<td class="cellrowborder" valign="top" width="14.000000000000002%" headers="mcps1.3.4.2.3.2.4.1.2 "><p id="modelarts_03_0077__p45781951152613">String</p>
</td>
<td class="cellrowborder" valign="top" width="68%" headers="mcps1.3.4.2.3.2.4.1.3 "><p id="modelarts_03_0077__p857995182615">Model subscription ID.</p>
</td>
</tr>
<tr id="modelarts_03_0077__row1866535920270"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.3.2.4.1.1 "><p id="modelarts_03_0077__p266515910273">extra</p>
</td>
<td class="cellrowborder" valign="top" width="14.000000000000002%" headers="mcps1.3.4.2.3.2.4.1.2 "><p id="modelarts_03_0077__p16651459122711">String</p>
</td>
<td class="cellrowborder" valign="top" width="68%" headers="mcps1.3.4.2.3.2.4.1.3 "><p id="modelarts_03_0077__p1766585962710">Extended field.</p>
</td>
</tr>
<tr id="modelarts_03_0077__row129421135451"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.3.2.4.1.1 "><p id="modelarts_03_0077__p149421134458">source_type</p>
</td>
<td class="cellrowborder" valign="top" width="14.000000000000002%" headers="mcps1.3.4.2.3.2.4.1.2 "><p id="modelarts_03_0077__p6942163114514">String</p>
</td>
<td class="cellrowborder" valign="top" width="68%" headers="mcps1.3.4.2.3.2.4.1.3 "><p id="modelarts_03_0077__p20942173104512">Model source type. This parameter is valid and its value is <strong id="modelarts_03_0077__b566614274557">auto</strong> only if the model is deployed using ExeML.</p>
</td>
</tr>
<tr id="modelarts_03_0077__row20719138164618"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.4.2.3.2.4.1.1 "><p id="modelarts_03_0077__p127192817462">specification</p>
</td>
<td class="cellrowborder" valign="top" width="14.000000000000002%" headers="mcps1.3.4.2.3.2.4.1.2 "><p id="modelarts_03_0077__p1719489468">Object</p>
</td>
<td class="cellrowborder" valign="top" width="68%" headers="mcps1.3.4.2.3.2.4.1.3 "><p id="modelarts_03_0077__p37193820462">Minimum deployment specification. For details, see <a href="#modelarts_03_0077__table1669514411217">Table 5</a>.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="tablenoborder"><a name="modelarts_03_0077__table1669514411217"></a><a name="table1669514411217"></a><table cellpadding="4" cellspacing="0" summary="" id="modelarts_03_0077__table1669514411217" frame="border" border="1" rules="all"><caption><b>Table 5 </b><strong id="modelarts_03_0077__b25641936115015">Specification</strong> parameters</caption><thead align="left"><tr id="modelarts_03_0077__row1069517443213"><th align="left" class="cellrowborder" valign="top" width="17.82178217821782%" id="mcps1.3.4.3.2.4.1.1"><p id="modelarts_03_0077__p2696174432118">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="13.861386138613863%" id="mcps1.3.4.3.2.4.1.2"><p id="modelarts_03_0077__p769634452112">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="68.31683168316832%" id="mcps1.3.4.3.2.4.1.3"><p id="modelarts_03_0077__p86961944152116">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="modelarts_03_0077__row1697114416217"><td class="cellrowborder" valign="top" width="17.82178217821782%" headers="mcps1.3.4.3.2.4.1.1 "><p id="modelarts_03_0077__p969714417210">min_cpu</p>
</td>
<td class="cellrowborder" valign="top" width="13.861386138613863%" headers="mcps1.3.4.3.2.4.1.2 "><p id="modelarts_03_0077__p4697174432114">String</p>
</td>
<td class="cellrowborder" valign="top" width="68.31683168316832%" headers="mcps1.3.4.3.2.4.1.3 "><p id="modelarts_03_0077__p2697154402119">Minimal CPU specifications</p>
</td>
</tr>
<tr id="modelarts_03_0077__row1669716446216"><td class="cellrowborder" valign="top" width="17.82178217821782%" headers="mcps1.3.4.3.2.4.1.1 "><p id="modelarts_03_0077__p1969713449217">min_gpu</p>
</td>
<td class="cellrowborder" valign="top" width="13.861386138613863%" headers="mcps1.3.4.3.2.4.1.2 "><p id="modelarts_03_0077__p0697194411210">String</p>
</td>
<td class="cellrowborder" valign="top" width="68.31683168316832%" headers="mcps1.3.4.3.2.4.1.3 "><p id="modelarts_03_0077__p17697154442117">Minimal GPU specifications</p>
</td>
</tr>
<tr id="modelarts_03_0077__row1069764442118"><td class="cellrowborder" valign="top" width="17.82178217821782%" headers="mcps1.3.4.3.2.4.1.1 "><p id="modelarts_03_0077__p3697744142117">min_memory</p>
</td>
<td class="cellrowborder" valign="top" width="13.861386138613863%" headers="mcps1.3.4.3.2.4.1.2 "><p id="modelarts_03_0077__p1969710444218">String</p>
</td>
<td class="cellrowborder" valign="top" width="68.31683168316832%" headers="mcps1.3.4.3.2.4.1.3 "><p id="modelarts_03_0077__p5697124402111">Minimum memory capacity</p>
</td>
</tr>
<tr id="modelarts_03_0077__row1569764412113"><td class="cellrowborder" valign="top" width="17.82178217821782%" headers="mcps1.3.4.3.2.4.1.1 "><p id="modelarts_03_0077__p14698644132115">min_ascend</p>
</td>
<td class="cellrowborder" valign="top" width="13.861386138613863%" headers="mcps1.3.4.3.2.4.1.2 "><p id="modelarts_03_0077__p156988449216">String</p>
</td>
<td class="cellrowborder" valign="top" width="68.31683168316832%" headers="mcps1.3.4.3.2.4.1.3 "><p id="modelarts_03_0077__p1169824422117">Minimal Ascend specifications</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="modelarts_03_0077__section1810193414711"><h4 class="sectiontitle">Samples</h4><p id="modelarts_03_0077__p1626113524475">The following shows how to query models.</p>
</div>
<ul id="modelarts_03_0077__ul11661134735818"><li id="modelarts_03_0077__li8663184755814">Sample request<pre class="screen" id="modelarts_03_0077__screen546819391982">GET https://endpoint/v1/{project_id}/models</pre>
</li></ul>
<ul id="modelarts_03_0077__ul163453474715"><li id="modelarts_03_0077__li1533103454717">Sample response<pre class="screen" id="modelarts_03_0077__screen1745564317818"> {
"total_count": 1,
"count": 1,
"models": [
{
"model_name": "mnist",
"model_version": "1.0.0",
"model_id": "10eb0091-887f-4839-9929-cbc884f1e20e",
"model_type": "tensorflow",
"model_size": 5012312,
"tenant": "6d28e85aa78b4e1a9b4bd83501bcd4a1",
"project": "d04c10db1f264cfeb1966deff1a3527c",
"owner": "6d28e85aa78b4e1a9b4bd83501bcd4a1",
"create_at": 1533041553000,
"description": "mnist model",
"workspace_id": "0",
"specification":{}
}
]
}</pre>
</li></ul>
<div class="section" id="modelarts_03_0077__section16948739"><h4 class="sectiontitle">Status Code</h4><p id="modelarts_03_0077__p1731954913014">For details about the status code, see <a href="modelarts_03_0094.html#modelarts_03_0094__table1450010510213">Table 1</a>.</p>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="modelarts_03_0153.html">Model Management</a></div>
</div>
</div>