Fix(#590): use snake_case DiskANN build params so max_degree/search_list_size are applied#670
Merged
Merged
Conversation
…ist_size are applied + README updates based on mlpstorage cli changes (pulled from PR #588)
|
MLCommons CLA bot All contributors have signed the MLCommons CLA ✍️ ✅ |
FileSystemGuy
approved these changes
Jul 4, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #590 + Pull updated README.md from PR #588
Problem
For
index_type: DISKANN, themax_degreeandsearch_list_sizevalues set inconfig.yaml(or via--max-degree/--search-list-size) had no effect on the built index. PR #497 fixed config parsing so the values reachcreate_index(),but the index was still built with engine defaults.
Root cause
As identified in issue #590 (comment),
this is a key-name case mismatch, not a
milvus.yamlserver-config limitation. knowhere's DiskANN config declares snake_case build fields (src/index/diskann/diskann_config.h:87-99) and builds withbuild_conf.max_degree.value()/build_conf.search_list_size.value()(src/index/diskann/diskann.cc:481-498). The benchmark's DISKANN branch passed CamelCase keys (MaxDegree,SearchListSize), which knowhere silently drops.The reporter's build log (configured
max_degree=72,search_list_size=137) confirms it: the snake_case fields were applied with defaults (56 / 100) while the CamelCase fields carried the configured values (72 / 137) but were ignored. HNSW and AISAQ were unaffected because their key names already match what the engine reads — the AISAQ branch was already snake_case.Changes
vdb_benchmark/vdbbench/load_vdb.pymax_degree/search_list_size(snake_case), matching the AISAQ branch; help strings updatedvdb_benchmark/vdbbench/mpi_wrapper.py_build_index_params()pathvdb_benchmark/vdbbench/benchmark/backends/milvus/backend.pyparams.get("max_degree", params.get("MaxDegree", 64))) so existing configs keep working but now take effectvdb_benchmark/vdbbench/benchmark/backends/milvus/__init__.pyParamDescriptornames renamed to snake_case so introspection advertises the working keysvdb_benchmark/vdbbench/benchmark/configs/1m_diskann.yamlvdb_benchmark/vdbbench/benchmark/backends/milvus/README.mdmlpstorage_py/cli/vectordb_args.pyNotes on scope:
run_benchmark.py:_collect_index_params()intentionally still accepts bothspellings; the backend normalizes CamelCase → snake_case, so this PR is
backward compatible with existing configs.
collection_mgr.pyalready reads both spellings for display; unchanged.Impact on submissions
Any prior DISKANN run on the affected code built its index with knowhere defaults regardless of configured values, so DISKANN "tuning" results were not actually varying build parameters. After this fix, configured values take effect — DISKANN build times and recall/QPS characteristics may legitimately change versus earlier runs with the same config. This may warrant a note in the v3.0 changelog / Rules discussion.
Validation
Start Milvus and load with clearly non-default values:
Confirm the applied build params in the Milvus/knowhere build log
(
grep -E "max_degree|search_list_size" <milvus log>): snake_case fieldsnow show
72/137instead of defaults56/100, and no ignoredCamelCase entries carry the configured values.
Confirm via index description:
Backward-compat check: run the modular framework with an old-style config containing
MaxDegree/SearchListSizeand confirm the backend normalizes and applies them (same log signature as step 2).Sanity: build-time sensitivity — with a fixed dataset,
max_degree=16vs72should now produce measurably different index build times and index file sizes, which was not the case before this fix.Regression: HNSW and AISAQ load paths unchanged (
M/efConstructionandinline_pq/max_degree/search_list_sizestill applied as before).