Skip to main content
Glama

get_cells

Retrieve the cell structure and source code for a notebook session using its session ID, so you can inspect and analyze notebook cells.

Instructions

Get the cell structure and code of a notebook session.

Args: session_id: The session ID from list_notebooks.

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": {
      "session_id": "<session_id>"
    },
    "name": "get_cells"
  }
}

Input Schema

NameRequiredDescriptionDefault
session_idYes

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.7/5.0
Behavior3/5

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

No annotations are supplied, so the description carries the full behavioral burden; 'Get' implies a read but read-only safety is never stated. It does indicate the return spans 'cell structure and code', yet says nothing about ordering, truncation of long cells, or whether outputs are included, and no permissions or side-effect context is given.

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?

The one-sentence purpose statement is front-loaded and waste-free, and the Args block is minimal. The docstring-style parameter block is slightly redundant given only one parameter but costs little.

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?

For a single-parameter read tool with an output schema that documents return values, the description covers purpose, the parameter's source, and the general nature of the result. Nothing essential for correct invocation is missing.

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 0% – the single session_id property has no description in the schema – so the description must compensate, and it does by naming the origin of the value ('from list_notebooks'). That provenance is genuinely useful for an agent chaining calls, though format/session-lifetime details are absent.

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?

The description uses a specific verb ('Get') plus a concrete resource ('cell structure and code of a notebook session'), which is far more informative than a bare name restatement. It does not explicitly contrast itself with the closely named sibling get_cell_data, so an agent must still infer which one returns per-cell contents versus overall notebook layout.

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?

The only usage guidance is embedded in the parameter note ('The session ID from list_notebooks'), which usefully establishes the prerequisite call chain. There is no statement of when to prefer this over get_cell_data, read_notebook, or show_notebook, and no exclusions or failure conditions.

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