notebook_run
Execute notebook cells with resume, replay, or full modes to update outputs safely. Use it to run specific cell ranges without rerunning long cells unnecessarily.
Instructions
Execute notebook cells. mode='resume' runs only the target cells in the live kernel; 'replay' silently rebuilds state from cell 0 first; 'full' re-runs everything.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| mode | No | Execution mode: 'auto' (default) | 'resume' | 'replay' | 'full' | |
| path | Yes | Notebook path | |
| cell_selector | No | Which code cells to run: 'all' (default), '3', '0-4', or a comma list like '0-4,7,9'. This is a string selector — do not pass an array. | |
| create_backup | No | Default true | |
| write_outputs | No | Write fresh outputs back to the .ipynb. Default true | |
| timeout_seconds | No | Per-cell timeout in seconds (1..86400; default from server config) | |
| clear_outputs_before | No | Clear target cells' outputs before running. Default true | |
| expected_content_hash | No | Optional optimistic-lock hash |