TxtAI Assistant MCP
@rmtech1
Model Context Protocol (MCP) server implementation for semantic vector search and memory management using TxtAI. This server provides a robust API for storing, retrieving, and managing text-based memories with semantic vector database search capabilities. You can use Claude and C
Overview
What is TxtAI Assistant MCP?
TxtAI Assistant MCP is a Model Context Protocol (MCP) server for semantic search and memory management, built on the open‑source txtai AI‑powered search engine. It provides an API for storing, retrieving, and managing text‑based memories with semantic search capabilities, and is designed for integration with AI assistants such as Claude and Cline.
How to use TxtAI Assistant MCP?
Clone the repository and run the ./scripts/start.sh script, which creates a virtual environment, installs dependencies, sets up directories, and starts the server. Configure the server via a .env file (template provided). Then add the server configuration to Claude’s or Cline’s MCP settings file to enable the available MCP tools.
Key features of TxtAI Assistant MCP
- Semantic search across stored memories
- Persistent file‑based storage of memories and tags
- Tag‑based memory organization and retrieval
- Memory statistics and health monitoring
- Automatic data persistence
- Integration with Claude and Cline AI assistants
Use cases of TxtAI Assistant MCP
- Store important conversation details and retrieve them later using natural language queries
- Search memories semantically to find relevant information quickly
- Organize memories with tags for efficient filtering and access
- Monitor memory database health and statistics via provided endpoints
- Enable AI assistants to maintain long‑term context across sessions
FAQ from TxtAI Assistant MCP
What does TxtAI Assistant MCP do that alternatives do not?
It integrates the txtai semantic search engine with the Model Context Protocol, allowing AI assistants like Claude and Cline to directly store and search memories using MCP tools while benefiting from txtai’s neural search, zero‑shot classification, and multi‑language support.
What are the runtime dependencies?
Python 3.8 or higher, pip, and a virtual environment (recommended). The startup script installs all required Python dependencies automatically.
Where are memories and data stored?
Memories and tag indexes are stored as JSON files in the data directory (memories.json and tags.json). Logs are stored in the logs directory.
Are there any configurable limits?
Yes. The MAX_MEMORIES environment variable (default 0, meaning no limit) can be set to cap the number of stored memories.
How is security and transport handled?
The server uses HTTP with configurable CORS origins (set via the CORS_ORIGINS environment variable). Input validation is performed on all endpoints, and file paths are sanitized to prevent directory traversal.