承接 rllngr/kirby-llmsizer 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

rllngr/kirby-llmsizer

最新稳定版本:1.1.2

Composer 安装命令:

composer require rllngr/kirby-llmsizer

包简介

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

README 文档

README

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

  • 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

Requirements

  • Kirby 4 or 5
  • PHP 8.1+

Installation

Via Composer (recommended — installs automatically into site/plugins/):

composer require rllngr/kirby-llmsizer

Manually — download or clone into site/plugins/kirby-llmsizer.

Endpoints

URL Format Description
/llms.txt Markdown Standard LLM content file
/llms-full.txt Markdown Full version with extended page content
/llms-sitemap.xml XML Sitemap for LLM indexers
/__llms__ JSON Headless mode API
/__llms-full__ JSON Headless mode API (full)

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

Key Type Description
heading string Section title (H2 in llms.txt)
pages string|callable Kirby query string or function($kirby) returning a Page or Pages
single bool Treat result as a single page (default: false)
limit int Max number of items
itemTitle string|callable Field name or callable for item title
itemUrl callable Custom URL resolver
itemDescription string|callable Field for short description
itemContent string|callable Field for full content (llms-full.txt only)

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

MIT — Nicolas Rollinger

统计信息

  • 总下载量: 16
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 8
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2026-03-29

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固