Skip to main content
Glama

set_thread_lineage

DestructiveIdempotent

Assign a producer's run_id as the parent_run_id for a thread to attribute nested work to that producer run.

Instructions

Home a producer's run_id on a thread as parent_run_id. Accepts the producer's string as-is (does not mint a parallel id). Empty / whitespace / over-long is rejected. Use when attributing nested work to a producer run; set_thread_result also auto-homes when the payload carries run_id.

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": {
      "thread_id": "<thread_id>",
      "parent_run_id": "<parent_run_id>"
    },
    "name": "set_thread_lineage"
  }
}

Input Schema

NameRequiredDescriptionDefault
thread_idYes
parent_run_idYesthe producer's run identifier (e.g. waiter envelope run_id)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv479.0.0

TDQS

A3.7/5.0
Behavior3/5

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

Annotations already declare destructiveHint=true, idempotentHint=true, readOnlyHint=false, so the safety profile is supplied. The description usefully adds input validation ('empty / whitespace / over-long is rejected') and the as-is/no-parallel-id behavior, but never explains what the destructive flag destroys, e.g. whether an existing parent_run_id is overwritten or lineage is cleared.

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?

Three tight sentences, front-loaded with the core action, then constraints, then the usage/alternative note. Dense but no filler; a reader can act after the first sentence.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a two-parameter destructive mutation with no output schema, the definition covers input semantics and timing but leaves open what happens on overwrite of an existing parent, what errors look like, and what the caller gets back. Adequate, with clear remaining gaps.

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 description coverage is 50%; thread_id carries only a UUID format hint while parent_run_id has a short description. The description compensates by explaining what the run_id must be (the producer's own string, taken as-is), which validation rejects it, and where it comes from ('waiter envelope run_id'), adding real meaning beyond the schema.

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?

The definition names a concrete verb-plus-resource pair: homing a producer's run_id onto a thread as parent_run_id. 'Home' is jargon, but the clause 'as parent_run_id' and 'does not mint a parallel id' pin down the exact effect so an agent can distinguish it from set_thread_lineage-like siblings.

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

Usage Guidelines4/5

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

It gives an explicit trigger ('Use when attributing nested work to a producer run') and flags the overlap case where set_thread_result auto-homes when the payload carries run_id. It stops short of a firm exclusion rule (e.g. 'do not call before/after set_thread_result'), so it is clear but not fully disambiguating.

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

Deploy Server

Other Tools