Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Unwraps hard-wrapped markdown files so that each sentence ends with a newline instead of mid-sentence line breaks. Joins continuation lines within a paragraph into single lines, then re-breaks at sentence boundaries (period, question mark, exclamation point). Preserves blank lines, headings, fenced code blocks, block quotes, and list items. Use when asked to unwrap text, fix line breaks, reflow sentences, or clean up hard-wrapped markdown or .qmd files.
| Test case | Without → With | Effect | Δ tokens | Δ turns |
|---|---|---|---|---|
| case-08 | ✗→✓ | ▲ Improved | 47% | 0% |
| case-12 | ✗→✓ | ▲ Improved | -26% | 0% |
| case-13 | ✗→✓ | ▲ Improved | 16% | 0% |
| case-14 | ✗→✓ | ▲ Improved | -28% | 0% |
| case-15 | ✗→✓ | ▲ Improved | 85% | 0% |
Reflow a markdown (or .qmd) file so that each sentence occupies its own line. This is the inverse of hard-wrapping: mid-sentence newlines are removed and the text is re-broken only at sentence endings.
| Position | Required | Description | |----------|----------|-------------| | 1 | Yes | Path to the input .md or .qmd file | | 2 | No | Output path. Defaults to overwriting the input file in-place |
Example invocations:
/markdown-unwrap paper/paper.qmd
/markdown-unwrap README.md README-unwrapped.mdProcess the file line-by-line, maintaining a current paragraph buffer:
#, ##, …) or ~~~); toggle a in-code-block flag and pass all lines through until the closing fence>-, *, +, or a digit followed by ./)--- / ... (pass the entire front-matter block through unchanged)(?<=[.!?])\s+ — i.e., after a sentence-ending punctuation mark followed by whitespace.Implement the algorithm directly in your response — read the file, process it line-by-line following the rules above, and write the result. No external script is needed.
The sentence-split heuristic: a period followed by whitespace and an uppercase letter is a sentence boundary unless the word immediately before the period is a known abbreviation. Maintain a blocklist of common abbreviations that should never trigger a split:
Mr, Mrs, Ms, Dr, Prof, Sr, Jr, Rev, Gove.g, i.e, et al, vs, etcFig, Eq, Sec, Ch, Vol, No, ppWhen the token before the period matches one of these (case-insensitively), do not split. For ? and ! there is no abbreviation concern — always split.
Other measured skills in the registry, with their headline benchmark lift.