How to optimize llms.txt
Turn a flat list of URLs into a concise, prioritized map that helps AI systems find the right Creght pages first.
Creght automatically serves /llms.txt and a Markdown version of every indexed page. The URL inventory comes from the same source as the sitemap, while the llms field controls how those URLs are presented to an AI reader.
Why structure matters
Without configuration, every page appears in one alphabetically sorted Pages section. That is a safe default, but it gives a pricing page, a key implementation guide, and a minor legal page equal prominence.
A better file puts high-value product and documentation pages first, groups related content, and removes pages that are duplicated, obsolete, private in intent, or too weak to help an AI answer accurately.
Recommended configuration
Add llms at the top level of talizen.config.ts. The following configuration prioritizes core pages and AI documentation, keeps the blog together, and marks legal content as optional.
export default {
llms: {
sections: [
{ name: 'Core pages', pages: ['/', '/ai', '/price', '/creght-vs-fkw', '/creght-vs-sxl'] },
{ name: 'AI website docs', pages: ['/docs/ai/*'] },
{ name: 'Blog', pages: ['/blogs/*'] },
{ name: 'Optional', pages: ['/legal/*', '/tuikuan'] },
],
exclude: [
'/docs/pxrp79jqtnyq',
'/blogs/o8e12bemmru6',
'/blogs/pc3r8bxa0m72',
],
},
}
Section names are emitted exactly as written, so use labels that make sense to the AI audience for your site. The name Optional has special placement semantics and is conventionally used for links an AI can skip when context is limited.
How matching works
Exact paths
A pattern such as /price matches only /price. A leading slash may be omitted, but including it is clearer.
Prefix wildcards
A trailing /* matches the prefix page and every child path. /docs/ai/* matches /docs/ai and /docs/ai/guide, but not /docs/ai-tools.
First match wins
A page is assigned to the first matching section. Put narrow, high-priority sections before broad catch-all patterns.
Exclusions win first
The exclude list is checked before sections. A matching page is omitted even if it also matches a section pattern.
Inside a section, the order of patterns in pages is the primary sort order. URLs matched by the same pattern are sorted alphabetically. Empty sections are not rendered.
Pages that match no configured section are preserved in an automatic Pages section. If an Optional section exists, this fallback section is inserted immediately before it; otherwise it appears last.
Add site context
Use details for a short Markdown briefing that should be available before an AI follows any page link. Keep it factual, stable, and compact: what the product is, which documentation is authoritative, and any important terminology.
llms: {
details: `Creght is a visual and AI website builder.
Use the AI website docs for implementation guidance.
Use core pages for product and pricing facts.`,
sections: [/* ... */],
}
The generated file already starts with the site title and metadata.description. Do not repeat those verbatim in details; use the space for context that improves routing and interpretation.
Verification checklist
- Open
/llms.txton the deployed domain and confirm the most important section appears first. - Follow several generated
.mdlinks, including/index.mdfor the home page, and verify the content is useful without browser-only UI. - Check that wildcard patterns do not unintentionally absorb a more specific section.
- Confirm excluded URLs are absent and unclassified pages still appear under
Pages. - Keep
Optionallast so constrained AI readers can safely deprioritize it.
