Skip to main content
Glama
Cloto-dev

CPersona

Official
by Cloto-dev

get_contents

Read-only

Fetch full, untrimmed content for recall preview refs, with optional node, block, or character ranges, so you can expand only the rows that matter after a preview recall.

Instructions

Fetch full, untrimmed content for recall preview refs. Use after a preview-tier recall to expand only the rows that matter instead of opting the whole recall out with full_content=true. Bounded twice: at most 20 refs per call, and a 40,000-character budget across the batch (2.5.4a2) that does not move when CPERSONA_MAX_CONTENT_LENGTH does. Rows are never cut to fit — when the budget is spent the remaining refs come back in deferred (absent otherwise) alongside budget_chars; re-fetch them in a second call. A single row larger than the budget is still returned in full, because this tool is the only path back to a row's complete text. RANGES: a ref may instead be an object that names part of its record -- {ref, node: i} or {ref, node: [first, last]} (inclusive) for overflow-tree nodes, e.g. the node.index of a reconstruct quote and its neighbours, or {ref, span: [start, end]} for characters. Offsets are in the stored text (a memory's content, an episode's summary without the '[Episode] ' label). The item then carries that slice as content and range = {span, content_len, and node + of when nodes were named, or block + of when blocks were}; a span end past the text is clamped and range.span says what was served. A ref may also carry revision, the digest a reconstruct quote's expand hands out for the text its offsets were measured in: a record rewritten since refuses rather than serving different characters under the same numbers. A range that cannot be served exactly is never widened to the whole row: it comes back in unresolved (absent otherwise) as {ref, reason}, reason one of invalid_range, no_current_nodes (the record has no complete node set -- short records have none, and a new long one gets them shortly after store), node_out_of_range, span_out_of_range, no_current_blocks, block_out_of_range, stale_revision. Only the slice counts against the budget.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
refsYesRefs from recall messages ('mem:<id>' / 'ep:<id>'), or range objects such as {'ref': 'mem:<id>', 'node': [2, 3]} / {'ref': 'ep:<id>', 'span': [0, 800]} / {'ref': 'mem:<id>', 'block': 4, 'revision': '<from an expand>'} (max 20 per call). At most one of node / span / block
agent_idYesAgent identifier (ownership check — another agent's refs come back in `missing`)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv2.6.1
    • changedInput schema / properties / refs / description
      Previous value: -"Refs from recall messages ('mem:<id>' / 'ep:<id>'), or range objects such as {'ref': 'mem:<id>', 'node': [2, 3]} / {'ref': 'ep:<id>', 'span': [0, 800]} (max 20 per call)"New value: +"Refs from recall messages ('mem:<id>' / 'ep:<id>'), or range objects such as {'ref': 'mem:<id>', 'node': [2, 3]} / {'ref': 'ep:<id>', 'span': [0, 800]} / {'ref': 'mem:<id>', 'block': 4, 'revision': '<from an expand>'} (max 20 per call). At most one of node / span / block"
    • changedInput schema / properties / refs / items / anyOf
      Previous value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "properties": {
      -      "node": {
      -        "anyOf": [
      -          {
      -            "minimum": 0,
      -            "type": "integer"
      -          },
      -          {
      -            "items": {
      -              "minimum": 0,
      -              "type": "integer"
      -            },
      -            "maxItems": 2,
      -            "minItems": 2,
      -            "type": "array"
      -          }
      -        ]
      -      },
      -      "ref": {
      -        "type": "string"
      -      },
      -      "span": {
      -        "items": {
      -          "minimum": 0,
      -          "type": "integer"
      -        },
      -        "maxItems": 2,
      -        "minItems": 2,
      -        "type": "array"
      -      }
      -    },
      -    "required": [
      -      "ref"
      -    ],
      -    "type": "object"
      -  }
      -]New value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "properties": {
      +      "block": {
      +        "anyOf": [
      +          {
      +            "minimum": 0,
      +            "type": "integer"
      +          },
      +          {
      +            "items": {
      +              "minimum": 0,
      +              "type": "integer"
      +            },
      +            "maxItems": 2,
      +            "minItems": 2,
      +            "type": "array"
      +          }
      +        ]
      +      },
      +      "node": {
      +        "anyOf": [
      +          {
      +            "minimum": 0,
      +            "type": "integer"
      +          },
      +          {
      +            "items": {
      +              "minimum": 0,
      +              "type": "integer"
      +            },
      +            "maxItems": 2,
      +            "minItems": 2,
      +            "type": "array"
      +          }
      +        ]
      +      },
      +      "ref": {
      +        "type": "string"
      +      },
      +      "revision": {
      +        "type": "string"
      +      },
      +      "span": {
      +        "items": {
      +          "minimum": 0,
      +          "type": "integer"
      +        },
      +        "maxItems": 2,
      +        "minItems": 2,
      +        "type": "array"
      +      }
      +    },
      +    "required": [
      +      "ref"
      +    ],
      +    "type": "object"
      +  }
      +]
  2. Changed3 schema fields changedv2.5.12
    • changedInput schema / properties / refs / description
      Previous value: -"Refs from recall messages, e.g. ['mem:123', 'ep:45'] (max 20 per call)"New value: +"Refs from recall messages ('mem:<id>' / 'ep:<id>'), or range objects such as {'ref': 'mem:<id>', 'node': [2, 3]} / {'ref': 'ep:<id>', 'span': [0, 800]} (max 20 per call)"
    • addedInput schema / properties / refs / items / anyOf
      Added value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "properties": {
      +      "node": {
      +        "anyOf": [
      +          {
      +            "minimum": 0,
      +            "type": "integer"
      +          },
      +          {
      +            "items": {
      +              "minimum": 0,
      +              "type": "integer"
      +            },
      +            "maxItems": 2,
      +            "minItems": 2,
      +            "type": "array"
      +          }
      +        ]
      +      },
      +      "ref": {
      +        "type": "string"
      +      },
      +      "span": {
      +        "items": {
      +          "minimum": 0,
      +          "type": "integer"
      +        },
      +        "maxItems": 2,
      +        "minItems": 2,
      +        "type": "array"
      +      }
      +    },
      +    "required": [
      +      "ref"
      +    ],
      +    "type": "object"
      +  }
      +]
    • removedInput schema / properties / refs / items / type
      Removed value: -"string"
  3. Addedv2.5.1

