Skip to main content
Glama

read

Read-only

Fetch file content from a workspace while returning a file revision needed for subsequent edit or write operations. Use offset and limit to retrieve additional context.

Instructions

Read actual file content using Pi. Returns a file revision for subsequent edit/write preconditions. Use offset/limit for more context.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathYesAbsolute path or path relative to the workspace. Home is a starting directory, not a sandbox.
limitNo
offsetNo
workspace_idYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.2

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true, destructiveHint=false, and openWorldHint=false, covering the safety profile. The description adds meaningful behavior beyond that: it returns a file revision that serves as a precondition for subsequent edit/write operations. This is valuable context not captured in annotations. The 'use offset/limit for more context' note also hints at pagination behavior. No contradictions.

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 concise sentences with no fluff. The core action ('Read actual file content') is front-loaded, followed by the key behavioral output (file revision) and parameter guidance. Every sentence earns its place.

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 tool is simple and the annotations cover safety. The description explains the primary use (read for edit/write) and mentions the return value (file revision). It does not detail error handling or non-existent files, but that is minor. For a low-complexity read tool with rich annotations, this is nearly complete. A 5 would require explicit handling of edge cases or more precise parameter semantics, but this is adequate.

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 coverage is low at 25% (only 'path' has a description). The description compensates partially by mentioning offset/limit for 'more context', giving them meaning. However, it does not explain workspace_id or the exact semantics of limit/offset (e.g., whether they refer to lines or bytes). Given the low coverage, the description should do more to clarify all parameters, but it at least addresses two of them.

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?

States a specific verb ('Read') and resource ('file content'), and immediately distinguishes from sibling tools like ls (listing) and grep (content search). It also clarifies that it returns a file revision, which is a distinct outcome. The purpose is unambiguous and differentiates it from the other tools.

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

Usage Guidelines4/5

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

The description clearly implies the primary use case: reading file content before an edit or write, since it returns a revision for preconditions. It also advises using offset/limit for more context. However, it does not explicitly mention alternatives or when not to use this tool, though the context makes it clear this is the dedicated read operation among siblings.

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