create-llms
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseCreate LLMs.txt File from Repository Structure
基于仓库结构创建LLMs.txt文件
Create a new file from scratch in the root of the repository following the official llms.txt specification at https://llmstxt.org/. This file provides high-level guidance to large language models (LLMs) on where to find relevant content for understanding the repository's purpose and specifications.
llms.txtPrimary Directive
核心指令
Create a comprehensive file that serves as an entry point for LLMs to understand and navigate the repository effectively. The file must comply with the llms.txt specification and be optimized for LLM consumption while remaining human-readable.
llms.txt创建一份全面的文件,作为LLMs有效理解和导航仓库的入口点。该文件必须符合llms.txt规范,同时兼顾LLM的读取需求与人类可读性。
llms.txtAnalysis and Planning Phase
分析与规划阶段
Before creating the file, you must complete a thorough analysis:
llms.txt在创建文件之前,你必须完成全面的分析:
llms.txtStep 1: Review llms.txt Specification
步骤1:查阅llms.txt规范
- Review the official specification at https://llmstxt.org/ to ensure full compliance
- Understand the required format structure and guidelines
- Note the specific markdown structure requirements
- 查阅https://llmstxt.org/上的官方规范,确保完全合规
- 理解所需的格式结构和指南
- 记录特定的Markdown结构要求
Step 2: Repository Structure Analysis
步骤2:仓库结构分析
- Examine the complete repository structure using appropriate tools
- Identify the primary purpose and scope of the repository
- Catalog all important directories and their purposes
- List key files that would be valuable for LLM understanding
- 使用合适的工具检查完整的仓库结构
- 明确仓库的主要用途和范围
- 整理所有重要目录及其用途
- 列出对LLM理解有价值的关键文件
Step 3: Content Discovery
步骤3:内容挖掘
- Identify README files and their locations
- Find documentation files (files in
.md,/docs/, etc.)/spec/ - Locate specification files and their purposes
- Discover configuration files and their relevance
- Find example files and code samples
- Identify any existing documentation structure
- 确定README文件及其位置
- 查找文档文件(如、
/docs/目录下的/spec/文件).md - 定位规范文件及其用途
- 发现配置文件及其相关性
- 找到示例文件和代码样本
- 识别现有的文档结构
Step 4: Create Implementation Plan
步骤4:制定实施计划
Based on your analysis, create a structured plan that includes:
- Repository purpose and scope summary
- Priority-ordered list of essential files for LLM understanding
- Secondary files that provide additional context
- Organizational structure for the llms.txt file
基于你的分析,制定结构化计划,包括:
- 仓库用途和范围摘要
- 按优先级排序的、对LLM理解至关重要的文件列表
- 提供额外上下文的次要文件
- llms.txt文件的组织结构
Implementation Requirements
实施要求
Format Compliance
格式合规性
The file must follow this exact structure per the specification:
llms.txt- H1 Header: Single line with repository/project name (required)
- Blockquote Summary: Brief description in blockquote format (optional but recommended)
- Additional Details: Zero or more markdown sections without headings for context
- File List Sections: Zero or more H2 sections containing markdown lists of links
llms.txt- H1标题:单行的仓库/项目名称(必填)
- 块引用摘要:采用块引用格式的简要描述(可选但推荐)
- 额外详情:零个或多个无标题的Markdown段落,用于补充上下文
- 文件列表章节:零个或多个H2章节,包含带链接的Markdown列表
Content Requirements
内容要求
Required Elements
必填元素
- Project Name: Clear, descriptive title as H1
- Summary: Concise blockquote explaining the repository's purpose
- Key Files: Essential files organized by category (H2 sections)
- 项目名称:清晰、描述性的H1标题
- 摘要:简洁的块引用,说明仓库用途
- 关键文件:按类别(H2章节)组织的重要文件
File Link Format
文件链接格式
Each file link must follow:
[descriptive-name](relative-url): optional description每个文件链接必须遵循:
[描述性名称](相对路径): 可选描述Section Organization
章节组织
Organize files into logical H2 sections such as:
- Documentation: Core documentation files
- Specifications: Technical specifications and requirements
- Examples: Sample code and usage examples
- Configuration: Setup and configuration files
- Optional: Secondary files (special meaning - can be skipped for shorter context)
将文件组织到逻辑H2章节中,例如:
- Documentation(文档):核心文档文件
- Specifications(规范):技术规范和要求
- Examples(示例):示例代码和使用示例
- Configuration(配置):安装和配置文件
- Optional(可选):次要文件(特殊含义 - 为获取更简洁的上下文可跳过)
Content Guidelines
内容指南
Language and Style
语言与风格
- Use concise, clear, unambiguous language
- Avoid jargon without explanation
- Write for both human and LLM readers
- Be specific and informative in descriptions
- 使用简洁、清晰、明确的语言
- 避免无解释的行话
- 同时面向人类和LLM读者写作
- 描述要具体且信息丰富
File Selection Criteria
文件选择标准
Include files that:
- Explain the repository's purpose and scope
- Provide essential technical documentation
- Show usage examples and patterns
- Define interfaces and specifications
- Contain configuration and setup instructions
Exclude files that:
- Are purely implementation details
- Contain redundant information
- Are build artifacts or generated content
- Are not relevant to understanding the project
包含以下类型的文件:
- 说明仓库用途和范围的文件
- 提供重要技术文档的文件
- 展示使用示例和模式的文件
- 定义接口和规范的文件
- 包含配置和安装说明的文件
排除以下类型的文件:
- 纯实现细节的文件
- 包含冗余信息的文件
- 构建产物或生成内容
- 与理解项目无关的文件
Execution Steps
执行步骤
Step 1: Repository Analysis
步骤1:仓库分析
- Examine the repository structure completely
- Read the main README.md to understand the project
- Identify all documentation directories and files
- Catalog specification files and their purposes
- Find example files and configuration files
- 完整检查仓库结构
- 阅读主README.md以理解项目
- 识别所有文档目录和文件
- 整理规范文件及其用途
- 找到示例文件和配置文件
Step 2: Content Planning
步骤2:内容规划
- Determine the primary purpose statement
- Write a concise summary for the blockquote
- Group identified files into logical categories
- Prioritize files by importance for LLM understanding
- Create descriptions for each file link
- 确定主要用途说明
- 为块引用编写简洁摘要
- 将识别到的文件分组到逻辑类别中
- 按对LLM理解的重要性对文件排序
- 为每个文件链接创建描述
Step 3: File Creation
步骤3:文件创建
- Create the file in the repository root
llms.txt - Follow the exact format specification
- Include all required sections
- Use proper markdown formatting
- Ensure all links are valid relative paths
- 在仓库根目录创建文件
llms.txt - 严格遵循格式规范
- 包含所有必填章节
- 使用正确的Markdown格式
- 确保所有链接都是有效的相对路径
Step 4: Validation
步骤4:验证
- Verify compliance with https://llmstxt.org/ specification
- Check that all links are valid and accessible
- Ensure the file serves as an effective LLM navigation tool
- Confirm the file is both human and machine readable
- 验证是否符合https://llmstxt.org/规范
- 检查所有链接是否有效且可访问
- 确保文件可作为有效的LLM导航工具
- 确认文件同时适用于人类和机器阅读
Quality Assurance
质量保证
Format Validation
格式验证
- ✅ H1 header with project name
- ✅ Blockquote summary (if included)
- ✅ H2 sections for file lists
- ✅ Proper markdown link format
- ✅ No broken or invalid links
- ✅ Consistent formatting throughout
- ✅ 包含项目名称的H1标题
- ✅ 块引用摘要(如果包含)
- ✅ 用于文件列表的H2章节
- ✅ 正确的Markdown链接格式
- ✅ 无损坏或无效链接
- ✅ 全程格式一致
Content Validation
内容验证
- ✅ Clear, unambiguous language
- ✅ Comprehensive coverage of essential files
- ✅ Logical organization of content
- ✅ Appropriate file descriptions
- ✅ Serves as effective LLM navigation tool
- ✅ 清晰、明确的语言
- ✅ 全面覆盖重要文件
- ✅ 内容组织逻辑清晰
- ✅ 文件描述恰当
- ✅ 可作为有效的LLM导航工具
Specification Compliance
规范合规性
- ✅ Follows https://llmstxt.org/ format exactly
- ✅ Uses required markdown structure
- ✅ Implements optional sections appropriately
- ✅ File located at repository root ()
/llms.txt
- ✅ 严格遵循https://llmstxt.org/格式
- ✅ 使用要求的Markdown结构
- ✅ 恰当实现可选章节
- ✅ 文件位于仓库根目录()
/llms.txt
Example Structure Template
示例结构模板
txt
undefinedtxt
undefined[Repository Name]
[Repository Name]
[Concise description of the repository's purpose and scope]
[Optional additional context paragraphs without headings]
[Concise description of the repository's purpose and scope]
[Optional additional context paragraphs without headings]
Documentation
Documentation
- Main README: Primary project documentation and getting started guide
- Contributing Guide: Guidelines for contributing to the project
- Code of Conduct: Community guidelines and expectations
- Main README: Primary project documentation and getting started guide
- Contributing Guide: Guidelines for contributing to the project
- Code of Conduct: Community guidelines and expectations
Specifications
Specifications
- Technical Specification: Detailed technical requirements and constraints
- API Specification: Interface definitions and data contracts
- Technical Specification: Detailed technical requirements and constraints
- API Specification: Interface definitions and data contracts
Examples
Examples
- Basic Example: Simple usage demonstration
- Advanced Example: Complex implementation patterns
- Basic Example: Simple usage demonstration
- Advanced Example: Complex implementation patterns
Configuration
Configuration
- Setup Guide: Installation and configuration instructions
- Deployment Guide: Production deployment guidelines
- Setup Guide: Installation and configuration instructions
- Deployment Guide: Production deployment guidelines
Optional
Optional
- Architecture Documentation: Detailed system architecture
- Design Decisions: Historical design decision records
undefined- Architecture Documentation: Detailed system architecture
- Design Decisions: Historical design decision records
undefinedSuccess Criteria
成功标准
The created file should:
llms.txt- Enable LLMs to quickly understand the repository's purpose
- Provide clear navigation to essential documentation
- Follow the official llms.txt specification exactly
- Be comprehensive yet concise
- Serve both human and machine readers effectively
- Include all critical files for project understanding
- Use clear, unambiguous language throughout
- Organize content logically for easy consumption
创建的文件应满足:
llms.txt- 让LLMs能够快速理解仓库的用途
- 为重要文档提供清晰的导航
- 严格遵循官方llms.txt规范
- 全面且简洁
- 同时有效服务于人类和机器读者
- 包含所有理解项目所需的关键文件
- 全程使用清晰、明确的语言
- 逻辑化组织内容以便于阅读