{"uid":"cap_zx_4BFPvsxACCATjbsQsB","slug":"brainiac-llms-txt-context-budget-analyzer-60a04026","name":"BRAINIAC llms.txt Context Budget Analyzer","description":"Pay-per-call APIs for AI agents: OFAC sanctions screening, compliance checks, token security, and Base chain data via x402. No account. Fixed USDC price. MCP-ready.","url":"https://www.brainiac.software/api/v1/llms-txt/context-budget-analyze?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"text":{"type":"string","maxLength":200000},"document":{"type":"object","properties":{"title":{"type":"string","maxLength":200},"summary":{"type":"string","maxLength":5000},"sections":{"type":"array","items":{"type":"object","required":["name","links"],"properties":{"name":{"type":"string","maxLength":200},"links":{"type":"array","items":{"type":"object","required":["title","url"],"properties":{"url":{"type":"string","maxLength":2000},"title":{"type":"string","maxLength":200},"description":{"type":"string","maxLength":1000}},"additionalProperties":false},"maxItems":200}},"additionalProperties":false},"maxItems":50}},"additionalProperties":false}}},"responseSchema":{"type":"json","example":{"score":87,"issues":[{"type":"duplicate_line","evidence":"Read this before calling the API today.","location":"line 9 and line 10","severity":"medium","description":"The same line of at least 20 characters appears more than once."},{"type":"duplicate_url","evidence":"/start","location":"line 6 and line 7","severity":"medium","description":"The same link path is repeated, so an agent may read the same target twice."}],"success":true,"analysis":"Measured 284 characters, 11 lines, and 2 links. The character estimate is 71 tokens at 4 characters per token.","warnings":[],"limitations":["The parser reads ATX headings, a blockquote directly after the H1, and markdown list links. It does not fetch URLs, run HTML, or decide that a link works.","Token count is Math.ceil(characters / 4). It is not the tokenizer of any model.","Score: 100, minus 5 per repeated line group (max 40), minus 8 per repeated path group (max 30), minus 8 when the text exceeds 8000 characters or 15 when it exceeds 20000.","Repeated text is an exact trimmed line. Similar sentences that are not identical are not counted."],"recommendations":[{"type":"repeated_description","location":"line 6","description":"The same link description appears on more than one link."}]}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.03","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.03/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.03","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.03","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_mxpS0mqWiH5EUTizhjJ2Y","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.03","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Analyzes an llms.txt document or raw text for token budget efficiency, duplicate content, and structural quality issues, returning a scored report with issues and recommendations.","exampleAgentPrompt":"Can you analyze this llms.txt document for me and check if it has any duplicate links, repeated lines, or token budget issues — then give me a quality score and recommendations to clean it up?","exampleUseCases":[{"title":"Pre-deploy llms.txt quality audit","prompt":"Before I publish my site's llms.txt, can you run it through the context budget analyzer to check for duplicate URLs, repeated lines, and estimate how many tokens it'll cost an agent reading it? Here's the full text: [paste llms.txt content]"},{"title":"Token budget check for large docs","prompt":"My llms.txt is getting long and I'm worried it's eating too much of agents' context windows. Can you analyze it and tell me exactly how many tokens it uses, and flag anything that's making it unnecessarily large?"},{"title":"Structured document section review","prompt":"I've structured my llms.txt with a title, summary, and several sections with links. Can you audit it for duplicate link paths, repeated descriptions, and give me a score out of 100 so I know how well it's optimized for AI agents?"}],"resultDescription":"A JSON object containing a 0–100 quality score, a list of issues (each with type, evidence, location, severity, and description), an analysis summary with character/line/link counts and estimated token count, warnings, limitations of the analysis, and an array of recommendations for improving the document.","failureModes":["Text exceeds 200,000 character limit — request rejected","Malformed document object missing required section fields — validation error","Empty or missing both text and document fields — no content to analyze","Network or payment failure via x402 — no response returned","Token estimate inaccuracy for non-English or code-heavy content due to fixed 4-chars-per-token heuristic"],"whenToPreferThis":"Use this endpoint when you need to validate and score an llms.txt document specifically — checking for duplicate lines, repeated URL paths, token budget sizing, and structural completeness. Prefer this over generic text linters when you are preparing an llms.txt file for AI agent consumption and want a domain-specific quality score with actionable recommendations. No account or API key is needed; payment is per-call in USDC on Base via x402.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-11-12T12:37:06.333Z","isFirstParty":false,"canonicalSlug":"brainiac-llms-txt-context-budget-analyzer-60a04026"}