scientific-notebook-workflows
Skill1 starsChanged 6 months agoApache-2.0View on GitHub
Maintain reproducible scientific notebook workflows, including
In this repository25 other files it gives its agents.
- AGENTS.mdAGENTS.md
- developer-tool-installation-policySkill
- git-refactor-hygieneSkill
- project-repository-setupSkill
- scientific-accelerator-portabilitySkill
- scientific-build-systemsSkill
- scientific-ciSkill
- scientific-cli-benchmarkSkill
- scientific-cli-designSkill
- scientific-code-styleSkill
- scientific-container-workflowsSkill
- scientific-data-analysis-and-visualizationSkill
- scientific-data-managementSkill
- scientific-documentationSkill
- scientific-io-and-data-formatsSkill
- scientific-numerics-reviewSkill
- scientific-package-managementSkill
- scientific-parallel-debuggingSkill
- scientific-performance-portabilitySkill
- scientific-profilingSkill
- scientific-release-and-publicationSkill
- scientific-reproducibilitySkill
- scientific-reviewSkill
- scientific-testingSkill
- scientific-workflow-automationSkill
The file
Show its rules and text
We split this skill into the rules it gives an agent
41 rules. About 0 are common, 34 are distinctive, and 7 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈34
Distinctive · estimate
This author's own choices. Worth a look.
7
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 10
Use this skill when scientific work uses Jupyter, Quarto, R Markdown, Pluto, or similar notebooks for exploration, reporting, demos, …
- Distinctive: line 28
Use this skill when:
- Very specific: line 37
Do not use this skill to replace project packaging or workflow orchestration.
- Very specific: line 38
Use scientific-package-management for package layout and scientific-workflow-automation for multi-step pipelines.
- Distinctive: line 43
When this skill applies:
- Distinctive: line 45
Read the repository AGENTS.md first, if present.
- Distinctive: line 50
Keep data paths, parameters, environment assumptions, and generated outputs explicit.
- Distinctive: line 55
Avoid treating all notebooks the same.
- Distinctive: line 75
Commit outputs intentionally when they are part of the repository contract, for example:
- Distinctive: line 85
document that outputs are intentionally committed.
- Distinctive: line 86
keep outputs small enough for review and repository size.
- Distinctive: line 87
avoid embedding secrets, private paths, large binary blobs, or unstable random output.
- Distinctive: line 93
Do not commit outputs merely because they happened to be present after an interactive session.
- Distinctive: line 98
Keep reusable functions in importable modules or scripts.
- Distinctive: line 99
Keep notebooks as consumers of project code, not the only implementation.
- Distinctive: line 100
Use clear sections for setup, parameters, data loading, analysis, and results.
- Distinctive: line 101
Avoid hidden state across non-linear execution order.
- Distinctive: line 102
Prefer explicit parameters over editing cells before each run.
- Distinctive: line 103
Keep long-running or expensive steps behind documented switches or cached inputs.
- Distinctive: line 110
Use small example data or documented subsets for notebooks intended to run in CI or by new users.
- Distinctive: line 112
Keep generated figures, tables, and exports in documented output locations.
- Distinctive: line 113
Do not rely on user-local absolute paths.
- Distinctive: line 116
Keep large datasets, caches, and generated outputs out of Git unless they are intentional release artifacts.
- Very specific: line 119
Use scientific-data-management for large data and fixture policy.
- Distinctive: line 123
Document the kernel, language version, and key packages.
- Distinctive: line 124
Prefer using the repository's normal environment setup instead of notebook-only installation cells.
- Distinctive: line 126
Avoid installing packages inside notebooks unless the notebook is explicitly a self-contained tutorial and the tradeoff is documented.
- Very specific: line 128
Keep environment setup consistent with pyproject.toml, environment files, lockfiles, or project documentation.
- Very specific: line 131
Use scientific-package-management when dependency structure needs cleanup.
- Distinctive: line 136
Prefer smoke checks for tutorials and demos rather than full production runs.
- Very specific: line 138
Consider checking execution with tools such as nbclient, pytest, nbval, Quarto render, or framework-native commands when they are already …
- Distinctive: line 141
Keep notebook CI separate from heavyweight analysis unless the repository deliberately validates full reports.
- Distinctive: line 144
If notebook execution is too expensive for CI, document the manual validation command and expected runtime.
- Distinctive: line 150
Avoid committing execution-order chaos when the notebook is meant to be readable.
- Distinctive: line 155
Treat large base64-encoded images or widgets as generated artifacts unless there is a clear reporting/demo reason.
- Distinctive: line 171
Prefer small helper modules or scripts over a large migration unless the project is ready for that change.
- Distinctive: line 177
Run the smallest representative notebook execution when practical.
- Distinctive: line 178
If outputs are committed, rerun from a clean kernel or state why that was not done.
- Distinctive: line 180
If outputs are stripped, verify no required report/demo output was removed.
- Very specific: line 181
Check .gitignore and repository policy for generated figures, data, and notebook checkpoints.
- Distinctive: line 196
When using this skill, briefly note:
≈ “Common” is an estimate: at least 1 in 5 of the 213,897 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Scientific Notebook Workflows
Use this skill when scientific work uses Jupyter, Quarto, R Markdown, Pluto, or similar notebooks for exploration, reporting, demos, documentation, or reproducible analysis.
Repository AGENTS.md instructions take precedence over this skill.
Purpose
Apply a pragmatic default for:
- keeping notebooks reproducible, reviewable, and useful;
- deciding when notebook outputs should be stripped or committed;
- separating reusable logic from exploratory cells;
- adding small execution or smoke-test paths for important notebooks;
- documenting data, environment, and artifact expectations.
When To Use
Use this skill when:
- notebooks are part of a scientific workflow, report, demo, tutorial, or analysis artifact;
- notebook outputs cause review noise or reproducibility concerns;
- reusable logic is trapped inside notebook cells;
- notebooks need CI execution, smoke checks, or conversion to scripts;
- GitHub preview of notebook outputs is intentionally useful.
Do not use this skill to replace project packaging or workflow orchestration.
Use scientific-package-management for package layout and
scientific-workflow-automation for multi-step pipelines.
Working Approach
When this skill applies:
- Read the repository
AGENTS.mdfirst, if present. - Identify the notebook role: exploration, report, demo, tutorial, documentation, or workflow step.
- Decide the output policy based on that role.
- Factor reusable logic into scripts, modules, or package code when practical.
- Keep data paths, parameters, environment assumptions, and generated outputs explicit.
- State what was made reproducible, what remains exploratory, and how the notebook should be reviewed.
Avoid treating all notebooks the same. Exploration notebooks, report notebooks, and CI-executed notebooks have different contracts.
Notebook Roles
- exploration: scratch or early-stage investigation, often not release-critical;
- analysis: reproducible computation over known inputs;
- report: narrative result presentation intended for readers;
- demo: runnable or previewable example of project behavior;
- tutorial: teaching material with explanatory output;
- workflow step: notebook is part of an automated or documented pipeline.
The role determines whether outputs, execution order, and CI expectations need to be strict.
Output Policy
Strip outputs by default when notebooks are primarily source artifacts and the outputs are reproducible, noisy, large, or irrelevant to review.
Commit outputs intentionally when they are part of the repository contract, for example:
- report notebooks where GitHub preview is useful to readers;
- demo notebooks where rendered output shows expected behavior;
- tutorial notebooks where outputs are instructional;
- publication or release artifacts where the rendered result is reviewed.
When committing outputs:
- document that outputs are intentionally committed;
- keep outputs small enough for review and repository size;
- avoid embedding secrets, private paths, large binary blobs, or unstable random output;
- record the environment and command used to regenerate the notebook;
- rerun from a clean kernel before committing if the notebook is meant to be reproducible.
Do not commit outputs merely because they happened to be present after an interactive session.
Structure and Reusable Logic
- Keep reusable functions in importable modules or scripts.
- Keep notebooks as consumers of project code, not the only implementation.
- Use clear sections for setup, parameters, data loading, analysis, and results.
- Avoid hidden state across non-linear execution order.
- Prefer explicit parameters over editing cells before each run.
- Keep long-running or expensive steps behind documented switches or cached inputs.
Notebook cells should tell a readable story without becoming the project's API.
Data and Artifacts
- Use small example data or documented subsets for notebooks intended to run in CI or by new users.
- Keep generated figures, tables, and exports in documented output locations.
- Do not rely on user-local absolute paths.
- Record data provenance, checksums, filters, and preprocessing where they affect interpretation.
- Keep large datasets, caches, and generated outputs out of Git unless they are intentional release artifacts.
Use scientific-data-management for large data and fixture policy.
Environment and Dependencies
- Document the kernel, language version, and key packages.
- Prefer using the repository's normal environment setup instead of notebook-only installation cells.
- Avoid installing packages inside notebooks unless the notebook is explicitly a self-contained tutorial and the tradeoff is documented.
- Keep environment setup consistent with
pyproject.toml, environment files, lockfiles, or project documentation.
Use scientific-package-management when dependency structure needs cleanup.
CI and Smoke Checks
- Execute important notebooks in CI only with small inputs and stable outputs.
- Prefer smoke checks for tutorials and demos rather than full production runs.
- Fail clearly when a notebook cannot run from a clean checkout.
- Consider checking execution with tools such as
nbclient,pytest,nbval, Quarto render, or framework-native commands when they are already part of the project. - Keep notebook CI separate from heavyweight analysis unless the repository deliberately validates full reports.
If notebook execution is too expensive for CI, document the manual validation command and expected runtime.
Review Hygiene
- Minimize irrelevant metadata churn.
- Avoid committing execution-order chaos when the notebook is meant to be readable.
- For output-stripped notebooks, verify the notebook still runs after stripping.
- For output-committed notebooks, ensure the output diff is meaningful and not just stale execution noise.
- Treat large base64-encoded images or widgets as generated artifacts unless there is a clear reporting/demo reason.
Reviewers should be able to distinguish source changes from generated output changes.
Converting Notebooks
Factor notebook logic out when:
- multiple notebooks copy the same code;
- tests need to cover notebook logic;
- a workflow depends on notebook internals;
- performance profiling or packaging requires a script/module boundary;
- notebooks are too large or fragile to review.
Prefer small helper modules or scripts over a large migration unless the project is ready for that change.
Validation Defaults
- Open or inspect the notebook metadata when output policy changes.
- Run the smallest representative notebook execution when practical.
- If outputs are committed, rerun from a clean kernel or state why that was not done.
- If outputs are stripped, verify no required report/demo output was removed.
- Check
.gitignoreand repository policy for generated figures, data, and notebook checkpoints.
Anti-Patterns
- keeping the only implementation of a workflow inside notebook cells;
- committing huge outputs or private paths by accident;
- stripping outputs from report/demo notebooks where preview is the point;
- relying on hidden kernel state;
- adding notebook-only dependency installation that diverges from the project environment;
- treating a rendered notebook as validated when it was not rerun cleanly.
Output Expectations
When using this skill, briefly note:
- the notebook role and chosen output policy;
- whether outputs were stripped, retained, regenerated, or intentionally committed;
- which reusable logic, data paths, environment assumptions, or generated artifacts changed;
- which notebook execution or render checks were run;
- what remains exploratory, manual, or too expensive to validate.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

