Download the PHP package kozmozio/kirby-llms without Composer

On this page you can find all versions of the php package kozmozio/kirby-llms. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package kirby-llms

Kozmoz Kirby LLMs Plugin

A Kirby CMS plugin that generates an llms.txt file in the root of your website or responds to the llms.txt route with necessary information for Large Language Models (LLMs)

Overview

This plugin creates an llms.txt file that provides structured information about your website to help Large Language Models better understand and interact with your content. Similar to how robots.txt works for search engines, llms.txt provides guidance for LLMs.

Features

Installation

Manual Installation

  1. Download or clone this repository
  2. Place the folder kirby-llms in your site/plugins directory
  3. Rename the folder to kirby-llms if needed

Composer Installation

Configuration

Via Config File

You can configure the plugin by adding options to your config.php file:

Via Kirby Panel

The plugin also provides a panel interface for configuring the settings. To enable this, you need to add the LLMs tab to your site blueprint.

  1. Add the LLMs tab to your site.yml blueprint:

This will add a new "LLMs" tab to your site settings in the panel, where you can configure:

Blueprint Structure

The plugin uses the following blueprint structure:

You can customize these blueprints by copying them to your site's blueprint directory and modifying them as needed:

Configuration Options

Option Type Default Description
enabled boolean true Enable or disable serving llms.txt
sitemap_enabled boolean true Enable or disable XML sitemap generation
cache boolean false Enable or disable caching
cache.duration integer 60 Cache duration in minutes
add_trailing_slash boolean true Whether to add trailing slashes to URLs in the output
group_by string 'parent' Group pages by: 'parent' (parent page name), 'template' (template type), or 'none' (flat list)
exclude.templates array ['error'] Templates to exclude from the output
exclude.pages array [] Pages to exclude from the output
include.pages array [] Pages to always include despite exclusions

Excluding Pages

You can exclude specific pages from the llms.txt output by adding their slugs to the exclude.pages array in your configuration. The plugin performs matching on:

For example:

Including Pages (Override Exclusions)

You can specify pages that should always be included in the output, even if they would normally be excluded by template or page exclusion rules. This is useful when you want to exclude a template globally but include specific pages that use that template.

The include.pages option overrides all exclusion rules and uses the same matching logic as exclusions:

For example:

In this example:

Include rules always take precedence over exclude rules.

Usage

Once installed, the plugin automatically sets up two routes:

The LLMs content will be in Markdown format with proper Markdown links for pages and their descriptions. The sitemap will be in standard XML format following the sitemap protocol. All HTML tags are automatically stripped from descriptions and metadata to ensure clean, plain text output.

Automatic Cache Clearing

The plugin automatically clears its cache when:

This ensures that both the llms.txt content and sitemap.xml are always up-to-date with your website's content.

Example Output

LLMs.txt Output

With default group_by: parent:

With group_by: none (flat list):

Sitemap.xml Output

Static Site Generation

If you're using a static site generator with Kirby, make sure to include both routes in your static routes:

Development Status

Phase 1: Basic Structure and Setup ✓

  1. Create plugin folder structure ✓
  2. Set up plugin initialization ✓
  3. Register the route for llms.txt ✓
  4. Implement basic configuration options ✓

Phase 2: Core Functionality ✓

  1. Develop the content generator for llms.txt ✓
  2. Implement page collection and filtering ✓
  3. Create the response formatter ✓
  4. Add caching mechanism ✓

Phase 3: Advanced Features ✓

  1. Add customization options for content exclusion ✓
  2. Implement metadata extraction ✓
  3. Add automatic cache clearing when content changes ✓
  4. Strip HTML tags from descriptions and metadata ✓
  5. Ensure URLs have trailing slashes ✓

Phase 4: Testing and Documentation ✓

  1. Test with different Kirby setups ✓
  2. Create comprehensive documentation ✓
  3. Add examples and use cases ✓
  4. Prepare for release ✓

Author

Inan Olcer Kozmoz

License

MIT


All versions of kirby-llms with dependencies

PHP Build Version
Package Version
Requires getkirby/composer-installer Version ^1.1
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package kozmozio/kirby-llms contains the following files

Loading the files please wait ...