Skip to main content
Glama
Keesan12

MartinLoop — Stop Runaway Loops, Bad Code & Token Waste

martin_pause

Destructive

Record a durable pause receipt for a MartinLoop run to temporarily hold work before risky follow-up. Provide a selector (file, loopId, or latest) and optional reason; does not terminate the process.

Instructions

Write a durable pause receipt for one canonical MartinLoop run. Provide exactly one selector: file, loopId, or latest; runsDir changes the run-store root, while reason and requestedBy add audit context. Use for a temporary hold before risky follow-up work. This records a request and does not kill a process; use martin_cancel to abandon work or martin_continue to resume.

Input Schema

NameRequiredDescriptionDefault
fileNoPath to one canonical run record or directory. Mutually exclusive with loopId and latest.
latestNoWhen true, targets the latest canonical run. Mutually exclusive with file and loopId.
loopIdNoCanonical MartinLoop run identifier. Mutually exclusive with file and latest.
reasonNoOptional non-empty reason recorded in the pause receipt.
runsDirNoOptional run-store root override used to resolve loopId or latest.
requestedByNoOptional human or runtime identity label recorded for audit context.

Output Schema

NameRequiredDescriptionDefault
okYesWhether the control receipt was recorded.
stateYesRun control state after this request, including all recorded receipts.
actionYesThe control action that was recorded.
loopIdYesMartinLoop run identifier the control was applied to.
reasonNoHuman-readable reason for the control, if provided.
summaryYesHuman-readable result of the control request.
controlIdYesUnique receipt ID for this control action.
requestedAtYesISO 8601 timestamp when the control was recorded.
requestedByNoIdentity that requested the control, if provided.
requestedActionYesThe control action that was requested.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changedv0.8.6
    • addedOutput schema / properties / ok
      Added value: +{
      +  "description": "Whether the control receipt was recorded.",
      +  "type": "boolean"
      +}
    • addedOutput schema / properties / requestedAction
      Added value: +{
      +  "description": "The control action that was requested.",
      +  "enum": [
      +    "pause",
      +    "cancel",
      +    "continue"
      +  ],
      +  "type": "string"
      +}
    • addedOutput schema / properties / state
      Added value: +{
      +  "additionalProperties": true,
      +  "description": "Run control state after this request, including all recorded receipts.",
      +  "type": "object"
      +}
    • addedOutput schema / properties / summary
      Added value: +{
      +  "description": "Human-readable result of the control request.",
      +  "type": "string"
      +}
    • changedOutput schema / required
      Previous value: -[
      -  "loopId",
      -  "action",
      -  "controlId",
      -  "requestedAt"
      -]New value: +[
      +  "loopId",
      +  "action",
      +  "controlId",
      +  "requestedAt",
      +  "ok",
      +  "summary",
      +  "requestedAction",
      +  "state"
      +]
  2. Changed1 schema field changedv0.6.6
    • removedInput schema / oneOf
      Removed value: -[
      -  {
      -    "required": [
      -      "file"
      -    ]
      -  },
      -  {
      -    "required": [
      -      "loopId"
      -    ]
      -  },
      -  {
      -    "required": [
      -      "latest"
      -    ]
      -  }
      -]
  3. Changed6 schema fields changedv0.5.9
    • addedInput schema / properties / file / description
      Added value: +"Path to one canonical run record or directory. Mutually exclusive with loopId and latest."
    • addedInput schema / properties / latest / description
      Added value: +"When true, targets the latest canonical run. Mutually exclusive with file and loopId."
    • addedInput schema / properties / loopId / description
      Added value: +"Canonical MartinLoop run identifier. Mutually exclusive with file and latest."
    • addedInput schema / properties / reason / description
      Added value: +"Optional non-empty reason recorded in the pause receipt."
    • addedInput schema / properties / requestedBy / description
      Added value: +"Optional human or runtime identity label recorded for audit context."
    • addedInput schema / properties / runsDir / description
      Added value: +"Optional run-store root override used to resolve loopId or latest."
  4. Changed3 schema fields changedv0.5.6
    • changedOutput schema / additionalProperties
      Previous value: -trueNew value: +false
    • addedOutput schema / properties
      Added value: +{
      +  "action": {
      +    "description": "The control action that was recorded.",
      +    "enum": [
      +      "pause",
      +      "cancel",
      +      "continue"
      +    ],
      +    "type": "string"
      +  },
      +  "controlId": {
      +    "description": "Unique receipt ID for this control action.",
      +    "type": "string"
      +  },
      +  "loopId": {
      +    "description": "MartinLoop run identifier the control was applied to.",
      +    "type": "string"
      +  },
      +  "reason": {
      +    "description": "Human-readable reason for the control, if provided.",
      +    "type": "string"
      +  },
      +  "requestedAt": {
      +    "description": "ISO 8601 timestamp when the control was recorded.",
      +    "type": "string"
      +  },
      +  "requestedBy": {
      +    "description": "Identity that requested the control, if provided.",
      +    "type": "string"
      +  }
      +}
    • addedOutput schema / required
      Added value: +[
      +  "loopId",
      +  "action",
      +  "controlId",
      +  "requestedAt"
      +]
  5. First observedv0.3.9

TDQS

A4.4/5.0
Behavior4/5

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

Annotations only declare idempotentHint=false and destructiveHint=true; the description adds the important clarification that this 'records a request and does not kill a process', which materially changes how an agent should reason about the destructive hint. It also flags the durable write. It stops short of covering permissions or repeat-call behaviour (non-idempotent → duplicate receipts?), which keeps it from a 5.

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?

Four sentences, front-loaded with the core action and effect, then selectors, then routing. Nothing is filler; even the semi-colon-packed selector sentence carries only required 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?

For a mutating tool with an output schema (so return values need not be explained) and annotations covering the safety hints, the description covers action, effect, selectors, audit fields, and sibling routing. Only secondary details such as required permissions or behaviour on repeated calls are absent.

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 the schema already documents every parameter, including the mutual exclusivity of file/loopId/latest and the roles of runsDir, reason, and requestedBy. The description restates the selector rule and field roles rather than adding new semantics, so the baseline of 3 is appropriate.

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 opening sentence names a specific verb and resource: 'Write a durable pause receipt for one canonical MartinLoop run.' The description also distinguishes the tool from its closest siblings by naming martin_cancel and martin_continue, so an agent can route without opening any schema.

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?

It states the positive case ('Use for a temporary hold before risky follow-up work') and the alternatives with their selecting conditions ('use martin_cancel to abandon work or martin_continue to resume'). The when-to-use / when-to-use-something-else decision is fully specified.

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