Skip to content
Back to skills

Scaling Query Volume

ASecurity

Use when Qdrant queries with large limits fan out across many shards and over-fetch — each shard returning the full limit. Applies Poisson-based per-shard limit reduction, valid when auto-sharding guarantees random distribution.

  • 10 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added October 10, 2026
ai-agentsgit

Security analysis

A100/100

Scanned October 10, 2026

npx -y skills add mouadja02/skills --skill scaling-query-volume --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Scaling Query Volume?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Scaling Query Volume
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/mouadja02-scaling-query-volume/badge)](https://www.skillsdirectory.com/skills/mouadja02-scaling-query-volume)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: qdrant-scaling-query-volume
description: Use when Qdrant queries with large limits fan out across many shards and over-fetch — each shard returning the full limit. Applies Poisson-based per-shard limit reduction, valid when auto-sharding guarantees random distribution.
source: "https://github.com/qdrant/skills"
attribution: "qdrant/skills by Qdrant"
---

> **Attribution:** Sourced from [qdrant/skills](https://github.com/qdrant/skills) by [Qdrant](https://qdrant.tech).

# Scaling for Query Volume

Problem: When a query has a large limit (e.g. 1000) and there are multiple shards (e.g. 10), naively each shard must return the full 1000 results — totaling 10,000 scored points transferred and merged. This is wasteful since data is randomly distributed across auto-shards.

## Core idea

Instead of asking every shard for the full limit, ask each shard for a smaller limit computed via Poisson distribution statistics, then merge. This is safe because auto-sharding guarantees random, independent data distribution.

## When it activates

- More than 1 shard
- Auto-sharding is in use (all queried shards share the same shard key)
- The request's limit + offset >= SHARD_QUERY_SUBSAMPLING_LIMIT (128)
- The query is not exact

## Key tradeoff

 The strategy trades a small probability of slightly incomplete results for a large reduction in inter-shard data transfer, especially for high-limit queries across many shards. The 1.2x safety factor and the 99.9% Poisson threshold keep the error rate very low — comparable to inaccuracies already introduced by approximate vector indices like HNSW.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…