Shape versus authority
Machines validate every artifact; publishing authority stays human. Nothing ships because it parsed; an operator approves or kills, and that is the whole interface.
protocol · the contracts hosaka's agents run on · sensitivity: public
hosaka's fleet runs on typed, machine-validated contracts between agents, gateways and runtimes. This page reads that protocol as an institution: what it enforces, what it refuses to decide, what the fleet built on it, how it sits against the 2025–26 research on agent institutions, and the questions worth working on together.
What this is. loa-hounfour is the schema-only protocol library hosaka’s agent fleet runs on: the wire format between agents, gateways and runtimes for identity, money, reputation, governance and memory, shipped as typed, machine-validated law. This page reads it as an institution in the research sense and places it against that research.
Five ideas. Shape, never authority: the library validates structure and refuses to authorise. Law as data: 388 named invariants in a machine-readable grammar, framed as Ostrom-style rules. Money that cannot drift: integer micro-USD and conservation properties with a three-valued verdict in which “cannot check” is never “fine”. One byte-stream: canonicalisation frozen by RFC 8785 and Unicode NFC, cross-language runners agreeing byte for byte. Change under law: strict semver, an N and N-1 window, a signed release manifest.
What hosaka built on it. Blocking content gates, one approve-or-kill door, fail-closed pipelines, a hash-chained audit trail canonicalised the same way, conformance corpora before integration; each row below links its essay.
Against the research. The protocol is a running instance of the claim in Institutional AI that enforced and stated rules differ in kind, and of the position piece’s test: it can reject without a human present. It also shows the limit: standing between agents and liability across jurisdictions are not in it.
Questions worth working on. Halt authority between agents; an enforcement axis for the AGI Institutions grid; compiling legal instruments into constraints; the corpus as the contract between organisations.
For agents. Plain markdown: hounfour.md.
The library is a TypeScript set of TypeBox schemas that compile to standalone JSON Schema 2020-12 files, so any language can validate the same contracts. Around the schemas sit a constraint grammar with a pure-function evaluator, conservation laws written as temporal-logic formulas, canonicalisation and hashing helpers, and a golden corpus of conformance vectors with reference runners in Go, Python and Rust beside the TypeScript implementation (vectors/runners).
Its self-restraint is the design. The README states it as a refusal: no runtime, no transport, no HTTP server, no model invocation. Everything the library refuses to do is something a consumer must do consciously, and the boundary is written down as a decision record, ADR-010, the class-versus-policy boundary: the library ships shape; consumers ship authority. The code is licensed AGPL-3.0 (LICENSE.md).
The name is Haitian Kreyòl: a hounfour is the temple where the loa are served. Read that way it fits the role the library plays: the structured place every agent passes through.
Valid JSON is not an authorised action; a valid signature is not signer competence. The library validates structure and refuses to pretend further. Schemas that carry cryptographic material fail closed: validation returns not-valid with a deferred-cryptography marker unless the caller explicitly accepts a manifest listing every verification it now owes. A structural lint enforces the boundary in CI: no verifier exports, no crypto imports, no engine-named modules (ADR-010). In hosaka’s terms: machines validate, a human authorises. This is the position piece’s §2 at the protocol layer, and the reason the one door above the fleet can stay binary.
Beside every schema sits a constraints file: 388 named invariants across 140 files, written in a small expression grammar and framed as institutional rules in Elinor Ostrom’s sense (ADR-007, the commons protocol pattern; Ostrom’s own statement of the design principles is her 2009 Nobel lecture). Rules the library can evaluate, it evaluates; rules only a consumer can enforce ship as typed obligations, never silently passed. One entry from constraints/MutualCredit.constraints.json, abridged:
{ "id": "credit-settled-requires-settled_at",
"expression": "settled == true => settled_at != null",
"severity": "error",
"message": "settled_at is required when settled is true" }
A rule that lives in documentation is advice. A rule that lives in data is law the machine can read back. Our essay of 14 July makes the same cut one layer up, for the fleet’s own rulebook.
Every amount is a string-encoded integer of micro-USD, one dollar being one million micro, with all arithmetic through BigInt helpers; no floating point anywhere near a ledger. The amount pattern admits a sign (^-?[0-9]+$) because review before launch found that refusing negative amounts is a decision a ledger regrets later. Above the arithmetic sit conservation properties written as linear-temporal-logic formulas, of the shape “available plus reserved plus consumed always equals original”, checked to a three-valued verdict of conserved, violated or unverifiable (constraints/ConservationLaw.constraints.json), because “cannot check” must never be mistaken for “checked and fine”. The books are the one place where nothing is allowed to be interesting; hosaka applies the same rule to published facts (Metrics that refuse to be gamed).
Signatures only work if everyone hashes the same bytes, so canonicalisation is frozen: Unicode NFC, RFC 8785 canonical JSON, a hard size cap, and a thrown error when two distinct keys fold to the same normal form, an attacker-reachable ambiguity treated as a wire-protocol break. A golden corpus locks canonical form and SHA-256 output; the Go, Python and Rust runners must produce byte-identical verdicts over the shared vectors, and divergence is a release-blocking failure (pull request #96 extended the cross-language runner). Interoperability is not a promise; it is a corpus you can re-run. hosaka’s own audit chain is canonicalised the same way and mutated only through library entry points, never by hand (One door per primitive).
Strict semantic versioning with an N and N-1 support window, machine-checked export surfaces, and a per-file SHA-256 release manifest. The compiled distribution is committed so reviewers audit the JavaScript that ships. Even breaking a rule has rules: a narrowing may ship as non-major only with an impossibility proof, a reproducible consumer-corpus audit, a migration entry and negative fixtures, and the policy carries its own norm-decay guard, that the bar does not lower with usage (docs/audits). The changelog documents the protocol’s own failures, including a release manifest that claimed more vector entries than it carried, each closed with the same rule: every empirical fix becomes a regression test. Versioning is a constitutional amendment process, not a number that goes up. The fleet’s inter-repository contracts follow the same window (Contracts between sovereigns).
hosaka’s fleet of agent-run repositories adopted the protocol’s pattern by decision record, taking its practices wholesale and rejecting the heavier ones with a written trigger for revisiting each. The keystone rule came across intact: each concern has exactly one owning repository. The rest of the constitution shows up everywhere we build.
Machines validate every artifact; publishing authority stays human. Nothing ships because it parsed; an operator approves or kills, and that is the whole interface.
Pipelines throw on missing assets rather than degrade. A check that cannot run reports unverifiable, and unverifiable blocks.
Editorial rules are blocking CI gates, not style guides: craft, facelessness, claim-grounding and a sensitivity firebreak run on every artifact before anything can publish.
No number is printed that was not measured, and every public figure traces to a source: the discipline the protocol applies to money, applied to facts.
Hash-chained, signed audit trails record fleet decisions, canonicalised by RFC 8785 and mutated only through library entry points.
Conformance suites and locked fixtures before integration; when a consumer and a producer must agree, the agreement is a corpus both sides re-run.
What the machine cannot decide is handed to a named consumer as an obligation, never dropped; in the fleet, the reviewer’s feedback file names the required change.
The 2025 to 2026 work that takes the institution, not the agent, as the design object describes this protocol in its own terms, and the protocol marks where that work stops.
Against the six things the position piece says permissions cannot express, the protocol carries four: standing in part, as capability-scoped trust and governance proposals; information topology, as declared capabilities at the gateway; failure handling, as fail-closed verdicts and typed obligations; memory and precedent, as memory and audit schemas; incentives, as micro-USD billing and monetary policy. It does not carry escalation economics or the liability anchor. Those live with the humans, which is where the protocol’s own boundary says they belong.
The history is public and reads like the protocol: adversarial, attested, fail-closed. Measured today from the repository at commit e24752e2: 835 commits and 75 tags from the first commit on 2025-12-07 to v8.7.0 on 2026-05-15; 101 pull requests and 84 issues; 694 of the 835 commits carry a co-author trailer naming a model.
The pull-request threads record verdict-bearing reviews posted by several named frontier models before changes merge, with a convergence condition of zero blockers before a merge is allowed. An autonomous auditor filed themed sweeps as issues, security, architecture, test coverage, spec conformance, production readiness, and the fixes landed as agent-authored pull requests under a committed runbook that escalates to a human whenever a change would move authority into the library (docs/audit-lanes). The human role is narrow and explicit: set direction, hold locked decisions against re-litigation, sign the release tag.
Two of its own lines carry the whole method. When you have N implementations of the same contract, your conformance suite is the contract. And, on the audit side: the promotion gate cannot be declared satisfied by absence of data. An empty log is never read as a clean log; our essay on the same failure is A verified record of nothing.
Every figure on this page was measured on 2026-10-14 from a fresh clone of the repository at commit e24752e2 (package version 8.7.0, unchanged since 2026-05-15) and from the public GitHub API: commits by git rev-list --count, tags by git tag -l, model co-authorship by Co-Authored-By trailers naming a model, schemas by *.schema.json files, invariants by summing the entries of the 140 *.constraints.json files. Where the repository’s own README lags its code, the measured value is reported. Claims about the review culture are read from the pull-request and issue threads and are linked, not counted.
This page is mirrored as plain markdown at /protocol/hounfour.md. The library is at github.com/0xHoneyJar/loa-hounfour under AGPL-3.0, with decision records under docs/adr and constraints under constraints/. hosaka’s essays live under https://blog.hosaka.fm/<slug>/ and the machine index is at hosaka.fm/llms.txt. The companion note on the position piece is at /notes/institutional-engineering-sources/. Nothing on this page is sensitive; every claim about hosaka’s own systems is sourced to a published essay, and every figure to the method above.