Skip to main content
Glama
pico-bay

pico-bay

Official

Write a board file

pico_file_write
Destructive

Create or overwrite a file on a connected MicroPython or CircuitPython board, automatically creating missing parent directories and accepting UTF-8 or base64 content up to 8 MB.

Instructions

Create or overwrite one board file, creating missing parent directories. content may be UTF-8 text or base64 and is limited to 8 MB decoded.

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": {
      "board_id": "<board_id>",
      "path": "<path>",
      "content": "<content>"
    },
    "name": "pico_file_write"
  }
}

Input Schema

NameRequiredDescriptionDefault
pathYesPath on the board filesystem, relative to its root.
contentYes
board_idYesStable board UID returned by pico_boards_list, or its current serial device path.
encodingNoutf8

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.9/5.0
Behavior4/5

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

Annotations already declare destructiveHint=true and readOnlyHint=false; the description adds real value beyond them by disclosing that existing content is overwritten, that missing parent directories are auto-created, and that decoded content is capped at 8 MB. Remaining gaps are minor: no statement about connectivity requirements, idempotency, or failure behavior on exceeding the size limit.

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 sentences, front-loaded with the core action and overwrite semantics, followed by the format and size constraints. No filler or redundant restatement of the tool name.

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 destructive write with no output schema, the definition covers the important operational facts (overwrite, parent creation, encoding options, size cap). It stops short of describing the return value or error conditions, which an agent would still need to handle.

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 only 50%, so the description must compensate, and it does partially: 'content may be UTF-8 text or base64' explains the content format and implicitly the role of the encoding parameter, plus the 8 MB decoded constraint. Neither parameter is named directly and the utf8 default is left to the schema, so it is not fully compensatory.

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 pair and resource ('Create or overwrite one board file') and adds the important detail that overwriting is allowed, which is the key semantic distinction from a pure-create tool. It is clearly separable from siblings like pico_file_read and pico_directory_create, though it never names an alternative explicitly.

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?

Usage is implied by 'create or overwrite' and the parent-directory behavior, but there is no explicit guidance on when to use this versus pico_directory_create, pico_path_rename, or pico_path_delete, and no prerequisite or exclusion statements.

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