SP Boucher Source Governance
One source-code identity, attribution and license standard for every SP Boucher repository: research, teaching, SP and ORIX applications, web platforms, AI systems and MacLustr infrastructure.
Author: Simon-Pierre Boucher — Professor of Finance, Université du Québec en Outaouais (UQO) — https://spboucher.ai — dev@spboucher.ai
What is here
| Path | Content |
|---|---|
SOURCE_HEADER_POLICY.md |
the standard: rules, variants, exclusions |
COPYRIGHT_POLICY.md |
how the rights holder and license of a header are established |
CONTACT_DIRECTORY.md |
official addresses and routing by project category |
SECURITY_POLICY.md |
what a header may never disclose |
config/ |
identity, comment syntax per language, exclusions (TOML) |
templates/ |
header bodies per variant |
spbheader/ |
the engine (Python ≥ 3.11, standard library only) |
bin/spb-header |
launcher |
tests/ |
unit and end-to-end tests |
integrations/ |
git hook, pre-commit, CI job, Claude Code section, Xcode, LaTeX notes |
docs/ONBOARDING.md, docs/ROLLBACK.md |
procedures |
Commands
export SPB_GOVERNANCE_WORKSPACE=~/path/to/workspace # repos/, policies/, ledger/, reports/
spb-header discover # list repositories of the workspace
spb-header classify [slug…] # draft a policy per repository from verifiable facts
spb-header audit [slug…] # read-only file-level audit
spb-header inventory # machine-readable inventory (JSON, CSV)
spb-header preview <slug> # proposed diff, nothing modified
spb-header apply [slug…] # branch chore/spb-source-governance, headers, validation, local commit
spb-header validate [slug…] # re-prove from git that each migration commit is comment-only
spb-header report # STATUS.md, summary.json, inventory.csv
spb-header status # compliance summary
spb-header rollback <slug> # remove headers file by file
spb-header check --repo . # hook / CI check of one repository
spb-header apply --repo . --files path/to/file # header for a new fileapply never pushes, never touches a default branch, never stashes and refuses a dirty tree.
Guarantees, and how they are checked
| Guarantee | Check |
|---|---|
| comment-only change | header removal must reproduce the baseline bytes (at write time, then again from git by validate) |
| no behaviour change | Python AST equality; swiftc -parse; node --check; bash -n; YAML/TOML data equality; notebook cells equality — each compared with the baseline |
| idempotent | a second scan must propose nothing |
| reversible | per-file ledger with hashes and replaced legacy blocks |
| nothing private in headers | leak patterns refused at write time and in check |
A repository is reported as validated only when all of these hold. Project builds and test suites remain the final word and are run per repository family (see the workspace reports).
Tests
python3 -m unittest discover -s testsRepository layout
spb-source-governance/
├── bin/ 1 file executables
├── config/ 3 files configuration
├── docs/ 2 files documentation
├── examples/ 1 file examples
├── integrations/ 8 files integrations
│ ├── ci/ 2
│ ├── claude-code/ 1
│ ├── git-hooks/ 2
│ ├── latexmk/ 1
│ ├── pre-commit/ 1
│ └── xcode/ 1
├── spbheader/ 5 files
├── templates/ 8 files
├── tests/ 1 file tests
├── CLAUDE.md
├── CONTACT_DIRECTORY.md
├── COPYRIGHT_POLICY.md
├── README.md
├── SECURITY_POLICY.md
└── SOURCE_HEADER_POLICY.mdLanguages
| Language | Files | Lines | Share |
|---|---|---|---|
| Python | 6 | 2 597 | ███████████████████ 96.7 % |
| Shell | 2 | 90 | █ 3.3 % |
Counted on git-tracked files, excluding dependencies and generated files.
Documentation
| Document | Title |
|---|---|
CLAUDE.md |
spb-source-governance |
CONTACT_DIRECTORY.md |
Official Contact Directory |
COPYRIGHT_POLICY.md |
Copyright and License Policy |
SECURITY_POLICY.md |
Security Policy of the governance system |
SOURCE_HEADER_POLICY.md |
SP Boucher Source Header Policy |
docs/ONBOARDING.md |
Onboarding a repository |
docs/ROLLBACK.md |
Rollback |
Repository facts
| First commit | 2026-11-21 |
| Contributors | 1 |
| Default branch | main |
| Tracked files | 37 |
| Website | https://git.spboucher.ai |
| Topics | source-headers governance copyright licensing python cli git-hooks |
| Clone | git clone https://git.spboucher.ai/spb-source-governance.git |
Author
Simon-Pierre Boucher · spboucher.ai · contact@spboucher.ai