Skip to main content
Glama
ianderso
by ianderso

update_child_ref

DestructiveIdempotent

Correct a child's relationship type to a parent in place, preserving citations, notes, and birth order that detaching and re-adding the child would lose.

Instructions

Change a child's relationship to the father or mother -- a stepson held as a birth child -- in place.

The child keeps the link's citations, notes and its place in the birth order, which detaching and re-adding the child loses.

Input Schema

NameRequiredDescriptionDefault
frelNoRelationship to the father: 'Birth', 'Adopted', 'Stepchild', 'Foster', 'Sponsored', 'Unknown', 'None'. Omit to keep.
mrelNoRelationship to the mother, the same values. Omit to keep.
childYesThe child's person handle or gramps_id.
familyYesFamily handle or gramps_id (e.g. 'F0001').
allow_new_typeNoAccept a type that is neither a Gramps standard type nor one of the tree's custom types, creating it as a new custom type. Only when meant: a near-miss is refused with the closest names.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv1.2.0
    • addedInput schema / properties / allow_new_type
      Added value: +{
      +  "default": false,
      +  "description": "Accept a type that is neither a Gramps standard type nor one of the tree's custom types, creating it as a new custom type. Only when meant: a near-miss is refused with the closest names.",
      +  "type": "boolean"
      +}
  2. Addedv1.0.1

TDQS

A4.2/5.0
Behavior4/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 covered. The description adds real behavioral value beyond that: it discloses exactly what is preserved (citations, notes, birth order) and contrasts the outcome with detach-and-re-add, which reframes an apparently destructive operation as a safer in-place edit.

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?

Two tight sentences with zero filler. The mutation and its in-place nature are front-loaded, and the second sentence justifies why this tool exists rather than merely restating the first.

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 5-parameter mutation tool with no output schema, the description supplies the key behavioral nuance an agent needs (in-place edit preserves metadata). The remaining gaps — return shape and the allow_new_type escape hatch — are adequately handled by the schema, so nothing critical 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 description coverage is 100%, and the per-parameter descriptions (frel/mrel allowed values, omit-to-keep semantics, handle vs gramps_id, allow_new_type behavior) are thorough on their own. The description only alludes to the father/mother relationship conceptually and adds no syntax, defaults, or format detail beyond the schema, so baseline 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?

States a specific verb ('Change') and resource ('a child's relationship to the father or mother') and pins the mode of operation with 'in place'. The stepson-as-birth-child example makes the exact scenario concrete, and it implicitly separates this tool from detach/re-add approaches used by siblings like detach_object or add_child_to_family.

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 clearly states the condition under which you'd use it (you want to change the parent-child relationship without losing link metadata), and it hints at the alternative path ('detaching and re-adding') by naming its cost. It never explicitly says when not to use it or names the sibling tools to prefer instead, so it falls short of a full 5.

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