Skip to main content
Glama

Upsert Node

upsert_node

Create or update a curated graph node for features, extensions, or notes. Use it to manually correct knowledge without a reindex overwriting your changes.

Instructions

Create or update one graph node. Prefer this for curated nodes (feature:, ext:, note: ids, or a manual correction to a code node) -- code nodes (file:/fn:) are normally written by index_repo instead, so a later reindex does not immediately overwrite what you just wrote.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYes
kindYes
pathNo
repoNo
labelYes
vaultNo
linenoNo
originNomanual
statusNoverified
summaryNo
note_pathNo
confidenceNohigh

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.4/5.0
Behavior3/5

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

With no annotations, the description carries the full behavioral burden. It does disclose one genuinely useful trait: code-node writes here can be clobbered by a subsequent reindex. But it says nothing about how defaults (origin=manual, status=verified, confidence=high) behave, what happens on id collision beyond 'update', or whether the operation is reversible.

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 sentences, front-loaded with the core action and then the routing constraint. Every clause works; no filler. Minor awkwardness only in the parenthetical id-prefix lists.

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?

An output schema exists, so return values need not be described, and the overwrite hazard is covered. However, for a 12-parameter mutation tool with no annotations, the description leaves the majority of parameters and the write semantics undocumented.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0% across 12 parameters, so the description must compensate and largely doesn't. It adds meaning only for the id parameter via the prefix conventions; kind, path, repo, vault, lineno, origin, status, summary, note_path, and confidence are left entirely unexplained, including their non-obvious defaults.

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 first sentence gives a specific verb+resource: create or update one graph node. It goes further by naming the identifier conventions it owns (feature:, ext:, note:) and explicitly contrasting with code nodes (file:/fn:) which are the domain of index_repo. It stops short of clarifying the relationship to the plural sibling upsert_nodes.

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 clear routing guidance: use this for curated nodes or manual corrections, and let index_repo own code nodes. The rationale (a later reindex would overwrite your write) makes the choice concrete. It doesn't address when to batch via upsert_nodes vs calling this once.

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