Removes stale and orphaned chunks from the ChromaDB vector store for files that have been deleted or renamed. Use after files are removed or moved to keep the vector index in sync with the filesystem. <example> user: "Clean up the vector store after I deleted some files" assistant: "I'll use vector-db-cleanup to remove orphaned chunks." </example> <example> user: "The vector database has chunks for files that no longer exist" assistant: "I'll run vector-db-cleanup to prune them." </example>
From vector-dbnpx claudepluginhub richfrem/agent-plugins-skills --plugin vector-dbThis skill is limited to using the following tools:
assets/resources/architecture_sequence.mmdassets/resources/deployment_model.mmdassets/resources/rag_design_choices.mdassets/resources/stabilizers/README.mdassets/resources/stabilizers/vector_consistency_check.mdevals/evals.jsonevals/results.tsvrequirements.inrequirements.txtscripts/cleanup.pyscripts/init.pyscripts/query.pyscripts/vector_config.pyscripts/vector_consistency_check.pyGuides Payload CMS config (payload.config.ts), collections, fields, hooks, access control, APIs. Debugs validation errors, security, relationships, queries, transactions, hook behavior.
Designs KPI dashboards with metrics selection (MRR, churn, LTV/CAC), visualization best practices, real-time monitoring, and hierarchy for executives, operations, and product teams.
Transforms raw data into narratives with story structures, visuals, and frameworks for executive presentations, analytics reports, and stakeholder communications.
This skill requires Python 3.8+ and standard library only. No external packages needed.
To install this skill's dependencies:
pip-compile ./requirements.in
pip install -r ./requirements.txt
See ./requirements.txt for the dependency lockfile (currently empty — standard library only).
You remove stale and orphaned chunks from the ChromaDB vector store. A chunk is stale when its source file no longer exists on disk. Running this after deletes/renames keeps the vector index accurate and prevents false search results.
This is a write (delete) operation. Always dry-run first.
query.py returns results pointing to non-existent filesIf not already up, run the vector-db-launch skill first.
For first-time setup (dependencies + profile config): run the vector-db-init skill.
curl -sf http://127.0.0.1:8110/api/v1/heartbeat
python3 ./scripts/cleanup.py \
--profile knowledge --dry-run
Report: "Found N orphaned chunks from X deleted files: [list of paths]"
python3 ./scripts/cleanup.py \
--profile knowledge --apply
python3 ./scripts/vector_consistency_check.py \
--profile knowledge
python3 ./scripts/query.py \
"test query" --profile knowledge --limit 3
.vector_data/ directly -- always use cleanup.py..sqlite3 files with raw shell tools -- will corrupt context.