Vector search (Java SDK V1)
OSS vector search lets you quickly find object files from a large collection of objects based on semantic content, OSS metadata, multimedia metadata, object ETags, tags, and custom metadata. This feature improves retrieval efficiency.
Notes
-
Only Java software development kit (SDK) versions 3.18.2 and later support the vector search feature.
-
The vector search feature is supported for buckets in the following regions: China (Qingdao), China (Beijing), China (Zhangjiakou), China (Hangzhou), China (Shanghai), China (Shenzhen), China (Guangzhou), China (Chengdu), China (Hong Kong), Singapore, Indonesia (Jakarta), Germany (Frankfurt), US (Virginia), and US (Silicon Valley).
-
In this topic, the public endpoint of the China (Hangzhou) region is used. To access OSS from other Alibaba Cloud services in the same region, use an internal endpoint. For details about supported regions and endpoints, see Regions and endpoints.
-
In this topic, access credentials are obtained from environment variables. For more information, see Configure access credentials.
-
This topic demonstrates creating an OSSClient instance with an OSS endpoint. For alternative configurations, such as using a custom domain or authenticating with credentials from Security Token Service (STS), see Client configuration.
-
By default, an Alibaba Cloud account has the permissions required to perform data indexing operations. If you want to use a Resource Access Management (RAM) user or STS to perform data indexing operations, you must have the following permissions:
-
To enable the metadata management feature, you must have the
oss:OpenMetaQuerypermission. -
To retrieve information about a metadata index, you must have the
oss:GetMetaQueryStatuspermission. -
To query for objects that meet specified conditions, you must have the
oss:DoMetaQuerypermission. -
To disable the metadata management feature, you must have the
oss:CloseMetaQuerypermission.
-
Sample code
References
-
For more information about the API operation to enable the metadata management feature, see OpenMetaQuery.
-
For more information about the API operation to retrieve information about a metadata index, see GetMetaQueryStatus.
-
For more information about the API operation to query for objects that meet specified conditions, see DoMetaQuery.
-
For more information about the API operation to disable the metadata management feature, see CloseMetaQuery.