Skip to main content
Glama
ShiYioo

opencode_native_tools

by ShiYioo

read

Read files or directories from the local filesystem using absolute paths. Retrieve specific line ranges with offset and limit, and view images or PDFs as attachments.

Instructions

Read a file or directory from the local filesystem. The filePath should be absolute. By default, returns up to 2000 lines starting at line 1. Use offset (1-indexed) and limit to read later sections. Lines are returned as : ; directories list entries with a trailing / for subdirectories. Lines longer than 2000 characters are truncated. Images and PDFs are returned as attachments.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNoThe maximum number of lines to read (defaults to 2000)
offsetNoThe line number to start reading from (1-indexed)
filePathYesThe absolute path to the file or directory to read
Behavior5/5

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

With no annotations, the description fully carries the behavioral burden. It discloses default line limits, offset/limit behavior, line formatting, truncation, directory listing format, and attachment handling for images/PDFs—all beyond what the schema provides.

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?

The description is concise and every sentence adds value. It is well-structured, covering purpose, usage, output format, and edge cases in a compact set of sentences with no redundancy.

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

Completeness5/5

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

Since there is no output schema, the description adequately explains return values and formatting. It covers common edge cases like line limits, long lines, directories, and binary attachments, making it complete for an agent to use the tool correctly.

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?

Schema coverage is 100%, so parameters are already documented. The description adds meaningful context: absolute path requirement, 1-indexed offset, default line count, line formatting, and directory trailing slash behavior, which enriches the agent's understanding beyond schema descriptions.

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?

The description clearly states it reads a file or directory from the local filesystem, which is a specific verb+resource. It distinguishes itself from sibling tools like glob, grep, write, and edit by focusing on reading local content, and from webfetch by specifying local filesystem.

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 provides clear context: reading local files/directories, requiring absolute paths, and using offset/limit for large files. It does not explicitly name alternatives or exclusion criteria, but the context is sufficiently clear to avoid confusion with sibling tools.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/ShiYioo/opencode_native_tools'

If you have feedback or need assistance with the MCP directory API, please join our Discord server