Skip to main content
Glama

capture_records

Read-only

Page through records in a .gputrace command stream to inspect Metal call names and analyze GPU commands without Xcode.

Instructions

Returns one page of the records of a .gputrace command stream, with their Metal call names when known.

Input Schema

NameRequiredDescriptionDefault
limitNorows per page, default 50, at most 500
offsetNofirst row, default 0
captureYespath of a .gputrace bundle saved from Xcode, inside METAL_TRACE_OUT or METAL_TRACE_READ

Output Schema

NameRequiredDescriptionDefault
rowsYes
totalYes
offsetYes
next_offsetYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.10.1
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "properties": {
      +    "next_offset": {
      +      "type": [
      +        "integer",
      +        "null"
      +      ]
      +    },
      +    "offset": {
      +      "type": "integer"
      +    },
      +    "rows": {
      +      "type": "array"
      +    },
      +    "total": {
      +      "type": "integer"
      +    }
      +  },
      +  "required": [
      +    "total",
      +    "offset",
      +    "rows",
      +    "next_offset"
      +  ],
      +  "type": "object"
      +}
  2. Changed1 schema field changedv0.7.1
    • addedInput schema / properties / capture / description
      Added value: +"path of a .gputrace bundle saved from Xcode, inside METAL_TRACE_OUT or METAL_TRACE_READ"
  3. First observedv0.2.0

TDQS

A3.8/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true and openWorldHint=false, so safety is covered. The description still adds real behavioral context beyond the annotations: results are paginated ('one page'), call names are best-effort ('when known'), and the operation is scoped to a single capture rather than global state.

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

Conciseness5/5

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

A single sentence that front-loads the pagination constraint and then the record contents. No filler, nothing repeated from the schema or annotations.

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 not be explained, and the required capture path is fully described in the schema. What is missing is orientation relative to siblings (trace_count for total rows, trace_query for filtering), which matters for a paged reader in a crowded toolset.

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 limit, offset, and the capture path constraint (METAL_TRACE_OUT / METAL_TRACE_READ) are already documented. The description's 'one page' phrasing reinforces the paging model but adds no syntax or format detail beyond the schema, so baseline 3 applies.

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?

States a specific verb-and-resource pair: it returns one page of records from a .gputrace command stream, and notes Metal call names are included when known. That is clear enough to distinguish it from the surrounding perf_* tools, though it never explicitly contrasts with trace_query or trace_tables, which operate on similar row data.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Usage is only implied: the tool reads a capture's records, so callers infer it applies after a capture exists. There is no explicit when-to-use guidance, no statement of when to prefer trace_query/trace_tables, and no note that trace_count should be consulted first to page correctly.

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