Skip to main content
Glama
Pseudogiant-xr

PseudoLife-MCP

Official

memory_graph_relate

Destructive

Assert a typed relation between two entities, auto-create or resolve them via aliases, and bump confidence on repeats. Returns edge details or closest relation suggestions if rejected.

Instructions

Assert a typed relation between two entities, e.g. ("web-app", "runs-on", "host-1"). Entities auto-create and resolve through aliases; re-asserting an edge bumps its confidence. On a rejected relation, pick a suggestion, fall back to related-to, or grow the vocabulary deliberately via memory_relation_define (full).

Returns: {src, relation, dst, confidence, warnings} or {error: "unknown_relation", suggestions}.

Input Schema

NameRequiredDescriptionDefault
dstYesThe object entity.
srcYesThe subject entity.
originNoWho asserted the edge.
dst_typeNoEntity kind for ``dst``: set when the node is created, or filled in on an existing node that has none.
relationYesFrom the closed registry: ``depends-on``, ``part-of``, ``runs-on``, ``hosts``, ``uses``, ``configures``, ``stores-data-in``, ``related-to``. Separator variants normalise; an unknown name is rejected WITH the closest matches.
src_typeNoEntity kind for ``src``: set when the node is created, or filled in on an existing node that has none.
confidenceNoHow sure you are, 0..1.

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changedv0.18.1
    • addedInput schema / additionalProperties
      Added value: +false
    • addedInput schema / properties / confidence / maximum
      Added value: +1
    • addedInput schema / properties / confidence / minimum
      Added value: +0
  2. Changed7 schema fields changedv0.15.0
    • addedInput schema / properties / confidence / description
      Added value: +"How sure you are, 0..1."
    • addedInput schema / properties / dst / description
      Added value: +"The object entity."
    • addedInput schema / properties / dst_type / description
      Added value: +"Entity kind for ``dst``: set when the node is created, or filled in on an existing node that has none."
    • addedInput schema / properties / origin / description
      Added value: +"Who asserted the edge."
    • addedInput schema / properties / relation / description
      Added value: +"From the closed registry: ``depends-on``, ``part-of``, ``runs-on``, ``hosts``, ``uses``, ``configures``, ``stores-data-in``, ``related-to``. Separator variants normalise; an unknown name is rejected WITH the closest matches."
    • addedInput schema / properties / src / description
      Added value: +"The subject entity."
    • addedInput schema / properties / src_type / description
      Added value: +"Entity kind for ``src``: set when the node is created, or filled in on an existing node that has none."
  3. First observedv0.11.0

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already flag destructive=true, idempotent=false and openWorld=false, and the description adds real substance on top: entities auto-create, names resolve through aliases, re-asserting bumps confidence, and unknown relation names are rejected WITH closest matches plus a suggestions payload. It does not explain why the call is flagged destructive or whether conflicting existing edges are overwritten.

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?

Front-loaded with the verb and a worked example, and each following clause carries new information (auto-create, alias resolution, confidence bump, error recovery). Minor waste: the trailing return-shape sentence duplicates the output schema, and the dangling ``(full)`` qualifier on memory_relation_define is unclear.

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 7-parameter mutating graph tool with full annotations and an output schema, the description covers the behaviours an agent actually needs: creation side effects, alias resolution, idempotency-ish confidence bumping, and the rejected-relation recovery path. Gaps remain around overwrite/conflict behaviour and the exact meaning of the destructive flag.

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 coverage is 100% so the baseline is 3, but the description earns extra by explaining the runtime semantics of src/dst (auto-creation and alias resolution) and of relation (closed registry, normalisation, rejection behaviour) rather than just restating field names. It adds no detail on origin, src_type/dst_type, or how confidence interacts with re-assertion.

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 (assert) on a specific resource (typed relation between two entities) and pins the semantics down with a concrete triple example using a real registry relation. It also names the sibling memory_relation_define as the escape hatch, and the 'assert' vs sibling memory_graph_unrelate contrast is implicit but unambiguous.

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?

Gives explicit conditional guidance for the failure path: on a rejected relation, take a suggestion, fall back to ``related-to``, or extend the registry via ``memory_relation_define``. It does not, however, say when to reach for this tool versus memory_graph, memory_store, or memory_graph_review.

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