PHPackages                             rllngr/kirby-llmsizer - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. rllngr/kirby-llmsizer

ActiveKirby-plugin

rllngr/kirby-llmsizer
=====================

Kirby plugin to generate /llms.txt and /llms-sitemap.xml for AI search engines. Works in both classic and headless mode.

00PHP

Since Mar 28Pushed 1mo agoCompare

[ Source](https://github.com/RLLNGR/kirby-llmsizer)[ Packagist](https://packagist.org/packages/rllngr/kirby-llmsizer)[ RSS](/packages/rllngr-kirby-llmsizer/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

kirby-llmsizer
==============

[](#kirby-llmsizer)

A Kirby CMS plugin that generates `/llms.txt` and `/llms-sitemap.xml` for AI search engines (Perplexity, ChatGPT, Claude…). Part of the **rllngr** plugin set.

Features
--------

[](#features)

- Generates `/llms.txt` and `/llms-full.txt` in standard Markdown format
- Generates `/llms-sitemap.xml` in XML sitemap format
- Classic mode (direct Kirby routes) and headless mode (JSON API)
- Configurable sections with Kirby query strings or PHP callables
- Template and page exclusions with include-override
- Optional trailing slash on URLs
- Built-in caching with auto-invalidation on content changes
- Panel blueprint section (`sections/llms`) with description and AI instructions fields

Installation
------------

[](#installation)

```
composer require rllngr/kirby-llmsizer
```

Or place the plugin folder in `site/plugins/kirby-llmsizer`.

Endpoints
---------

[](#endpoints)

URLFormatDescription`/llms.txt`MarkdownStandard LLM content file`/llms-full.txt`MarkdownFull version with extended page content`/llms-sitemap.xml`XMLSitemap for LLM indexers`/__llms__`JSONHeadless mode API`/__llms-full__`JSONHeadless mode API (full)Configuration
-------------

[](#configuration)

In `config.php`:

```
return [
    'rllngr.kirby-llmsizer' => [
        // 'classic' or 'headless'
        'mode' => 'classic',

        // Caching
        'cache'         => true,
        'cacheDuration' => 60, // minutes

        // Trailing slash on page URLs
        'trailingSlash' => false,

        // Enable /llms-sitemap.xml (classic mode only)
        'sitemap' => true,

        // Override base URL (headless mode)
        'siteUrl' => null,

        // Exclusion rules (applied across all sections)
        'exclude' => [
            'templates' => ['error'],
            'pages'     => ['private-page'],
        ],

        // Force-include pages despite exclusion rules
        'include' => [
            'pages' => [],
        ],

        // Panel field names
        'fields' => [
            'description'  => 'llmsdescription',
            'instructions' => 'llmsinstructions',
        ],

        // Content sections
        'sections' => [
            [
                'heading'         => 'Projects',
                'pages'           => 'site.find("projects").children.listed',
                'itemDescription' => 'excerpt',
                'itemContent'     => 'text', // used in llms-full.txt
            ],
            [
                'heading'         => 'About',
                'pages'           => 'site.find("about")',
                'single'          => true,
                'itemDescription' => 'text',
            ],
        ],
    ],
];
```

### Section options

[](#section-options)

KeyTypeDescription`heading`stringSection title (H2 in llms.txt)`pages`string|callableKirby query string or `function($kirby)` returning a `Page` or `Pages``single`boolTreat result as a single page (default: `false`)`limit`intMax number of items`itemTitle`string|callableField name or callable for item title`itemUrl`callableCustom URL resolver`itemDescription`string|callableField for short description`itemContent`string|callableField for full content (llms-full.txt only)Panel Integration
-----------------

[](#panel-integration)

Add the section to any blueprint:

```
sections:
  geo:
    extends: sections/llms
```

This adds the **llmsdescription** and **llmsinstructions** fields to the panel page.

License
-------

[](#license)

MIT — [Nicolas Rollinger](https://rollinger.ch)

###  Health Score

19

—

LowBetter than 10% of packages

Maintenance60

Regular maintenance activity

Popularity0

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity11

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/a423a955706f2f0254ab40c1bc7a17f9a88f8134a65d51a0036cd0e9ce0d6382?d=identicon)[RLLNGR](/maintainers/RLLNGR)

---

Top Contributors

[![RLLNGR](https://avatars.githubusercontent.com/u/34002361?v=4)](https://github.com/RLLNGR "RLLNGR (2 commits)")

### Embed Badge

![Health badge](/badges/rllngr-kirby-llmsizer/health.svg)

```
[![Health](https://phpackages.com/badges/rllngr-kirby-llmsizer/health.svg)](https://phpackages.com/packages/rllngr-kirby-llmsizer)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
