Skip to main content
Glama

map_update_edge

[PUBLIC WRITE - TOPOLOGY LINK] Record or update (Upsert) a directional relation between two nodes in the Map Ledger (.braincell/map.jsonl). ROUTING vs SIBLINGS: Use map_update_edge to CREATE or MODIFY edge attributes/weight; use map_invalidate_edge to DEACTIVATE an existing edge without deleting lineage history. UPSERT SEMANTICS: Creates edge if absent, updates relation/weight if existing. RETURNS: { success: true, edge: { edge_id, from, to, rel, weight, status: "ACTIVE" } }. Side effects: Writes edge event to .braincell/map.jsonl WAL log.

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": {
      "from": "<from>",
      "to": "<to>",
      "rel": "<rel>"
    },
    "name": "map_update_edge"
  }
}

Input Schema

NameRequiredDescriptionDefault
toYesTarget node ID (e.g. "cell_fact_02").
relYesRelation type (supports, why, depends_on, relates_to, part_of).
fromYesSource node ID (e.g. "cell_skill_01").
weightNoEdge weight or confidence score (0.0 to 1.0).
edge_idNoOptional explicit edge ID for targeted upsert.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changed
    • addedInput schema / properties / edge_id
      Added value: +{
      +  "description": "Optional explicit edge ID for targeted upsert.",
      +  "type": "string"
      +}
    • changedInput schema / properties / from / description
      Previous value: -"Source node ID."New value: +"Source node ID (e.g. \"cell_skill_01\")."
    • changedInput schema / properties / to / description
      Previous value: -"Target node ID."New value: +"Target node ID (e.g. \"cell_fact_02\")."
    • addedInput schema / properties / weight
      Added value: +{
      +  "default": 1,
      +  "description": "Edge weight or confidence score (0.0 to 1.0).",
      +  "type": "number"
      +}
  2. Changed3 schema fields changed
    • changedInput schema / properties / from / description
      Previous value: -"Source ID"New value: +"Source node ID."
    • changedInput schema / properties / rel / description
      Previous value: -"Relation type (8 canonical branches)."New value: +"Relation type (supports, why, depends_on, relates_to, part_of)."
    • changedInput schema / properties / to / description
      Previous value: -"Target ID"New value: +"Target node ID."
  3. Added

TDQS

A4.3/5.0
Behavior4/5

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

With no annotations provided, the description carries the full burden and does most of it: it discloses upsert semantics, the exact return shape, and the side effect of writing an edge event to the .braincell/map.jsonl WAL log. It omits failure modes and any permission/authorization requirements beyond the "PUBLIC WRITE" tag, which keeps it just short of 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.

Conciseness4/5

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

The text is front-loaded and labeled with clear section headers (SIBLINGS, UPSERT SEMANTICS, RETURNS, Side effects), so each sentence earns its place. The parenthetical "(Upsert)" and the RETURNS block mildly duplicate the UPSERT SEMANTICS sentence, costing a point.

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 mutation tool with no annotations and no output schema, the description supplies the return object shape and the persistent side effect, which is the critical missing information. It is nearly complete; error/conflict behavior on upsert is the only notable omission.

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%, so the schema already documents from/to/rel/weight/edge_id, including the relation enum values and weight range. The description only restates that relation and weight are updatable and adds nothing about edge_id targeted-upsert behavior, so the baseline 3 applies.

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 description names a specific verb ("Record or update (Upsert)") and resource ("a directional relation between two nodes in the Map Ledger"), and explicitly distinguishes the tool from its closest sibling map_invalidate_edge. An agent can identify exactly what this does without opening the 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 gives explicit routing guidance: use map_update_edge to create or modify edge attributes/weight, and use map_invalidate_edge to deactivate without deleting lineage. Both the when-to-use and the when-to-use-the-alternative conditions are stated.

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