This topic describes the build parameters and search parameters of the CAGRA algorithm.
CAGRA index build parameters
Parameter | Type | Default value | Description |
proxima.cagra.index.graph_degree | int | 64 | The number of edges per node in the nearest-neighbor graph used during the query phase. A larger value improves the recall rate but reduces performance. |
proxima.cagra.index.intermediate_graph_degree | int | 128 | The number of edges per node in the nearest-neighbor graph built during the graph construction phase. During the query phase, the graph is pruned to proxima.cagra.index.graph_degree. The value must be greater than or equal to proxima.cagra.index.graph_degree, and is generally no more than 1.5 times proxima.cagra.index.graph_degree. |
proxima.cagra.index.mode.fp16 | int | 0 | Specifies whether to enable FP16 quantization. We recommend that you set this parameter to 1 (enabled). FP16 quantization has little impact on the recall rate. |
CAGRA index search parameters
Parameter | Type | Default value | Description |
proxima.cagra.search.use_batchable_searcher | int | 0 | Executing user query requests in batches usually achieves higher efficiency than executing them one by one. If you set this option to 1 (enabled), the system automatically merges requests that arrive at about the same time within a short period into a batch for execution, which improves performance. |
proxima.cagra.search.use_gpu_built_index | int | 0 | Specifies whether to use a graph built on the CPU. Currently, this parameter can only be set to 0 (yes). |
proxima.cagra.search.itopk_size | int | 64 | Related to the size of the candidate set during algorithm iterations. The value must be a multiple of 32 and must be greater than or equal to the required topK value. For example, if the top 100 results need to be returned, the value must be greater than or equal to 100. A larger value improves the recall rate but reduces performance. |