Skip to main content
Glama
KitchenSink4AI

io.github.nometalalchemist/kitchensink4xl

Write Range

write_range
Destructive

Write a rectangular block of values and formulas into a spreadsheet at a specified cell, replacing only that range while leaving surrounding content untouched.

Instructions

Write a 2D block of values and formulas anchored at the location's top-left cell. data is a list of row lists and must be RECTANGULAR: ragged rows refuse (pad short rows with null, which clears those cells); content outside the block is never touched. Formula strings ('=...') are normalized and flag recalculation. Grid limits and the 200,000-cell write ceiling apply. A hazardous workbook refuses unless allow_loss is true. Auto-backup to .ks4xl-backups; atomic verified save. Refuses while open in Excel.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
dataYesRows of cell values, rectangular: every row the same length.
pathYes
sheetNo
backupNo
locationYes
allow_lossNo
verify_comNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv1.2.0
    • changedOutput schema / (root)
      Previous value: -{
      -  "additionalProperties": true,
      -  "type": "object"
      -}New value: +null
  2. Changed4 schema fields changedv1.1.0
    • addedInput schema / properties / data / description
      Added value: +"Rows of cell values, rectangular: every row the same length."
    • addedInput schema / properties / data / items / items / anyOf
      Added value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "type": "number"
      +  },
      +  {
      +    "type": "boolean"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • addedInput schema / properties / data / items / items / description
      Added value: +"A cell value: text, a number, a boolean, or null to clear. A string beginning with '=' is stored as a formula."
    • addedInput schema / properties / location / anyOf
      Added value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "type": "object"
      +  }
      +]
  3. First observedv1.0.0

TDQS

A4.4/5.0
Behavior5/5

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

Annotations only supply readOnlyHint=false and destructiveHint=true; the description adds substantial beyond-annotation behavior: ragged rows are refused with null-padding semantics, content outside the block is untouched, formula normalization triggers recalculation, hazardous workbooks require allow_loss, auto-backup with atomic verified save, and refusal while open in Excel. No contradiction with the destructive hint.

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?

Seven sentences, each earning its place: purpose is front-loaded, followed by data invariants, safety ceilings, loss handling, and workflow guards. Dense but not bloated, with zero filler or repetition of schema or annotation content.

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 7-parameter destructive mutation with no output schema, the description covers behavior comprehensively: data shape, boundaries of effect, limits, hazard handling, backup, and concurrency refusal. It leaves minor gaps — no description of the confirmation/return payload, and sheet/verify_com semantics are unaddressed — but an agent can call this correctly with the information given.

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?

With only 14% schema description coverage, the description must compensate, and it does for the key parameters: data is explained in depth (list of row lists, must be rectangular, null clears, '=' prefix means formula), location is clarified as the top-left anchor, and allow_loss is mapped to the hazardous-workbook refusal. However, sheet, verify_com, and backup get no explicit parameter-level explanation beyond the general backup statement.

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 first sentence names a specific verb and resource ('Write a 2D block of values and formulas anchored at the location's top-left cell'), which clearly distinguishes it from single-cell writes (set_cell), clears (clear_range), and copies (copy_range). The anchoring detail adds precision beyond a generic 'write values' statement.

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 gives clear context for what the tool writes (rectangular blocks anchored top-left) and its constraints (200,000-cell ceiling, Excel lock refusal), so usage is implied. However, it never explicitly routes the agent away from near-siblings set_cells, apply_edits, or import_data, nor states when NOT to use it, which matters given ~40 sibling tools.

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