jekyll-llms-generator

A Jekyll generator plugin that automatically builds an /llms.txt file every time your site builds — keeping AI language models up to date with your latest content.

Gem Version

What is llms.txt?

llms.txt is an emerging convention that lets website owners expose a structured plain-text summary of their site's content for AI models and LLM crawlers. It's like robots.txt, but instead of telling crawlers what to ignore it tells them what matters and where to find it.

Installation

Add to your site's Gemfile:

gem "jekyll-llms-generator", "~> 0.1"

Add to your _config.yml plugins list:

plugins:
  - jekyll-llms-generator

Then run bundle install.

Configuration

All configuration lives under the llms_txt: key in _config.yml.

llms_txt:
  title: "Jason Chance"
  tagline: "Downtown revitalization, local government technology, and public finance."
  intro: |
    Jason Chance is a DDA director and web developer writing about public finance,
    local government technology, and downtown revitalization.
  link_tag: true       # inject <link rel="ai" href="/llms.txt"> into every HTML page (default: true)
  full: false          # also generate /llms-full.txt with full stripped-HTML content (default: false)
  sections:
    - title: "Blog Posts"
      collection: posts
      limit: 20          # optional: cap number of items
    - title: "Projects"
      collection: projects
    - title: "Pages"
      pages:
        - /about/
        - /contact/

Options

Key Default Description
title site title H1 heading at the top of llms.txt
tagline site description Blockquote line below the title
intro (none) Optional paragraph after the tagline
link_tag true Inject <link rel="ai" href="/llms.txt"> into HTML head
full false Also generate /llms-full.txt with full stripped-HTML content; adds a discovery link in llms.txt header
sections [] Array of section definitions (see below)

Section options

Each section must have a title. Specify one or both of collection and pages.

Key Description
collection Jekyll collection name (posts, projects, etc.)
limit Max number of items from this collection
pages Array of page URLs to include

Opt-out per document

Add llms_txt: false to any post or collection document's frontmatter to exclude it:

---
title: "Internal Draft"
llms_txt: false
---

Description used in llms.txt

The plugin looks for a description in this order:

  1. description: frontmatter
  2. tagline: frontmatter
  3. Automatically generated excerpt (first paragraph)

Descriptions use the first complete sentence — no hard character truncation.

Output

/llms.txt — compact reference: title, tagline, intro, and a bulleted list of links with first-sentence descriptions per section. When full: true, includes a [Full content version](/llms-full.txt) link in the header so LLM crawlers can discover the full file.

/llms-full.txt — full content file (when full: true). Each entry uses ### [Title](url) headings, a > description blockquote, the complete stripped-HTML article text, and --- separators between articles — making article boundaries unambiguous for LLM parsers.

Discovery

AI crawlers discover llms.txt by checking <your-site>/llms.txt directly, the same way they check robots.txt or sitemap.xml. Additional discovery signals:

  • The optional <link rel="ai" href="/llms.txt"> injected into every HTML page's <head> (link_tag: true, on by default)
  • The [Full content version] link in the llms.txt header points crawlers to llms-full.txt

You can also submit your site to the llmstxt.org directory for broader discovery.

Compatibility

  • Jekyll 3.7 – 4.x
  • Ruby 2.7+
  • Works with GitHub Pages via the remote_theme workflow (plugin must be listed in plugins:)

Contributing

See CONTRIBUTING.md.

License

MIT © Jason Chance