Skip to main content
Glama

Read Project File

read_project_file

Read the full contents of a project file using a path relative to the project root. Inspect a specific file before editing or discussing it.

Instructions

Reads and returns the full contents of a file in the current project, given a path relative to the project root. Use this to inspect a specific file's contents before editing or discussing it.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
filepathYesPath to the file, relative to the project root.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.8/5.0
Behavior3/5

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

With no annotations, the description carries the full behavioral burden. It usefully discloses that it returns 'the full contents' of a file, implying a read-only, non-destructive operation, but says nothing about behavior for missing files, binary/encoding handling, large-file limits, or permissions—gaps that matter for a file-read tool.

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 tight sentences, no redundancy, and the core purpose is front-loaded before the usage note. Every clause 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?

For a single-parameter, read-only tool with a fully covered schema and no output schema, the description is essentially complete: an agent knows what it does, when to use it, and what it returns. Only minor edge-case behavior (errors, encoding) is unaddressed.

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 100%, and the single parameter is fully documented in the schema ('Path to the file, relative to the project root'). The description restates the same relative-to-root semantics without adding format, extension, or resolution details, so the baseline 3 applies.

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 and resource ('Reads and returns the full contents of a file') with an explicit scope ('in the current project'), which is immediately distinguishable from siblings like list_project_structure and search_code. It does not name those siblings directly, keeping it at 4 rather than 5.

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?

Gives clear situational guidance: 'Use this to inspect a specific file's contents before editing or discussing it,' which ties the tool to a concrete workflow. It lacks explicit when-not-to-use or alternative-naming (e.g., use search_code to locate a file), so it falls short of 5.

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