Skip to main content
Glama
JacobBhatt12

ATR (Automation for Token Reduction)

by JacobBhatt12

atr_read_file

Read-only

Read only the needed parts of a local file by line range or regex search; for large code files without filters, returns an outline instead of full text.

Instructions

Read part of a local file. Pass lines= (e.g. from a search hit) or search= to get only what you need; with just a path, big code files return an outline instead of the whole file.

Input Schema

NameRequiredDescriptionDefault
pathYes
freshNoSend the full text even if you read it before.
linesNoLine range, e.g. 120-180.
budgetNo
searchNoRegex: only matching lines, with line numbers.
contextNoLines around each search match (default 0).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A3.8/5.0
Behavior4/5

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

Annotations already establish read-only, non-destructive, closed-world behavior. Beyond that, the description usefully discloses the non-obvious default that large code files may return an outline instead of full text when only a path is supplied.

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?

Two tightly written sentences front-load the main action and key usage modes. There is no redundant restatement of annotations or schema details.

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?

The description covers the core read behavior, partial-read modes, and outline fallback, which are the main things an agent needs. Without an output schema, it could say more about return formats and the undocumented budget parameter, but overall it is sufficiently complete.

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

Parameters3/5

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

Schema description coverage is 67%, and the description adds meaning for lines, search, and the path-only outline behavior. It still leaves budget undocumented in both schema and description, and context is only explained in 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?

The description states a specific verb and resource: read part of a local file. It clarifies scope through lines/search/outline behavior, but it does not explicitly differentiate this tool from sibling file-search or read tools such as atr_read or atr_search_code.

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?

It gives practical usage hints, such as passing lines from a search hit or using search to narrow results. However, it does not state when to use this tool versus siblings like atr_read, atr_search_code, or atr_query, nor does it give explicit exclusions.

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