insert_cell
Inserts a code or markdown cell at a specified position in the active Jupyter notebook. Use -1 to append at the end.
Instructions
Insert a cell to specified position from the currently activated notebook.
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": {
"cell_index": "<cell_index>",
"cell_type": "<cell_type>",
"cell_source": "<cell_source>"
},
"name": "insert_cell"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cell_type | Yes | Type of cell to insert | |
| cell_index | Yes | Target index for insertion (0-based), use -1 to append at end | |
| cell_source | Yes | Source content for the cell |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes | Success message and the structure of its surrounding cells |