Skip to main content
Glama
Auto Ontology MCP

Auto Ontology MCP

Update a table join relationship

set_relationship
DestructiveIdempotent

Accept, reject, add, update, or delete a join relationship between two table columns, identified by relationship_id or source and target, to control which joins enter join paths.

Instructions

Modify one join relationship between two table columns: accept or reject a proposed join, add a missing one, update its role/description/default flag, or delete it permanently. Use after reviewing joins in list_relationships; use find_join_path to inspect active routes instead. Identify the join by relationship_id or by source and target ('table.column'). Only accepted joins enter join paths and survive re-scans; action='delete' removes the record permanently while 'reject' preserves the negative decision. Fails if the columns or relationship do not exist.

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": {
      "action": "<action>"
    },
    "name": "set_relationship"
  }
}

Input Schema

NameRequiredDescriptionDefault
roleNoBusiness role when multiple columns reference the same table, e.g. 'billing'.
actionYesOperation to perform: accept or reject a proposed join, add a missing one, update metadata/default flag, or delete permanently.
sourceNoForeign-key column formatted as 'table.column' (used with target when adding or without relationship_id).
targetNoReferenced key column formatted as 'table.column' (used with source).
datasourceNoDatasource name. Optional when only one datasource is registered.
is_defaultNoSet true to mark this join as the default path between its two tables.
descriptionNoBusiness meaning of this join relationship.
relationship_idNoRelationship id from list_relationships (alternative to passing source and target).

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed7 schema fields changedv0.6.2
    • changedInput schema / properties / action / description
      Previous value: -"What to do."New value: +"Operation to perform: accept or reject a proposed join, add a missing one, update metadata/default flag, or delete permanently."
    • changedInput schema / properties / description / description
      Previous value: -"What the relationship means."New value: +"Business meaning of this join relationship."
    • changedInput schema / properties / is_default / description
      Previous value: -"Make this the default join between the two tables."New value: +"Set true to mark this join as the default path between its two tables."
    • changedInput schema / properties / relationship_id / description
      Previous value: -"Id from list_relationships (or give source and target)."New value: +"Relationship id from list_relationships (alternative to passing source and target)."
    • changedInput schema / properties / role / description
      Previous value: -"Business role when several columns reference the same table, e.g. 'billing'."New value: +"Business role when multiple columns reference the same table, e.g. 'billing'."
    • changedInput schema / properties / source / description
      Previous value: -"Foreign-key side, 'table.column'."New value: +"Foreign-key column formatted as 'table.column' (used with target when adding or without relationship_id)."
    • changedInput schema / properties / target / description
      Previous value: -"Referenced key, 'table.column'."New value: +"Referenced key column formatted as 'table.column' (used with source)."
  2. First observedv0.3.0

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=false and destructiveHint=true, and the description adds real value on top: only accepted joins enter join paths and survive re-scans, 'delete' removes the record permanently while 'reject' preserves the negative decision, and the call fails when columns or relationship do not exist. It does not cover permissions or what happens to downstream joins when a record is deleted. There is also a mild tension with idempotentHint=true, since a repeated delete is stated to fail on a now-missing relationship.

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?

Four sentences, front-loaded with the operation set, then usage routing, then identification and consequences. Nearly every clause earns its place, though the accept/reject consequence sentence is dense and slightly overlaps the schema's action description.

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?

An output schema exists, so return values need no explanation, and the definition covers action semantics, identification, and failure conditions for an 8-parameter mutation tool. Remaining gaps are secondary: whether deleting a join cascades to dependent paths, and whether datasource is needed when multiple datasources are registered.

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 every parameter including action, relationship_id, source/target, and is_default is already documented in the schema. The description reinforces the two identification routes (relationship_id or 'table.column' pair) and adds the nonexistence failure constraint, but adds no syntax or format detail beyond the schema. Baseline 3 applies when the schema carries the load.

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?

Opens with a specific verb and resource ('Modify one join relationship between two table columns') and enumerates the concrete operations: accept, reject, add, update role/description/default flag, or delete. It also explicitly separates itself from list_relationships and find_join_path, so an agent can route correctly without opening a 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?

Gives explicit sequencing ('Use after reviewing joins in list_relationships') and a named alternative for a different need ('use find_join_path to inspect active routes instead'). It also states the selection rule between accept and reject, which is the key decision an agent must make here.

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