{"uid":"cap_LguJAWID6PexSwhkVEymK","slug":"lordevo-text-chunker-for-rag-fc9d2371","name":"Lordevo Text Chunker for RAG","description":"Text chunker for RAG (heading-aware, token-sized chunks): Splits text you send, or the main content of one public page, into heading-aware chunks of at most max_tokens with optional overlap, each with its heading path and an approximate token count, for RAG ingestion. Input: text (POST for long text","url":"https://shop.lordevo.com/api/quick/text-chunk?utm_source=zero.xyz","method":"GET","headers":{},"bodySchema":{"type":"object","$schema":"https://json-schema.org/draft/2020-12/schema","required":["input"],"properties":{"input":{"type":"object","required":["type","method"],"properties":{"type":{"type":"string","const":"http"},"method":{"enum":["GET"],"type":"string"},"queryParams":{"type":"object","required":[],"properties":{"url":{"type":"string","description":"Public http(s) URL or bare domain, e.g. https://example.com (instead of text)"},"text":{"type":"string","description":"Plain text or Markdown, 1-400,000 characters (short text in the query; long text as POST JSON {\"text\": \"...\"}) (or give url)"},"max_tokens":{"type":"string","default":"500","pattern":"^\\d{2,4}$","description":"Max tokens per chunk, 50-4000 (default 500)"},"overlap_tokens":{"type":"string","default":"50","pattern":"^\\d{1,4}$","description":"Tokens repeated from the previous chunk, 0 to half of max_tokens (default 50)"}}}},"additionalProperties":false},"output":{"type":"object","required":["type"],"properties":{"type":{"type":"string"},"example":{"type":"object","required":["tool","chunk_count","chunks"],"properties":{"tool":{"type":"string"},"chunks":{"type":"array","items":{"type":"object","properties":{"text":{"type":"string"},"index":{"type":"integer"},"heading":{"type":["string","null"]},"heading_path":{"type":"array"},"approx_tokens":{"type":"integer"}}}},"source":{"enum":["text","url"],"type":"string"},"truncated":{"type":"boolean"},"max_tokens":{"type":"integer"},"chunk_count":{"type":"integer"},"overlap_tokens":{"type":"integer"},"total_tokens_estimate":{"type":"integer"}}}}}}},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.002","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.002/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.002","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.002","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_9e03pwdGPOxj1qdZXgddG","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.002","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Splits plain text or a public webpage into heading-aware, token-sized chunks with overlap for RAG ingestion, returning each chunk's heading path and approximate token count.","exampleAgentPrompt":"Can you chunk this article into heading-aware pieces of at most 300 tokens each, with 50 tokens of overlap, so I can feed them into my RAG pipeline? Here's the text: [paste text]","exampleUseCases":[{"title":"Chunking a knowledge base article","prompt":"Take this 5,000-word support documentation page at https://docs.example.com/setup-guide and split it into heading-aware chunks of at most 400 tokens with 60 tokens of overlap so I can index them into my vector database."},{"title":"Preparing a research paper for RAG","prompt":"I have a long academic paper I'm pasting below — can you break it into chunks of no more than 600 tokens each, with 80 tokens of overlap, keeping the heading structure so I know which section each chunk belongs to?"},{"title":"Indexing a public blog post","prompt":"Chunk the content from https://blog.mysite.com/intro-to-llms into 500-token pieces with 50 tokens of overlap so I can embed them for semantic search — make sure each chunk includes its heading path."}],"resultDescription":"Returns a JSON object with an array of chunks, each containing: the chunk text, its sequential index, the heading it falls under, the full heading path (breadcrumb), and an approximate token count. Also includes top-level metadata: source type (text or url), total chunk count, max_tokens setting, overlap_tokens setting, total token estimate, and a truncated flag if input was trimmed.","failureModes":["Missing 'text' or 'url' parameter returns an error requesting at least one input","Text exceeding 400,000 characters may be truncated (truncated flag set to true)","Invalid max_tokens value outside 50–4000 range returns a validation error","Non-public or unreachable URL returns a fetch error","overlap_tokens exceeding half of max_tokens returns a validation error","Malformed URL format returns a parsing error"],"whenToPreferThis":"Choose this endpoint when you need heading-aware chunking that preserves document structure (heading paths) alongside token-controlled splitting with configurable overlap — ideal for RAG pipelines where semantic context and section provenance matter. Prefer it over generic text splitters when you need to chunk a live public webpage by URL without preprocessing, or when you need approximate token counts per chunk for downstream embedding budget management.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-31T18:35:44.669Z","isFirstParty":false,"canonicalSlug":"lordevo-text-chunker-for-rag-fc9d2371"}