Skip to main content
Glama
isina-nej
by isina-nej

Read host file

read_file
Read-only

Read text file contents from allowed host paths, respecting configured permissions. Specify path and optional max characters.

Instructions

Read a text file from an allowed host path.

Default readable roots are the home directory plus /etc and /var/log on Linux/macOS. Configure HOST_MCP_READ_ROOTS to change them.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathYes
max_charsNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.8.0

TDQS

C2.7/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true, so the tool is known to be read-only. The description adds useful behavioral context about allowed readable roots (home directory, /etc, /var/log) and configurability via HOST_MCP_READ_ROOTS. However, it does not disclose behavior for out-of-root paths, binary files, or what happens when max_chars is exceeded (e.g., truncation). The description adds some value but is not fully transparent.

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?

The description is concise—two sentences—and front-loads the core purpose in the first sentence. It does not waste words, though it omits parameter details. Given its brevity, it is well-structured but could be slightly improved by including a note about max_chars.

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

Completeness2/5

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

For a tool with 2 parameters and no schema descriptions, the description is incomplete. It fails to explain the 'path' parameter semantics, the 'max_chars' parameter, error handling for non-existent or unreadable files, and the return format (though an output schema exists, it is not provided in the input). It also does not distinguish from similar sibling tools. An agent would struggle to invoke it correctly without additional information.

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

Parameters1/5

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

Schema description coverage is 0%, so the description must compensate for the lack of parameter documentation. It does not explain the 'path' parameter format, how it relates to allowed roots, or the purpose and default of 'max_chars' (default 50000). Without any parameter explanation in the description, an agent cannot reliably know how to set these parameters correctly.

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 clearly states the tool's purpose: 'Read a text file from an allowed host path.' It uses a specific verb (Read) and resource (text file from allowed path). It is clear but does not differentiate from siblings like head_file or tail_file that also read file content, though it implies reading the whole file rather than a portion.

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?

The description provides no guidance on when to use this tool versus alternatives. It does not mention when to prefer read_file over head_file, tail_file, file_stat, or other file-reading tools. The only contextual note is about allowed roots, which is a restriction rather than usage guidance.

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