Vector Index Tuning
Unverified●30/40Claude Code◐PartialHas SKILL.md but declares no allowed-tools — Claude Code will ask for permission each time
Cursor◐PartialPlain prose you can paste in — but no Cursor rules file
Codex◐PartialPlain prose you can paste in — but no AGENTS.md
Gemini CLI◐PartialPlain prose you can paste in
Copilot◐PartialPlain prose you can paste in — but no Copilot instructions file
npx agentalley add vector-index-tuningWho is stuck, and on what
Optimize vector index performance for latency, recall, and memory. Use when tuning HNSW parameters, selecting quantization strategies, or scaling vector search infrastructure.
The whole source
Frontmatter — 2 properties
| name | vector-index-tuning |
|---|---|
| description | Optimize vector index performance for latency, recall, and memory. Use when tuning HNSW parameters, selecting quantization strategies, or scaling vector search infrastructure. |
| 1 | --- |
| 2 | name: vector-index-tuning |
| 3 | description: Optimize vector index performance for latency, recall, and memory. Use when tuning HNSW parameters, selecting quantization strategies, or scaling vector search infrastructure. |
| 4 | ---A5 — No allowed-tools declared — no way to tell what this skill may touch |
| 5 | |
| 6 | # Vector Index Tuning |
| 7 | |
| 8 | Guide to optimizing vector indexes for production performance. |
| 9 | |
| 10 | ## When to Use This Skill |
| 11 | |
| 12 | - Tuning HNSW parameters |
| 13 | - Implementing quantization |
| 14 | - Optimizing memory usage |
| 15 | - Reducing search latency |
| 16 | - Balancing recall vs speed |
| 17 | - Scaling to billions of vectors |
| 18 | |
| 19 | ## Core Concepts |
| 20 | |
| 21 | ### 1. Index Type Selection |
| 22 | |
| 23 | ``` |
| 24 | Data Size Recommended Index |
| 25 | ──────────────────────────────────────── |
| 26 | < 10K vectors → Flat (exact search) |
| 27 | 10K - 1M → HNSW |
| 28 | 1M - 100M → HNSW + Quantization |
| 29 | > 100M → IVF + PQ or DiskANN |
| 30 | ``` |
| 31 | |
| 32 | ### 2. HNSW Parameters |
| 33 | |
| 34 | | Parameter | Default | Effect | |
| 35 | | ------------------ | ------- | ---------------------------------------------------- | |
| 36 | | **M** | 16 | Connections per node, ↑ = better recall, more memory | |
| 37 | | **efConstruction** | 100 | Build quality, ↑ = better index, slower build | |
| 38 | | **efSearch** | 50 | Search quality, ↑ = better recall, slower search | |
| 39 | |
| 40 | ### 3. Quantization Types |
| 41 | |
| 42 | ``` |
| 43 | Full Precision (FP32): 4 bytes × dimensions |
| 44 | Half Precision (FP16): 2 bytes × dimensions |
| 45 | INT8 Scalar: 1 byte × dimensions |
| 46 | Product Quantization: ~32-64 bytes total |
| 47 | Binary: dimensions/8 bytes |
| 48 | ``` |
| 49 | |
| 50 | ## Templates and detailed worked examples |
| 51 | |
| 52 | Full template library and detailed worked examples live in `references/details.md`. Read that file when you need the concrete templates. |
| 53 | |
| 54 | ## Best Practices |
| 55 | |
| 56 | ### Do's |
| 57 | |
| 58 | - **Benchmark with real queries** - Synthetic may not represent production |
| 59 | - **Monitor recall continuously** - Can degrade with data drift |
| 60 | - **Start with defaults** - Tune only when needed |
| 61 | - **Use quantization** - Significant memory savings |
| 62 | - **Consider tiered storage** - Hot/cold data separation |
| 63 | |
| 64 | ### Don'ts |
| 65 | |
| 66 | - **Don't over-optimize early** - Profile first |
| 67 | - **Don't ignore build time** - Index updates have cost |
| 68 | - **Don't forget reindexing** - Plan for maintenance |
| 69 | - **Don't skip warming** - Cold indexes are slow |
| 70 |
Reviews
Installed this one?Write the first review and take the Trailblazer badge.
Alternatives
Task Coordination StrategiesDecompose complex tasks, design dependency graphs, and coordinate multi-agent work with proper task descriptions and workload balancing. Use this skill when breaking down work for agent teams, managing task dependencies, or monitoring team progress.◐◐◐◐◐●35/40Ebay Seller Tools·····●34/40Tough Decision Advisor: Every Angle ConsideredHand in a decision you're stuck on. Get back a clear breakdown of every angle — the trade-offs, the risks, the blind spot, and a recommended path.●····●32/40DHDNA Profiler — Cognitive Pattern ExtractionPaste any email, proposal, or note someone wrote, and get back a plain-language read on how they think, what drives their decisions, and how they communicate.●····●32/40