Note
This variable is available starting with V4.3.3. It is supported only for MySQL tenants.
Description
ob_hnsw_ef_search specifies the number of neighbor points that the HNSW algorithm searches for in each layer of the graph during vector index queries. A larger value means that the algorithm explores more neighbor points, increasing the chances of finding the true nearest neighbors and thus improving search accuracy. However, this also increases the search time.
Privilege requirements
Query variables
The
systenant and all user tenants can use theSHOW VARIABLESstatement or theinformation_schema.SESSION_VARIABLESview (MySQL mode) to view the values of session system variables.Modify variables
The
systenant and all MySQL user tenants can directly modify the values of session system variables for their own tenants.
Attributes
| Attribute | Description |
|---|---|
| Type | Uint |
| Default value | 64 |
| Value range | [1,1000] |
| Scope | Session |
| Modifiable | Yes. You can execute the SET statement to modify the value. |
Examples
Set the number of neighbor points that the HNSW algorithm searches for in each layer of the graph during vector index queries to 50.
obclient> SET ob_hnsw_ef_search = 50;
