• TypeScript 73.8%
  • Just 23.5%
  • JavaScript 2%
  • Shell 0.7%
Find a file
2026-05-31 09:54:27 -07:00
.agents Initial commit 2026-05-31 15:33:46 +00:00
.claude Initial commit 2026-05-31 15:33:46 +00:00
.codex Initial commit 2026-05-31 15:33:46 +00:00
.forgejo/workflows fix the build 2026-05-31 09:16:53 -07:00
.githooks Initial commit 2026-05-31 15:33:46 +00:00
.pi Initial commit 2026-05-31 15:33:46 +00:00
.vscode Initial commit 2026-05-31 15:33:46 +00:00
coverage new plugin: llms 2026-05-31 09:11:07 -07:00
openspec Initial commit 2026-05-31 15:33:46 +00:00
scripts Initial commit 2026-05-31 15:33:46 +00:00
src fix(llms): use Lume's actual page-data shape from search.pages 2026-05-31 09:36:40 -07:00
wiki Initial commit 2026-05-31 15:33:46 +00:00
.gitignore Initial commit 2026-05-31 15:33:46 +00:00
AGENTS.md new plugin: llms 2026-05-31 09:11:07 -07:00
CLAUDE.md Initial commit 2026-05-31 15:33:46 +00:00
deno.json release v0.1.2 2026-05-31 09:36:46 -07:00
deno.lock fix(llms): use Lume's actual page-data shape from search.pages 2026-05-31 09:36:40 -07:00
Justfile fix the build 2026-05-31 09:16:53 -07:00
LICENSE new plugin: llms 2026-05-31 09:11:07 -07:00
README.md Fix badge 2026-05-31 09:54:27 -07:00
test.just Initial commit 2026-05-31 15:33:46 +00:00

@tfks/lume-plugins

Lume plugins published by TFKS. Each plugin lives under src/<name>/ and is exported from deno.json.

Validation Checks

Setup

just setup     # check prereqs, configure git hooks, cache deps
just           # list available recipes
just test      # run the test suite
just validate  # run the full CI suite locally

Layout

  • src/<name>/mod.ts — plugin entry point (one directory per plugin)
  • src/<name>/mod.test.ts — tests
  • Justfile — task runner
  • wiki/ — repo-local memory (agent protocol, prompts)
  • AGENTS.md — operating manual for AI agents (and humans)
  • .forgejo/workflows/ — CI/CD

Releasing

just release # patch bump (default); pass `minor` or `major` to override

Plugins

llms — llms.txt generator

Emits a llms.txt file for your Lume site. This plugin renders the page title, description, and tags on each line so an LLM can decide whether a link is worth drilling into before fetching it.

// _config.ts
import lume from "lume/mod.ts"
import llms from "jsr:@tfks/lume-plugins/llms"

const site = lume()
site.use(llms({
  title: "My Site",
  description: "Notes on distributed systems.",
}))
export default site

Each emitted line looks like:

- [Quorum reads explained](/posts/quorum-reads/): when leader leases fail you — #consensus #postgres

Scoping which pages to include

The plugin follows the same convention as the built-in sitemap and feed plugins: pass a Lume search query via the query option. The query runs against page frontmatter, so a page opts in by setting the matching field.

Opt-in pattern — only pages with llms: true in their frontmatter:

site.use(llms({
  query: "llms=true",
}))
---
title: Quorum reads explained
llms: true
tags: [consensus, postgres]
---

Opt-out pattern — include everything except pages flagged llms: false:

site.use(llms({
  query: "llms!=false",
}))

Combined filters — queries support =, !=, ^=, $=, *=, <, >, <=, >=, space-separated AND, and | OR. So you can write query: "type=post llms!=false" to grab posts that haven't opted out.

For predicate logic the query syntax can't express, fall through to filter:

site.use(llms({
  query: "type=post",
  filter: (data) => !data.draft && (data.tags ?? []).length > 0,
}))

Options

Option Type Default Notes
filename string "llms.txt" Output filename, written to site.options.dest.
title string "Site" H1 heading.
description string "" Blockquote summary under the H1.
body string "" Free-form markdown inserted before the page list.
query string all pages Lume search query, e.g. "llms=true". Same syntax as sitemap/feed.
filter (data) => boolean include all Escape hatch applied after query; receives page.data.
sort (a, b) => number by URL Custom ordering, receives whole pages.