Skip to main content
Glama

arabic_token_metrics

Compute token-to-word ratios, character counts, and compression statistics for Arabic prompts to evaluate token efficiency and guide prompt optimization.

Instructions

Computes token-to-word ratio, character count, and compression statistics for Arabic prompts.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "text": "<text>"
    },
    "name": "arabic_token_metrics"
  }
}

Input Schema

NameRequiredDescriptionDefault
textYesThe Arabic text to evaluate.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.2/5.0
Behavior2/5

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

No annotations are provided, so the description carries the full burden. It does not disclose whether the operation is read-only (implied but unstated), and critically it never says which tokenizer or model the token counts are based on — a decisive detail for any token metric — nor anything about return format.

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

Conciseness5/5

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

One front-loaded sentence that names the metrics immediately, with no filler, hedging, or redundant restatement of the tool name.

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

Completeness3/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 does at least enumerate the returned metrics, which partly compensates. However, for a metrics tool the missing tokenizer/model basis and the absence of any sample output shape leave real ambiguity about what the numbers mean.

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?

Only one parameter exists and schema description coverage is 100%, with the schema already stating 'The Arabic text to evaluate.' Per the single-parameter baseline, the description need add nothing more, and it does not conflict with the schema.

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

Purpose4/5

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

States a specific verb ('Computes') and enumerates the exact metrics produced (token-to-word ratio, character count, compression statistics) for a specific resource (Arabic prompts). It is clearly distinct from siblings like arabic_normalize_text and arabic_strip_diacritics, though it never explicitly names that distinction.

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

Usage Guidelines2/5

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

There is no statement of when to use this tool, when not to, or which sibling to pick instead. An agent must infer from the sibling names that this is the measurement tool rather than a transformation tool.

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