Skip to content

BuddySpuds/llms-txt-validator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

llms-txt-validator

PyPI License: MIT

Validate llms.txt files for AI agent discoverability. Built by Citability — the AI visibility scoring platform.

What is llms.txt?

llms.txt is a proposed standard (llmstxt.org) for providing LLMs and AI agents with structured context about a website. It helps tools like ChatGPT, Claude, Perplexity, and Gemini better understand and cite your content.

This validator checks your llms.txt file against the spec, scoring it from 0–100 and flagging errors and recommended improvements.

Install

pip install llms-txt-validator

Usage

CLI

# Validate a remote site (fetches /llms.txt automatically)
llms-txt-validate example.com

# Validate a specific URL
llms-txt-validate https://example.com/llms.txt

# Validate a local file
llms-txt-validate ./llms.txt

Python

from llms_txt_validator import validate_llms_txt, fetch_and_validate

# Validate string content
result = validate_llms_txt(open("llms.txt").read())
print(f"Score: {result.score}/100")
print(f"Valid: {result.valid}")
print(f"Sections: {result.sections}")

# Fetch and validate from URL
result = fetch_and_validate("citability.ai")

What it checks

  • H1 title (required) — 30 points
  • Summary blockquote (recommended) — 20 points
  • H2 section headers — up to 30 points
  • Markdown links — up to 20 points
  • URL format (absolute URLs) — warnings on relative URLs

Want more?

For a comprehensive AI visibility scan that checks llms.txt and robots.txt AI rules, Schema.org, MCP endpoints, citation readiness, and 51 other AI discovery signals, try the free scanner at:

https://citability.ai/scan

Citability scores domains across 5 pillars (Authority, Performance, Content, Social, Agentic) using 44+ metrics from Common Crawl, DataForSEO, PageSpeed Insights, and proprietary AI visibility scanners.

License

MIT — see LICENSE for details.

Related

About

Validate llms.txt files for AI agent discoverability. Built by Citability.ai

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages