Metadata-Version: 2.4
Name: rag-multiple-files
Version: 0.1.0
Summary: MCP server for semantic PDF querying using RAG
Project-URL: Homepage, https://codeberg.org/mionita1980/rag-multiple-files
Project-URL: Source, https://codeberg.org/mionita1980/rag-multiple-files
Author-email: Mihai Ionita <mionita1980@proton.me>
Requires-Python: >=3.11
Requires-Dist: faiss-cpu
Requires-Dist: mcp[cli]
Requires-Dist: sentence-transformers
Description-Content-Type: text/markdown

# RAG Multiple Files MCP Server

A local MCP server that lets you semantically search multiple PDFs using natural language queries.

## Use from Claude Code

Configure the MCP server:

```json
"mcpServers": {
    ...
    "rag-multiple-files": {
        "type": "stdio",
        "command": "uvx",
        "args": [
            "rag-multiple-files"
        ],
        "env": {
            "PDF_FOLDER": "/path/to/your/folder"
        }
    }
}
```

### Sample Request

Query:

```
YYYYYYYYYYYYYYY.pdf: What is the chain slack
```

Response:

```
Based on the YYYYYYYYYYYYYYY owner's manual:
    Chain tension (slack): XX mm (ZZ in)
```

## How it works

1. **Querying** — The query is embedded with the same model and searched against the FAISS index. The top-k most similar chunks are returned with their page numbers and similarity scores.

Parameters:

- query (str) - required - no default - the question or topic to search for
- file_name (str) - required - no default - the name of the PDF file
- top_k (int) - not required - 5 default - number of chunks to return
