Skip to main content
Glama

BYOKG

Export a reasoning chain

export_reasoning_chain
Read-onlyIdempotent

Turn a path of stored edges the user picked into a research-plan scaffold, when the user wants to write up or test a chain of relations. Input: steps (required: edge ids from query_graph_paths or find_shortest_paths, or triples of from_ref, relation_type and to_ref with every ref as get_node takes it), question, hypothesis, format and namespace_id. Returns seven sections: the question, the evidence chain, the hypothesis marked HYPOTHESIS, gap candidates, empty slots for experiments and risks, the cited sources and what reproduces it. Each step continues where the one before ends, and nothing is filled in: a step that names no stored edge is CHAIN_STEP_NOT_STORED, a triple matching several edges CHAIN_STEP_AMBIGUOUS with the edges as candidates, a broken chain CHAIN_NOT_CONNECTED. One room per chain. Deterministic, read-only, no model call, nothing stored. A step may walk its edge against the stored direction (direction reverse); a triple must match exactly one stored edge, stored either way, and an edge id is the id query_graph_paths or find_shortest_paths gives, or the bundle's edge id. The answer's seven sections: the user's question, the evidence chain (relation types as stored), the user's hypothesis marked HYPOTHESIS and never among the evidence, find_gaps candidates at the chain's nodes (candidates, not facts), empty slots for experiments and risks, the cited sources with release and licence from the room's stored source metadata (NOT_STATED otherwise), and what reproduces it. format markdown adds it as one text with the user's text escaped; json gives the sections only. question and hypothesis are the user's own, plain text, escaped in markdown. Several rooms are not supported. Without the MCP token it reads the public rooms. Example: {"steps": [{"from_ref": "GO:0005739", "relation_type": "IS_A", "to_ref": "GO:0043231"}], "namespace_id": "obo-go"}. Added in contract revision 4.8.0. The contract revision in force is the one every response repeats in _meta.contract_revision and server_info reports; a revision note (Added in, Since) says when a field or a tool appeared, never which revision is current.

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": {
      "steps": "<steps>"
    },
    "name": "export_reasoning_chain"
  }
}

Input Schema

NameRequiredDescriptionDefault
stepsYesIn order: edge ids or triples; each starts where the one before ends.
formatNomarkdown adds one text; json gives the sections only.markdown
questionNoThe user's question, plain text.
hypothesisNoThe user's hypothesis, plain text; marked HYPOTHESIS.
namespace_idNoRoom name; omitted: the default room.

Output Schema

NameRequiredDescriptionDefault
risksYesAn empty slot for the user.
stepsYes
formatYes
sourcesYes
markdownYesWith format markdown, the seven sections as one markdown text; the user's text escaped so it opens no heading or section.
questionYes
revisionYes
read_onlyYes
generationYes
hypothesisYes
experimentsYesAn empty slot for the user.
namespace_idYes
gap_candidatesYes
reproducibilityYes
contract_revisionYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.6/5.0
Behavior5/5

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

Beyond the readOnly/idempotent annotations, the description discloses determinism, absence of any model call, nothing being stored, per-step error codes (CHAIN_STEP_NOT_STORED, CHAIN_STEP_AMBIGUOUS, CHAIN_NOT_CONNECTED), single-room limitation, auth fallback, and provenance/licence handling. That is far more behavioral context than the annotations supply.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

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

It is front-loaded and information-dense, but the seven-section return list is enumerated twice in near-identical wording, and the contract-revision aside is tangential to invoking the tool. Substantial trimming is possible without losing call-critical information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given a 5-parameter tool with nested anyOf steps, an output schema, and mutation-adjacent provenance concerns, the description covers inputs, chain rules, errors, formatting, auth, and room scope. Nothing an agent needs to call it correctly appears to be missing.

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

Parameters5/5

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

Schema coverage is already 100%, yet the description adds real semantics: steps must form a continuous chain, a step may walk its edge in reverse, a triple must match exactly one stored edge in either direction, and format markdown escapes user text while json returns sections only. These are behavioral constraints the schema does not encode.

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 first clause gives a specific verb and resource: 'Turn a path of stored edges the user picked into a research-plan scaffold.' It names the exact upstream sources of those edges (query_graph_paths, find_shortest_paths), so an agent can distinguish this export step from the path-finding siblings without opening any schema.

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?

Usage is stated conditionally ('when the user wants to write up or test a chain of relations') and the input source tools are named explicitly. It also bounds scope with 'Several rooms are not supported' and describes the no-token fallback to public rooms. No explicit 'use X instead when...' exclusion is given, which keeps it below a 5.

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