Installs into .claude/skills of the current project.
Sponsors
SSkills DirectorySkills Directory
Know which skills are safe — weekly.
SSkills DirectorySkills Directory
Is that skill safe to install?
Are you the author of Vector Databases?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/adityaaatiwari-vector-databases-anvil)
---
name: vector-databases
description: Design and query vector databases cleanly with aligned embeddings, metadata pre-filtering, HNSW tuning, and hybrid search
---
<!-- Generated by `anvil plugin build` from catalog/. Edit the catalog, not this file. -->
# Vector databases
Use when adding, indexing, or tuning similarity search in vector stores such as pgvector, Qdrant, Pinecone, or Weaviate.
## Indexing and embeddings
- Store the `embedding_model` and `model_version` alongside vectors so re-indexing triggers cleanly on model changes.
- Match distance metrics (cosine, dot-product, L2) explicitly between training normalization and index creation.
- Tune HNSW build parameters (`m`, `ef_construction`) for recall vs memory, and adjust query-time `ef_search` before scaling nodes.
## Filtering and hybrid retrieval
- Apply metadata pre-filtering (tenant ID, permissions, deleted flags) inside the index query rather than post-filtering top-K results.
- Combine dense semantic search with sparse lexical search (BM25 / `tsvector`) using Reciprocal Rank Fusion when exact codes or identifiers matter.
- Keep vector updates idempotent with deterministic document chunk IDs and delete stale chunks on source edits.
## Verify
Measure recall@K against an exact scan baseline, latency at p95 under concurrent filtered queries, and tenant isolation boundaries.