Skip to main content
Glama

pine_read32

Read a 32-bit unsigned value from emulated memory at a 4-byte aligned address.

Instructions

Read an unsigned 32-bit little-endian value from emulated memory. Address should be 4-byte aligned.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
addressYesMemory address (4-byte aligned)

Implementation Reference

  • src/tools.ts:55-63 (registration)
    Registration of the 'pine_read32' tool as a Tool definition in the TOOLS array, including its name, description, and input JSON schema (requires an integer 'address' property with 4-byte alignment).
    {
      name: "pine_read32",
      description: "Read an unsigned 32-bit little-endian value from emulated memory. Address should be 4-byte aligned.",
      inputSchema: {
        type: "object",
        required: ["address"],
        properties: { address: { type: "integer", description: "Memory address (4-byte aligned)" } },
      },
    },
  • Handler case in the CallToolRequestSchema switch statement: calls pine.read32(addr()) and returns the result formatted as hex and decimal.
    case "pine_read32": return ok(`${addrHex(addr())}: ${fmtHex(await pine.read32(addr()))}`);
  • The PineClient.read32() method that implements the low-level PINE protocol Read32 operation: sends opcode 0x02 with a 4-byte LE address argument and reads back a 32-bit unsigned LE value from the reply buffer.
    async read32(addr: number): Promise<number> {
      const args = Buffer.alloc(4); args.writeUInt32LE(addr, 0);
      const r = await this.call(Op.Read32, args);
      return r.readUInt32LE(0);
    }
  • Definition of the Read32 opcode constant (0x02) used in the PINE wire protocol.
    Read32:       0x02,
Behavior3/5

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

Since no annotations are provided, the description must cover behavioral traits. It states the operation is a read from emulated memory and mentions alignment, which implies it does not modify state. However, it does not specify return value semantics, potential errors, or whether it allows only aligned addresses (enforced or assumed). The description is adequate but not exhaustive.

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 extremely concise with two sentences, each adding value. It is front-loaded and avoids unnecessary words, making it easy for an AI agent to parse quickly.

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?

Given the simplicity of the tool (one parameter, no output schema, no annotations), the description covers the essential aspects: operation, data type, and constraint. It is complete for the intended use.

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?

The input schema already describes the only parameter ('address') with 100% coverage. The description reiterates the alignment requirement but adds no new meaning. Baseline score of 3 applies because the schema does the heavy lifting.

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 specifies the operation ('Read'), resource ('emulated memory'), data type ('unsigned 32-bit little-endian value'), and alignment requirement. This distinguishes it from sibling read tools of different bit widths and endianness, making the purpose unambiguous.

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?

The description provides a necessary alignment constraint ('Address should be 4-byte aligned') but does not explicitly guide when to choose this tool over siblings like pine_read16 or pine_read64. The name itself implies bit width, but explicit differentiation would improve clarity.

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/dmang-dev/mcp-pine'

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