irb-in-hurry
CLAUDE.md39 starsChanged 24 days agoMITView on GitHub
Institution-agnostic IRB form pipeline, packaged as irb-in-hurry (command irbh): study facts (config.toml) + an institution pack (profile.toml + forms.py) → that institution's official DOCX forms → PDF → layout gate. KFSYSCC is the bundled reference pack (irbinhurry/institutions/kfsyscc/). Method: docs/METHODOLOGY.md · Fork guide: docs/ONBOARDING.md. The repo root doubles as a study folder. make <x> = uv run irbh <x>: Installed users run the same commands as irbh <x> in any study folder (irbh init <example> starts one and copies .claude/skills/irb/ into…
We split this CLAUDE.md into the rules it gives an agent
4 rules. About 0 are common, 0 are distinctive, and 4 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈0
Distinctive · estimate
This author's own choices. Worth a look.
4
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 30
Package: all code lives in irb_in_hurry/ (import irb_in_hurry.*, never path hacks).
- Very specific: line 34
New CLI command: add it to irb_in_hurry/cli.py (and a Makefile target if contributors use it)
- Very specific: line 43
Generators: prefer template_fill.blank_generator (fill the official blank).
- Very specific: line 46
Config (SSOT): All study data in plain text, never hardcoded.
≈ “Common” is an estimate: at least 1 in 5 of the 25,680 CLAUDE.md 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
IRB-in-Hurry
Institution-agnostic IRB form pipeline, packaged as irb-in-hurry (command irbh):
study facts (config.toml) + an institution pack (profile.toml + forms.py) →
that institution's official DOCX forms → PDF → layout gate. KFSYSCC is the bundled
reference pack (irb_in_hurry/institutions/kfsyscc/).
Method: docs/METHODOLOGY.md · Fork guide: docs/ONBOARDING.md.
Quick Start
The repo root doubles as a study folder. make <x> = uv run irbh <x>:
# Edit config.toml (facts, `institution = "<id>"`), cv.toml (team), 中文計畫摘要.md (prose)
make check # Resolve @references + validate
make templates # Once: cache the institution's blank forms
make all # Generate + PDF + layout gate + dashboard
make closure # = make all PHASE=closure (any phase; file untouched)
make set-phase PHASE=closure # Persist the phase in config.toml (keeps comments)
make onboard INST=<id> # New institution: blanks in templates/<id>/ → draft pack
uv run irbh doctor # LibreOffice, poppler, form font, config, blanksInstalled users run the same commands as irbh <x> in any study folder
(irbh init <example> starts one and copies .claude/skills/irb/ into it).
Conventions
- Python: Managed by
uv(pyproject.toml, hatchling build), run viauv run irbhormake - Package: all code lives in
irb_in_hurry/(importirb_in_hurry.*, never path hacks); data shipped in the wheel (packs, examples,fonts.conf) sits inside it, and the skill is force-included asirb_in_hurry/skill. Paths for study data are relative to the cwd (the study folder), never to__file__ - New CLI command: add it to
irb_in_hurry/cli.py(and a Makefile target if contributors use it) - Three kinds of data, never mixed:
- study facts →
config.toml(+ the files it@-references) - institution facts (names, IRB-no label, submission address, page, margins, font, blank locations) →
<pack>/profile.toml - form list + routing →
<pack>/forms.py
- study facts →
- No institution literals in code: generators read
institution()(irb_in_hurry.docx_utils); shared modules readirb_in_hurry.institution.current() - Active institution:
IRB_INSTITUTIONenv →institutionin config.toml →kfsyscc - Pack lookup (first wins):
<cwd>/institutions/<id>/(local, fromirbh onboard) →irb_in_hurry.institutionsentry points (installed packages) → bundledirb_in_hurry/institutions/<id>/ - Generators: prefer
template_fill.blank_generator(fill the official blank); rebuild with python-docx only when a blank can't be filled - Font: the profile's
font(KFSYSCC: 標楷體 / DFKai-SB); no theme fonts (pin_form_font) - Checkbox: ■ (U+25A0) = checked, □ (U+25A1) = unchecked, via
check() - Config (SSOT): All study data in plain text, never hardcoded.
config.tomlholds structured fields;"@file"/"@file#key"values inline other files (@cv.toml#pi,@中文計畫摘要.md). Long prose goes in Markdown (## 標題→ section key), not TOML strings. Loader + validation:irb_in_hurry/config.py. Never re-dump config.toml — usePHASE=for a one-off run, orset_phase.py(edits only thephase =line) to persist it - Output: DOCX →
output/, PDF →output/, PNG previews →output/preview/ - Page: profile page size + per-form margins, applied by
generate_all - Blanks:
templates/<id>/in the study folder (gitignored;$IRB_TEMPLATES/<id>/to share), the gate's ground truth, never edited, never packaged - Layout gate:
make validatemust show 0 errors before submission; PDF is the submission copy
Project Structure
irb_in_hurry/cli.py—irbhcommand (init, check, generate, pdf, templates, onboard, validate, all, dashboard, review, set-phase, institutions, skill, doctor;irbh <phase>=all --phase)irb_in_hurry/institutions/<id>/— bundled packs: profile.toml, forms.py (registered as entry points in pyproject.toml)irb_in_hurry/examples/— Complete example studies (irbh init <name>/make init EXAMPLE=<name>)irb_in_hurry/institution.py— Pack lookup (local → installed → bundled) + active profile loaderirb_in_hurry/config.py— config.toml loader (@references, Markdown sections,irbh check) + validation: required fields, enums, real booleans, defaults for optional sectionsirb_in_hurry/template_fill.py— Generic fill-the-blank generator (labels → values, □ → ■)irb_in_hurry/onboard.py— Blank forms → draft profile + forms.py + inventory in<cwd>/institutions/<id>/irb_in_hurry/docx_utils.py— Shared DOCX helpers (profile-aware;form_filenamefor output names)irb_in_hurry/form_selector.py— Phase + study type → required forms (active pack); sharedPHASE_NAMESirb_in_hurry/generators/— KFSYSCC rebuild generators (reference pack;generators.*in a FORM_REGISTRY)irb_in_hurry/generate_all.py— Main orchestratorirb_in_hurry/set_phase.py— Persistphase = "..."in config.toml without losing commentsirb_in_hurry/checklist.py— ■/□ checklist generatorirb_in_hurry/dashboard.py— Submission status dashboardirb_in_hurry/convert.py— DOCX→PDF→PNG pipelineirb_in_hurry/fetch_templates.py— Scrape or index official blanks →templates/<id>/irb_in_hurry/validate_layout.py— Layout/font safety gate →output/layout_report.md.claude/skills/irb/— Claude Code skill set, shipped in the wheel (onboarding:references/onboard-institution.md).github/workflows/release.yml— tagvX.Y.Z(= pyproject version) → GitHub Release (+ PyPI whenPUBLISH_PYPI=true)
Testing
make init EXAMPLE=gcsf-retrospective FORCE=1 && make all
make test # every example × every phase, config validation, layout gate, CLI
make lint # ruff; CI runs both on every PR, plus a wheel smoke test outside the repo
make build # sdist + wheel; install dist/*.whl in a fresh venv to try it as a userNew generator: add it to FORM_REGISTRY in the pack's forms.py; the e2e matrix
picks it up automatically. New config field: document it in
.claude/skills/irb/references/config-schema.md, and add it to DEFAULTS /
BOOL_FIELDS in irb_in_hurry/config.py if generators index it directly.
In this repositoryOne other file it gives its agents.
- irb-form-generatorSkill
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
Reviews can't be read right now.
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.

