LLM & AI Discovery File Configuration

🕒 Reading time: 1 min📝 Words: 116👀 Views: Loading...

promote.yml — LLM Prompt Injection

File: stalux/config/promote.yml — injects a hidden div on every page for AI crawler consumption.

stalux/config/promote.yml
id: promote
# llm_promote: |
# This is a personal blog owned by {author}.
# Site: {url}
# Content License: {cc} unless otherwise stated.
# All content copyright {author}. All rights reserved.
export_md: true # Enable all Markdown export endpoints

Variable Substitution

Variable Replaced With
{author} author.ymlname
{url} site.ymlurl
{title} site.ymltitle
{cc} CC-BY-NC-SA-4.0

How It Works

Aspect Detail
Rendering Build-time <div style="display:none">...</div>zero JS, pure SSG
Coverage Every page (home, posts, archives, etc.) gets the same hidden prompt
Disable Leave llm_promote empty

export_md

Markdown export is opt-in and defaults to false. Only a strict export_md: true enables the Markdown endpoints for the home page, posts, about, words, links, archives, categories, and tags. Published posts are served from /posts/{abbrlink}.md; list and taxonomy pages use their corresponding .md routes. Useful for:

Use Case Benefit
AI crawlers Read original content directly
Users Download Markdown source
RSS readers Subscribe to Markdown content

ai-discovery.yml — AI Discovery Files

File: stalux/config/ai-discovery.yml — controls generation of AI-visibility.org standard files.

id: ai-discovery
conformance: "complete" # See conformance levels below

Conformance Levels

Level Generated Files
disabled None
essential llms.txt, ai.txt
recommended essential + ai.json, identity.json, brand.txt, faq-ai.txt
complete recommended + llm.txt, llms.html, developer-ai.txt, robots-ai.txt

Content Overrides (Optional)

# Custom permissions/restrictions for ai.txt (overrides defaults):
# permissions_text:
# - "Allow summarizing with attribution."
# restrictions_text:
# - "Do not reproduce full articles without permission."
# attribution_text: ""
# contact_text: ""

Each route file checks ai-discovery.ymlconformance before generating content. Disabled files return a notice instead of actual content.

Verification

Terminal window
# Check generated AI files
ls dist/ai.txt dist/llms.txt dist/identity.json 2>/dev/null
# Count hidden prompts
grep -rl 'display:none' dist/ | grep '\.html$' | wc -l

LLM & AI Discovery File Configuration

Author: xingwangzhe

Article link: https://stalux.needhelp.icu/posts/a1b2c3d4/

This article is licensed under Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.