🔧Tool Prompts/file-ops
Notebook Edit Tool
src/tools/NotebookEditTool/prompt.ts
Prompt Engineering Insight
The Notebook Edit tool prompt is tightly scoped, providing just enough context about what Jupyter notebooks are and how cell indexing works. It uses structured output guidance by specifying the edit_mode parameter values (insert/delete) and enforces the absolute path constraint consistently with other file tools.
Techniques Used
scope-limitingstructured-outputtool-use-guidance
prompt
Completely replaces the contents of a specific cell in a Jupyter notebook (.ipynb file) with new source. Jupyter notebooks are interactive documents that combine code, text, and visualizations, commonly used for data analysis and scientific computing. The notebook_path parameter must be an absolute path, not a relative path. The cell_number is 0-indexed. Use edit_mode=insert to add a new cell at the index specified by cell_number. Use edit_mode=delete to delete the cell at the index specified by cell_number.
Tags
jupyternotebookcell-editingdata-science