Skip to main content
Glama

arno.insert

Insert new text into a file without overwriting existing content. Place it before or after an exact anchor, or append to the end when no anchor is given.

Instructions

Add text to a file without replacing anything — a new function, a new section, an extra case. Use this for additive work instead of rewriting a surrounding symbol. With no anchor it appends to the end of the file; with one it places the text before or after that anchor, refusing if the anchor is absent or matches more than once. Several additions or edits at once belong in apply.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathYesFile to add to.
textYesText to insert.
anchorNoOptional. Exact, unique text to place the insertion beside. Omit to append to the end of the file.
positionNoOptional. "before" or "after" the anchor. Defaults to after.
expectedDigestNoOptional. The digest from the read this edit is based on; the edit is refused if the file changed since, by anyone.
expectedRevisionNoOptional. Revision expected before editing; the edit is rejected if the workspace has moved on. Omit for no precondition.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.0.12

TDQS

A4.6/5.0
Behavior4/5

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

Beyond the annotations (destructiveHint=false), the description discloses append-vs-anchor behavior and refusal conditions (missing anchor, multiple matches). This is concrete behavioral context that the annotations alone do not provide. It doesn't cover permissions, but the schema already documents digest/revision preconditions.

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?

Three sentences with zero filler: purpose, usage, and behavior are cleanly separated. The most important 'add without replacing' is front-loaded, and each sentence contributes new information.

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?

The description is complete for a single-edit tool with full schema coverage: it covers purpose, usage, anchor semantics, and points to apply for batch work. It does not describe return value behavior, but no output schema exists and the essential preconditions are in the parameter descriptions. For an agent picking and invoking the tool, this is sufficient.

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 the bar is moderate, but the description adds real meaning for anchor and position by explaining append default and before/after placement. It also explains refusal on ambiguous anchors, which is not in the schema. ExpectedDigest and expectedRevision are left to their schema descriptions, which is acceptable given full coverage.

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?

States a specific verb ('add') and resource ('text to a file') with a clear non-destructive scope, and explicitly distinguishes itself from rewriting (replace_text) and from apply for batch edits. The phrase 'without replacing anything' makes the tool's role unambiguous.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives explicit direction: use for additive work instead of rewriting a surrounding symbol, and routes multi-edit work to apply. This tells the agent when to choose this tool and when to pick an alternative, satisfying the highest bar.

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