qdrant-search-quality-diagnosis
它能做什么
这个工具可以帮你找出 Qdrant 中搜索结果不理想的原因。它会检查问题是出在所用的 AI 模型、搜索设置,还是其他因素。
适用场景
- ✓当搜索结果看起来不对或不相关时。
- ✓当你明明预期能找到某些内容,却没有找到时。
- ✓当搜索质量突然变差时。
技能链接
https://github.com/github/awesome-copilot/blob/main/skills/qdrant-search-quality/diagnosis/SKILL.md复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。
使用方法
最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。
可直接粘贴的消息
适用于 Claude Code、Codex 或 Cursor:在项目文件夹中运行,即可安装该技能。
下载 SKILL.md,放进智能体的技能文件夹。
可以这样问 AI
“帮我弄清楚,为什么我的 Qdrant 搜索结果不好。”
每周 5 个新技能,1 分钟读完。
工作原理
它会对比精确搜索和近似搜索,看错误出现在哪一步。然后,它会建议你检查 AI 模型、搜索设置(比如 HNSW),或者看看是否有过滤器把结果挡掉了。
技术内容(原始 SKILL.md)
作者在 GitHub 上的英文原文。
How to Diagnose Bad Search Quality
Before tuning, establish baselines. Use exact KNN as ground truth, compare against approximate HNSW. Target >95% recall@K for production.
Don't Know What's Wrong Yet
Use when: results are irrelevant or missing expected matches and you need to isolate the cause.
- Test with
exact=trueto bypass HNSW approximation Search API - Exact search bad = model or search pipeline problem. Exact good, approximate bad = tune HNSW.
- Check if quantization degrades quality (compare with and without)
- Check if filters are too restrictive (then you might need to use ACORN)
- If duplicate results from chunked documents, use Grouping API to deduplicate Grouping
Payload filtering and sparse vector search are different things. Metadata (dates, categories, tags) goes in payload for filtering. Text content goes in sparse vectors for search.
Approximate Search Worse Than Exact
Use when: exact search returns good results but HNSW approximation misses them.
- Increase
hnsw_efat query time Search params - Increase
ef_construct(200+ for high quality) HNSW config - Increase
m(16 default, 32 for high recall) HNSW config - Enable oversampling + rescore with quantization Search with quantization
- ACORN for filtered queries (v1.16+) ACORN
Binary quantization requires rescore. Without it, quality loss is severe. Use oversampling (3-5x minimum for binary) to recover recall. Always test quantization impact on your data before production. Quantization
Wrong Embedding Model
Use when: exact search also returns bad results.
Test top 3 MTEB models on 100-1000 sample queries, measure recall@10. Domain-specific models often outperform general models. Hosted inference
Unoptimized Search Pipeline
Use when: exact search also returns bad results and model choice is confirmed by user.
Optimize search according to advanced search-strategies skill.
What NOT to Do
- Tune Qdrant before verifying the model is right for the task (most quality issues are model issues)
- Use binary quantization without rescore (severe quality loss)
- Set
hnsw_eflower than results requested (guaranteed bad recall) - Skip payload indexes on filtered fields then blame quality (HNSW can't traverse filtered-out nodes, and filterable HNSW is built only if payload indexes were set up prior)
- Deploy without baseline recall or other search relevance metrics (no way to measure regressions)
- Confuse payload filtering with sparse vector search (different things, different config)
常见问题
什么是“召回率”?
召回率是衡量搜索能否找到所有应该被找到的相关内容的指标。
什么是 HNSW?
HNSW 是一种近似搜索方法,速度很快,但准确度可能不如精确搜索。
什么是“量化”(quantization)?
量化是一种缩小数据体积的技术,可以加快搜索速度,但有时会降低结果质量。
详情
作者的原始描述
Diagnoses Qdrant search quality issues. Use when someone reports 'results are bad', 'wrong results', 'not relevant results', 'missing matches', 'recall is low', 'approximate search worse than exact', 'which embedding model', or 'quality dropped after quantization'. Also use when search quality degrades without obvious changes.
repo: github/awesome-copilot
热度
- GitHub 星标
- 40k
- 排名
- #7373
- 许可证
- MIT
- 更新时间
- 2026/10/15
评论
- …
同一仓库的更多技能
acquire-codebase-knowledge
40k帮你的智能体理解并编写现有代码项目的文档。它有助于新成员快速上手,或者快速了解项目架构。
acreadiness-assess
40k让你的智能体评估一个项目对 AI 的准备程度,并生成报告。它有助于了解项目在使用 AI 工具方面的准备情况。
acreadiness-generate-instructions
40k帮你的智能体根据评估结果编写 AI 工具的指令文件。它有助于改善 AI 与代码的交互方式,并弥补已发现的不足。
acreadiness-policy
40k让你的智能体协助制定或应用 AI 项目评估的政策。它有助于规范项目的评估方式,并确保合规。