home / mcp / antigravity pdf mcp server
Provides ingest of PDFs, MDs, and TXT into a persistent knowledge base with hybrid search and page-cited results.
Configuration
View docs{
"mcpServers": {
"asoluka-antigravity-pdf-mcp": {
"command": "node",
"args": [
"/absolute/path/to/antigravity-pdf-mcp/dist/server.js"
],
"env": {
"OPENAI_API_KEY": "YOUR_API_KEY"
}
}
}
}Antigravity PDF MCP Server lets you build a persistent knowledge base from PDFs, Markdown, and text files and query it using advanced hybrid search. It integrates with MCP-enabled clients and IDEs over Stdio, provides real-time ingestion progress, and stores documents and their embeddings in a local SQLite database for reliable restarts and quick access.
You connect to the server from any MCP-enabled client or IDE using Stdio transport. Ingest documents such as PDFs, Markdown, and TXT files to populate a searchable knowledge base. Then issue queries to retrieve relevant passages with page citations for easy verification. Use document filtering to focus results on a specific file, if needed. Expect real-time feedback during ingestion and fast hybrid search that combines keyword matching with semantic embeddings.
Typical usage flow:
Prerequisites you need before installation are Node.js version 18 or higher and npm.
# 1. Clone the repository
git clone <repository-url>
cd antigravity-pdf-mcp
# 2. Install dependencies
npm install
# 3. Build the project
npm run buildSemantic search (OpenAI embeddings) can be enabled by providing an API key. If no key is supplied, the server falls back to local TF-IDF search only.
OPENAI_API_KEY=sk-your-api-key-hereTo enable Embeddings, create an environment file in the project root with your API key. The server uses this key when available and otherwise uses keyword-only search.
The server communicates via the MCP over Stdio transport, so your MCP client or IDE can connect directly using standard MCP patterns.
Ingest a file (PDF, TXT, MD) into the knowledge base. Provide the absolute path to the file.
Search the knowledge base with a query. Optional filter by document_id to limit results to a specific document.
List all ingested documents currently stored in the library.
Clear the entire knowledge base, removing all documents and vectors.
Deprecated alias for ingest_document; use ingest_document instead.