npx claudepluginhub joranhonig/grimoireThis skill uses the workspace's default tool permissions.
Build or rebuild the semantic search index over all registered libraries.
Performs semantic search on Qdrant vector DB of indexed knowledge bases for librarian agent. Returns ranked results with scores and source metadata for citations.
Indexes project with QMD semantic search, file suggestions, and codebase map. Run on new codebases or after changes to optimize token usage in exploration.
Indexes and searches local files via CLI using BM25, vector embeddings, hybrid search, and reranking with Ollama. Supports MCP mode and includes security guardrails.
Share bugs, ideas, or general feedback.
Build or rebuild the semantic search index over all registered libraries.
Text-based grep finds exact strings. Vector search finds meaning. When a
researcher asks "how does reentrancy work in pull-payment patterns?" a grep
for reentrancy may miss a file that discusses it under a different term. By
storing library content as vector embeddings, the librarian can retrieve
relevant chunks even when the exact words don't match.
The indexing pipeline is a single Python script (scripts/index.py) that:
~/.grimoire/librarian/library/libraries.yaml~/.grimoire/librarian/qdrant/Chunks get deterministic IDs derived from their content hash, so re-running the index overwrites rather than duplicates. This makes the skill fully idempotent.
Dependencies are declared inline in the script via PEP 723 metadata. Running
with uv run handles everything automatically — no manual pip install
needed. Since the plugin already requires uvx (for MCP servers), uv is
guaranteed to be available.
When this skill is activated, create a todo list from the following steps:
- [ ] 1. Run the indexer — execute index.py via uv run
- [ ] 2. Report — relay the script's output to the user
The script is located at skills/librarian-index/scripts/index.py inside the
plugin directory.
Index all libraries (default):
uv run /path/to/grimoire/skills/librarian-index/scripts/index.py index
Index a single library:
uv run /path/to/grimoire/skills/librarian-index/scripts/index.py index_library \
<library_dir> <library_name> <source_url>
Optional flags (apply to both commands):
| Flag | Default | Description |
|---|---|---|
--qdrant_path | ~/.grimoire/librarian/qdrant | Path to local Qdrant database |
--collection | grimoire-library | Qdrant collection name |
--embedding_model | sentence-transformers/all-MiniLM-L6-v2 | FastEmbed model |
--extensions | .md,.sol,.py,.js,.ts,.rs,.go,.txt | File extensions to include |
--max_file_size_kb | 200 | Skip files larger than this |
The first run will download the embedding model (~80 MB). Subsequent runs reuse the cached model.
Relay the script's stdout to the user. The script prints a per-library summary and a total chunk count. If errors occurred (missing directories, unknown library types), they appear at the bottom.
Remind the user to run librarian-index again after adding or updating
libraries with modify-library.
libraries.yaml or any file inside the libraries.[library-name] path/to/file so search results
self-identify their origin.