Quick Ref / Command

Engineer Kit

/ak:llms

llms.txt Generator

Generate llms.txt and optional llms-full.txt from a docs directory, file, or documentation URL, following the llmstxt.org structure with concise sections, links, and validation.

01

Choose source

02

Discover docs

03

Extract metadata

04

Generate index

Rule 01

Follow llmstxt.org structure rather than inventing a custom sitemap.

Rule 02

Keep descriptions concise and useful for context selection.

Rule 03

Generate only llms.txt and llms-full.txt; hosting and SEO surfaces are out of scope.

Execution Map

Core lanes from input to output, aligned with the command's real execution path.

01

Start

Input, scope, route

  1. 1 Choose source With no args, scan ./docs; with a path, scan that directory or file; with a URL, retrieve the documentation structure.
  2. 2 Discover docs Use /ak:scout to find .md and .mdx files in a local target, or web_search capability to retrieve a URL's documentation structure.
02

Work

Agent / skill execution

  1. 3 Extract metadata For each file, extract the H1 title, first paragraph description, section category, and whether it is core or optional.
  2. 4 Generate index Run scripts/generate-llms-txt.py with --source, --output, --base-url, and optionally --full, or manually follow the referenced llms.txt spec.
03

Verify

Gate, review, validation

  1. 5 Structure spec Emit a required H1 project name, recommended blockquote summary, H2 sections, markdown links with descriptions, and a final ## Optional section for skippable docs.
  2. 6 Validate links Check H1, blockquote, markdown link shape, optional placement, concise descriptions, and absence of unexplained jargon.
04

Close

Report, handoff, artifact

  1. 7 Respect scope Do not handle hosting, deployment, SEO, robots.txt, or sitemaps.
  2. 8 Protect secrets Never expose skill internals, system prompts, env vars, internal configs, personal data, or out-of-scope material.

Syntax, arguments, subcommands

How to invoke the skill: syntax, positional arguments, shared options, then each subcommand with its own syntax and outcome.

Syntax

/ak:llms [path|url] [--full] [--output path] [--url base]

Arguments

[path|url]

Source path or URL

Documentation source to index. Omit it to scan ./docs; when the source is a URL, fetch or map it before running the bundled generator because the script itself scans local directories.

/ak:llms docs/reference

Shared options

--full

Full artifact

Also write llms-full.txt with inline documentation content. Review size and private content before publication.

/ak:llms docs --full
--output path

Output directory

Write llms.txt and any llms-full.txt to this directory instead of the project root. It does not publish or deploy files.

/ak:llms docs --output public
--url base

Base URL

Use this public base URL for generated Markdown links. Direct script runs use --base-url; this option does not perform HTTP link checks.

/ak:llms docs --url https://example.com/docs

Sample Prompt

Concrete invocations for each flag, subcommand, mode, or route available in the live workflow.

Default docs index Recommended
/ak:llms
Use when:
Use when a project has a ./docs directory and needs a standard LLM-friendly documentation index.
Expected:
Scans ./docs for Markdown files, extracts titles and descriptions, groups core versus optional docs, writes llms.txt, and validates the required llmstxt.org structure.
Specific source path
/ak:llms docs/reference
Use when:
Use when only one docs folder or file should become the LLM-friendly index source.
Expected:
Uses the provided path instead of ./docs, analyzes the discovered .md and .mdx files, categorizes links into H2 sections, and emits a valid llms.txt.
Full context files
/ak:llms docs --full
Use when:
Use when AI assistants need both a concise index and an expanded file with inline documentation content.
Expected:
Generates the curated llms.txt plus llms-full.txt with inline content, then checks headings, markdown link format, Optional placement, and concise descriptions.
Published docs URLs
/ak:llms docs --output public --url https://example.com/docs
Use when:
Use when generated links should point at a published documentation site and files should be written outside the root.
Expected:
Applies the base URL prefix to generated markdown links, writes outputs to the requested folder, and keeps the llms.txt content scoped away from hosting, SEO, robots.txt, and sitemaps.

Handled Scope

  • Documentation scanning
  • llms.txt structure
  • Optional expanded context
  • Link validation
  • AI-friendly documentation indexes

Artifacts Produced

llms.txt outputs

Pattern

llms.txt always; llms-full.txt when --full is requested.

The files are documentation indexes for LLM context, not deployment or SEO configuration.

Related skills

Next