1. Understand the Goal: The user wants a "computational reproducibility rubric." The specific areas to focus on are "environment capture," "seeds," "provenance," and "review artifacts." The output should be structured like a rubric (criteria, levels of performance, scoring/feedback).
-
Deconstruct the Components:
- Computational Reproducibility: The ability to re-run the exact same code and get the exact same results.
- Environment Capture: Software versions, OS, libraries, dependencies.
- Seeds: Random number generation control (critical for ML/stats).
- Provenance: Tracking the history of data and code (versions, lineage).
- Review Artifacts: Documentation and scripts provided for reviewers to actually check the work (READMEs, scripts).
-
Drafting the Structure:
A standard rubric usually has:
- Category/Dimension
- Specific Criteria
- Performance Levels (e.g., Missing, Developing, Meets Expectations, Exemplary).
-
Developing Specific Categories:
-
Category 1: Environment Capture (The "Where" and "How")
- Low: "It works on my machine."
- Medium: Requirements file (
requirements.txt or similar), but versions not pinned.
- High: Pinned versions (hashes), OS specified, maybe a container (Docker/Singularity).
- Excellent: Isolated environment (Container/VM) + instructions on how to build.
-
Category 2: Randomness & Control (The "Seeds")
- Low: No seed set. Results change every run.
- Medium: Global seed set in code, but non-deterministic GPU ops or parallelism issues ignored.
- High: Seeds set for all libraries (numpy, torch, random), deterministic flags enabled.
- Excellent: Verified reproducibility script included (run twice, compare output hash).
-
Category 3: Provenance & Versioning (The "History")
- Low: Code is a zip file. Data is "data.csv".
- Medium: Git repo used (but dirty state). Data sources listed in text.
- High: Tagged release/commit hash used. DOI for data (Zenodo/etc.). Input hashes calculated.
- Excellent: Complete lineage graph or workflow manager (Snakemake/Nextflow) defining input->output relationships.
-
Category 4: Review Artifacts & Execution (The "Handoff")
- Low: "Just run main.py". No docs.
- Medium: README exists. Steps are listed manually.
- High: "One-click" run script (
make all or run.sh). Clear README with hardware requirements.
- Excellent: Continuous Integration (CI) pipeline or a "CodeCheck" badge showing it ran on a fresh machine automatically.
-
Refining and Formatting:
- Use a table format for readability.
- Use clear, actionable language.
- Add a scoring guide or weighting (optional, but helpful).
- Add a "Checklist" summary for quick use.
-
Self-Correction/Review during drafting:
- Critique: Is "Environment Capture" distinct enough from "Review Artifacts"?
- Correction: Yes. Environment is about specification (versions), Artifacts are about usability (instructions/scripts).
- Critique: The "Seeds" section needs to be careful about non-determinism in CUDA.
- Adjustment: Add a specific note about strict determinism vs. statistical reproducibility in the "Exemplary" tier.
-
Final Polish (Simulating the Output):
- Title: Computational Reproducibility Rubric (CRR).
- Structure: Matrix with levels 0-3.
- Content: Fill in the cells based on step 4.
-
Final Output Generation: (This matches the provided good response, ensuring all user constraints—environment, seeds, provenance, review artifacts—are met.)
Here is a comprehensive computational reproducibility rubric designed for evaluating research code, machine learning pipelines, and data analysis workflows.
This rubric is divided into four main pillars: Environment Capture, Randomness Control, Provenance & Lineage, and Review Artifacts. Each category is scored on a maturity level from 0 (Irreproducible) to 3 (Fully Reproducible).
The Computational Reproducibility Rubric (CRR)
Scoring Guidelines
- 0 (Non-Reproducible): Critical dependencies or data are missing; execution fails.
- 1 (Minimally Reproducible): Works with significant manual effort ("works on my machine").
- 2 (Strongly Reproducible): Automated setup; works with minor intervention.
- 3 (Perfectly Reproducible): One-click execution; containerized; bitwise identical results.
1. Environment Capture
Focus: Can the exact software and hardware context be recreated?
| Criteria | Level 0 (Failing) | Level 1 (Basic) | Level 2 (Robust) | Level 3 (Exemplary) |
|---|
| Dependency Management | No list of libraries provided. | Generic list provided (e.g., requirements.txt without versions, or "pip freeze" dump). | Pinned versions for all direct dependencies (e.g., package==1.2.3). | Lockfile approach (e.g., conda-lock, poetry.lock, renv) capturing transitive dependencies. |
| System Environment | No OS or hardware specs listed. | OS version mentioned in text (e.g., "Ubuntu 20.04"). | System libraries and compiler versions specified. | Containerization (Docker/Singularity) or Virtual Machine image provided. |
| Package Conflict Resolution | Assumed user has a clean environment. | Instructions suggest creating a new environment, but manual troubleshooting required. | Setup script installs environment automatically. | Isolated environment builds verified via CI/CD pipeline. |
2. Seeds & Randomness
Focus: Are stochastic processes controlled to ensure identical outputs?
| Criteria | Level 0 (Failing) | Level 1 (Basic) | Level 2 (Robust) | Level 3 (Exemplary) |
|---|
| Seed Setting | No seeds set. Results change on every run. | Global seed set (e.g., np.random.seed(42)), but only for main thread. | Seeds set for all libraries (Python, Torch, TensorFlow) and worker processes. | Seeds set for OS-level randomness and GPU determinism (e.g., CUBLAS_WORKSPACE_CONFIG). |
| Non-Determinism Mitigation | Hardware non-determinism ignored (e.g., GPU atomic ops). | Warning issued about potential variability. | Deterministic algorithms forced where possible (speed trade-off accepted). | Verified Reproducibility: Report includes hash comparison of outputs to prove bitwise identity. |
| Initialization | Weights/Data initialized randomly without saving. | Initialization state saved, but reloading not automated. | Checkpointing ensures initialization can be restored exactly. | Initialization generated procedurally from the master seed. |
3. Provenance & Lineage
Focus: Is the history of the data, code, and parameters traceable?
| Criteria | Level 0 (Failing) | Level 1 (Basic) | Level 2 (Robust) | Level 3 (Exemplary) |
|---|
| Data Versioning | Only final processed data provided; raw data missing. | Links to static data sources (e.g., URL to Drive/Dropbox). | Data versioned via hash (SHA-256) or unique Identifier (DOI). | Data Version Control (e.g., DVC, Git-LFS) used to track data snapshots alongside code. |
| Code Versioning | Code provided as a zip file; no git history. | Public Git repo, but no release tag or specific commit referenced. | Specific Commit Hash or Release Tag (v1.0) referenced in the paper. | Archived Repository: Zenodo/SoftwareX DOI linking permanently to the specific code version. |
| Parameter Logging | Hyperparameters mentioned only in the paper text. | Parameters listed in a config file (JSON/YAML). | Parameters are logged automatically by the pipeline runner (e.g., MLflow, Weights & Biases). | Inputs, parameters, and outputs are cryptographically linked (Workflow provenance). |
4. Review Artifacts
Focus: Can a reviewer easily validate the claim without expert knowledge of the code?
| Criteria | Level 0 (Failing) | Level 1 (Basic) | Level 2 (Robust) | Level 3 (Exemplary) |
|---|
| Documentation (README) | No instructions provided. | Text file explaining how to run the main script. | Comprehensive README with Prerequisites, Installation, and Execution steps. | Executable Paper: Notebooks (Jupyter/RMarkdown) that weave narrative, code, and results together. |
| Build & Execution | Manual installation of complex dependencies required. | make or bash script provided to run steps sequentially. | Workflow manager used (e.g., Snakemake, Nextflow, Airflow) to handle execution graph. | One-Click Reproduce: Single command (e.g., reproduce.sh) pulls data, builds container, runs analysis, and generates figures. |
| Output Verification | Reviewer must visually compare generated figures to paper. | Script outputs files to a folder; reviewer checks manually. | Script prints "Success" or asserts expected values. | Automated assertion tests that compare generated output hashes against the "Gold Standard" paper results. |
Rubric Summary Checklist
When submitting or reviewing, check off the items below to determine the Reproducibility Grade:
- [ ] Grade A (Exemplary): Meets Level 3 in all categories. (Dockerized, Deterministic, DOI-minted, Automated).
- [ ] Grade B (Strong): Meets Level 2 in most categories. (Pinned versions, Config files, Git tagged).
- [ ] Grade C (Basic): Meets Level 1. (Requirements.txt, README exists, Data linked).
- [ ] Grade D (Failing): Meets Level 0 in any category. (Missing data, unpinned deps, manual hacks required).
How to use this Rubric
- For Authors: Use this as a pre-submission checklist to ensure your code repository meets community standards.
- For Reviewers: Use the "Review Artifacts" section to verify that the "One-Command" promise is kept.
- For Labs: Adopt the "Environment" and "Seeds" sections as standard operating procedure for new projects.