druellan/llms-mcp
If you are the rightful owner of llms-mcp and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to henry@mcphub.com.
An MCP server that enhances AI context by exposing the llms.txt file and its resources.
llms-mcp
An MCP (Model Context Protocol) server that exposes the llms.txt
file from your project root as a resource for AI context enhancement.
Overview
llms-mcp is a MCP server that looks for the llms.txt
file in the root of your project directory and exposes it as a resource that can be consumed by MCP-compatible AI clients, based on the llms.txt proposed standard.
Features
- Detection: Finds the
llms.txt
file in your project root - File Resource: Exposes the file via
file://
URI for direct content access - Parsing: Extracts local file references and external URLs from llms.txt content. Automatically exposes referenced local files and external URLs as additional MCP resources.
- Fetching: Can fetch external resources on-demand.
Installation
Prerequisites
- Node.js >= 18.0.0
Setup
- Clone or download this repository
- Install dependencies:
npm install
Usage
Running the Server
Start the MCP server:
npm start
Test Mode
Validate that the server can detect your llms.txt
file:
npm test
This will scan your project directory and show if an llms.txt
file is detected without starting the server.
Environment Configuration
The server uses the ProjectPath
environment variable to determine the root directory to scan:
export ProjectPath="/path/to/your/project"
npm start
$env:projectPath = "/path/to/your/project"; npm start
MCP Client Configuration
Claude Desktop/Cline/Roo/Kilocode
Add this configuration to your Claude Desktop config file:
{
"mcpServers": {
"llms-mcp": {
"command": "node",
"args": ["path/to/llms-mcp/src/index.js"],
"env": {
"ProjectPath": "./"
}
}
}
}
Referenced Resources
The server automatically parses the llms.txt
content and exposes referenced files and URLs as additional resources:
Local Files:
- Markdown-style file links:
[text](file.ext)
External URLs:
- HTTP/HTTPS URLs:
https://example.com
- URLs in markdown links:
[text](https://example.com)
All local files are validated for existence before being exposed as resources. External URLs are exposed as-is and fetched on-demand when accessed.
License
MIT License - see LICENSE file for details.
Related Projects
- llms.txt - The llms.txt standard
- Model Context Protocol - MCP specification