Modifies an index table.
Operation description
Method
PUT
URI
/openapi/ha3/instances/{instanceId}/tables/{tableName}
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
searchengine:ModifyTable |
update |
*Instance
|
None | None |
Request syntax
PUT /openapi/ha3/instances/{instanceId}/tables/{tableName} HTTP/1.1
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| instanceId |
string |
Yes |
The instance ID. |
ha-cn-pl32rf0**** |
| tableName |
string |
Yes |
The name of the index table. |
index_hdfs |
| dryRun |
boolean |
No |
Specifies whether to perform a dry run. A dry run checks if the data source is valid. Valid values: true and false. |
true |
| body |
object |
No |
The request body. |
|
| partitionCount |
integer |
No |
The number of data shards. |
1 |
| dataSource |
object |
No |
The data source configuration. |
|
| dataTimeSec |
integer |
No |
The UNIX timestamp for incremental data. |
1715160176 |
| autoBuildIndex |
boolean |
No |
Specifies whether to automatically rebuild the index. |
true |
| config |
object |
No |
The data source configuration. |
|
| endpoint |
string |
No |
The endpoint. |
http://service.cn-hangzhou.maxcompute.aliyun-inc.com/api |
| accessKey |
string |
No |
The AccessKey ID of the MaxCompute data source. |
L***p |
| accessSecret |
string |
No |
The AccessKey secret of the MaxCompute data source. |
5**9a6 |
| project |
string |
No |
The name of the MaxCompute project. |
test_project |
| partition |
string |
No |
The partition information. |
ds=20231220 |
| table |
string |
No |
The name of the table in the MaxCompute or Data Lake Formation (DLF) data source. |
behavior |
| ossPath |
string |
No |
The path of the file in OSS. |
/opensearch/test.txt |
| bucket |
string |
No |
The OSS bucket. |
test_bucket |
| catalog |
string |
No |
The name of the data catalog in the DLF data source. |
test_catalog |
| database |
string |
No |
The database in the DLF data source. |
opensearch_db |
| tag |
string |
No |
The tag for the DLF data source. |
test |
| tableFormat |
string |
No |
The table format for the DLF data source. |
paimon lance object |
| path |
string |
No |
The relative path. |
/test |
| format |
string |
No |
The file format. |
ha3 json |
| rawSchema |
string |
No |
The raw schema. If specified, this schema is used directly as the schema structure, and the system does not build one. |
{} |
| primaryKey |
string |
No |
The primary key field. |
id |
| fieldSchema |
object |
No |
A map of fields. |
|
|
string |
No |
The key is the field name and the value is the field type. |
{ "id": "INT64", "source_image": "STRING", "namespace": "INT64", "source_image_vector": "MULTI_FLOAT" } |
|
| vectorIndex |
array |
No |
The index schema. |
|
|
array<object> |
No |
The details of the index schema. |
||
| indexName |
string |
No |
The name of the index schema. |
test_index |
| vectorField |
string |
No |
The vector field. |
source_image_vector |
| sparseIndexField |
string |
No |
The field for the indexes of a sparse vector. |
sparse_indices |
| sparseValueField |
string |
No |
The field for the values of a sparse vector. |
sparse_values |
| dimension |
string |
No |
The vector dimensions. |
128 |
| vectorIndexType |
string |
No |
The vector index algorithm. |
Qc |
| distanceType |
string |
No |
The distance type. |
SquaredEuclidean |
| namespace |
string |
No |
The namespace field. |
namespace |
| advanceParams |
object |
No |
The index schema configuration. |
|
| buildIndexParams |
string |
No |
The index building parameters. |
{} |
| searchIndexParams |
string |
No |
The index retrieval parameters. |
{} |
| minScanDocCnt |
string |
No |
The minimum number of documents to retrieve for the candidate set. |
20000 |
| linearBuildThreshold |
string |
No |
The threshold for linear building. |
5000 |
| dataProcessConfig |
array |
No |
The field processing configuration. |
|
|
array<object> |
No |
The details of the field processing configuration. |
||
| operator |
string |
No |
The method for processing the field. Valid values: `copy`: copies the source field to the destination field. `vectorize`: converts the source field into a vector using a model and stores the vector in the destination field. |
vectorize |
| dstField |
string |
No |
The destination field. |
source_image_vector |
| srcField |
string |
No |
The source field. |
source_image |
| params |
object |
No |
The model configuration. |
|
| vectorModel |
string |
No |
The vectorization model. |
clip |
| vectorModal |
string |
No |
The data type. |
image |
| srcFieldConfig |
object |
No |
The source of the vectorization information. |
|
| ossEndpoint |
string |
No |
The OSS region endpoint. |
oss-cn-hangzhou-internal.aliyuncs.com |
| ossBucket |
string |
No |
The name of the OSS bucket. |
test-bucket |
| uid |
string |
No |
The ID of the Alibaba Cloud account. |
1062017779051424 |
Request example
PUT /openapi/ha3/instances/{instanceId}/tables/{tableName}
{
"partitionCount": 1,
"primaryKey": "id",
"fieldSchema": {
"id": "INT64",
"source_image": "STRING",
"namespace": "STRING",
"source_image_vector": "MULTI_FLOAT"
},
"vectorIndex": [
{
"indexName": "test_index_1",
"vectorField": "source_image_vector",
"vectorIndexType": "HNSW",
"dimension": "512",
"distanceType": "InnerProduct"
}
]
}
For more information, see Response structure.
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| requestId |
string |
The request ID. |
FE03180A-0E29-5474-8A86-33F0683294A4 |
| result |
object |
The result of the request. |
{} |
Examples
Success response
JSON format
{
"requestId": "FE03180A-0E29-5474-8A86-33F0683294A4",
"result": {}
}
Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.