Skip to content

starside-io/llmstxt-generator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

llms.txt Generator

A web-based tool to help you create llms.txt files for your website, making it easier for Large Language Models (LLMs) to index and understand your content.

llms.txt Generator License JavaScript

What is llms.txt?

llms.txt is a markdown file placed at /llms.txt on your website that provides LLMs with a structured summary, details, and links to key resources in a format that's easy to parse and index. Learn more at llmstxt.org.

Features

  • Automatic Content Extraction: Fetches website content and automatically generates llms.txt files
  • Manual Mode: Full manual control for custom content creation
  • Real-time Preview: See your llms.txt output as you type
  • Modern UI: Clean, responsive interface with Mars-themed design
  • Smooth Animations: Enhanced user experience with particle effects and smooth transitions
  • Mobile Responsive: Works perfectly on all device sizes

How It Works

  1. Automatic Mode (Default): Enter a website URL and the tool will:

    • Fetch the website content
    • Extract title, description, and key links
    • Generate a properly formatted llms.txt file
  2. Manual Mode: Toggle manual mode to:

    • Fill out form fields manually
    • Add custom sections and links
    • Have full control over the output

llms.txt Format

The generated file follows this structure:

# Project Title

> Short summary for LLMs

Optional details or notes about the project.

## Files

- [Docs Home](https://yoursite/docs/index.md): Main docs
- [API Reference](https://yoursite/api.md): API details

## Optional

- [Extra Resource](https://yoursite/extra.md)

Format Elements

  • # Title: H1 with your project/site name (required)
  • > Summary: Blockquote with a short summary (required)
  • Details: Optional plain markdown for extra context
  • ## Files: H2 section with markdown list of key links (recommended)
  • ## Optional: H2 section for secondary/extra links (optional)

Project Structure

llmstxt-generator/
├── index.html              # Main application page
├── easter-eggs.js          # Easter egg functionality
├── img/
│   └── mars.png           # Starside.io logo
└── js/
    ├── app.js             # Main application initialization
    ├── form-handler.js    # Form handling and URL fetching
    ├── main.js            # Core application logic
    ├── module-index.js    # Module exports
    ├── navigation.js      # Navigation and UI interactions
    ├── parser.js          # HTML parsing and content extraction
    ├── ui-effects.js      # Visual effects and animations
    └── utils.js           # Utility functions

Getting Started

Installation

  1. Clone the repository:
git clone https://github.com/starside-io/llmstxt-generator.git
cd llmstxt-generator
  1. Serve the files using any static web server:
# Using Python
python -m http.server 8000

# Using Node.js (with serve package)
npx serve .

# Using PHP
php -S localhost:8000
  1. Open your browser and navigate to http://localhost:8000

Usage

  1. Automatic Mode:

    • Enter a website URL in the input field
    • Click "Fetch" to automatically extract content
    • Review and copy the generated llms.txt content
  2. Manual Mode:

    • Toggle "Enable Manual Mode"
    • Fill out the form with your website information
    • Click "Generate llms.txt"
    • Copy the generated content to your website's /llms.txt file

Technical Details

Core Technologies

  • Vanilla JavaScript: No frameworks, pure ES6+ modules
  • Tailwind CSS: Utility-first CSS framework
  • HTML5: Semantic markup and modern web standards

Key Features

  • CORS Proxy: Uses a CORS proxy for fetching external websites
  • HTML Parsing: Extracts metadata, titles, and links from HTML content
  • Security Detection: Identifies and handles security service pages (Cloudflare, etc.)
  • Error Handling: Comprehensive error handling with user-friendly messages
  • Responsive Design: Mobile-first design approach

Browser Support

  • Chrome/Chromium 80+
  • Firefox 75+
  • Safari 13+
  • Edge 80+

Easter Eggs

This project includes interactive easter eggs for enhanced user experience. The easter eggs were generated using:

Try exploring the application to discover hidden features!

Contributing

Contributions are welcome! Please feel free to submit a Pull Request. For major changes, please open an issue first to discuss what you would like to change.

Development

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/AmazingFeature)
  3. Commit your changes (git commit -m 'Add some AmazingFeature')
  4. Push to the branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

License

This project is licensed under the MIT License - see the LICENSE file for details.

Built by Starside Labs

This tool is built by Starside Labs - Building powerful open source tooling and frameworks that democratize AI adoption.

Related Projects


Made with ❤️ by Starside Labs

About

Generate llms.txt file for your website

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors