prereg
Freeze a plan before you run it, and record what changed after.
Install
pip install prereg
Quick start
prereg new V16_reliability_ceilings
# fill in the plan, commit it
prereg freeze
# run the experiment, then log what happened
prereg log "tolerance now derived from fixtures" --access "no results seen"
prereg check
unchanged V16_reliability_ceilings/PREREG.md
Commands
| Command | What it does |
|---|---|
prereg new <name> |
Scaffold a plan in OSF's headings |
prereg freeze |
Record the commit and hash |
prereg freeze --osf |
Freeze and push as a draft registration to OSF |
prereg log <note> |
Append to the log without freezing |
prereg check |
Has the plan changed since the freeze? |
prereg setup |
Save your OSF token to .env |
One file, one rule
V16_reliability_ceilings/
PREREG.md the plan, then a line, then an append-only log
tests/ results/
Never edit above the line. Only append below it.
prereg check enforces it — the freeze records a hash of the plan, and any later edit to it
fails the check. Appending to the log does not.
The log
2026-08-11 frozen at 9894e148e429 nothing run
2026-08-13 tolerance now from fixtures no results seen
2026-08-14 ran results not opened
2026-08-15 C5 failed at k=15: 6.6% vs 5% results seen
The last column is what distinguishes an amendment from a deviation, so you never have to
decide which word to use. nothing run, no results seen, results not opened, results seen. An entry logged before results is an amendment; one logged after is a deviation.
Check output
| Exit | Result | Meaning |
|---|---|---|
| 0 | unchanged |
The plan says what it said |
| 1 | CHANGED |
The plan was edited above the line after freezing |
| 2 | not frozen |
No hash recorded — nothing was measured |
not frozen is not a pass. It is the absence of a check.
The plan uses OSF's headings
Verbatim, so the document maps onto an OSF registration without being rewritten. Two of the twenty-seven do the real work:
- Foreknowledge of data or evidence — what you have already seen.
- Inference criteria — the decision rule as a commitment, before the number exists.
A heading that does not apply is answered N/A with a reason, never deleted.
OSF integration
The plan uses OSF's question titles verbatim, so prereg freeze --osf pushes it directly to
OSF as a draft registration. You review and submit it there — submission is irreversible.
prereg setup # save your OSF token (once)
prereg freeze --osf # freeze locally and push to OSF
Create a token at osf.io/settings/tokens with the
osf.full_write scope. The token is stored in .env (gitignored).
What a freeze is
A commit and a hash. The commit is the evidence — it is in history, dated, and not yours to
revise quietly. The hash is the convenience that lets prereg check tell you in a second
whether the plan still says what it said.
Neither proves you did not run the experiment first. Nothing can: a timestamp bounds when something existed, never when work began.
Claude Code
plugin/ is a Claude Code plugin that tells Claude when to reach for the CLI.
/plugin marketplace add elliottower/prereg
/plugin install prereg@prereg
For all three reproducible-science tools in one plugin (prereg + citations + results):
/plugin marketplace add elliottower/reproducible-science
MIT licensed.
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file prereg-0.2.0.tar.gz.
File metadata
- Download URL: prereg-0.2.0.tar.gz
- Upload date:
- Size: 20.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5138d9b81ab2d1d3f5eeac10daa0f66a05120d7e61c99299a4ad5f03604278f3
|
|
| MD5 |
1760ada6089081f2c829ef1c02c0b736
|
|
| BLAKE2b-256 |
e0625adb64fd7e1b6149dc6b799f63aa6ff22f4ddad14d75c3c460fb5c063ef8
|
Provenance
The following attestation bundles were made for prereg-0.2.0.tar.gz:
Publisher:
publish-prereg.yml on elliottower/reproducible-science
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
prereg-0.2.0.tar.gz -
Subject digest:
5138d9b81ab2d1d3f5eeac10daa0f66a05120d7e61c99299a4ad5f03604278f3 - Sigstore transparency entry: 2582481805
- Sigstore integration time:
-
Permalink:
elliottower/reproducible-science@e19b7e952529c76fe4f9d304c7dc93f806ad2a72 -
Branch / Tag:
refs/tags/v0.2.0 - Owner: https://github.com/elliottower
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-prereg.yml@e19b7e952529c76fe4f9d304c7dc93f806ad2a72 -
Trigger Event:
push
-
Statement type:
File details
Details for the file prereg-0.2.0-py3-none-any.whl.
File metadata
- Download URL: prereg-0.2.0-py3-none-any.whl
- Upload date:
- Size: 15.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2e2fd3497bab82904488229cb5213f9817fee21eb3fb6d12b30332ff9cda9c4f
|
|
| MD5 |
0fe58a51fe8b5eac59615843e23b372c
|
|
| BLAKE2b-256 |
06e1d07204512d1bd98a9539091786127cc316c3fb692d66ed073608fd9cfea0
|
Provenance
The following attestation bundles were made for prereg-0.2.0-py3-none-any.whl:
Publisher:
publish-prereg.yml on elliottower/reproducible-science
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
prereg-0.2.0-py3-none-any.whl -
Subject digest:
2e2fd3497bab82904488229cb5213f9817fee21eb3fb6d12b30332ff9cda9c4f - Sigstore transparency entry: 2582481924
- Sigstore integration time:
-
Permalink:
elliottower/reproducible-science@e19b7e952529c76fe4f9d304c7dc93f806ad2a72 -
Branch / Tag:
refs/tags/v0.2.0 - Owner: https://github.com/elliottower
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-prereg.yml@e19b7e952529c76fe4f9d304c7dc93f806ad2a72 -
Trigger Event:
push
-
Statement type: