Skip to main content
Glama

Create Cell

create_cell

Add a new cell to a marimo notebook, optionally placing it before or after another cell and hiding its code for setup tasks.

Instructions

Create a new cell in the notebook.

Created cells are visible in the UI by default (hide_code=False); pass hide_code=True explicitly for setup/implementation cells you want hidden.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameNoOptional cell name.
afterNoOptional cell_id to place this cell after.
beforeNoOptional cell_id to place this cell before.
sourceYesSource code for the new cell.
hide_codeNoWhether the code is hidden in the UI (default False).
server_urlNoServer URL override.
session_idNoSession ID; omit only when the active-session binding holds for this call (see `list_active_notebooks`).

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.3.3

TDQS

B3.4/5.0
Behavior3/5

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

No annotations are provided, so the description carries the full burden. It usefully discloses a default outcome ('cells are visible in the UI by default'), but says nothing about session binding/auth requirements, whether the cell is persisted or executed, or what occurs if both after and before are supplied.

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?

Two tight sentences with no filler, and the default-behavior point is front-loaded. The opening sentence largely restates the name/title, which is conventional but not additive, keeping it just below a 5.

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

Completeness3/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 described, and the schema fully covers parameters. However, for a creation tool with no annotations, the description omits permission/session prerequisites and the interaction between the mutually related after/before placement options, leaving meaningful gaps.

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 all seven parameters are already documented in the schema; this sets the baseline at 3. The description adds a modest amount of meaning for hide_code by explaining the intent behind the flag, but nothing for name, after, before, server_url, or session_id.

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 states a specific verb and resource ('Create a new cell in the notebook'), which cleanly separates it from siblings like edit_cell, delete_cell, and run_cell. It does not explicitly name those siblings or clarify boundaries, but the create/edit/delete/run distinction is unambiguous from the verb alone.

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?

It gives real guidance for one decision point: hide_code defaults to False, and True is for 'setup/implementation cells you want hidden.' That is usage guidance for a parameter rather than for the tool itself; there is no guidance on when to use create_cell versus edit_cell, or on the after/before positioning options.

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