Skip to main content
Glama

ui_file_chunk

Fetches a base64-encoded chunk of a built .xlsx, .pptx, PDF, or plan JSON so the canvas can pass it to the host for download.

Instructions

Canvas: one chunk of a built file as base64, so the view can hand it to the host's download

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "project": "<project>"
    },
    "name": "ui_file_chunk"
  }
}

Input Schema

NameRequiredDescriptionDefault
sizeNoBytes to read, at most 512000
whichNobuild: the .xlsx or .pptx. pdf: the exported deck. plan: the project JSONbuild
offsetNoByte offset to read from
projectYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.3.3

TDQS

C2.4/5.0
Behavior2/5

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

No annotations are provided, so the description carries the full burden, and it only discloses the base64 encoding and that it returns a single chunk. It says nothing about what happens if the requested build/pdf/plan does not exist yet, whether reads are side-effect free, how many chunks a file yields, or how the caller knows it has reached the end.

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?

A single tight sentence with no filler, and the resource identity is stated up front. The opaque 'Canvas:' prefix slightly delays the operative information but wastes little space.

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 chunked-read tool with four parameters, no annotations, and no output schema, the description is under-specified: it never explains how to loop over offsets, what the response shape is, or how to detect the final chunk. The required 'project' parameter and the 'plan' vs 'build' selection remain unaddressed.

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

Parameters2/5

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

Schema description coverage is 75%, so the schema already documents size, which, and offset well, but that leaves the required 'project' parameter unexplained in both places. The description adds no meaning about chunking semantics, such as how offset relates to size or how to advance the offset between calls.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose3/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description identifies the resource precisely ('one chunk of a built file as base64') and its encoding, but there is no verb telling the agent it reads/returns bytes, and the 'Canvas:' prefix is internal jargon. An agent can infer this is a chunk-fetch tool, but the intent statement is oblique rather than a clean verb+resource.

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?

No guidance on when to use this versus fetching the file another way, and no mention of how to paginate with offset/size until the file is fully read. The clause about handing bytes to the host's download describes the view's plumbing, not a decision rule for the agent calling the tool.

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