agentleFS
wu736139669wu736139669/markdown-for-agents-worker/skills/markdown-for-agents/SKILL.md

markdown-for-agents

Skill0 starsChanged 53 days agoMITView on GitHub

Make a static website readable and citable by AI agents and answer engines (GEO/AEO). Generates Markdown versions of every page, publishes llms.txt and llms-full.txt indexes, adds rel="alternate" type="text/markdown" link relations, and optionally wires content negotiation on Cloudflare Workers so agents sending 'Accept: text/markdown' get clean Markdown while browsers keep HTML. Use when asked to optimize a site for ChatGPT/Claude/Perplexity/Grok citations, add llms.txt, implement Markdown for Agents, or improve generative engine optimization for a website.

1 other project uses a version of this.

Adopted by

Most recently taken up by

  • Other versions1 project uses a version of this.

    Word for word · 0

    None found.

    Edited · 0

    None found.

    Wrote their own version · 1

    1. KKonstantinov/markdown-for-agents★ 34same name

    How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.

  • In this repositoryOne other file it gives its agents.

The file

We split this skill into the rules it gives an agent

5 rules. About 0 are common, 3 are distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈3

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Check what exists: robots.txt (must allow AI crawlers), llms.txt, JSON-LD (application/ld+json), sitemap.xml.

    line 26
  2. Distinctive:

    Use the bundled converter as a starting point, then review the output:

    line 32
  3. Distinctive:

    Keep name/description identical to the page title/meta description.

    line 74
  4. Distinctive:

    Don't convert runtime HTML per request: deterministic pre-generated files are faster, free, and reviewable.

    line 97
  5. Very specific:

    Only some agents send the Accept header today (Claude Code, OpenCode).

    line 99

≈ “Common” is an estimate: at least 1 in 5 of the 408,460 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Markdown for Agents

Turn a static site into a source AI agents can read cheaply: ship Markdown versions of every page and let agents fetch them. Live reference implementation: https://toolpantry.app (also a public repo, markdown-for-agents-worker).

When to use

  • The user wants their site cited/recommended by AI assistants.
  • The user mentions llms.txt, Markdown for Agents, GEO/AEO, AI search visibility.
  • A docs/marketing static site should be readable by Claude Code, OpenCode, Cursor, or similar agents (they send Accept: text/markdown).

Workflow

1. Survey first

  • Find the publish root (folder containing index.html).
  • Identify hosting: Cloudflare Workers/Pages, Netlify, Vercel, plain Nginx.
  • Check what exists: robots.txt (must allow AI crawlers), llms.txt, JSON-LD (application/ld+json), sitemap.xml.
  • Count pages and note which are content vs. app UI.

2. Generate Markdown versions

Use the bundled converter as a starting point, then review the output:

python3 scripts/generate_md.py ./public --base https://example.com

For template-driven sites, generating .md from the data model yields better quality than converting HTML — write a small generator instead. Rules: title as # H1, one > description blockquote, then content; keep FAQ Q&A; strip nav/forms/scripts; absolute links.

3. Publish indexes

  • llms.txt (spec: https://llmstxt.org): # Name, > summary, then sections of links — link to the .md URLs, e.g. - [Pricing](https://example.com/pricing.md): one-line description.
  • llms-full.txt: concatenation of every .md separated by \n\n---\n\n.

4. Add link relations to every page head

<link rel="alternate" type="text/markdown" href="/about.md" />
<link rel="describedby" href="/llms.txt" />

5. Content negotiation (Cloudflare Workers, free plan)

  • Copy scripts/worker.js into the site repo; configure:
{ "main": "worker.js",
  "assets": { "directory": ".", "binding": "ASSETS", "run_worker_first": true } }
  • The worker serves {path}.md when Accept: text/markdown is present and falls through to HTML otherwise; it sets Vary: Accept on both variants.
  • On non-Cloudflare hosting, the static .md files + llms.txt links still work — negotiation is a bonus, not a requirement.

6. Structured data (recommended, big GEO win)

  • WebSite + WebApplication JSON-LD per page; FAQPage wherever Q&A exists.
  • Keep name/description identical to the page title/meta description.

7. Verify and report

curl -s -H "Accept: text/markdown" https://example.com/about | head -3   # markdown
curl -sI https://example.com/about | grep -i vary                        # Vary: Accept
curl -s https://example.com/llms.txt | head -5                           # index ok

Report: pages converted, files added, negotiation status, anything skipped.

Checklist

  • .md counterpart exists for every content page
  • llms.txt links point at .md URLs; llms-full.txt generated
  • rel="alternate" + rel="describedby" on every page head
  • robots.txt explicitly allows GPTBot, ClaudeBot, PerplexityBot, GrokBot, Bingbot
  • Negotiation returns text/markdown; charset=utf-8 + Vary: Accept
  • JSON-LD parses on sampled pages

Notes

  • Don't convert runtime HTML per request: deterministic pre-generated files are faster, free, and reviewable.
  • Only some agents send the Accept header today (Claude Code, OpenCode); others discover .md via llms.txt and link relations — keep both paths working.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.