Skip to content

TQ 1-2 bits rescoring - #8941

Merged
IvanPleshkov merged 1 commit into
devfrom
tq-default-rescoring
May 7, 2026
Merged

IvanPleshkov merged 1 commit into
devfrom
tq-default-rescoring

Conversation

@IvanPleshkov

Copy link
Copy Markdown
Contributor

Enable rescoring by default for 1-1.5-2 bit TQ

@IvanPleshkov IvanPleshkov added this to the TurboQuant milestone May 7, 2026
@IvanPleshkov IvanPleshkov changed the title 1-2 bits rescoring TQ 1-2 bits rescoring May 7, 2026
@IvanPleshkov
IvanPleshkov requested a review from JojiiOfficial May 7, 2026 12:12
@IvanPleshkov IvanPleshkov mentioned this pull request May 7, 2026
63 of 69 tasks
@coderabbitai

coderabbitai Bot commented May 7, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack
No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 220453b8-78c6-4442-9f00-1fce6aa636a1

📥 Commits

Reviewing files that changed from the base of the PR and between 94db47b and a0a6ab9.

📒 Files selected for processing (1)
  • lib/segment/src/vector_storage/quantized/quantized_vectors.rs

📝 Walkthrough

Walkthrough

This PR introduces data-driven default rescoring behavior for TurboQuant storage variants. A new helper function tq_bits_default_rescoring maps TQBits enum values to a boolean rescoring setting: enabled for 1-bit, 1.5-bit, and 2-bit quantization; disabled for 4-bit. The QuantizedVectors::default_rescoring method was updated to read the TQBits value from storage metadata for all TQ variants and apply this mapping, replacing the previous unconditional false return value.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

Possibly related PRs

  • qdrant/qdrant#8678: Modifies quantized_vectors.rs to add/adjust TurboQuant handling, specifically touching default rescoring behavior and TQ variants.

Suggested reviewers

  • JojiiOfficial
🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title 'TQ 1-2 bits rescoring' clearly and concisely summarizes the main change: enabling rescoring for TurboQuant with 1-2 bit widths.
Description check ✅ Passed The description 'Enable rescoring by default for 1-1.5-2 bit TQ' directly relates to and accurately describes the changeset modifications.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch tq-default-rescoring

Tip

💬 Introducing Slack Agent: The best way for teams to turn conversations into code.

Slack Agent is built on CodeRabbit's deep understanding of your code, so your team can collaborate across the entire SDLC without losing context.

  • Generate code and open pull requests
  • Plan features and break down work
  • Investigate incidents and troubleshoot customer tickets together
  • Automate recurring tasks and respond to alerts with triggers
  • Summarize progress and report instantly

Built for teams:

  • Shared memory across your entire org—no repeating context
  • Per-thread sandboxes to safely plan and execute work
  • Governance built-in—scoped access, auditability, and budget controls

One agent for your entire SDLC. Right inside Slack.

👉 Get started


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@IvanPleshkov
IvanPleshkov merged commit d8218ed into dev May 7, 2026
15 checks passed
@IvanPleshkov
IvanPleshkov deleted the tq-default-rescoring branch May 7, 2026 12:46
timvisee pushed a commit that referenced this pull request May 8, 2026
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.

2 participants