Sarah Chen, SEO Content Strategist
What This Tool Does
Claude is exceptional at working with long documents, but it performs best when those documents are clearly delimited and the task is well placed. This tool takes raw Markdown and produces a Claude-optimized prompt: it cleans noise, tags code blocks, wraps your content in XML tags, and orders everything the way Anthropic recommends.
XML-Tagged Structure
Rather than relying on Markdown fences alone, the output wraps your document in a <document> tag (with an optional title attribute) and any instruction in an <instructions> tag. These explicit boundaries are the format Claude parses most reliably, reducing the chance it confuses reference material with the task you want done.
Document-Then-Instruction
For long-context prompts, Anthropic recommends placing the bulky document first and the instruction last. The tool follows this ordering automatically, so Claude reads your material and then encounters a clear, final statement of what to do with it.
Token Budgeting
The optimized output's token count is estimated and shown against Claude's context windows, including the standard 200K and the 1M-token beta. You can confirm even a large document fits comfortably and leaves room for a detailed response.
Common Use Cases
- Document Q&A: ground Claude on a spec, contract, or article.
- Summarization: hand Claude a long report with a clear instruction.
- Code understanding: provide tagged code for review or explanation.
- Reusable prompts: standardize a document + instruction template.
Tips
- Always add a concise instruction — Claude weights the final instruction heavily.
- Use a descriptive title so Claude can refer to the document by name.
- Clean content pasted from other tools first with the Markdown Cleaner.
