Execute

From brycewang-stanford/Auto-Empirical-Research-Skills · View interactive version

Execute is an AI agent skill from the GitHub repository brycewang-stanford/Auto-Empirical-Research-Skills. Executes all registered notebooks, strips noisy cell metadata, and syncs Jupytext pairs. Use when asked to re-run notebooks or refresh outputs.

How to use this skill

Skill file

Execute All Notebooks

Execute all registered notebooks, strip noisy metadata, and sync Jupytext pairs.

Steps

  1. Read _quarto.yml and extract all notebook paths from manuscript.notebooks
  2. For each notebook, execute it:

```bash

uv run jupyter execute --inplace notebooks/<name>.ipynb

```

Record execution time and success/failure for each notebook.

  1. After all notebooks execute, strip noisy cell metadata from every .ipynb file.

Open each .ipynb as JSON and remove these keys from every cell's metadata object:

Save the cleaned JSON back to the file (preserve formatting with 1-space indent).

  1. Sync all Jupytext .md pairs:

```bash

uv run jupytext --sync notebooks/<name>.md

```

  1. Report a summary table:

Error handling

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.