Skip to main content
Glama

Save the final edit of a draft

save_edit
DestructiveIdempotent

Save the user's FINAL edited version of a generated draft. Call this when the user has finished editing a draft (in conversation or elsewhere) and is happy with it — the diff against the original feeds ScriptGrain's closed-loop voice learning, so future drafts in that profile improve. Needs a generation with status 'drafted' (an 'outline' id has no draft to diff against); afterwards its status is 'edited'. Optional voice_rating (1-5): how well the ORIGINAL draft matched their voice. Saving again for the same generation replaces the previous edit. Free.

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": {
      "generation_id": "<generation_id>",
      "final_text": "<final_text>"
    },
    "name": "save_edit"
  }
}

Input Schema

NameRequiredDescriptionDefault
final_textYesThe user's final version of the text.
voice_ratingNoUser's 1-5 rating of how well the original draft matched their voice.
generation_idYesThe generation the user edited.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4/5.0
Behavior3/5

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

Annotations already declare this is a non-read-only, destructive, idempotent, closed-world write. The description adds valuable context beyond that: the prerequisite status, the resulting status change to 'edited', overwrite-on-repeat behavior, and that the call is free. It still doesn't cover error behavior or what the response contains, so this is solid 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.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loads the core action, then prerequisites, then optional parameter notes, with no filler sentences. The single dense paragraph is slightly harder to scan than a short bulleted structure would be, but every clause carries information.

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?

For a mutating, three-parameter tool with no output schema, the description covers the trigger, state precondition, state transition, repeat-call behavior, and cost. Nothing essential for correct invocation is missing.

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?

Schema coverage is 100%, so every parameter is already documented. The description adds the 'drafted' status constraint on generation_id and clarifies replacement semantics, but it mostly restates the voice_rating range and meaning already in the schema. Baseline 3 is appropriate.

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?

Opens with a specific verb and resource: save the user's final edited version of a generated draft. It clearly separates this action from listing or restoring versions, but it doesn't explicitly name a sibling tool for the agent to contrast against.

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 an explicit trigger ('when the user has finished editing a draft and is happy with it') plus a hard precondition (generation must be in 'drafted' status) and a negative case ('an outline id has no draft to diff against'). The agent knows both when to call and when the call will fail.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources