Semantic search over a personal knowledge corpus using SQLite + sqlite-vec for local embeddings, exposing a stdio MCP server to Claude Code. Version 0.1.49. Indexes markdown roots (defaults to `../../thoughts`). Supports multi-root indexing, gitignore-style ignore patterns, layered configuration (CLI, env vars, config file), and hybrid search with two-tiered retrieval tools (`knowledge_search` and `knowledge_recall`). Ships TypeScript types and provides a reindex CLI. Differentiated by local-only, file-based vector search with no external API dependencies, configurable memory tiers (doc, raw, reflection, wiki), and role-based retrieval policies. Releases appear to be early-stage (pre-1.0) with active development.
npm install ralph-hero-knowledge-indexNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Indexes markdown roots and starts an MCP server that Claude Code can connect to for semantic search.
Use incremental indexing (not yet supported) or backup the SQLite file before reindexing.
Explicitly pass `rerank: true` or `rerank: false` in your tool call to avoid surprises.
Always validate that paths exist before running reindex. Check logs for 'Using roots from' message to confirm source.
Use full absolute paths or environment variables like $HOME when running on Windows.
Use `knowledge_search` with explicit `memory_tier` if you need a different tier combination.
Currently no configuration to include non-markdown files. If needed, manually convert to markdown or wait for a future release.
Run `npm install` to install native addons. If using a platform without prebuilt binaries, ensure build tools are available (e.g., `apt install build-essential` on Linux).
Call `await reindex(config)` before any search operations. The database must exist and be populated.
Either pass paths as CLI arguments (e.g., `npm run reindex -- /my/thoughts`), set the `RALPH_KNOWLEDGE_DIRS` env var, or create `~/.ralph/knowledge.config.json` with a `roots` array.
Use one of the valid tier names: `doc`, `raw`, `reflection`, `wiki`, or `any` (case-sensitive).