DSH users often face difficulties when processing publications, such as tracking citations and locating specific page numbers or sections. General RAG systems often return summaries rather than evidence from the original text. dsh-kb-rag solves this problem by indexing PDF files and Zotero libraries into a single SQLite file and returning paragraphs with location metadata.
Plugin Information¶
- Name: dsh-kb-rag
- Category: Memory
- Maintainer: Breeze136
- License: MIT
- GitHub: Breeze136/dsh-kb-rag
- Directory page: dsh-kb-rag on SkillHub
Core Features¶
- Local-first publication RAG: All indexing, embedding, and reranking run locally, without uploading data and without API costs.
- Multi-source indexing: Supports indexing PDF files and Zotero libraries into a single SQLite database.
- Location metadata: Retrieved paragraphs include section information, physical PDF page numbers, and clickable DOI links.
- Local models: Uses local embedding and reranking models.
- MCP support: Provides MCP server mode, which can be used by tools such as Claude Desktop and Cursor.
Installation and Enablement¶
The installation process handles Python dependencies, engine testing, and Node/pnpm checks.
- Run the installation command:
npx dsh-kb-rag-install
- On first use, the plugin downloads an embedding model of about 95MB and a reranker of about 1.1GB, so initialization is relatively slow. Subsequent queries will be served from the in-memory cache, significantly improving speed.
Typical Usage¶
After installation, you can interact through the following tools:
- kb_rag: Retrieve evidence. Used to ask questions to the knowledge base and retrieve cited paragraphs.
- kb_ingest: Batch indexing. Used to process file indexing tasks and supports background asynchronous jobs.
- kb_status: Query status. Used to poll the status of background jobs started by
kb_ingest. - kb_scope: Define scope. Used to define strict mode and query scope.
Applicable Scenarios and Considerations¶
Applicable scenarios:
* Researchers who need RAG retrieval based on a local publication library.
* Users who already have a large collection of PDF publications or a Zotero library and want to index them structurally.
* Developers who need precise citations with source and page-number information.
Considerations:
* Permissions: The plugin runs with the permissions of the current DSH process. Check the source code and license before installation.
* First-use speed: The first use requires downloading model files, which may take a long time.
* File format limitations: Scanned PDFs without a text layer will be skipped.
* Indexed content: Images themselves are not indexed; only image captions are indexed as text.
* Language limitations: Cross-language retrieval capability is weak.
Conclusion¶
dsh-kb-rag provides a local, structured approach to publication management. By using SQLite storage and local model computation, it can protect data privacy while delivering retrieval results with precise location information. For more details, see its GitHub repository.