TDQS

A4.9/5.0
Behavior5/5

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

Annotations carry only readOnlyHint=true; the description shoulders the rest and does so richly: two hard bounds (20 refs, 40,000-char budget), the deliberate non-truncation policy with `deferred`/`budget_chars`, the oversized-single-row exception, staleness refusal via `revision`, and enumerated `unresolved` reasons. Nothing here contradicts the read-only annotation.

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?

It is long, but the tool's surface genuinely is large (ranges, node vs block vs span, revisions, deferral), and the purpose is front-loaded before the mechanics. The version tag and env-var mention are minor noise, keeping this just under a 5.

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?

With no output schema, the description must explain returns — and it does: `deferred`, `budget_chars`, `unresolved` with enumerated reasons, `range` contents, `missing` for foreign refs, and the oversized-row pass-through. An agent has everything needed to call and interpret results correctly.

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?

Although schema coverage is 100%, the description adds substantially more than the schema: concrete ref formats ('mem:<id>' / 'ep:<id>'), example range objects, offset semantics (offsets are in stored text; episode summary excludes the '[Episode] ' label), the clamp behavior for spans past the end, and the meaning of `revision`. This far exceeds the schema's 'At most one of node / span / block' note.

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 and resource ('Fetch full, untrimmed content for recall preview refs') and positions itself relative to sibling behaviors: it expands preview-tier rows rather than opting the whole recall out with full_content=true. An agent can distinguish this from recall and reconstruct without inspecting schemas.

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?

Explicitly names the trigger ('after a preview-tier recall') and the anti-pattern it replaces (setting full_content=true on the whole recall), steering the agent toward 'expand only the rows that matter.' The alternative path and the condition selecting it are stated, not implied.

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