Skip to content

Add autotuner for benchmark parameter optimization#736

Draft
Copilot wants to merge 3 commits intomainfrom
copilot/add-autotuner-tool
Draft

Add autotuner for benchmark parameter optimization#736
Copilot wants to merge 3 commits intomainfrom
copilot/add-autotuner-tool

Conversation

Copy link
Contributor

Copilot AI commented Feb 7, 2026

The benchmark framework measures QPS/latency/recall for given configurations but lacks automated parameter tuning. This adds a tool to sweep parameters and identify optimal configurations.

Implementation

New binary: diskann-tools/bin/autotuner

  • Parameter sweep engine for max_degree (R), l_build, search_l, num_pq_chunks
  • Generates all build parameter combinations, runs benchmarks, parses results
  • Three optimization criteria: maximize QPS at target recall, minimize latency at target recall, maximize recall
  • Outputs individual configs/results plus summary with best configuration

CLI commands:

# Generate example sweep config
autotuner example --output sweep_config.json

# Run sweep
autotuner sweep \
  --base-config benchmark.json \
  --sweep-config sweep_config.json \
  --output-dir ./results \
  --criterion qps \
  --target-recall 0.95

Configuration format:

{
  "max_degree": [16, 32, 64],
  "l_build": [50, 75, 100],
  "search_l": [10, 20, 30, 40, 50],
  "num_pq_chunks": [8, 16, 32]
}

Changes

  • Add diskann-tools/src/bin/autotuner.rs - main implementation with tests
  • Add diskann-tools/AUTOTUNER.md - usage documentation
  • Update diskann-benchmark/README.md - reference autotuner
  • Update diskann-tools/Cargo.toml - add serde_json dependency
Original prompt

This section details on the original issue you should resolve

<issue_title>Create an autotuner tool on top of benchmark</issue_title>
<issue_description>## Is your feature request related to a problem? Please describe.
the repo contains a comprehensive benchmark framework that takes configuration as inputs and measures throughput (qps), latency etc. We want a tool that builds on this to sweep over a subset of parameters, for example R (graph degree), l_build, l_search, and quantization bytes where applicable, and identify the best configuration.

Describe the solution you'd like

A clear and concise description of what you want to happen.

Describe alternatives you've considered

A clear and concise description of any alternative solutions or features you've considered.

Provide references (if applicable)

If your feature request is related to a published algorithm/idea, please provide links to
any relevant articles or webpages.

Additional context

Add any other context or screenshots about the feature request here.

</issue_description>

Comments on the Issue (you are @copilot in this section)


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

Copilot AI and others added 2 commits February 7, 2026 01:21
Co-authored-by: harsha-simhadri <5590673+harsha-simhadri@users.noreply.github.com>
Co-authored-by: harsha-simhadri <5590673+harsha-simhadri@users.noreply.github.com>
Copilot AI changed the title [WIP] Add autotuner tool on top of benchmark Add autotuner for benchmark parameter optimization Feb 7, 2026
Copilot AI requested a review from harsha-simhadri February 7, 2026 01:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Create an autotuner tool on top of benchmark

2 participants