Token导航 LogoToken导航TokenDH.com
Llms Txt Generator MCP logo
文档知识stdio官方级别未说明来源级核验

Llms Txt Generator MCP

MCP Server

一个强大的MCP服务器,自动为任何网站生成`llms.txt`和`llms-full.txt`文件,遵循[llmstxt.org规范](https://llmstxt.org/)。

工具数

0

提示词数

0

GitHub Stars

4

资源数

0
文档生成PythonCursorCursor

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

作者 / 组织

damionrashford

提供方

damionrashford

最后核验

2026/5/17 20:23

运行时

Python

快速接入

先看主来源和安装命令,再打开仓库或文档;下面只保留这个条目的关键接入事实。

命令预览

python -m venv venv

详细介绍

LLMs.txt生成器

一个功能强大的MCP(模型上下文协议)服务器,可以自动生成 llms.txtllms-full.txt 任何网站的文件,遵循 llmstxt.org规范.

🚀 快速入门-在Cursor中安装

选项1:一键安装(推荐)

备注:一键安装要求您在本地克隆存储库。克隆后,您可以创建自己的深度链接。

  1. 克隆存储库:
   git clone https://github.com/damionrashford/llms-txt-generator-mcp.git
   cd llms-txt-generator-mcp
  1. 创建您的深度链接:

替换 /path/to/your/llms-txt-generator-mcp 使用此配置中的实际路径:

   {
     "llms-txt-generator": {
       "command": "python3",
       "args": ["/path/to/your/llms-txt-generator-mcp/server.py"],
       "env": {
         "PYTHONPATH": "/path/to/your/llms-txt-generator-mcp",
         "LOG_LEVEL": "INFO"
       },
       "timeout": 60000,
       "initTimeout": 15000,
       "stderr": "inherit"
     }
   }
  1. 生成深度链接:

- 复制上面的JSON配置 - 替换 /path/to/your/llms-txt-generator-mcp 与你的实际路径 - Base64编码JSON - 创建深度链接: cursor://anysphere.cursor-deeplink/mcp/install?name=llms-txt-generator&config=YOUR_BASE64_CONFIG

  1. 点击深度链接 在Cursor中安装

选项2:手动安装

  1. 克隆存储库:
   git clone https://github.com/damionrashford/llms-txt-generator-mcp.git
   cd llms-txt-generator-mcp
  1. 设置环境:
   python -m venv venv
   source venv/bin/activate  # On Windows: venv\Scripts\activate
   pip install -e .
  1. 添加到Cursor的MCP配置:

打开 ~/.cursor/mcp.json (如果不存在则创建)并添加:

   {
     "mcpServers": {
       "llms-txt-generator": {
         "command": "python3",
         "args": ["/path/to/your/llms-txt-generator-mcp/server.py"],
         "env": {
           "PYTHONPATH": "/path/to/your/llms-txt-generator-mcp",
           "LOG_LEVEL": "INFO"
         },
         "timeout": 60000,
         "initTimeout": 15000,
         "stderr": "inherit"
       }
     }
   }
  1. 重新启动游标 加载新的MCP服务器。

🛠️ 用法

安装后,您可以使用 generate_llms_txt 光标中的工具:

支持的URL格式:

  • https://example.com
  • @https://example.com (带@前缀)
  • example.com (自动添加https://)
  • 本地文件路径

示例用法:

Generate LLMs.txt for https://gofastmcp.com/clients/roots

该工具将生成:

  • llms.txt:干净、结构化的文件
  • llms-full.txt:包含HTML的完整内容
  • documentation_data.json:供程序使用的结构化数据

📋 特性

  • 自动页面发现:抓取网站以查找相关页面
  • 灵活的URL支持:处理各种URL格式和本地文件
  • 结构化输出:生成人类可读和机器可读的格式
  • MCP集成:与Cursor和其他MCP客户端无缝集成
  • 错误处理:强大的错误处理和详细的反馈
  • 速率限制:内置速率限制,以尊重服务器

🏗️ 建筑

核心组件

  • server.py:使用官方MCP Python SDK的主MCP服务器
  • src/core/generator.py:核心LLMs.txt生成逻辑
  • src/config/config.py:配置管理
  • src/utils/:用于内容处理和站点地图提取的实用模块

MCP服务器功能

  • 单一工具: generate_llms_txt -为任何网站生成文档
  • 结构化输出:返回成功状态、页数、文件内容和输出位置
  • 灵活输入:接受各种格式的URL,并自动规范化
  • 临时处理:使用临时目录生成干净文件

🔧 发展

先决条件

  • Python 3.8+
  • pip或uv

安装

  1. 克隆和设置:
   git clone https://github.com/damionrashford/llms-txt-generator-mcp.git
   cd llms-txt-generator-mcp
   python -m venv venv
   source venv/bin/activate
   pip install -e .
  1. 运行服务器:
   python server.py
  1. 使用CLI进行测试:
   python generate_llms_txt.py https://example.com

项目结构

llms-txt-generator-mcp/
├── server.py                 # Main MCP server
├── generate_llms_txt.py      # Standalone CLI tool
├── generate_deeplink.py      # Helper script for creating deeplinks
├── pyproject.toml           # Project configuration
├── Makefile                 # Development commands
├── src/
│   ├── core/
│   │   └── generator.py     # Core generation logic
│   ├── config/
│   │   └── config.py        # Configuration management
│   └── utils/               # Utility modules
└── README.md

📦 分布

对于其他用户

为了使其他用户可以使用此功能,他们可以:

  1. 使用一键安装链接 (推荐)
  2. 手动克隆和设置 按照上面的安装说明进行操作
  3. 创建自己的深度链接 使用MCP配置格式

MCP配置格式

{
  "llms-txt-generator": {
    "command": "python3",
    "args": ["/path/to/server.py"],
    "env": {
      "PYTHONPATH": "/path/to/project",
      "LOG_LEVEL": "INFO"
    },
    "timeout": 60000,
    "initTimeout": 15000,
    "stderr": "inherit"
  }
}

创建深度链接

  1. 准备配置:
   # Create the JSON config (replace with your path)
   echo '{"llms-txt-generator":{"command":"python3","args":["/path/to/your/llms-txt-generator-mcp/server.py"],"env":{"PYTHONPATH":"/path/to/your/llms-txt-generator-mcp","LOG_LEVEL":"INFO"},"timeout":60000,"initTimeout":15000,"stderr":"inherit"}}' > config.json
  1. Base64编码:
   cat config.json | base64
  1. 创建深度链接:
   cursor://anysphere.cursor-deeplink/mcp/install?name=llms-txt-generator&config=YOUR_BASE64_OUTPUT

🙏 致谢

______________________________________________________________________

准备好为任何网站生成LLMs.txt文件了吗?安装MCP服务器并开始记录! 🚀

目录标签

目录标签

文档生成PythonCursor本地部署MCP服务器网站爬取结构化输出自动化工具

支持客户端

Cursor

接入字段

传输方式(transport,传输协议)

stdio

鉴权方式(authType,认证方式)

none

运行时(runtime,运行环境)

Python

工具数量(toolCount,工具数)

0

资源数量(resourceCount,资源数)

0

提示词数量(promptCount,提示词数)

0

权限和风险

stdionone部署方式未说明

接入前请确认传输方式、认证方式和部署位置,并根据实际工具能力限制访问范围。

安装前确认

不要直接授予不必要的文件、网络或账号权限;先核对安装命令和配置内容。

来源信息

继续浏览同类 MCP