Skip to main content
Glama

Word count

text_word_count
Read-onlyIdempotent

Count words, characters, sentences, paragraphs, lines, and unique words in text or a file; estimate reading and speaking times; list top keywords with density. Supports English and Arabic.

Instructions

Count words, characters (with and without spaces), sentences, paragraphs, lines and unique words; estimate reading (238 wpm) and speaking (150 wpm) time; list the most used keywords with density. Works for English and Arabic (tashkeel ignored). Give "text" or a text file "path". Web version: https://s3eidat.github.io/word-count/

Input Schema

NameRequiredDescriptionDefault
pathNoOr: a path to a UTF-8 text file.
textNoThe text to analyse.
keywordsNoHow many top keywords to return (0 = none).
includeStopWordsNoCount common words like "the"/"في" as keywords.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.1/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint, idempotentHint and openWorldHint=false, so safety is covered. The description adds genuine behavioral context beyond that: fixed 238/150 wpm constants for the estimates, tashkeel being ignored for Arabic, and keyword density semantics. It does not clarify what happens if both text and path are provided, which is the main remaining gap.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Outputs are front-loaded in a single dense semicolon-delimited sentence, followed by two short sentences on language support and input modes. The trailing web-version URL is the one element that doesn't help an agent invoke the tool, but the overall structure is efficient.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no output schema, the description correctly carries the burden of describing return values, and it enumerates nearly everything returned including keyword density. Remaining gaps are minor: precedence when both text and path are supplied, and behavior on unreadable paths, though the read-only annotations mean no destructive risk is hidden.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline is 3. The description adds meaning on top by framing "text" and "path" as alternative inputs rather than independent fields, and by explaining that keyword output is ranked with density. The keywords count and stop-word toggle are left entirely to the schema, which is acceptable given full coverage.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description names specific verbs and outputs — count words/characters/sentences/paragraphs/lines/unique words, estimate reading (238 wpm) and speaking (150 wpm) time, and list top keywords with density. This clearly separates it from siblings like ai_token_count (tokens), text_readability (scores), and text_social_count (platform limits).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Usage is only implied: the description says to supply "text" or a text file "path" and notes English/Arabic support, which conveys input modes but not when to choose this tool over alternatives. It never names a sibling such as ai_token_count or text_readability or states exclusions. An agent must infer applicability from the output list.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools