text_counter
Count characters, words, lines, sentences, and paragraphs in a text block. Get reading time estimates and top frequent characters for quick analysis.
Instructions
Text Counter (character, word, and line tally). Count the characters, characters-without-spaces, words, lines, sentences and paragraphs of one block of text, plus average characters-per-word and words-per-sentence, an estimated reading time at three speeds, and (when the text exceeds 10 words) the ten most frequent a-z/space characters. Use this for a quick plain tally; use text_text_statistics instead for a richer linguistic profile with readability scores, or text_line_counter when you only need line counts and line-length metrics. Runs locally on the supplied text: read-only, non-destructive, contacts no external service, and is rate-limited. Returns a stats object, a readingTime object, and a topCharacters map.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| text | Yes | The text to count. May be empty; an empty string yields zero counts. Counting is Unicode code-point based; lines split on newlines, sentences split on runs of . ! ?, paragraphs split on blank lines. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| success | No | True when counting succeeded. | |
| stats | No | Core counts and averages. | |
| readingTime | No | Estimated reading time strings (e.g. 30 sec, 2 min). | |
| topCharacters | No | Map of the up-to-10 most frequent a-z/space characters to their counts. Empty object when the text has 10 or fewer words. |