ipynb_replace_cells_batch
Replace multiple cells in a Jupyter Notebook at once by providing cell indices and new content in a single batch operation.
Instructions
Replace multiple cells in one operation in a Jupyter Notebook (.ipynb).
Args: ipynb_filepath: Path to Jupyter Notebook (.ipynb) file (absolute path preferred) replacements: List of dicts with 'cell_index' and 'content' keys (provide content as raw strings, no additional escaping needed)
Returns: Dict with 'success' and 'cells_modified' or 'error' key
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": {
"ipynb_filepath": "<ipynb_filepath>",
"replacements": "<replacements>"
},
"name": "ipynb_replace_cells_batch"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| replacements | Yes | ||
| ipynb_filepath | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||