From 159120a47dc36a65c1de1872922ba2a317c296cd Mon Sep 17 00:00:00 2001 From: hyperpolymath <6759885+hyperpolymath@users.noreply.github.com> Date: Mon, 22 Jun 2026 09:52:12 +0100 Subject: [PATCH 1/4] feat(design): Haec surface grammar + elaboration-to-IR table MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit design/grammar.ebnf (term formers, fix, 5 atomic effects + sugar); design/ elaboration.adoc (each construct → Trope IR edge + grade + its O2 lowering obligation); vendored design/trope-ir.schema.json (the IR contract Haec targets). --- design/elaboration.adoc | 84 ++++++++++++++ design/grammar.ebnf | 68 +++++++++++ design/trope-ir.schema.json | 225 ++++++++++++++++++++++++++++++++++++ 3 files changed, 377 insertions(+) create mode 100644 design/elaboration.adoc create mode 100644 design/grammar.ebnf create mode 100644 design/trope-ir.schema.json diff --git a/design/elaboration.adoc b/design/elaboration.adoc new file mode 100644 index 0000000..11258b6 --- /dev/null +++ b/design/elaboration.adoc @@ -0,0 +1,84 @@ +// SPDX-FileCopyrightText: © 2026 Jonathan D.A. Jewell (hyperpolymath) +// SPDX-License-Identifier: MPL-2.0 +// SPDX-License-Identifier: CC-BY-SA-4.0 += Haec elaboration — surface construct → Trope IR edge +:revdate: 2026-06-22 +:toc: macro +:sectnums: + +How each Haec construct lowers to a Trope IR effect edge and its grade. The grade +algebra and the IR are normative in the checker (`trope-checker/spec/`); this table +is Haec's *lowering*. For every construct we also state its *lowering-correctness +obligation* (calculus O2) as Haec's burden — a sentence even where the proof is +later (HC-5: stated, not asserted-as-discharged). + +toc::[] + +== The unit and the five atoms + +[cols="1,2,2",options="header"] +|=== +| Construct | IR edge (effect, grade) | O2 obligation (Haec's burden) +| `preserve e` +| `preserve`, grade ε = (all `Present`, `Intact`, `Single`) +| Prove the elaborated term is observationally identity on the instance — it drops/blurs/merges nothing. +| `attenuate[δ] e` +| `attenuate`, `fate(φ)=Attenuated(δ)` for present φ; `bond`,`merge` unchanged +| Prove the operation degrades fidelity by at most δ on each present field and touches neither bond nor cardinality (δ=`top` when the bound is unknown — always sound). +| `predicate[P] e` +| (atomic) `fate(quality)=Predicated(P)`, others unchanged here +| Prove the result is exactly `P` applied to the quality, and that `P` is the predicate named. +| `drop[S] e` +| `project`/`drop`, `fate(φ)=Dropped` for φ∈S; `bond=Withheld` if `bearer∈S`; `merge=Single` +| Prove exactly the fields in S are withheld and no others, and that dropping the bearer is a clean named drop (Withheld), not a constitutive severance. +| `sever e` +| `detach`-core, `fate(quality)=Present`, others `Dropped`, `bond=Severed`; type → `FloatingQuality` +| Prove the quality survives intact and the quality–bearer tie is genuinely cut (irrecoverable) — the `Severed`, not merely `Withheld`, claim. +| `fuse[τ] e₁ e₂` +| `fuse` (two inputs), `merge=Fused(τ)`, fates `Present`, bond = meet of inputs +| Prove τ faithfully records the provenance of the blend so plurality is recoverable from it — i.e. the merge is labelled, never silent. +|=== + +== Sugar (expanded per the calculus) + +[cols="1,2,2",options="header"] +|=== +| Construct | Expansion | O2 obligation +| `project[S] e` +| `drop[Φ∖S] e` — drop the complement of the kept set S +| As `drop`, for the complement: prove exactly Φ∖S is withheld. +| `collapse[P] e` +| `predicate[quality,P] e ▷ drop[bearer,context,record]` — collapse subsumes prior fidelity loss; result fate(quality)=`Predicated(P)`, others `Dropped`, bond `Withheld`, merge `Single`; type → the predicate codomain (e.g. `Bool`) +| Prove the construct yields *only* the value of P over the quality (a checkbox), with everything else genuinely gone — the `Predicated`-incomparable-to-`Dropped` claim. +| `detach e` +| `drop[bearer,context,record] e ▷ sever` — yields `FloatingQuality` +| Prove the quality is lifted free-standing and the bond is `Severed` (irrecoverable), distinguishing it from a bearer-projection. +|=== + +== General recursion (`fix`) + +`fix x. e` lowers to the body's edges under the *least-fixed-point grade* of the +body's grade functional (calculus §7). Haec is *bidirectional*: the author declares +a `loss_signature` (`! { fate=…, bond=…, merge=… }`) at every recursive and +effectful boundary; grades are *checked* against it there and *inferred* through the +straight-line fragment. An unbounded lossy loop has fidelity grade `top` — the +honest answer; any use-model demanding better than `top` rejects it. The checker +never executes the term, so Rice's theorem is no obstacle. + +*O2 for `fix`:* prove the declared loss-signature is an upper bound (in loss) on the +body's grade functional, so the lfp it induces is sound. + +== The deceptive trio is NOT elaborable + +There is no surface form for value-falsification, mis-binding, or untagged merge +(HC-3). `fuse` *requires* a tag; an untagged merge does not parse. If a (buggy) +lowering ever emitted `Falsified`/`Misbound`/`Conflated`, the Trope IR would be +malformed and the checker rejects it at validation, naming the coordinate +(R-2026-06-22, prevent profile). That rejection is the conflation/deception detector +at Haec's lowering boundary. + +== Worked correspondence + +`examples/` pairs each small program with the exact IR it lowers to; those IR +documents are accepted by the checker and produce the verdicts the examples state. +The example IR is kept in lockstep with the checker's conformance fixtures. diff --git a/design/grammar.ebnf b/design/grammar.ebnf new file mode 100644 index 0000000..dd75a62 --- /dev/null +++ b/design/grammar.ebnf @@ -0,0 +1,68 @@ +(* SPDX-FileCopyrightText: © 2026 Jonathan D.A. Jewell (hyperpolymath) *) +(* SPDX-License-Identifier: MPL-2.0 *) +(* + Haec surface grammar (design v0.1) — ISO/IEC 14977 EBNF. + + Haec is a small Turing-complete front-end whose type discipline is + trope-particularity. It is deliberately NOT a kitchen sink: term formers, + general recursion (`fix`), the FIVE atomic effect forms, and the surface + SUGAR (preserve, project, collapse, detach). Every effect lowers to a Trope + IR edge — see design/elaboration.adoc. The deceptive trio (falsify, misbind, + conflate) is intentionally absent: it is not writable (HC-3). +*) + +program = { declaration } ; + +declaration = "let", identifier, [ ":", loss_signature ], "=", expression + | "fix", identifier, [ ":", loss_signature ], "=", expression ; + +expression = trope_literal + | identifier + | application + | effect + | "fix", identifier, ".", expression (* general recursion *) + | "(", expression, ")" ; + +application = expression, expression ; + +trope_literal = "trope", "{", field, { ",", field }, "}" ; +field = field_name, "=", value ; +field_name = "quality" | "bearer" | "context" | "record" ; + +(* ── effects ───────────────────────────────────────────────────────────── *) +effect = atomic_effect | surface_sugar ; + +(* the five atomic moves that generate the honest fragment *) +atomic_effect = "attenuate", "[", delta, "]", expression + | "predicate", "[", predicate, "]", expression (* quality only *) + | "drop", "[", field_set, "]", expression + | "sever", expression + | "fuse", "[", tag, "]", expression, expression ; + +(* sugar, expanded per the calculus (design/elaboration.adoc) *) +surface_sugar = "preserve", expression + | "project", "[", field_set, "]", expression (* keep S; drop the rest *) + | "collapse", "[", predicate, "]", expression (* = predicate ▷ drops *) + | "detach", expression ; (* = drops ▷ sever *) + +(* ── loss signatures (declared at recursive/effectful boundaries) ──────── *) +loss_signature = "!", grade ; +grade = "{", "fate", "=", fate_map, ",", + "bond", "=", bond, ",", + "merge", "=", merge, "}" ; +fate_map = "{", field_name, "=", fate, { ",", field_name, "=", fate }, "}" ; +fate = "Present" | "Attenuated", "(", delta, ")" | "Predicated" | "Dropped" ; +bond = "Intact" | "Withheld" | "Severed" ; +merge = "Single" | "Fused", "(", tag, ")" ; + +field_set = field_name, { ",", field_name } ; +delta = natural | "inf" | "top" ; +predicate = identifier ; +tag = string ; +value = string | natural | identifier ; +identifier = letter, { letter | digit | "_" } ; +natural = digit, { digit } ; +string = '"', { character - '"' }, '"' ; +letter = "a" | "..." | "z" | "A" | "..." | "Z" ; +digit = "0" | "..." | "9" ; +character = ? any printable character ? ; diff --git a/design/trope-ir.schema.json b/design/trope-ir.schema.json new file mode 100644 index 0000000..9771d60 --- /dev/null +++ b/design/trope-ir.schema.json @@ -0,0 +1,225 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://github.com/hyperpolymath/trope-checker/schemas/trope-ir.schema.json", + "title": "Trope IR", + "$comment": "SPDX-FileCopyrightText: © 2026 Jonathan D.A. Jewell (hyperpolymath) . SPDX-License-Identifier: MPL-2.0. The language-neutral interchange of the trope-particularity calculus (spec/calculus.adoc). This is the canonical PREVENT profile (DEPLOY_VARIANT=prevent, R-2026-06-22): the three deceptive grade values (fate=Falsified, bond=Misbound, merge=Conflated) and the untagged merge are MALFORMED here and are rejected at validation with the offending coordinate named. The grade shape is the dependent record Sigma(fate). Bond(fate.bearer) x Merge; the if/then/else on bond makes bearer-incoherent grades unrepresentable (HC-4). The semantics (Idris2 src/) carries the COMPLETE lattices including the deceptive bottoms; the detect-profile schema (trope-ir.detect.schema.json) permits them and defers the check to the verdict.", + "description": "A labelled DAG: nodes are property-instances (field-presence + type tag), edges are effect applications carrying a loss-shape grade, and a use-model node carries the floor. The checker is a pure function from this document to a verdict.", + "type": "object", + "required": ["version", "profile", "nodes", "edges", "use_model"], + "additionalProperties": false, + "properties": { + "$schema": { "type": "string" }, + "$comment": { "type": "string" }, + "version": { "type": "string", "const": "0.1" }, + "profile": { + "type": "string", + "const": "prevent", + "$comment": "This schema is the prevent profile. A detect-profile document MUST use trope-ir.detect.schema.json and declare profile=detect." + }, + "nodes": { + "type": "array", + "minItems": 1, + "items": { "$ref": "#/$defs/node" } + }, + "edges": { + "type": "array", + "items": { "$ref": "#/$defs/edge" } + }, + "use_model": { "$ref": "#/$defs/useModel" } + }, + "$defs": { + "fieldName": { "enum": ["quality", "bearer", "context", "record"] }, + + "delta": { + "$comment": "A fidelity element of N union {inf, top}. Finite delta is tropical (min-plus) quantified loss; inf is total quantified loss; top is loss of unknown amount.", + "oneOf": [ + { "type": "integer", "minimum": 0 }, + { "type": "string", "enum": ["inf", "top"] } + ] + }, + + "fatePresent": { "type": "object", "required": ["k"], "additionalProperties": false, "properties": { "k": { "const": "Present" } } }, + "fateAttenuated": { "type": "object", "required": ["k", "delta"], "additionalProperties": false, "properties": { "k": { "const": "Attenuated" }, "delta": { "$ref": "#/$defs/delta" } } }, + "fatePredicated": { "type": "object", "required": ["k", "predicate"], "additionalProperties": false, "properties": { "k": { "const": "Predicated" }, "predicate": { "type": "string", "minLength": 1 } } }, + "fateDropped": { "type": "object", "required": ["k"], "additionalProperties": false, "properties": { "k": { "const": "Dropped" } } }, + + "fateQuality": { + "$comment": "Predicated is well-formed ONLY on the quality field (calculus 3.1). Falsified (deceptive) is excluded under the prevent profile.", + "oneOf": [ + { "$ref": "#/$defs/fatePresent" }, + { "$ref": "#/$defs/fateAttenuated" }, + { "$ref": "#/$defs/fatePredicated" }, + { "$ref": "#/$defs/fateDropped" } + ] + }, + "fateNonQuality": { + "$comment": "No Predicated off the quality field; no Falsified under prevent.", + "oneOf": [ + { "$ref": "#/$defs/fatePresent" }, + { "$ref": "#/$defs/fateAttenuated" }, + { "$ref": "#/$defs/fateDropped" } + ] + }, + + "fate": { + "type": "object", + "required": ["quality", "bearer", "context", "record"], + "additionalProperties": false, + "properties": { + "quality": { "$ref": "#/$defs/fateQuality" }, + "bearer": { "$ref": "#/$defs/fateNonQuality" }, + "context": { "$ref": "#/$defs/fateNonQuality" }, + "record": { "$ref": "#/$defs/fateNonQuality" } + } + }, + + "bond": { + "$comment": "Intact where bearer present; Withheld/Severed where bearer absent. Misbound (deceptive, bearer present) is excluded under prevent. The Sigma-dependency is enforced by the grade-level if/then/else, not here.", + "type": "object", + "required": ["k"], + "additionalProperties": false, + "properties": { "k": { "enum": ["Intact", "Withheld", "Severed"] } } + }, + + "merge": { + "$comment": "Single, or Fused with a REQUIRED provenance tag tau (R-2026-06-22: an untagged merge does not elaborate). Conflated (deceptive) is excluded under prevent.", + "oneOf": [ + { "type": "object", "required": ["k"], "additionalProperties": false, "properties": { "k": { "const": "Single" } } }, + { "type": "object", "required": ["k", "tau"], "additionalProperties": false, "properties": { "k": { "const": "Fused" }, "tau": { "type": "string", "minLength": 1 } } } + ] + }, + + "grade": { + "$comment": "The dependent record Sigma(fate). Bond(fate.bearer) x Merge. HC-4: the if/then/else makes bearer-incoherent states unrepresentable.", + "type": "object", + "required": ["fate", "bond", "merge"], + "additionalProperties": false, + "properties": { + "fate": { "$ref": "#/$defs/fate" }, + "bond": { "$ref": "#/$defs/bond" }, + "merge": { "$ref": "#/$defs/merge" } + }, + "if": { + "properties": { "fate": { "properties": { "bearer": { "properties": { "k": { "const": "Dropped" } }, "required": ["k"] } }, "required": ["bearer"] } }, + "required": ["fate"] + }, + "then": { + "$comment": "bearer absent -> bond is a clean named drop (Withheld) or a constitutive severance (Severed).", + "properties": { "bond": { "properties": { "k": { "enum": ["Withheld", "Severed"] } } } } + }, + "else": { + "$comment": "bearer present -> the tie holds (Intact). Severed/Withheld here would be incoherent (HC-4); Misbound is the deceptive case, excluded under prevent.", + "properties": { "bond": { "properties": { "k": { "const": "Intact" } } } } + } + }, + + "node": { + "type": "object", + "required": ["id", "type"], + "additionalProperties": false, + "properties": { + "id": { "type": "string", "minLength": 1 }, + "type": { + "$comment": "Trope[S] (a property-instance over a field-presence subset), FloatingQuality (quality severed; no bearer field), or Codomain (a collapse target, e.g. Bool; a non-trope).", + "enum": ["Trope", "FloatingQuality", "Codomain"] + }, + "present": { + "type": "array", + "uniqueItems": true, + "items": { "$ref": "#/$defs/fieldName" } + }, + "codomain": { "type": "string", "minLength": 1 }, + "label": { "type": "string" } + }, + "allOf": [ + { + "if": { "properties": { "type": { "const": "FloatingQuality" } }, "required": ["type"] }, + "then": { + "$comment": "A FloatingQuality has no bearer field (the severance is structurally visible).", + "properties": { "present": { "not": { "contains": { "const": "bearer" } } } } + } + }, + { + "if": { "properties": { "type": { "const": "Codomain" } }, "required": ["type"] }, + "then": { "required": ["codomain"] } + } + ] + }, + + "edge": { + "type": "object", + "required": ["id", "effect", "inputs", "output", "grade"], + "additionalProperties": false, + "properties": { + "id": { "type": "string", "minLength": 1 }, + "effect": { + "$comment": "The six writable effects. The deceptive trio (falsify, misbind, conflate) and any untagged merge are NOT writable (HC-3); they cannot appear as a well-formed effect here.", + "enum": ["preserve", "project", "collapse", "detach", "attenuate", "fuse"] + }, + "inputs": { + "type": "array", + "items": { "type": "string", "minLength": 1 }, + "minItems": 1, + "maxItems": 2 + }, + "output": { "type": "string", "minLength": 1 }, + "grade": { "$ref": "#/$defs/grade" }, + "note": { "type": "string" } + }, + "allOf": [ + { + "if": { "properties": { "effect": { "const": "fuse" } }, "required": ["effect"] }, + "then": { + "$comment": "fuse is the only two-instance writable effect; its grade must be a labelled (Fused) merge.", + "properties": { "inputs": { "minItems": 2, "maxItems": 2 }, "grade": { "properties": { "merge": { "required": ["tau"], "properties": { "k": { "const": "Fused" } } } } } } + }, + "else": { + "$comment": "every other writable effect is single-instance.", + "properties": { "inputs": { "minItems": 1, "maxItems": 1 } } + } + } + ] + }, + + "floorFate": { + "$comment": "A floor MAY be specified per field; absent fields impose no demand (calculus 5.2). A floor may not demand a deceptive value.", + "type": "object", + "additionalProperties": false, + "minProperties": 1, + "properties": { + "quality": { "$ref": "#/$defs/fateQuality" }, + "bearer": { "$ref": "#/$defs/fateNonQuality" }, + "context": { "$ref": "#/$defs/fateNonQuality" }, + "record": { "$ref": "#/$defs/fateNonQuality" } + } + }, + + "floorGrade": { + "$comment": "The minimum retained particularity the use requires. Every coordinate is OPTIONAL; an omitted coordinate imposes no demand on it.", + "type": "object", + "additionalProperties": false, + "minProperties": 1, + "properties": { + "fate": { "$ref": "#/$defs/floorFate" }, + "bond": { "$ref": "#/$defs/bond" }, + "merge": { "$ref": "#/$defs/merge" } + } + }, + + "useModel": { + "type": "object", + "required": ["output", "floor"], + "additionalProperties": false, + "properties": { + "id": { "type": "string" }, + "label": { "type": "string" }, + "output": { + "$comment": "The node whose accumulated grade is checked against the floor.", + "type": "string", + "minLength": 1 + }, + "floor": { "$ref": "#/$defs/floorGrade" } + } + } + } +} From 810929eed362e4e372a26dcc636c36a309426d89 Mon Sep 17 00:00:00 2001 From: hyperpolymath <6759885+hyperpolymath@users.noreply.github.com> Date: Mon, 22 Jun 2026 09:52:12 +0100 Subject: [PATCH 2/4] feat(examples): programs paired with lowered Trope IR + standalone checker MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit examples/*.haec with their *.ir.json; faithful record → p-sufficient, survey collapse → p-insufficient (witness=collapse), labelled fuse → p-sufficient. Each round-trips through trope-checker; tests/check-examples.py validates standalone. --- examples/EXAMPLES.json | 26 ++++++++ examples/faithful-record.haec | 15 +++++ examples/faithful-record.ir.json | 72 +++++++++++++++++++++ examples/station-average.haec | 12 ++++ examples/station-average.ir.json | 82 ++++++++++++++++++++++++ examples/survey-collapse.haec | 16 +++++ examples/survey-collapse.ir.json | 68 ++++++++++++++++++++ examples/web-project-deno.json | 2 +- tests/aspect_tests.sh | 2 +- tests/check-examples.py | 52 +++++++++++++++ tests/e2e.sh | 4 +- tests/e2e/template_instantiation_test.sh | 16 ++--- 12 files changed, 355 insertions(+), 12 deletions(-) create mode 100644 examples/EXAMPLES.json create mode 100644 examples/faithful-record.haec create mode 100644 examples/faithful-record.ir.json create mode 100644 examples/station-average.haec create mode 100644 examples/station-average.ir.json create mode 100644 examples/survey-collapse.haec create mode 100644 examples/survey-collapse.ir.json create mode 100644 tests/check-examples.py diff --git a/examples/EXAMPLES.json b/examples/EXAMPLES.json new file mode 100644 index 0000000..56ad73e --- /dev/null +++ b/examples/EXAMPLES.json @@ -0,0 +1,26 @@ +{ + "$comment": "SPDX-FileCopyrightText: \u00a9 2026 Jonathan D.A. Jewell (hyperpolymath) . SPDX-License-Identifier: MPL-2.0", + "examples": [ + { + "program": "faithful-record.haec", + "ir": "faithful-record.ir.json", + "expect": "p-sufficient", + "witness": null + }, + { + "program": "survey-collapse.haec", + "ir": "survey-collapse.ir.json", + "expect": "p-insufficient", + "witness": [ + "e_collapse", + "fate.quality" + ] + }, + { + "program": "station-average.haec", + "ir": "station-average.ir.json", + "expect": "p-sufficient", + "witness": null + } + ] +} diff --git a/examples/faithful-record.haec b/examples/faithful-record.haec new file mode 100644 index 0000000..5efe142 --- /dev/null +++ b/examples/faithful-record.haec @@ -0,0 +1,15 @@ +-- SPDX-FileCopyrightText: © 2026 Jonathan D.A. Jewell (hyperpolymath) +-- SPDX-License-Identifier: MPL-2.0 +-- +-- A naturalist's lossless record of THIS duck's morning call. +-- Lowers to a single `preserve` edge (grade ε). Consumer: a bioacoustics study +-- whose floor demands the call's spectral content. Verdict: p-sufficient. + +let dawnCall : ! { fate = {quality=Present, bearer=Present, context=Present, record=Present}, + bond = Intact, merge = Single } = + preserve (trope { + quality = "hoarse-quack-spectrogram", + bearer = "ring#A2173", + context = "Mill-Pond 2026-06-22 drizzle", + record = "lossless-wav+provenance" + }) diff --git a/examples/faithful-record.ir.json b/examples/faithful-record.ir.json new file mode 100644 index 0000000..606590b --- /dev/null +++ b/examples/faithful-record.ir.json @@ -0,0 +1,72 @@ +{ + "$schema": "https://github.com/hyperpolymath/trope-checker/schemas/trope-ir.schema.json", + "$comment": "SPDX-FileCopyrightText: © 2026 Jonathan D.A. Jewell (hyperpolymath) . SPDX-License-Identifier: MPL-2.0", + "version": "0.1", + "profile": "prevent", + "nodes": [ + { + "id": "dawnCall.in", + "type": "Trope", + "present": [ + "quality", + "bearer", + "context", + "record" + ] + }, + { + "id": "dawnCall", + "type": "Trope", + "present": [ + "quality", + "bearer", + "context", + "record" + ] + } + ], + "edges": [ + { + "id": "e_preserve", + "effect": "preserve", + "inputs": [ + "dawnCall.in" + ], + "output": "dawnCall", + "grade": { + "fate": { + "quality": { + "k": "Present" + }, + "bearer": { + "k": "Present" + }, + "context": { + "k": "Present" + }, + "record": { + "k": "Present" + } + }, + "bond": { + "k": "Intact" + }, + "merge": { + "k": "Single" + } + }, + "note": "preserve (ε)" + } + ], + "use_model": { + "output": "dawnCall", + "floor": { + "fate": { + "quality": { + "k": "Attenuated", + "delta": 3 + } + } + } + } +} diff --git a/examples/station-average.haec b/examples/station-average.haec new file mode 100644 index 0000000..7ee275d --- /dev/null +++ b/examples/station-average.haec @@ -0,0 +1,12 @@ +-- SPDX-FileCopyrightText: © 2026 Jonathan D.A. Jewell (hyperpolymath) +-- SPDX-License-Identifier: MPL-2.0 +-- +-- A weather page shows the regional figure as the labelled mean of two stations. +-- `fuse[tag]` requires the provenance tag (an untagged merge does not parse). +-- A consumer that accepts a labelled merge: p-sufficient. + +let regional : ! { fate = {quality=Present, bearer=Present, context=Present, record=Present}, + bond = Intact, merge = Fused("mean-of-2-stations") } = + fuse["mean-of-2-stations"] + (trope { quality = "12.4C", bearer = "station-EGLL", context = "12:00Z", record = "METAR" }) + (trope { quality = "11.9C", bearer = "station-EGLC", context = "12:00Z", record = "METAR" }) diff --git a/examples/station-average.ir.json b/examples/station-average.ir.json new file mode 100644 index 0000000..a17ee4b --- /dev/null +++ b/examples/station-average.ir.json @@ -0,0 +1,82 @@ +{ + "$schema": "https://github.com/hyperpolymath/trope-checker/schemas/trope-ir.schema.json", + "$comment": "SPDX-FileCopyrightText: © 2026 Jonathan D.A. Jewell (hyperpolymath) . SPDX-License-Identifier: MPL-2.0", + "version": "0.1", + "profile": "prevent", + "nodes": [ + { + "id": "s1", + "type": "Trope", + "present": [ + "quality", + "bearer", + "context", + "record" + ] + }, + { + "id": "s2", + "type": "Trope", + "present": [ + "quality", + "bearer", + "context", + "record" + ] + }, + { + "id": "regional", + "type": "Trope", + "present": [ + "quality", + "bearer", + "context", + "record" + ] + } + ], + "edges": [ + { + "id": "e_fuse", + "effect": "fuse", + "inputs": [ + "s1", + "s2" + ], + "output": "regional", + "grade": { + "fate": { + "quality": { + "k": "Present" + }, + "bearer": { + "k": "Present" + }, + "context": { + "k": "Present" + }, + "record": { + "k": "Present" + } + }, + "bond": { + "k": "Intact" + }, + "merge": { + "k": "Fused", + "tau": "mean-of-2-stations" + } + }, + "note": "fuse[mean-of-2-stations]" + } + ], + "use_model": { + "output": "regional", + "floor": { + "merge": { + "k": "Fused", + "tau": "any" + } + } + } +} diff --git a/examples/survey-collapse.haec b/examples/survey-collapse.haec new file mode 100644 index 0000000..cf82bb3 --- /dev/null +++ b/examples/survey-collapse.haec @@ -0,0 +1,16 @@ +-- SPDX-FileCopyrightText: © 2026 Jonathan D.A. Jewell (hyperpolymath) +-- SPDX-License-Identifier: MPL-2.0 +-- +-- A bird survey logs the same call as one column: heard a quack? -> yes. +-- `collapse[isQuack]` = predicate[quality,isQuack] then drop the rest. +-- Against a floor demanding spectral content, the checkbox is not enough. +-- Verdict: p-insufficient; witness: the collapse edge. + +let surveyCell : ! { fate = {quality=Predicated, bearer=Dropped, context=Dropped, record=Dropped}, + bond = Withheld, merge = Single } = + collapse[isQuack] (trope { + quality = "hoarse-quack-spectrogram", + bearer = "ring#A2173", + context = "Mill-Pond 2026-06-22 drizzle", + record = "lossless-wav+provenance" + }) diff --git a/examples/survey-collapse.ir.json b/examples/survey-collapse.ir.json new file mode 100644 index 0000000..dbec03c --- /dev/null +++ b/examples/survey-collapse.ir.json @@ -0,0 +1,68 @@ +{ + "$schema": "https://github.com/hyperpolymath/trope-checker/schemas/trope-ir.schema.json", + "$comment": "SPDX-FileCopyrightText: © 2026 Jonathan D.A. Jewell (hyperpolymath) . SPDX-License-Identifier: MPL-2.0", + "version": "0.1", + "profile": "prevent", + "nodes": [ + { + "id": "call.in", + "type": "Trope", + "present": [ + "quality", + "bearer", + "context", + "record" + ] + }, + { + "id": "surveyCell", + "type": "Codomain", + "codomain": "Bool" + } + ], + "edges": [ + { + "id": "e_collapse", + "effect": "collapse", + "inputs": [ + "call.in" + ], + "output": "surveyCell", + "grade": { + "fate": { + "quality": { + "k": "Predicated", + "predicate": "isQuack" + }, + "bearer": { + "k": "Dropped" + }, + "context": { + "k": "Dropped" + }, + "record": { + "k": "Dropped" + } + }, + "bond": { + "k": "Withheld" + }, + "merge": { + "k": "Single" + } + }, + "note": "collapse[isQuack]" + } + ], + "use_model": { + "output": "surveyCell", + "floor": { + "fate": { + "quality": { + "k": "Attenuated", + "delta": 3 + } + } + } + } +} diff --git a/examples/web-project-deno.json b/examples/web-project-deno.json index 028e4f1..5ddd3bd 100644 --- a/examples/web-project-deno.json +++ b/examples/web-project-deno.json @@ -10,7 +10,7 @@ "imports": { "rescript": "^12.0.0", "@rescript/core": "npm:@rescript/core@^1.6.0", - "safe-dom/": "https://raw.githubusercontent.com/{{OWNER}}/rescript-dom-mounter/main/src/", + "safe-dom/": "https://raw.githubusercontent.com/hyperpolymath/rescript-dom-mounter/main/src/", "proven/": "../proven/bindings/rescript/src/" }, "compilerOptions": { diff --git a/tests/aspect_tests.sh b/tests/aspect_tests.sh index 028b2c0..69d206b 100755 --- a/tests/aspect_tests.sh +++ b/tests/aspect_tests.sh @@ -39,7 +39,7 @@ fail() { red " FAIL: $1"; FAIL=$((FAIL + 1)); } warn() { yellow " WARN: $1"; WARN=$((WARN + 1)); } echo "═══════════════════════════════════════════════════════════════" -echo " {{PROJECT}} — Aspect Tests (Cross-Cutting Concerns)" +echo " HAEC — Aspect Tests (Cross-Cutting Concerns)" echo "═══════════════════════════════════════════════════════════════" echo "" diff --git a/tests/check-examples.py b/tests/check-examples.py new file mode 100644 index 0000000..b1059f7 --- /dev/null +++ b/tests/check-examples.py @@ -0,0 +1,52 @@ +#!/usr/bin/env python3 +# SPDX-FileCopyrightText: © 2026 Jonathan D.A. Jewell (hyperpolymath) +# SPDX-License-Identifier: MPL-2.0 +"""Validate that every Haec example lowers to a well-formed Trope IR document. + +Self-contained: validates examples/*.ir.json against the vendored IR contract +(design/trope-ir.schema.json — canonical in trope-checker). The full round-trip +(verdicts via the checker) is a cross-repo integration; run it with a checkout of +the sibling trope-checker (see README). This keeps `just check` green standalone. +""" +from __future__ import annotations +import json, pathlib, sys + +try: + from jsonschema import Draft202012Validator +except ImportError: + sys.exit("error: python 'jsonschema' package is required") + +ROOT = pathlib.Path(__file__).resolve().parent.parent +SCHEMA = ROOT / "design" / "trope-ir.schema.json" +EX = ROOT / "examples" +GREEN, RED, OFF = "\033[32m", "\033[31m", "\033[0m" + + +def main() -> int: + v = Draft202012Validator(json.loads(SCHEMA.read_text(encoding="utf-8"))) + manifest = json.loads((EX / "EXAMPLES.json").read_text(encoding="utf-8")) + by_ir = {e["ir"]: e for e in manifest["examples"]} + failures = 0 + for path in sorted(EX.glob("*.ir.json")): + doc = json.loads(path.read_text(encoding="utf-8")) + errs = sorted(v.iter_errors(doc), key=lambda e: list(e.absolute_path)) + if errs: + failures += 1 + print(f"{RED}FAIL{OFF} {path.name}: {errs[0].message} at " + f"{'/'.join(str(p) for p in errs[0].absolute_path)}") + elif path.name not in by_ir: + failures += 1 + print(f"{RED}FAIL{OFF} {path.name}: not listed in EXAMPLES.json") + else: + prog = by_ir[path.name]["program"] + if not (EX / prog).exists(): + failures += 1 + print(f"{RED}FAIL{OFF} {path.name}: program {prog} missing") + else: + print(f"{GREEN}ok{OFF} {prog} → {path.name} (valid IR, expects {by_ir[path.name]['expect']})") + print(f"\n{(GREEN+'examples: all lower to valid Trope IR') if not failures else (RED+f'examples: {failures} failure(s)')}{OFF}") + return 1 if failures else 0 + + +if __name__ == "__main__": + raise SystemExit(main()) diff --git a/tests/e2e.sh b/tests/e2e.sh index 11143fc..764a1dc 100755 --- a/tests/e2e.sh +++ b/tests/e2e.sh @@ -62,7 +62,7 @@ skip_test() { } echo "═══════════════════════════════════════════════════════════════" -echo " {{PROJECT}} — End-to-End Tests" +echo " HAEC — End-to-End Tests" echo "═══════════════════════════════════════════════════════════════" echo "" @@ -122,7 +122,7 @@ echo "" # else # STATUS=$(curl -s -o /dev/null -w "%{http_code}" -X POST "$VERISIM_URL/api/v1/hexads" \ # -H "Content-Type: application/json" \ -# -d '{"tool":"{{PROJECT}}","modality":"document","content":"e2e test"}') +# -d '{"tool":"HAEC","modality":"document","content":"e2e test"}') # check_status "hexad POST" "201" "$STATUS" # fi diff --git a/tests/e2e/template_instantiation_test.sh b/tests/e2e/template_instantiation_test.sh index f991d5d..2333b90 100755 --- a/tests/e2e/template_instantiation_test.sh +++ b/tests/e2e/template_instantiation_test.sh @@ -119,16 +119,16 @@ find "$TEST_REPO_PATH" -type f \ -exec bash -c ' file="$1" placeholder_pairs=( - "{{REPO}}|$TEST_REPO_NAME" - "{{OWNER}}|$TEST_OWNER" - "{{FORGE}}|$TEST_FORGE" - "{{PROJECT}}|$TEST_PROJECT_NAME" - "{{project}}|'"${TEST_REPO_NAME//-/_}"'" + "haec|$TEST_REPO_NAME" + "hyperpolymath|$TEST_OWNER" + "github.com|$TEST_FORGE" + "HAEC|$TEST_PROJECT_NAME" + "haec|'"${TEST_REPO_NAME//-/_}"'" "{{REPO_DESCRIPTION}}|$TEST_DESCRIPTION" "{{PRIMARY_LANGUAGE}}|$TEST_PRIMARY_LANGUAGE" - "{{AUTHOR}}|$TEST_AUTHOR" - "{{AUTHOR_EMAIL}}|$TEST_AUTHOR_EMAIL" - "{{CURRENT_DATE}}|2026-04-04" + "Jonathan D.A. Jewell|$TEST_AUTHOR" + "j.d.a.jewell@open.ac.uk|$TEST_AUTHOR_EMAIL" + "2026-06-22|2026-04-04" ) for pair in "${placeholder_pairs[@]}"; do From 7c4f82c731c09fbbe004ed34446f35c79310419e Mon Sep 17 00:00:00 2001 From: hyperpolymath <6759885+hyperpolymath@users.noreply.github.com> Date: Mon, 22 Jun 2026 09:52:12 +0100 Subject: [PATCH 3/4] docs: README/EXPLAINME/AUDIT/AFFIRMATION/ADR + compiler|lsp STATUS + CI Haec as one IR-producing front-end (not the checker, not the vocabulary); honest design-pass snapshot; compiler/ and lsp/ scaffolded as named future work. --- .github/workflows/trope-check.yml | 31 +++ AFFIRMATION.adoc | 32 +++ AUDIT.adoc | 60 ++---- EXPLAINME.adoc | 117 ++++------- README.adoc | 188 +++++++++++------- compiler/STATUS.adoc | 22 ++ docs/QUICKSTART.adoc | 2 +- docs/architecture/THREAT-MODEL.adoc | 12 +- docs/attribution/CITATION.cff | 12 +- docs/attribution/CITATIONS.adoc | 20 +- docs/attribution/MAINTAINERS.adoc | 4 +- docs/decisions/0000-template.adoc | 2 +- docs/decisions/0001-adopt-rsr-standard.adoc | 4 +- docs/decisions/0002-haec-build.adoc | 30 +++ docs/developer/ABI-FFI-README.adoc | 56 +++--- docs/governance/CRG-AUDIT-TEMPLATE.adoc | 20 +- docs/governance/TEMPLATE-STANDARDS-AUDIT.adoc | 2 +- docs/practice/AI-CONVENTIONS.adoc | 8 +- docs/practice/STATE-VISUALIZER-GUIDE.adoc | 4 +- docs/status/PROOF-NEEDS.adoc | 2 +- docs/status/PROOF-STATUS.adoc | 2 +- docs/status/READINESS.adoc | 20 +- docs/status/TEST-NEEDS.adoc | 2 +- docs/trope-estate-architecture.svg | 70 +++++++ lsp/STATUS.adoc | 12 ++ 25 files changed, 455 insertions(+), 279 deletions(-) create mode 100644 .github/workflows/trope-check.yml create mode 100644 AFFIRMATION.adoc create mode 100644 compiler/STATUS.adoc create mode 100644 docs/decisions/0002-haec-build.adoc create mode 100755 docs/trope-estate-architecture.svg create mode 100644 lsp/STATUS.adoc diff --git a/.github/workflows/trope-check.yml b/.github/workflows/trope-check.yml new file mode 100644 index 0000000..7ea78f5 --- /dev/null +++ b/.github/workflows/trope-check.yml @@ -0,0 +1,31 @@ +# SPDX-License-Identifier: MPL-2.0 +# Copyright (c) 2026 Jonathan D.A. Jewell (hyperpolymath) +# +# Haec: validate that every example lowers to a well-formed Trope IR document. +name: trope-check + +on: + push: + paths: + - 'design/**' + - 'examples/**' + - 'tests/**' + - '.github/workflows/trope-check.yml' + pull_request: + workflow_dispatch: + +permissions: + contents: read + +jobs: + examples-lower-to-valid-ir: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 + with: + python-version: '3.12' + - name: Install jsonschema + run: python -m pip install --upgrade jsonschema + - name: Examples lower to valid Trope IR + run: python3 tests/check-examples.py diff --git a/AFFIRMATION.adoc b/AFFIRMATION.adoc new file mode 100644 index 0000000..8d9e126 --- /dev/null +++ b/AFFIRMATION.adoc @@ -0,0 +1,32 @@ +// SPDX-FileCopyrightText: © 2026 Jonathan D.A. Jewell (hyperpolymath) +// SPDX-License-Identifier: MPL-2.0 +// SPDX-License-Identifier: CC-BY-SA-4.0 += AFFIRMATION — Haec +:revdate: 2026-06-22 + +A dated, ground-truthed honesty snapshot. This is the brief's "STATUS" for Haec: +what exists, what is verified, what is deferred — stated plainly, no overclaim. + +== As of 2026-06-22 + +*What exists (design pass):* the surface grammar (`design/grammar.ebnf`), the +elaboration table with a per-construct lowering-correctness (O2) obligation +(`design/elaboration.adoc`), and `examples/` pairing small programs with their +lowered Trope IR. + +*Ground truth:* every `examples/*.ir.json` is schema-valid against the IR contract +and round-trips through the sibling trope-checker to the verdict the example states +(faithful record → `p-sufficient`; survey collapse → `p-insufficient`, witness = +the collapse edge; labelled aggregate fuse → `p-sufficient`). `just check` +validates this standalone against the vendored schema. + +*What does NOT exist yet (deferred, named):* the compiler (parser, type-checker, +elaborator, codegen — `compiler/STATUS.adoc`), the LSP (`lsp/STATUS.adoc`), and a +runtime. The O2 lowering-correctness *proofs* are stated as obligations, not yet +discharged (HC-5: stated, not asserted-as-done). + +*Honest scope:* Haec is one front-end among many; it defines neither the checker +nor the vocabulary. Its sole present claim is that its elaboration targets the IR +and its examples lower to IR the checker accepts. + +— Authored by the build agent under owner direction; signed in git history. diff --git a/AUDIT.adoc b/AUDIT.adoc index 0f4f5ac..127708f 100644 --- a/AUDIT.adoc +++ b/AUDIT.adoc @@ -1,48 +1,24 @@ +// SPDX-FileCopyrightText: © 2026 Jonathan D.A. Jewell (hyperpolymath) // SPDX-License-Identifier: MPL-2.0 -// Copyright (c) Jonathan D.A. Jewell -= Audit Gate -Codex -v1.1, 2026-04-07 -:toc: -:toclevels: 2 -:sectnums: +// SPDX-License-Identifier: CC-BY-SA-4.0 += AUDIT — Haec release gate +:revdate: 2026-06-22 -== Purpose +The release-audit gate. Ground-truth by running the tools. -This root document exists so humans and bots can see the hard audit posture -without having to discover the standards repository first. +[cols="1,2,1",options="header"] +|=== +| Check | Command | State 2026-06-22 +| Examples lower to valid IR | `just check` (`python3 tests/check-examples.py`) | PASS (3/3) +| Round-trip through the checker | `just haec-roundtrip` (needs sibling trope-checker) | PASS (verdicts + witness match) +| Design artefacts present | grammar.ebnf, elaboration.adoc | PASS +|=== -Canonical source documents live in the `standards` repository. This file is a -repo-local audit gate summary for template users and automated agents. +== Out of scope for this gate (deferred, named) -== Hard Rules +* The compiler (`compiler/STATUS.adoc`), the LSP (`lsp/STATUS.adoc`), the runtime. +* O2 lowering-correctness *proofs* (obligations stated, not yet discharged). +* Inherited RSR-template machinery (`just validate`, the estate CI set) — template + state, not Haec's gate. -* Do not call anything `stable`, `v1.0.0`, or full release unless the stable - release gate has been passed end to end. -* Do not publish implementation-facing work below `B` in CRG unless the work is - genuinely abstract and makes no implementation-readiness claim. -* `D` requires RSR compliance or a documented equivalent repository discipline. -* `C` requires deep code and folder annotation, not just local confidence. -* `B` means `beta-stable`: external breadth and safe broad trial, not merely - public visibility. -* Papers, whitepapers, release notes, and READMEs must not outrun the proofs, - tests, or artefacts that support their claims. -* Release paths must not ship with placeholders, stubs, `FIXME`, `XXX`, - template residue, fake fuzz, fake benches, or partial proof debt hidden as - if it were complete. - -== Canonical Standards - -Read these as the authoritative source: - -* `standards/component-readiness-grades/COMPONENT-READINESS-GRADES.md` -* `standards/release-pre-flight/V1-GATE.adoc` -* `standards/publication-pre-flight/PREFLIGHT.adoc` -* `standards/publication-pre-flight/ESTATE-AUDIT-BASELINE-2026-03-30.adoc` -* `standards/session-management-standards/README.adoc` - -== Bot Requirement - -Bots operating in repositories derived from this template should treat this -document as a key root audit document and should not make optimistic release or -publication claims that conflict with it. +Built into the RSR-template scaffold on `feat/trope-build`; commits signed. diff --git a/EXPLAINME.adoc b/EXPLAINME.adoc index dee9b62..841aa72 100644 --- a/EXPLAINME.adoc +++ b/EXPLAINME.adoc @@ -1,94 +1,49 @@ +// SPDX-FileCopyrightText: © 2026 Jonathan D.A. Jewell (hyperpolymath) // SPDX-License-Identifier: MPL-2.0 -// Copyright (c) Jonathan D.A. Jewell -= RSR Template Repo - Explainme -image:https://img.shields.io/badge/License-MPL_2.0-blue.svg[License: MPL-2.0,link="https://opensource.org/licenses/MPL-2.0"] +// SPDX-License-Identifier: CC-BY-SA-4.0 += EXPLAINME — Haec (developer deep-dive) +:toc: macro -:toc: -:icons: font +The README is the pitch; this is the shape of the language and why. -This file explains how the key template claims map to real files. +== The split that defines Haec -== Central Session Protocol Authority +Haec writes and type-checks programs and *emits Trope IR*. It does not decide +acceptability and it does not define the vocabulary. Turing-completeness lives in +Haec's terms; decidability lives in the checker's grade algebra; they never meet. +This separation is the whole point — the trust guarantee must be about the IR, not +about Haec. -Claim: -Session protocols are centrally maintained and not duplicated in this template. +== Two artefacts, in order -How this is implemented: +. `design/grammar.ebnf` — a small surface: term formers, `fix`, the five atomic + effects (`attenuate`, `predicate`, `drop`, `sever`, `fuse`) and the sugar + (`preserve`, `project`, `collapse`, `detach`). +. `design/elaboration.adoc` — each construct → a Trope IR edge with its grade, and + each construct's *lowering-correctness obligation* (calculus O2). The sugar + expands per the calculus (`collapse = predicate ▷ drops`; `detach = drops ▷ sever`). -* The local dispatcher (`session/dispatch.sh`) maps canonical commands to central - protocol paths in `standards/session-management-standards`. -* Local files (`session/custom-checks.k9`, `session/local-hooks.sh`, - `coordination.k9`) are integration-only. +`examples/` is the executable check on the design: each `.haec` is paired with the +`.ir.json` it lowers to, and that IR round-trips through the checker. -Caveat: +== Bidirectional checking -* If `SESSION_STANDARDS_DIR` is unset and no adjacent standards checkout exists, - the dispatcher records the command but cannot resolve central checklist paths. +Grades are *checked* against declared loss-signatures at every recursive (`fix`) +and effectful boundary, and *inferred* through the straight-line fragment. An +unbounded lossy recursion has fidelity grade `top` — the honest "unknown" — which +any demanding use-model rejects. The author writes the signature; Haec checks it. -== Canonical Command Surface +== Why no compiler yet -Claim: -Template bindings align to one canonical command model. +This is a design pass (HC-5: small verified increments, no fluent code outrunning +its proofs). The grammar + elaboration + round-tripping examples pin the language's +*meaning* before a parser/codegen exists. `compiler/` and `lsp/` are scaffolded +with `STATUS.adoc` as named future work; the runtime needs only a Turing-complete +target and is otherwise unconstrained at this stage. -How this is implemented: +== The deceptive trio is unwritable -* `Justfile` provides thin aliases (`intake-repo`, `checkpoint-change`, - `verify-maintenance`, `verify-substantial`, `verify-release`, `close-planned`, - `close-urgent`, `recover-repo`, `handover-*`). -* Every alias calls `session/dispatch.sh` with canonical verb-object pairs. - -Caveat: - -* Recipes are wrappers only. They do not replace protocol content from - the central standards repo. - -== Runtime State Is Local - -Claim: -Session state is per-repository runtime output, not standards text. - -How this is implemented: - -* `session/dispatch.sh` writes command and continuity-core capture stubs to - `.session/LAST-CANONICAL-COMMAND.md` in the target repository path. - -Caveat: - -* Runtime files are intentionally lightweight and require human/agent completion. - -== Template Token Policy - -Claim: -Placeholders are explicit template content until initialization. - -How this is implemented: - -* `README.adoc` and bootstrap recipes keep `{{TOKEN}}` placeholders visible. -* `just init` performs token replacement. - -Caveat: - -* Uninitialized placeholders must not be treated as project-specific truth. - -== Julia Registry Packages — Standalone Repo Requirement - -Claim: -If this template is used to create a Julia package, it must remain a standalone repository registered with the Julia package registry. - -How this is implemented: - -* Julia's package registry (General.jl or other) expects each package to be a standalone GitHub repository with `Project.toml` at the repository root. -* Installation via `Pkg.add()`, dependency resolution, and automated CI/CD all depend on this canonical structure. - -Caveat: - -* Do NOT move this repository into a monorepo or subdirectory, as this breaks registry registration and package discoverability. -* See `JULIA-REGISTRY-REQUIREMENT.md` (workspace root) for the complete list of 34 registered Julia packages and enforcement rationale. -* Non-registry Julia packages can be organized differently if they are not published to any registry. - - -== License - -This project is licensed under the Mozilla Public License, v. 2.0. See the `LICENSE` file for details. - -SPDX-License-Identifier: MPL-2.0 +There is no surface syntax for value-falsification, mis-binding, or untagged merge +(HC-3). `fuse` requires a tag. A buggy lowering that emitted a deceptive grade would +produce malformed IR that the checker rejects at validation — the conflation +detector at Haec's lowering boundary. diff --git a/README.adoc b/README.adoc index 6eb4a5e..546a3c8 100644 --- a/README.adoc +++ b/README.adoc @@ -1,91 +1,139 @@ +// SPDX-FileCopyrightText: © 2026 Jonathan D.A. Jewell (hyperpolymath) // SPDX-License-Identifier: MPL-2.0 -// Copyright (c) Jonathan D.A. Jewell -// SPDX-FileCopyrightText: 2024-2026 Jonathan D.A. Jewell (hyperpolymath) -= {{PROJECT_NAME}} -:toc: +// SPDX-License-Identifier: CC-BY-SA-4.0 += Haec +:revnumber: 0.1 (design) +:revdate: 2026-06-22 +:toc: macro :toc-placement: preamble -image:https://img.shields.io/badge/OpenSSF-Best_Practices-green?logo=opensourcesecurity[OpenSSF Best Practices,link="https://www.bestpractices.dev/en/projects/new?repo_url=https://{{FORGE}}/{{OWNER}}/{{REPO}}"] image:https://img.shields.io/badge/License-MPL_2.0-blue.svg[License: MPL-2.0,link="https://opensource.org/licenses/MPL-2.0"] -image:https://api.thegreenwebfoundation.org/greencheckimage/{{FORGE}}[Green Web,link="https://www.thegreenwebfoundation.org/green-web-check/?url={{FORGE}}"] - -{{PROJECT_DESCRIPTION}} +image:https://img.shields.io/badge/status-design-orange[Status: design] + +[.lead] +A Turing-complete language whose type discipline is *trope-particularity*. + +NOTE: Working name. The project is the *language*, not the checker and not the +vocabulary; *Haec* (from _haecceity_, "thisness") is a placeholder — rename freely. + +[quote] +Duck typing asks whether it quacks. A trope language lets you write the program +that decides which quack to keep — and the checker tells you, against each +consumer's declared use, whether the quack you kept was enough. + +toc::[] + +== What Haec is + +Haec is a general-purpose, Turing-complete language (it has general recursion) in +which every operation over a *property-instance* — a quality as borne by this +entity, in this context, under these conditions — carries a *loss-shape grade*. +The grade records what the operation did to the instance's individuating content: +how much was retained, whether the quality–bearer bond held, whether plurality was +merged, and whether what is presented is true. + +Haec does not decide whether a flow is acceptable. It *produces* a record of +graded effects — the *Trope IR* — and the (language-independent) *tropechecker* +consumes that IR and returns a verdict against each consumer's declared +use-model. Turing-completeness lives in Haec's terms; decidability lives in the +checker's grade algebra. The two never meet: the checker never executes a Haec +program, so Rice's theorem is no obstacle — an unbounded lossy loop simply gets an +honest "unknown" (`top`) grade, which any demanding use rejects. + +== What Haec is not + +* *Not the tropechecker.* The checker is a separate, portable artefact + (`github.com/hyperpolymath/trope-checker`). Haec is *one* producer of its input + among potentially many — a static analyser for another language could emit the + same IR. Keeping the checker out of this repository is deliberate: its guarantee + must be a guarantee about the IR, not "the Haec checker." +* *Not the vocabulary.* The named effects, the residual, and the verdict are + defined in the Particularity workbench + (`github.com/hyperpolymath/trope-particularity-workbench`). Haec *implements* + those terms; it does not define them. +* *Not "trope safety" as a rival to type safety.* Haec adds a diagnostic layer + *over* ordinary typing, not a replacement for it. + +== Where it sits — the three-repo picture + +[%hardbreaks] +*Haec (this repo)* — writes & type-checks programs; *emits* Trope IR. + │ emits + ▼ +*Trope IR* — a graded-effect DAG (the wire format / trust boundary). + │ consumed by + ▼ +*trope-checker* — composes grades, checks each consumer's use-model, returns a + verdict (`p-sufficient` / `p-insufficient`) with a witness edge. + +Both Haec and the checker *realise* the *Particularity* vocabulary; the *formal +calculus* (grade algebra, IR semantics, soundness) is normative in +`trope-checker/spec/calculus.adoc`, which this repository references rather than +restates. See `docs/trope-estate-architecture.svg`. + +== The type discipline (summary; the normative spec lives with the checker) + +The judgement is `Γ ⊢ e : A ! g` — _e_ produces an _A_ with loss-shape grade _g_. +The grade is a dependent record over a *recoverability × veridicality* space; the +bond coordinate fibres over whether the bearer survives, so incoherent states +(bearer present yet bond severed) are not representable. The honest fragment is +generated by *five atomic moves* — `attenuate`, `predicate`, `drop`, `sever`, +`fuse` — and the familiar surface effects (`preserve`, `project`, `collapse`, +`detach`) are sugar over them; the deceptive fragment has exactly three values, and +none is writable in source (an untagged merge, a value-substitution, or a +mis-attribution is a *lowering fault*, not a program). General recursion takes the +least-fixed-point grade, with an *unknown* (`top`) grade as the honest answer for +unbounded loss. Checking is *bidirectional*: declared loss-signatures at recursive +and effectful boundaries, inference through the straight-line fragment. + +Haec's own job is the part the calculus leaves to a front-end: a surface syntax +(`design/grammar.ebnf`), and an *elaboration* (`design/elaboration.adoc`) that +lowers each construct to a Trope IR effect edge. [IMPORTANT] +.Haec's burden: lowering correctness (calculus O2) ==== -*This file is a template.* You are reading `README.adoc` from the *RSR template repo* -(or a freshly-cloned copy of it). Run `just init` to replace every `{{PLACEHOLDER}}` -token with your project's details, then delete this admonition. Until you do, the -`{{...}}` markers below are intentional placeholders, not content. +The checker's soundness is *relative to faithful lowering*. It cannot verify that a +Haec construct claimed to be (say) a `collapse` really is one, nor that a value +Haec marks faithful is not in fact falsified — that needs ground truth the checker +does not have. *Proving each construct's lowering faithful is Haec's obligation*, +discharged per construct (`design/elaboration.adoc`) — not something the checker +provides. ==== -== What this is - -A new repository scaffolded from the *Rhodium Standard Repository (RSR)* template: -a batteries-included starting point that ships with CI/CD, machine-readable project -metadata, an AI-agent gatekeeper protocol, a formally-typed ABI/FFI seam -(Idris2 + Zig), container and reproducible-build scaffolding, and governance -infrastructure — all wired and passing the RSR validators on day one. - -Replace this section with a description of *your* project once initialised. - -== Quick start - -[source,bash] ----- -# 1. Create a repo from this template (or clone it), then from the repo root: -just init # interactive bootstrap: fills every {{PLACEHOLDER}} - -# 2. See the available tasks: -just # lists all phases (build, test, validate, audit, ...) - -# 3. Check the repo still satisfies the RSR shape: -just validate # structure + metadata checks ----- +== Status -`just init` prompts for the project name, owner, author, licence contact, and the -other values listed in `.machine_readable/ai/PLACEHOLDERS.adoc`, substitutes them -across the tree, validates the result, and (if available) runs the `k9-svc` checks. - -== What you get - -* *Machine-readable metadata* (`.machine_readable/6a2/`) — `STATE`, `META`, - `ECOSYSTEM`, `PLAYBOOK`, `AGENTIC`, `NEUROSYM`, `CLADE`, and `anchors/ANCHOR`, - in a2ml, so tools and agents can read the project's state and boundaries. -* *AI gatekeeper protocol* — `0-AI-MANIFEST.a2ml` is the universal entry point that - tells an AI agent how to work in this repo before it touches anything. -* *Typed ABI/FFI seam* — `src/interface/Abi/` (Idris2 type + layout proofs) over - `src/interface/ffi/` (Zig implementation), with generated C headers. -* *CI/CD* — GitHub Actions for quality, security (CodeQL, Scorecard, secret - scanning), multi-forge mirroring, and RSR anti-pattern enforcement. -* *Supply-chain & reproducibility* — container layering (stapeln), Nix/Guix shells, - SBOM, and signing hooks. -* *Governance* — `GOVERNANCE.adoc`, `MAINTAINERS.adoc`, `.github/` community health - files, and a release `AUDIT.adoc` gate. +Design. The surface syntax and the elaboration table are the first artefacts; +`examples/` pairs small programs with the IR they lower to, and each lowered IR +round-trips through the trope-checker (schema-valid, expected verdict). There is no +compiler yet — `compiler/` and `lsp/` are named future work (`STATUS.adoc`). == Repository map -[cols="1,3"] +[cols="1,3",options="header"] |=== | Path | What lives there - -| `0-AI-MANIFEST.a2ml` | Universal entry point for AI agents (read first). -| `.machine_readable/` | Project metadata, policies, contractiles, AI configs. -| `src/interface/` | Typed ABI (Idris2) + FFI (Zig) + generated headers. -| `docs/` | Onboarding, status, governance, practice, decisions. -| `build/`, `Justfile` | Task orchestration (`just` phases delegate to `build/just/*.just`). -| `.github/` | Workflows + community health files. -| `tests/`, `benches/` | Test suites and benchmarks. +| `README.adoc` | This file. +| `design/grammar.ebnf` | The surface grammar. +| `design/elaboration.adoc` | The elaboration-to-IR table (+ per-construct O2 obligations). +| `design/trope-ir.schema.json` | Vendored copy of the IR contract Haec targets (canonical in trope-checker). +| `examples/` | Small programs (`*.haec`) paired with the IR they lower to (`*.ir.json`). +| `docs/trope-estate-architecture.svg` | The three-repo dependency picture. +| `compiler/` | (planned) Parser, type-checker, elaborator, codegen — see `STATUS.adoc`. +| `lsp/` | (planned) Editor support — see `STATUS.adoc`. |=== -== Where to go next +== Run the checks -* `EXPLAINME.adoc` — the engineering deep-dive: how the pieces actually work. -* `AFFIRMATION.adoc` — the dated, signed honesty snapshot of the repo's true state. -* `AUDIT.adoc` — the release audit gate. -* `.machine_readable/ai/PLACEHOLDERS.adoc` — the full placeholder reference. +[source,sh] +---- +just check # validate examples/*.ir.json against the vendored IR schema +# full round-trip (verdicts) needs a checkout of the sibling trope-checker: +python3 ../trope-checker/src/checker/tropecheck.py examples/survey-collapse.ir.json +---- == Licence -Released under the link:LICENSE[Mozilla Public License 2.0] unless a per-file -`SPDX-License-Identifier` says otherwise. +Code, config, and the vendored schema: Mozilla Public License 2.0. Prose +documentation: CC-BY-SA-4.0. Per-file `SPDX-License-Identifier` headers are +authoritative; the single GitHub badge is MPL-2.0 from the root `LICENSE`. diff --git a/compiler/STATUS.adoc b/compiler/STATUS.adoc new file mode 100644 index 0000000..65dd182 --- /dev/null +++ b/compiler/STATUS.adoc @@ -0,0 +1,22 @@ +// SPDX-FileCopyrightText: © 2026 Jonathan D.A. Jewell (hyperpolymath) +// SPDX-License-Identifier: MPL-2.0 +// SPDX-License-Identifier: CC-BY-SA-4.0 += compiler/ — STATUS (named future work) +:revdate: 2026-06-22 + +*Not built.* This directory is scaffolded for the Haec compiler. Per the build +brief, the compiler/codegen/runtime are explicitly *beyond* the current handover. + +Planned stages (in dependency order): + +. *Parser* — surface syntax per `../design/grammar.ebnf`. +. *Type-checker* — bidirectional; checks grades against declared loss-signatures at + recursive/effectful boundaries, infers through the straight-line fragment + (calculus §7). +. *Elaborator* — lowers each construct to a Trope IR edge per + `../design/elaboration.adoc`, emitting a `*.ir.json` the checker consumes. This is + where each construct's lowering-correctness obligation (O2) must be discharged. +. *Codegen / runtime* — any Turing-complete target; unconstrained at this stage. + +Until this exists, `examples/` is hand-lowered and round-tripped through the checker +to pin the intended elaboration. diff --git a/docs/QUICKSTART.adoc b/docs/QUICKSTART.adoc index 7974257..013bf34 100644 --- a/docs/QUICKSTART.adoc +++ b/docs/QUICKSTART.adoc @@ -15,7 +15,7 @@ Get up and running in 60 seconds. [source,bash] ---- -git clone https://github.com/{{OWNER}}/rsr-template-repo my-project +git clone https://github.com/hyperpolymath/rsr-template-repo my-project cd my-project rm -rf .git && git init -b main just init # interactive placeholder replacement diff --git a/docs/architecture/THREAT-MODEL.adoc b/docs/architecture/THREAT-MODEL.adoc index 05e1f7c..98cab44 100644 --- a/docs/architecture/THREAT-MODEL.adoc +++ b/docs/architecture/THREAT-MODEL.adoc @@ -2,18 +2,18 @@ // Copyright (c) Jonathan D.A. Jewell = Threat Model - + -# Threat Model: {{PROJECT_NAME}} +# Threat Model: Haec ## Document Info | Field | Value | |---------------|--------------------------------| -| Project | {{PROJECT_NAME}} | +| Project | Haec | | Version | 1.0 | -| Last Reviewed | {{DATE}} | -| Author | {{AUTHOR}} | +| Last Reviewed | 2026-06-22 | +| Author | Jonathan D.A. Jewell | | Methodology | STRIDE | ## Scope @@ -36,7 +36,7 @@ ## System Overview -Brief description of {{PROJECT_NAME}} and its architecture. +Brief description of Haec and its architecture. > See [STATE-VISUALIZER.adoc](../STATE-VISUALIZER.adoc) for the full architecture diagram and completion dashboard. diff --git a/docs/attribution/CITATION.cff b/docs/attribution/CITATION.cff index 05d36d9..c91cd45 100644 --- a/docs/attribution/CITATION.cff +++ b/docs/attribution/CITATION.cff @@ -1,14 +1,14 @@ cff-version: 1.2.0 message: "If you use this software, please cite it as below." authors: -- family-names: "{{AUTHOR_LAST}}" - given-names: "{{AUTHOR_FIRST}}" +- family-names: "Jewell" + given-names: "Jonathan D.A." orcid: "https://orcid.org/0000-0000-0000-0000" # Placeholder -title: "{{PROJECT_NAME}}" +title: "Haec" version: 0.1.0 -date-released: {{CURRENT_DATE}} -url: "https://{{FORGE}}/{{OWNER}}/{{REPO}}" -repository-code: "https://{{FORGE}}/{{OWNER}}/{{REPO}}" +date-released: 2026-06-22 +url: "https://github.com/hyperpolymath/haec" +repository-code: "https://github.com/hyperpolymath/haec" license: MPL-2.0 keywords: - "rsr" diff --git a/docs/attribution/CITATIONS.adoc b/docs/attribution/CITATIONS.adoc index 3273e53..83b1c55 100644 --- a/docs/attribution/CITATIONS.adoc +++ b/docs/attribution/CITATIONS.adoc @@ -1,36 +1,36 @@ // SPDX-License-Identifier: MPL-2.0 // Copyright (c) Jonathan D.A. Jewell -= {{PROJECT_NAME}} - Citation Guide += Haec - Citation Guide :toc: == BibTeX [source,bibtex] ---- -@software{{{PROJECT_NAME}}_{{CURRENT_YEAR}}, - author = {{{AUTHOR_LAST}}, {{AUTHOR_FIRST}}}, - title = {{{PROJECT_NAME}}}, - year = {{{CURRENT_YEAR}}}, - url = {https://github.com/{{OWNER}}/{{PROJECT_NAME}}}, +@software{Haec_2026, + author = {Jewell, Jonathan D.A.}, + title = {Haec}, + year = {2026}, + url = {https://github.com/hyperpolymath/Haec}, license = {MPL-2.0} } ---- == Harvard Style -{{AUTHOR_LAST}}, {{AUTHOR_INITIALS}} ({{CURRENT_YEAR}}) _{{PROJECT_NAME}}_ [Computer software]. Available at: https://github.com/{{OWNER}}/{{PROJECT_NAME}} +Jewell, J. (2026) _Haec_ [Computer software]. Available at: https://github.com/hyperpolymath/Haec == OSCOLA -{{AUTHOR}}, '{{PROJECT_NAME}}' ({{CURRENT_YEAR}}) +Jonathan D.A. Jewell, 'Haec' (2026) == MLA -{{AUTHOR_LAST}}, {{AUTHOR_FIRST}} "{{PROJECT_NAME}}." {{CURRENT_YEAR}}, github.com/{{OWNER}}/{{PROJECT_NAME}}. +Jewell, Jonathan D.A. "Haec." 2026, github.com/hyperpolymath/Haec. == APA 7 -{{AUTHOR_LAST}}, {{AUTHOR_INITIALS}} ({{CURRENT_YEAR}}). _{{PROJECT_NAME}}_ [Computer software]. GitHub. https://github.com/{{OWNER}}/{{PROJECT_NAME}} +Jewell, J. (2026). _Haec_ [Computer software]. GitHub. https://github.com/hyperpolymath/Haec == See Also diff --git a/docs/attribution/MAINTAINERS.adoc b/docs/attribution/MAINTAINERS.adoc index c5a4b31..becaa3e 100644 --- a/docs/attribution/MAINTAINERS.adoc +++ b/docs/attribution/MAINTAINERS.adoc @@ -11,9 +11,9 @@ This document lists the maintainers of this project and their responsibilities. |=== | Name | Role | Contact -| {{AUTHOR}} +| Jonathan D.A. Jewell | Lead Maintainer -| https://github.com/{{OWNER}}[@{{OWNER}}] +| https://github.com/hyperpolymath[@hyperpolymath] |=== == Responsibilities diff --git a/docs/decisions/0000-template.adoc b/docs/decisions/0000-template.adoc index 07c5453..825ea4a 100644 --- a/docs/decisions/0000-template.adoc +++ b/docs/decisions/0000-template.adoc @@ -2,7 +2,7 @@ // Copyright (c) Jonathan D.A. Jewell = Architecture Decision Record: 0000-template - + # [NUMBER]. [TITLE] diff --git a/docs/decisions/0001-adopt-rsr-standard.adoc b/docs/decisions/0001-adopt-rsr-standard.adoc index 7a4fd26..7a56065 100644 --- a/docs/decisions/0001-adopt-rsr-standard.adoc +++ b/docs/decisions/0001-adopt-rsr-standard.adoc @@ -2,7 +2,7 @@ // Copyright (c) Jonathan D.A. Jewell = Architecture Decision Record: 0001-adopt-rsr-standard - + # 1. Adopt Rhodium Standard Repository (RSR) Template @@ -53,7 +53,7 @@ The RSR template provides: New repositories are created by cloning the template: ```bash -git clone https://github.com/{{OWNER}}/rsr-template-repo new-repo-name +git clone https://github.com/hyperpolymath/rsr-template-repo new-repo-name cd new-repo-name rm -rf .git && git init ``` diff --git a/docs/decisions/0002-haec-build.adoc b/docs/decisions/0002-haec-build.adoc new file mode 100644 index 0000000..68125e4 --- /dev/null +++ b/docs/decisions/0002-haec-build.adoc @@ -0,0 +1,30 @@ +// SPDX-FileCopyrightText: © 2026 Jonathan D.A. Jewell (hyperpolymath) +// SPDX-License-Identifier: MPL-2.0 +// SPDX-License-Identifier: CC-BY-SA-4.0 += ADR 0002 — Haec design pass +:revdate: 2026-06-22 + +== Status +Accepted (design). + +== Context +Haec is the first front-end of the trope-particularity pipeline: it writes and +type-checks programs and emits the language-neutral Trope IR consumed by +`trope-checker`. The calculus (`trope-checker/spec/calculus.adoc`) leaves the +surface syntax and elaboration to the front-end; this ADR records that pass. + +== Decisions +[cols="1,3",options="header"] +|=== +| ID | Decision +| Design before compiler (HC-5) | Pin the surface grammar + elaboration + round-tripping examples first; scaffold `compiler/` and `lsp/` as named future work. No parser/codegen this pass. +| Five atoms + sugar | The honest fragment is generated by `attenuate`/`predicate`/`drop`/`sever`/`fuse`; `preserve`/`project`/`collapse`/`detach` are sugar (calculus expansions). The deceptive trio is not writable (HC-3). +| Lowering correctness is Haec's burden (O2) | Every construct in `design/elaboration.adoc` carries a stated O2 obligation. The checker's soundness is relative to faithful lowering; Haec owns the proofs (deferred, named — not asserted). +| Vendored IR schema | `design/trope-ir.schema.json` is a vendored copy of the published IR contract so `just check` validates examples standalone. The language depends on the IR (correct direction); the checker depends on no language (HC-1). +| RSR placement | `design/` (grammar, elaboration, vendored schema), `examples/`, `compiler/`, `lsp/` added to `root-allow.txt` with justification. Code = MPL-2.0, prose docs = CC-BY-SA-4.0. +|=== + +== Consequences +Haec's meaning is fixed and machine-checkable (examples round-trip through the +checker) before any implementation exists. A reader can see, per construct, what it +lowers to and what Haec must still prove about that lowering. diff --git a/docs/developer/ABI-FFI-README.adoc b/docs/developer/ABI-FFI-README.adoc index 08d2a72..7764600 100644 --- a/docs/developer/ABI-FFI-README.adoc +++ b/docs/developer/ABI-FFI-README.adoc @@ -3,7 +3,7 @@ = ABI/FFI Standards {{~ Aditionally delete this line and fill out the template below ~}} -# {{PROJECT}} ABI/FFI Documentation +# HAEC ABI/FFI Documentation ## Overview @@ -29,7 +29,7 @@ This library follows the **Hyperpolymath RSR Standard** for ABI and FFI design: ▼ ┌─────────────────────────────────────────────┐ │ C Headers (auto-generated) │ -│ generated/abi/{{project}}.h │ +│ generated/abi/haec.h │ └─────────────────┬───────────────────────────┘ │ │ imported by @@ -42,7 +42,7 @@ This library follows the **Hyperpolymath RSR Standard** for ABI and FFI design: │ - Memory-safe by default │ └─────────────────┬───────────────────────────┘ │ - │ compiled to lib{{project}}.so/.a + │ compiled to libhaec.so/.a ▼ ┌─────────────────────────────────────────────┐ │ Any Language via C ABI │ @@ -53,7 +53,7 @@ This library follows the **Hyperpolymath RSR Standard** for ABI and FFI design: ## Directory Structure ``` -{{project}}/ +haec/ ├── src/ │ ├── abi/ # ABI definitions (Idris2) │ │ ├── Types.idr # Core type definitions with proofs @@ -70,11 +70,11 @@ This library follows the **Hyperpolymath RSR Standard** for ABI and FFI design: │ ├── test/ │ │ └── integration_test.zig │ └── include/ -│ └── {{project}}.h # C header (optional, can be generated) +│ └── haec.h # C header (optional, can be generated) │ ├── generated/ # Auto-generated files │ └── abi/ -│ └── {{project}}.h # Generated from Idris2 ABI +│ └── haec.h # Generated from Idris2 ABI │ └── bindings/ # Language-specific wrappers (optional) ├── rust/ @@ -202,7 +202,7 @@ zig build test # Run tests ```bash cd src/abi -idris2 --cg c-header Types.idr -o ../../generated/abi/{{project}}.h +idris2 --cg c-header Types.idr -o ../../generated/abi/haec.h ``` ### Cross-Compile @@ -225,32 +225,32 @@ zig build -Dtarget=x86_64-windows ### From C ```c -#include "{{project}}.h" +#include "haec.h" int main() { - void* handle = {{project}}_init(); + void* handle = haec_init(); if (!handle) return 1; - int result = {{project}}_process(handle, 42); + int result = haec_process(handle, 42); if (result != 0) { - const char* err = {{project}}_last_error(); + const char* err = haec_last_error(); fprintf(stderr, "Error: %s\n", err); } - {{project}}_free(handle); + haec_free(handle); return 0; } ``` Compile with: ```bash -gcc -o example example.c -l{{project}} -L./zig-out/lib +gcc -o example example.c -lhaec -L./zig-out/lib ``` ### From Idris2 ```idris -import {{PROJECT}}.ABI.Foreign +import HAEC.ABI.Foreign main : IO () main = do @@ -267,22 +267,22 @@ main = do ### From Rust ```rust -#[link(name = "{{project}}")] +#[link(name = "haec")] extern "C" { - fn {{project}}_init() -> *mut std::ffi::c_void; - fn {{project}}_free(handle: *mut std::ffi::c_void); - fn {{project}}_process(handle: *mut std::ffi::c_void, input: u32) -> i32; + fn haec_init() -> *mut std::ffi::c_void; + fn haec_free(handle: *mut std::ffi::c_void); + fn haec_process(handle: *mut std::ffi::c_void, input: u32) -> i32; } fn main() { unsafe { - let handle = {{project}}_init(); + let handle = haec_init(); assert!(!handle.is_null()); - let result = {{project}}_process(handle, 42); + let result = haec_process(handle, 42); assert_eq!(result, 0); - {{project}}_free(handle); + haec_free(handle); } } ``` @@ -290,21 +290,21 @@ fn main() { ### From Julia ```julia -const lib{{project}} = "lib{{project}}" +const libhaec = "libhaec" function init() - handle = ccall((:{{project}}_init, lib{{project}}), Ptr{Cvoid}, ()) + handle = ccall((:haec_init, libhaec), Ptr{Cvoid}, ()) handle == C_NULL && error("Failed to initialize") handle end function process(handle, input) - result = ccall((:{{project}}_process, lib{{project}}), Cint, (Ptr{Cvoid}, UInt32), handle, input) + result = ccall((:haec_process, libhaec), Cint, (Ptr{Cvoid}, UInt32), handle, input) result end function cleanup(handle) - ccall((:{{project}}_free, lib{{project}}), Cvoid, (Ptr{Cvoid},), handle) + ccall((:haec_free, libhaec), Cvoid, (Ptr{Cvoid},), handle) end # Usage @@ -358,7 +358,7 @@ When modifying the ABI/FFI: 2. **Generate C header** ```bash - idris2 --cg c-header src/abi/Types.idr -o generated/abi/{{project}}.h + idris2 --cg c-header src/abi/Types.idr -o generated/abi/haec.h ``` 3. **Update FFI implementation** (`ffi/zig/src/main.zig`) @@ -377,10 +377,10 @@ When modifying the ABI/FFI: ## License -{{LICENSE}} +MPL-2.0 ## See Also - [Idris2 Documentation](https://idris2.readthedocs.io) - [Zig Documentation](https://ziglang.org/documentation/master/) -- [Rhodium Standard Repositories](https://github.com/{{OWNER}}/rhodium-standard-repositories) +- [Rhodium Standard Repositories](https://github.com/hyperpolymath/rhodium-standard-repositories) diff --git a/docs/governance/CRG-AUDIT-TEMPLATE.adoc b/docs/governance/CRG-AUDIT-TEMPLATE.adoc index b409104..4ad32f2 100644 --- a/docs/governance/CRG-AUDIT-TEMPLATE.adoc +++ b/docs/governance/CRG-AUDIT-TEMPLATE.adoc @@ -1,8 +1,8 @@ // SPDX-License-Identifier: MPL-2.0 // Copyright (c) Jonathan D.A. Jewell -= {{PROJECT_NAME}} — CRG Audit ({{CURRENT_DATE}}) -{{AUTHOR}} -{{CURRENT_DATE}} += Haec — CRG Audit (2026-06-22) +Jonathan D.A. Jewell +2026-06-22 :toc: :sectnums: @@ -18,7 +18,7 @@ == Scope and Standard -Evaluates the `{{REPO}}` repository against +Evaluates the `haec` repository against *Component Readiness Grades v2.0 (STRICT)*, 2026-03-30 revision. - Standard: `standards/component-readiness-grades/COMPONENT-READINESS-GRADES.md` @@ -27,8 +27,8 @@ Evaluates the `{{REPO}}` repository against * `.machine_readable/6a2/STATE.a2ml` → `grade = ""` * `docs/READINESS.md` (if present) → per-component grades * Third-party badges (Glama, OpenSSF, etc.) if any — note date and scope -- Audit date: {{CURRENT_DATE}} -- Auditor: {{AUTHOR}} +- Audit date: 2026-06-22 +- Auditor: Jonathan D.A. Jewell The audit grades the repo *as-is today*, not aspirationally. @@ -49,7 +49,7 @@ The audit grades the repo *as-is today*, not aspirationally. Publication requires B+. Long alpha is discipline, not shame. -== Evidence Inventory (verified {{CURRENT_DATE}}) +== Evidence Inventory (verified 2026-06-22) === Structural compliance (Grade D floor) @@ -101,7 +101,7 @@ Do *not* mark PRESENT without citing the path. | Build-system policy (RSR R-020) | Remote -| `git@{{FORGE}}:{{OWNER}}/{{REPO}}.git` (origin only) / drift +| `git@github.com:hyperpolymath/haec.git` (origin only) / drift | `git remote -v` |=== @@ -135,7 +135,7 @@ RSR compliance verdict: *met* / *partial* / *not met* — Grade D floor satisfie | Dangerous-pattern scan (`assert_total`, `Admitted`, `sorry`, `unsafeCoerce`, `Obj.magic`) | N -| Grepped {{CURRENT_DATE}}. +| Grepped 2026-06-22. |=== === Test matrix @@ -281,7 +281,7 @@ them. Examples: - `docs/READINESS.md` — per-component table. Note v1.0-vs-v2.0 schema alignment. - `.machine_readable/6a2/STATE.a2ml` — authoritative self-declared state. -- `docs/governance/CRG-LIFT-PLAN-{{CURRENT_DATE}}.adoc` — companion plan for +- `docs/governance/CRG-LIFT-PLAN-2026-06-22.adoc` — companion plan for D→C (and medium-term C→B) lifts. - `docs/governance/CRG-CRITERIA.adoc` — boilerplate criteria doc. diff --git a/docs/governance/TEMPLATE-STANDARDS-AUDIT.adoc b/docs/governance/TEMPLATE-STANDARDS-AUDIT.adoc index 34b25a1..fa5216d 100644 --- a/docs/governance/TEMPLATE-STANDARDS-AUDIT.adoc +++ b/docs/governance/TEMPLATE-STANDARDS-AUDIT.adoc @@ -28,7 +28,7 @@ Inventory snapshot at audit time: | Placeholder badge tokens in README | `README.adoc` -| `{{OPENSSF_PROJECT_ID}}`, `{{OWNER}}`, `{{REPO}}` +| `{{OPENSSF_PROJECT_ID}}`, `hyperpolymath`, `haec` | placeholder | Template placeholders are intentional pre-bootstrap content. | Keep; document clearly as template tokens. diff --git a/docs/practice/AI-CONVENTIONS.adoc b/docs/practice/AI-CONVENTIONS.adoc index a174609..2bc7e15 100644 --- a/docs/practice/AI-CONVENTIONS.adoc +++ b/docs/practice/AI-CONVENTIONS.adoc @@ -2,7 +2,7 @@ // Copyright (c) Jonathan D.A. Jewell = AI Conventions - + # AI Conventions (Authoritative Source) @@ -29,9 +29,9 @@ Per-tool config files (.cursorrules, .clinerules, etc.) reference this document. ## Author Attribution -- Name: **{{AUTHOR}}** -- Email: **{{AUTHOR_EMAIL}}** -- Copyright: `Copyright (c) {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}>` +- Name: **Jonathan D.A. Jewell** +- Email: **j.d.a.jewell@open.ac.uk** +- Copyright: `Copyright (c) 2026 Jonathan D.A. Jewell (hyperpolymath) ` ## State Files diff --git a/docs/practice/STATE-VISUALIZER-GUIDE.adoc b/docs/practice/STATE-VISUALIZER-GUIDE.adoc index 4fcbddd..6e97d92 100644 --- a/docs/practice/STATE-VISUALIZER-GUIDE.adoc +++ b/docs/practice/STATE-VISUALIZER-GUIDE.adoc @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MPL-2.0 // Copyright (c) Jonathan D.A. Jewell = TOPOLOGY.md — Generation Guide -{{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +Jonathan D.A. Jewell (hyperpolymath) :toc: :sectnums: @@ -153,4 +153,4 @@ _structured data_ for tooling. Both should agree. == Copyright -Copyright (c) {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +Copyright (c) 2026 Jonathan D.A. Jewell (hyperpolymath) diff --git a/docs/status/PROOF-NEEDS.adoc b/docs/status/PROOF-NEEDS.adoc index b907af8..9b771b4 100644 --- a/docs/status/PROOF-NEEDS.adoc +++ b/docs/status/PROOF-NEEDS.adoc @@ -2,7 +2,7 @@ // Copyright (c) Jonathan D.A. Jewell // Template: rsr-template-repo/docs/status/PROOF-NEEDS.adoc // Authoritative master list: ~/Desktop/PROOF-REQUIREMENTS-MASTER.adoc -= Proof Requirements — {{PROJECT}} += Proof Requirements — HAEC == Proof Tier diff --git a/docs/status/PROOF-STATUS.adoc b/docs/status/PROOF-STATUS.adoc index 721c464..d660084 100644 --- a/docs/status/PROOF-STATUS.adoc +++ b/docs/status/PROOF-STATUS.adoc @@ -2,7 +2,7 @@ // Copyright (c) Jonathan D.A. Jewell // Template: rsr-template-repo/docs/status/PROOF-STATUS.adoc // Tracks proof completion. Requirements defined in PROOF-NEEDS.adoc -= Proof Status — {{PROJECT}} += Proof Status — HAEC == Summary diff --git a/docs/status/READINESS.adoc b/docs/status/READINESS.adoc index b06eedb..e5116d7 100644 --- a/docs/status/READINESS.adoc +++ b/docs/status/READINESS.adoc @@ -1,10 +1,10 @@ // SPDX-License-Identifier: MPL-2.0 // Copyright (c) Jonathan D.A. Jewell -= {{PROJECT_NAME}} Component Readiness Assessment += Haec Component Readiness Assessment -*Standard:* link:https://{{FORGE}}/{{OWNER}}/standards/tree/main/component-readiness-grades[Component Readiness Grades (CRG) v2.0 STRICT] + -*Assessed:* {{CURRENT_DATE}} + -*Assessor:* {{AUTHOR}} + +*Standard:* link:https://github.com/hyperpolymath/standards/tree/main/component-readiness-grades[Component Readiness Grades (CRG) v2.0 STRICT] + +*Assessed:* 2026-06-22 + +*Assessor:* Jonathan D.A. Jewell + *Previous assessment:* __ *Current Grade:* X @@ -59,7 +59,7 @@ Below B, any publication must be explicitly abstract or provisional. ''' -== 2. Headline Evidence (as of {{CURRENT_DATE}}) +== 2. Headline Evidence (as of 2026-06-22) [cols="2,3,3", options="header"] |=== @@ -67,7 +67,7 @@ Below B, any publication must be explicitly abstract or provisional. | Test count | __ | `.machine_readable/6a2/STATE.a2ml` or CI | Formal-verification posture | __ | grep of proof dirs -| Dangerous patterns (`assert_total`, `unsafeCoerce`, `Obj.magic`) | __ | grep {{CURRENT_DATE}} +| Dangerous patterns (`assert_total`, `unsafeCoerce`, `Obj.magic`) | __ | grep 2026-06-22 | Per-unit README coverage | __ | filesystem scan of unit dirs | CI status | __ | `.github/workflows/` | RSR mandatory workflows | __ | `.github/workflows/` @@ -87,9 +87,9 @@ unless noted. |=== | Component | Grade | Posture | Evidence Summary | Promotion blocker | Last Assessed -| __ | X/F/E/D/C/B/A | __ | __ | __ | {{CURRENT_DATE}} -| __ | … | … | … | … | {{CURRENT_DATE}} -| __ | … | … | … | … | {{CURRENT_DATE}} +| __ | X/F/E/D/C/B/A | __ | __ | __ | 2026-06-22 +| __ | … | … | … | … | 2026-06-22 +| __ | … | … | … | … | 2026-06-22 |=== *Rules of thumb for populating this table:* @@ -164,7 +164,7 @@ Real-world external feedback confirming value. Populate ''' -== 7. Summary ({{CURRENT_DATE}}) +== 7. Summary (2026-06-22) * Project grade: __. Why: _<1-2 line justification>_. * Delta since last assessment: __. diff --git a/docs/status/TEST-NEEDS.adoc b/docs/status/TEST-NEEDS.adoc index 8fd55fd..8230374 100644 --- a/docs/status/TEST-NEEDS.adoc +++ b/docs/status/TEST-NEEDS.adoc @@ -57,7 +57,7 @@ === Zig FFI Tests ✅ * [x] `src/interface/ffi/test/integration_test.zig` — template with examples -** Converted from `{{project}}` placeholders to "template" namespace +** Converted from `haec` placeholders to "template" namespace ** Added comprehensive comments for how to instantiate ** Tests grouped by category (lifecycle, operations, strings, errors, version, memory safety, threading) ** Compiles and passes placeholder test diff --git a/docs/trope-estate-architecture.svg b/docs/trope-estate-architecture.svg new file mode 100755 index 0000000..838c2f2 --- /dev/null +++ b/docs/trope-estate-architecture.svg @@ -0,0 +1,70 @@ + +Trope-particularity — three repositories, one pipeline +A language (gray) writes and type-checks programs and emits the Trope IR (a white conduit), which the tropechecker (teal, the trust boundary, which also holds the formal calculus and IR schema) consumes to produce a verdict (coral): p-sufficient or p-insufficient. Below, the Particularity workbench (purple) defines the vocabulary — the named effects, the residual, the verdict — and is realised by both the language and the checker. The checker depends on no language; the language is one producer of the IR among potentially many. + + + + + + + +Trope-particularity — three repositories, one pipeline +A language produces the IR · a portable checker consumes it · a workbench defines the words both use + + + +Haec +a language (one of many) +writes, checks, emits IR + + + + + +Trope IR +graded-effect DAG + + + + + +tropechecker +consumes IR → verdict · trust boundary +holds the formal calculus + IR schema + + + + + +verdict — p-sufficient | p-insufficient + + + +Particularity — the vocabulary +informal · the named effects · the residual · the verdict +defines the words both sides use; depends on nothing + + + +realised by + +realised by & formalised in + + + +Language + +Trope IR (wire format) + +Checker (trust boundary) + +Workbench (vocabulary) + +Verdict + diff --git a/lsp/STATUS.adoc b/lsp/STATUS.adoc new file mode 100644 index 0000000..0ec48db --- /dev/null +++ b/lsp/STATUS.adoc @@ -0,0 +1,12 @@ +// SPDX-FileCopyrightText: © 2026 Jonathan D.A. Jewell (hyperpolymath) +// SPDX-License-Identifier: MPL-2.0 +// SPDX-License-Identifier: CC-BY-SA-4.0 += lsp/ — STATUS (named future work) +:revdate: 2026-06-22 + +*Not built.* Scaffolded for Haec editor support. Beyond the current handover. + +When built, the natural surface is: show each expression's inferred loss-shape +grade inline; surface the *witness edge* from a `p-insufficient` verdict at the +offending construct; and flag any construct whose lowering-correctness obligation +(O2) is still open. Depends on `compiler/` (parser + type-checker + elaborator). From 8616c86f7251e6c66d40a771d4421b1557cbedfb Mon Sep 17 00:00:00 2001 From: hyperpolymath <6759885+hyperpolymath@users.noreply.github.com> Date: Mon, 22 Jun 2026 09:52:12 +0100 Subject: [PATCH 4/4] chore: configure RSR template for haec De-template; identity; root-allow (design/, compiler/, lsp/, LICENSES/); LICENSES (MPL-2.0 + CC-BY-SA-4.0); Justfile import of build/just/trope.just (check). --- .devcontainer/Containerfile | 8 +- .devcontainer/README.adoc | 4 +- .devcontainer/devcontainer.json | 6 +- .envrc | 2 +- .github/.mailmap | 2 +- .github/CODEOWNERS | 12 +- .github/CODE_OF_CONDUCT.md | 36 +- .github/CONTRIBUTING.md | 20 +- .github/FUNDING.yml | 8 +- .github/GOVERNANCE.md | 6 +- .github/ISSUE_TEMPLATE/bug_report.yml | 2 +- .github/ISSUE_TEMPLATE/config.yml | 6 +- .github/ISSUE_TEMPLATE/custom.yml | 2 +- .github/ISSUE_TEMPLATE/documentation.yml | 2 +- .github/ISSUE_TEMPLATE/feature_request.yml | 2 +- .github/ISSUE_TEMPLATE/question.yml | 4 +- .github/MAINTAINERS | 2 +- .github/SECURITY.md | 36 +- .github/SUPPORT | 4 +- .github/copilot-instructions.md | 4 +- .github/settings.yml | 6 +- .machine_readable/6a2/anchors/ANCHOR.a2ml | 10 +- .machine_readable/ENSAID_CONFIG.a2ml | 8 +- .machine_readable/ai/.clinerules | 4 +- .machine_readable/ai/.cursorrules | 4 +- .machine_readable/ai/.windsurfrules | 4 +- .machine_readable/ai/PLACEHOLDERS.adoc | 70 ++-- .../bot_directives/coverage.a2ml | 4 +- .machine_readable/bot_directives/debt.a2ml | 4 +- .../bot_directives/methodology.a2ml | 6 +- .machine_readable/compliance/reuse/dep5 | 26 +- .machine_readable/configs/eclexiaiser.toml | 2 +- .../configs/git-cliff/cliff.toml | 10 +- .machine_readable/configs/selur-compose.toml | 4 +- .machine_readable/configs/stapeln.toml | 12 +- .machine_readable/contractiles/Justfile | 38 +- .../contractiles/dust/Dustfile.a2ml | 2 +- .machine_readable/integrations/groove.a2ml | 4 +- .../policies/MAINTENANCE-AXES.a2ml | 4 +- .machine_readable/root-allow.txt | 6 + .../scripts/maintenance/maint-assault.sh | 2 +- .machine_readable/self-validating/README.adoc | 12 +- .../self-validating/examples/ci-config.k9.ncl | 2 +- .../examples/project-metadata.k9.ncl | 12 +- .../examples/setup-repo.k9.ncl | 8 +- .../self-validating/methodology-guard.k9.ncl | 2 +- .../self-validating/template-hunt.k9.ncl | 2 +- .../self-validating/template-kennel.k9.ncl | 2 +- .../self-validating/template-yard.k9.ncl | 2 +- .well-known/humans.txt | 6 +- .well-known/security.txt | 10 +- 0-AI-MANIFEST.a2ml | 6 +- Justfile | 43 +- LICENSES/CC-BY-SA-4.0.txt | 170 ++++++++ LICENSES/MPL-2.0.txt | 373 ++++++++++++++++++ build/.guix-channel | 10 +- build/Containerfile | 18 +- build/guix.scm | 12 +- build/just/trope.just | 15 + container/.gatekeeper.yaml | 6 +- container/Containerfile | 38 +- container/README.adoc | 2 +- container/compose.toml | 22 +- container/ct-build.sh | 14 +- container/deploy.k9.ncl | 18 +- container/entrypoint.sh | 14 +- container/manifest.toml | 26 +- container/vordr.toml | 16 +- docs-template/README.adoc | 4 +- docs-template/architecture.adoc | 6 +- docs-template/contributing.adoc | 14 +- docs-template/decisions/0001-template.adoc | 4 +- docs-template/troubleshooting.adoc | 8 +- docs-template/usage.adoc | 10 +- .../Intentfile.a2ml | 2 +- .../canonical-directory-structure/README.adoc | 2 +- .../Trustfile.a2ml | 2 +- .../bust/Bustfile.a2ml | 2 +- src/interface/ffi/src/main.zig | 38 +- 79 files changed, 958 insertions(+), 393 deletions(-) create mode 100644 LICENSES/CC-BY-SA-4.0.txt create mode 100644 LICENSES/MPL-2.0.txt create mode 100644 build/just/trope.just diff --git a/.devcontainer/Containerfile b/.devcontainer/Containerfile index b0a6fd1..455a443 100644 --- a/.devcontainer/Containerfile +++ b/.devcontainer/Containerfile @@ -1,9 +1,9 @@ # SPDX-License-Identifier: MPL-2.0 -# Copyright (c) {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +# Copyright (c) 2026 Jonathan D.A. Jewell (hyperpolymath) # -# Dev Container image for {{PROJECT_NAME}} +# Dev Container image for Haec # Base: Chainguard Wolfi (minimal, supply-chain-secure) -# Build: podman build -t {{PROJECT_NAME}}-dev -f .devcontainer/Containerfile . +# Build: podman build -t Haec-dev -f .devcontainer/Containerfile . FROM cgr.dev/chainguard/wolfi-base:latest @@ -24,7 +24,7 @@ RUN groupadd -g 1000 nonroot || true \ && useradd -m -u 1000 -g 1000 -s /bin/bash nonroot || true # Set workspace directory -WORKDIR /workspaces/{{PROJECT_NAME}} +WORKDIR /workspaces/Haec # Default shell ENV SHELL=/bin/bash diff --git a/.devcontainer/README.adoc b/.devcontainer/README.adoc index 7a370f2..aaf19bd 100644 --- a/.devcontainer/README.adoc +++ b/.devcontainer/README.adoc @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MPL-2.0 // Copyright (c) Jonathan D.A. Jewell = Dev Container Usage -:author: {{AUTHOR}} <{{AUTHOR_EMAIL}}> +:author: Jonathan D.A. Jewell == Overview @@ -25,4 +25,4 @@ This dev container uses `cgr.dev/chainguard/wolfi-base` with git, curl, bash, an == Customization -Replace `{{PROJECT_NAME}}` placeholders in both `devcontainer.json` and `Containerfile` with your actual project name. Run `just deps` to verify the environment after first launch. +Replace `Haec` placeholders in both `devcontainer.json` and `Containerfile` with your actual project name. Run `just deps` to verify the environment after first launch. diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index a4b33e0..ecabcf8 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -1,11 +1,11 @@ // SPDX-License-Identifier: MPL-2.0 -// Copyright (c) {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +// Copyright (c) 2026 Jonathan D.A. Jewell (hyperpolymath) // -// Dev Container configuration for {{PROJECT_NAME}} +// Dev Container configuration for Haec // Works with: VS Code Dev Containers, GitHub Codespaces, Gitpod // Container runtime: Podman (recommended) or any OCI-compliant runtime { - "name": "{{PROJECT_NAME}}", + "name": "Haec", "build": { "dockerfile": "Containerfile", diff --git a/.envrc b/.envrc index 0b5b702..42936b3 100644 --- a/.envrc +++ b/.envrc @@ -18,7 +18,7 @@ if has nix && [ -f flake.nix ]; then fi # Project environment variables -export PROJECT_NAME="{{PROJECT_NAME}}" +export PROJECT_NAME="Haec" export RSR_TIER="infrastructure" # export DATABASE_URL="..." # export API_KEY="..." diff --git a/.github/.mailmap b/.github/.mailmap index 0ada9de..e555414 100644 --- a/.github/.mailmap +++ b/.github/.mailmap @@ -1 +1 @@ -{{AUTHOR}} <{{AUTHOR_EMAIL}}> <{{AUTHOR_EMAIL_ALT}}> +Jonathan D.A. Jewell <> diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 611b5a8..8d339b7 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -2,13 +2,13 @@ # CODEOWNERS - Define code review assignments # See: https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-code-owners # -# Replace {{OWNER}} with your GitHub username or team +# Replace hyperpolymath with your GitHub username or team # Default owners for everything -* @{{OWNER}} +* @hyperpolymath # Security-sensitive files require explicit review -SECURITY.md @{{OWNER}} -.github/workflows/ @{{OWNER}} -Trustfile.a2ml @{{OWNER}} -.machine_readable/ @{{OWNER}} +SECURITY.md @hyperpolymath +.github/workflows/ @hyperpolymath +Trustfile.a2ml @hyperpolymath +.machine_readable/ @hyperpolymath diff --git a/.github/CODE_OF_CONDUCT.md b/.github/CODE_OF_CONDUCT.md index 9142f2a..70d6bba 100644 --- a/.github/CODE_OF_CONDUCT.md +++ b/.github/CODE_OF_CONDUCT.md @@ -9,13 +9,13 @@ Copyright (c) Jonathan D.A. Jewell TEMPLATE INSTRUCTIONS (delete this block before publishing) ============================================================================ Replace all {{PLACEHOLDER}} values: - {{PROJECT_NAME}} - Your project name - {{OWNER}} - GitHub/GitLab username or org - {{REPO}} - Repository name - {{CONDUCT_EMAIL}} - Email for conduct reports - {{CONDUCT_TEAM}} - Name of conduct team/committee - {{RESPONSE_TIME}} - Initial response SLA (e.g., 48 hours) - {{CURRENT_YEAR}} - Current year + Haec - Your project name + hyperpolymath - GitHub/GitLab username or org + haec - Repository name + j.d.a.jewell@open.ac.uk - Email for conduct reports + Code of Conduct Committee - Name of conduct team/committee + 48 hours - Initial response SLA (e.g., 48 hours) + 2026 - Current year Review and customise: - Adjust enforcement ladder for your community size @@ -26,7 +26,7 @@ Review and customise: ## Our Pledge -We as members, contributors, and leaders pledge to make participation in {{PROJECT_NAME}} a harassment-free experience for everyone, regardless of age, body size, visible or invisible disability, ethnicity, sex characteristics, gender identity and expression, level of experience, education, socio-economic status, nationality, personal appearance, race, caste, colour, religion, or sexual identity and orientation. +We as members, contributors, and leaders pledge to make participation in Haec a harassment-free experience for everyone, regardless of age, body size, visible or invisible disability, ethnicity, sex characteristics, gender identity and expression, level of experience, education, socio-economic status, nationality, personal appearance, race, caste, colour, religion, or sexual identity and orientation. We pledge to act and interact in ways that contribute to an open, welcoming, diverse, inclusive, and healthy community. @@ -140,7 +140,7 @@ If you experience or witness unacceptable behaviour, or have any other concerns, | Method | Details | Best For | |--------|---------|----------| -| **Email** | {{CONDUCT_EMAIL}} | Detailed reports, sensitive matters | +| **Email** | j.d.a.jewell@open.ac.uk | Detailed reports, sensitive matters | | **Private Message** | Contact any maintainer directly | Quick questions, minor issues | | **Anonymous Form** | [Link to form if available] | When you need anonymity | @@ -156,8 +156,8 @@ If you experience or witness unacceptable behaviour, or have any other concerns, **What Happens Next** -1. You will receive acknowledgment within **{{RESPONSE_TIME}}** -2. The {{CONDUCT_TEAM}} will review the report +1. You will receive acknowledgment within **48 hours** +2. The Code of Conduct Committee will review the report 3. We may ask for additional information 4. We will determine appropriate action 5. We will inform you of the outcome (respecting others' privacy) @@ -173,7 +173,7 @@ All reports will be handled with discretion: ### Conflicts of Interest -If a {{CONDUCT_TEAM}} member is involved in an incident: +If a Code of Conduct Committee member is involved in an incident: - They will recuse themselves from the process - Another maintainer or external party will handle the report @@ -183,7 +183,7 @@ If a {{CONDUCT_TEAM}} member is involved in an incident: ## Enforcement Guidelines -The {{CONDUCT_TEAM}} will follow these guidelines in determining consequences: +The Code of Conduct Committee will follow these guidelines in determining consequences: ### 1. Correction @@ -235,13 +235,13 @@ For contributors with elevated access (Perimeter 2 or 1): If you believe an enforcement decision was made in error: 1. **Wait 7 days** after the decision (cooling-off period) -2. **Email** {{CONDUCT_EMAIL}} with subject line "Appeal: [Original Report ID]" +2. **Email** j.d.a.jewell@open.ac.uk with subject line "Appeal: [Original Report ID]" 3. **Explain** why you believe the decision should be reconsidered 4. **Provide** any new information not previously available **Appeals Process** -- Appeals are reviewed by a different {{CONDUCT_TEAM}} member than the original +- Appeals are reviewed by a different Code of Conduct Committee member than the original - You will receive a response within 14 days - The appeals decision is final - You may only appeal once per incident @@ -314,8 +314,8 @@ We thank these communities for their leadership in creating welcoming spaces. If you have questions about this Code of Conduct: -- Open a [Discussion](https://{{FORGE}}/{{OWNER}}/{{REPO}}/discussions) (for general questions) -- Email {{CONDUCT_EMAIL}} (for private questions) +- Open a [Discussion](https://github.com/hyperpolymath/haec/discussions) (for general questions) +- Email j.d.a.jewell@open.ac.uk (for private questions) - Contact any maintainer directly --- @@ -328,4 +328,4 @@ We're all here because we care about this project. Let's make it a place where e --- -Last updated: {{CURRENT_YEAR}} · Based on Contributor Covenant 2.1 +Last updated: 2026 · Based on Contributor Covenant 2.1 diff --git a/.github/CONTRIBUTING.md b/.github/CONTRIBUTING.md index d07b3e9..d382840 100644 --- a/.github/CONTRIBUTING.md +++ b/.github/CONTRIBUTING.md @@ -3,15 +3,15 @@ SPDX-License-Identifier: MPL-2.0 Copyright (c) Jonathan D.A. Jewell --> # Clone the repository -git clone https://{{FORGE}}/{{OWNER}}/{{REPO}}.git -cd {{REPO}} +git clone https://github.com/hyperpolymath/haec.git +cd haec # Using Nix (recommended for reproducibility) nix develop # Or using toolbox/distrobox -toolbox create {{REPO}}-dev -toolbox enter {{REPO}}-dev +toolbox create haec-dev +toolbox enter haec-dev # Install dependencies manually # Verify setup @@ -21,7 +21,7 @@ just test # Run test suite ### Repository Structure ``` -{{REPO}}/ +haec/ ├── src/ # Source code (Perimeter 1-2) ├── lib/ # Library code (Perimeter 1-2) ├── extensions/ # Extensions (Perimeter 2) @@ -62,7 +62,7 @@ just test # Run test suite **Before reporting**: 1. Search existing issues -2. Check if it's already fixed in `{{MAIN_BRANCH}}` +2. Check if it's already fixed in `main` 3. Determine which perimeter the bug affects **When reporting**: @@ -95,10 +95,10 @@ Use the [feature request template](.github/ISSUE_TEMPLATE/feature_request.md) an Look for issues labelled: -- [`good first issue`](https://{{FORGE}}/{{OWNER}}/{{REPO}}/labels/good%20first%20issue) — Simple Perimeter 3 tasks -- [`help wanted`](https://{{FORGE}}/{{OWNER}}/{{REPO}}/labels/help%20wanted) — Community help needed -- [`documentation`](https://{{FORGE}}/{{OWNER}}/{{REPO}}/labels/documentation) — Docs improvements -- [`perimeter-3`](https://{{FORGE}}/{{OWNER}}/{{REPO}}/labels/perimeter-3) — Community sandbox scope +- [`good first issue`](https://github.com/hyperpolymath/haec/labels/good%20first%20issue) — Simple Perimeter 3 tasks +- [`help wanted`](https://github.com/hyperpolymath/haec/labels/help%20wanted) — Community help needed +- [`documentation`](https://github.com/hyperpolymath/haec/labels/documentation) — Docs improvements +- [`perimeter-3`](https://github.com/hyperpolymath/haec/labels/perimeter-3) — Community sandbox scope --- diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml index c078261..688a442 100644 --- a/.github/FUNDING.yml +++ b/.github/FUNDING.yml @@ -1,7 +1,7 @@ # SPDX-License-Identifier: MPL-2.0 -# Funding platforms for {{OWNER}} projects +# Funding platforms for hyperpolymath projects # See: https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/displaying-a-sponsor-button-in-your-repository -github: {{OWNER}} -ko_fi: {{OWNER}} -liberapay: {{OWNER}} +github: hyperpolymath +ko_fi: hyperpolymath +liberapay: hyperpolymath diff --git a/.github/GOVERNANCE.md b/.github/GOVERNANCE.md index 8ef7166..c1bd882 100644 --- a/.github/GOVERNANCE.md +++ b/.github/GOVERNANCE.md @@ -4,13 +4,13 @@ Copyright (c) Jonathan D.A. Jewell --> # Project Governance -This document describes the governance model for **{{PROJECT_NAME}}**. +This document describes the governance model for **Haec**. --- ## Project Governance Model -{{PROJECT_NAME}} follows a **Benevolent Dictator For Life (BDFL)** governance model. +Haec follows a **Benevolent Dictator For Life (BDFL)** governance model. This model is well-suited for solo maintainers and small project teams where rapid, consistent decision-making is more valuable than formal consensus processes. @@ -157,4 +157,4 @@ with the community before adoption, even though the BDFL retains final authority --- -Copyright (c) {{CURRENT_YEAR}} {{OWNER}}. Licensed under MPL-2.0. +Copyright (c) 2026 hyperpolymath. Licensed under MPL-2.0. diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml index ec2aa28..a9567af 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.yml +++ b/.github/ISSUE_TEMPLATE/bug_report.yml @@ -1,5 +1,5 @@ # SPDX-License-Identifier: MPL-2.0 -# Bug report issue template for {{OWNER}}/{{REPO}} +# Bug report issue template for hyperpolymath/haec name: Bug Report description: Create a report to help us improve title: "[Bug]: " diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml index cb7a33c..c52c3d0 100644 --- a/.github/ISSUE_TEMPLATE/config.yml +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -1,10 +1,10 @@ # SPDX-License-Identifier: MPL-2.0 -# Issue template chooser configuration for {{OWNER}}/{{REPO}} +# Issue template chooser configuration for hyperpolymath/haec blank_issues_enabled: true contact_links: - name: Discussions - url: https://github.com/{{OWNER}}/{{REPO}}/discussions + url: https://github.com/hyperpolymath/haec/discussions about: Ask questions, share ideas, or start a conversation in Discussions. - name: Security Vulnerabilities - url: https://github.com/{{OWNER}}/{{REPO}}/security/advisories/new + url: https://github.com/hyperpolymath/haec/security/advisories/new about: Report security vulnerabilities privately via GitHub Security Advisories. diff --git a/.github/ISSUE_TEMPLATE/custom.yml b/.github/ISSUE_TEMPLATE/custom.yml index 6aa9e63..408e2ce 100644 --- a/.github/ISSUE_TEMPLATE/custom.yml +++ b/.github/ISSUE_TEMPLATE/custom.yml @@ -1,5 +1,5 @@ # SPDX-License-Identifier: MPL-2.0 -# Custom issue template for {{OWNER}}/{{REPO}} +# Custom issue template for hyperpolymath/haec name: Other description: Report an issue that does not fit the other categories title: "" diff --git a/.github/ISSUE_TEMPLATE/documentation.yml b/.github/ISSUE_TEMPLATE/documentation.yml index 88e0720..ee6da9d 100644 --- a/.github/ISSUE_TEMPLATE/documentation.yml +++ b/.github/ISSUE_TEMPLATE/documentation.yml @@ -1,5 +1,5 @@ # SPDX-License-Identifier: MPL-2.0 -# Documentation issue template for {{OWNER}}/{{REPO}} +# Documentation issue template for hyperpolymath/haec name: Documentation description: Report unclear, missing, or incorrect documentation title: "[Docs]: " diff --git a/.github/ISSUE_TEMPLATE/feature_request.yml b/.github/ISSUE_TEMPLATE/feature_request.yml index 6d88090..274a8e3 100644 --- a/.github/ISSUE_TEMPLATE/feature_request.yml +++ b/.github/ISSUE_TEMPLATE/feature_request.yml @@ -1,5 +1,5 @@ # SPDX-License-Identifier: MPL-2.0 -# Feature request issue template for {{OWNER}}/{{REPO}} +# Feature request issue template for hyperpolymath/haec name: Feature Request description: Suggest an idea or enhancement for this project title: "[Feature]: " diff --git a/.github/ISSUE_TEMPLATE/question.yml b/.github/ISSUE_TEMPLATE/question.yml index 48bb574..645ff67 100644 --- a/.github/ISSUE_TEMPLATE/question.yml +++ b/.github/ISSUE_TEMPLATE/question.yml @@ -1,5 +1,5 @@ # SPDX-License-Identifier: MPL-2.0 -# Question issue template for {{OWNER}}/{{REPO}} +# Question issue template for hyperpolymath/haec name: Question description: Ask a question about usage or behaviour title: "[Question]: " @@ -10,7 +10,7 @@ body: attributes: value: | Have a question? You can also ask in - [Discussions](https://github.com/{{OWNER}}/{{REPO}}/discussions) + [Discussions](https://github.com/hyperpolymath/haec/discussions) for broader conversations. - type: textarea diff --git a/.github/MAINTAINERS b/.github/MAINTAINERS index 145c4e9..63989c7 100644 --- a/.github/MAINTAINERS +++ b/.github/MAINTAINERS @@ -4,7 +4,7 @@ # Format: Name (role) # Replace placeholders with actual maintainer information. -{{AUTHOR}} <{{AUTHOR_EMAIL}}> (Lead Maintainer) +Jonathan D.A. Jewell (Lead Maintainer) # Additional maintainers: # Name (role) diff --git a/.github/SECURITY.md b/.github/SECURITY.md index 09fc7b8..9c92364 100644 --- a/.github/SECURITY.md +++ b/.github/SECURITY.md @@ -9,14 +9,14 @@ Copyright (c) Jonathan D.A. Jewell TEMPLATE INSTRUCTIONS (delete this block before publishing) ============================================================================ Replace all {{PLACEHOLDER}} values with your information: - {{PROJECT_NAME}} - Your project name - {{OWNER}} - GitHub username or org (e.g., hyperpolymath) - {{REPO}} - Repository name - {{SECURITY_EMAIL}} - Security contact email + Haec - Your project name + hyperpolymath - GitHub username or org (e.g., hyperpolymath) + haec - Repository name + j.d.a.jewell@open.ac.uk - Security contact email {{PGP_FINGERPRINT}} - Your PGP key fingerprint (40 chars, no spaces) {{PGP_KEY_URL}} - URL to your public PGP key - {{WEBSITE}} - Your website/domain - {{CURRENT_YEAR}} - Current year for copyright + https://github.com/hyperpolymath/haec - Your website/domain + 2026 - Current year for copyright Optional: Remove sections that don't apply (e.g., PGP if you don't use it) ============================================================================ @@ -44,7 +44,7 @@ We take security seriously. We appreciate your efforts to responsibly disclose v The preferred method for reporting security vulnerabilities is through GitHub's Security Advisory feature: -1. Navigate to [Report a Vulnerability](https://github.com/{{OWNER}}/{{REPO}}/security/advisories/new) +1. Navigate to [Report a Vulnerability](https://github.com/hyperpolymath/haec/security/advisories/new) 2. Click **"Report a vulnerability"** 3. Complete the form with as much detail as possible 4. Submit — we'll receive a private notification @@ -62,7 +62,7 @@ If you cannot use GitHub Security Advisories, you may email us directly: | | | |---|---| -| **Email** | {{SECURITY_EMAIL}} | +| **Email** | j.d.a.jewell@open.ac.uk | | **PGP Key** | [Download Public Key]({{PGP_KEY_URL}}) | | **Fingerprint** | `{{PGP_FINGERPRINT}}` | @@ -71,10 +71,10 @@ If you cannot use GitHub Security Advisories, you may email us directly: curl -sSL {{PGP_KEY_URL}} | gpg --import # Verify fingerprint -gpg --fingerprint {{SECURITY_EMAIL}} +gpg --fingerprint j.d.a.jewell@open.ac.uk # Encrypt your report -gpg --armor --encrypt --recipient {{SECURITY_EMAIL}} report.txt +gpg --armor --encrypt --recipient j.d.a.jewell@open.ac.uk report.txt ``` > **⚠️ Important:** Do not report security vulnerabilities through public GitHub issues, pull requests, discussions, or social media. @@ -207,7 +207,7 @@ If we cannot reach agreement on disclosure timing, we default to 90 days from yo The following are within scope for security research: -- This repository (`{{OWNER}}/{{REPO}}`) and all its code +- This repository (`hyperpolymath/haec`) and all its code - Official releases and packages published from this repository - Documentation that could lead to security issues - Build and deployment configurations in this repository @@ -326,7 +326,7 @@ Recognition includes: To stay informed about security updates: - **Watch this repository**: Click "Watch" → "Custom" → Select "Security alerts" -- **GitHub Security Advisories**: Published at [Security Advisories](https://github.com/{{OWNER}}/{{REPO}}/security/advisories) +- **GitHub Security Advisories**: Published at [Security Advisories](https://github.com/hyperpolymath/haec/security/advisories) - **Release notes**: Security fixes noted in [CHANGELOG](CHANGELOG.md) ### Update Policy @@ -352,7 +352,7 @@ To stay informed about security updates: ## Security Best Practices -When using {{PROJECT_NAME}}, we recommend: +When using Haec, we recommend: ### General @@ -375,7 +375,7 @@ When using {{PROJECT_NAME}}, we recommend: ## Additional Resources - [Our PGP Public Key]({{PGP_KEY_URL}}) -- [Security Advisories](https://github.com/{{OWNER}}/{{REPO}}/security/advisories) +- [Security Advisories](https://github.com/hyperpolymath/haec/security/advisories) - [Changelog](CHANGELOG.md) - [Contributing Guidelines](CONTRIBUTING.md) - [CVE Database](https://cve.mitre.org/) @@ -387,8 +387,8 @@ When using {{PROJECT_NAME}}, we recommend: | Purpose | Contact | |---------|---------| -| **Security issues** | [Report via GitHub](https://github.com/{{OWNER}}/{{REPO}}/security/advisories/new) or {{SECURITY_EMAIL}} | -| **General questions** | [GitHub Discussions](https://github.com/{{OWNER}}/{{REPO}}/discussions) | +| **Security issues** | [Report via GitHub](https://github.com/hyperpolymath/haec/security/advisories/new) or j.d.a.jewell@open.ac.uk | +| **General questions** | [GitHub Discussions](https://github.com/hyperpolymath/haec/discussions) | | **Other enquiries** | See [README](README.md) for contact information | --- @@ -403,8 +403,8 @@ This security policy may be updated from time to time. Significant changes will --- -*Thank you for helping keep {{PROJECT_NAME}} and its users safe.* 🛡️ +*Thank you for helping keep Haec and its users safe.* 🛡️ --- -Last updated: {{CURRENT_YEAR}} · Policy version: 1.0.0 +Last updated: 2026 · Policy version: 1.0.0 diff --git a/.github/SUPPORT b/.github/SUPPORT index b06c59a..c046e8f 100644 --- a/.github/SUPPORT +++ b/.github/SUPPORT @@ -2,6 +2,6 @@ For questions, help, and community discussion: -- GitHub Discussions: https://github.com/{{OWNER}}/{{REPO}}/discussions -- GitHub Issues: https://github.com/{{OWNER}}/{{REPO}}/issues +- GitHub Discussions: https://github.com/hyperpolymath/haec/discussions +- GitHub Issues: https://github.com/hyperpolymath/haec/issues - Documentation: See README.adoc in the root directory. diff --git a/.github/copilot-instructions.md b/.github/copilot-instructions.md index cd2d3fb..dfb7a0e 100644 --- a/.github/copilot-instructions.md +++ b/.github/copilot-instructions.md @@ -2,7 +2,7 @@ SPDX-License-Identifier: MPL-2.0 Copyright (c) Jonathan D.A. Jewell --> - + # Copilot Instructions @@ -16,7 +16,7 @@ Copyright (c) Jonathan D.A. Jewell - SPDX: `MPL-2.0` on all new files. - Never use AGPL-3.0. -- Copyright: `{{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}>` +- Copyright: `Jonathan D.A. Jewell (hyperpolymath) ` ## Code Style diff --git a/.github/settings.yml b/.github/settings.yml index 92306c4..3fdc06e 100644 --- a/.github/settings.yml +++ b/.github/settings.yml @@ -7,14 +7,14 @@ # applied by the probot/settings app when changes are pushed to the default # branch. Install the app at: https://github.com/apps/settings # -# Template file — replace {{REPO}} and {{DESCRIPTION}} with actual values. +# Template file — replace haec and {{DESCRIPTION}} with actual values. # ─── Repository Settings ─────────────────────────────────────────────────────── repository: - name: "{{REPO}}" + name: "haec" description: "{{DESCRIPTION}}" - homepage: "https://github.com/hyperpolymath/{{REPO}}" + homepage: "https://github.com/hyperpolymath/haec" private: false has_issues: true has_projects: true diff --git a/.machine_readable/6a2/anchors/ANCHOR.a2ml b/.machine_readable/6a2/anchors/ANCHOR.a2ml index 8723899..0ea7fd3 100644 --- a/.machine_readable/6a2/anchors/ANCHOR.a2ml +++ b/.machine_readable/6a2/anchors/ANCHOR.a2ml @@ -1,15 +1,15 @@ # SPDX-License-Identifier: MPL-2.0 -# Copyright (c) {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +# Copyright (c) 2026 Jonathan D.A. Jewell (hyperpolymath) # # ANCHOR.a2ml - authoritative anchor for this repository [metadata] version = "1.0.0" -last-updated = "{{CURRENT_DATE}}" +last-updated = "2026-06-22" [anchor] schema = "hyperpolymath.anchor/1" -repo = "{{OWNER}}/{{REPO}}" +repo = "hyperpolymath/haec" authority = "upstream-canonical" purpose = [ @@ -19,9 +19,9 @@ purpose = [ ] [identity] -project = "{{PROJECT_NAME}}" +project = "Haec" kind = "{{PROJECT_KIND}}" # language | library | service | tool -one-sentence = "{{PROJECT_PURPOSE}}" +one-sentence = "A Turing-complete language whose type discipline is trope-particularity; it lowers programs to the language-neutral Trope IR." domain = "{{PROJECT_DOMAIN}}" [semantic-authority] diff --git a/.machine_readable/ENSAID_CONFIG.a2ml b/.machine_readable/ENSAID_CONFIG.a2ml index 1384822..7aa8dec 100644 --- a/.machine_readable/ENSAID_CONFIG.a2ml +++ b/.machine_readable/ENSAID_CONFIG.a2ml @@ -1,5 +1,5 @@ # SPDX-License-Identifier: MPL-2.0 -# Copyright (c) {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +# Copyright (c) 2026 Jonathan D.A. Jewell (hyperpolymath) # # ENSAID_CONFIG.a2ml — eNSAID Environment Configuration # Per-repo configuration for PanLL and eNSAID-compatible tools. @@ -89,8 +89,8 @@ version = "1.0.0" # Example: a custom portfolio for this project # [[portfolios.custom]] -# id = "{{project}}-dev" -# name = "{{PROJECT_NAME}} Development" -# description = "Panels for {{PROJECT_NAME}} development" +# id = "haec-dev" +# name = "Haec Development" +# description = "Panels for Haec development" # panels = ["valence-shell", "editor-bridge", "build-dashboard"] # default-isolation = "native" diff --git a/.machine_readable/ai/.clinerules b/.machine_readable/ai/.clinerules index 8f38042..4818351 100644 --- a/.machine_readable/ai/.clinerules +++ b/.machine_readable/ai/.clinerules @@ -1,5 +1,5 @@ # SPDX-License-Identifier: MPL-2.0 -# Copyright (c) {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +# Copyright (c) 2026 Jonathan D.A. Jewell (hyperpolymath) # Authoritative source: docs/AI-CONVENTIONS.md # STARTUP: Read 0-AI-MANIFEST.a2ml first, then .machine_readable/6a2/STATE.a2ml. @@ -8,7 +8,7 @@ # All original code: MPL-2.0. # Never AGPL-3.0. MPL-2.0 only as platform-required fallback. # SPDX header required on every source file. -# Copyright: {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +# Copyright: Jonathan D.A. Jewell (hyperpolymath) # STATE FILES (.machine_readable/ ONLY) # Never create in repo root: STATE.a2ml, META.a2ml, ECOSYSTEM.a2ml, diff --git a/.machine_readable/ai/.cursorrules b/.machine_readable/ai/.cursorrules index c13b393..5255a80 100644 --- a/.machine_readable/ai/.cursorrules +++ b/.machine_readable/ai/.cursorrules @@ -1,5 +1,5 @@ # SPDX-License-Identifier: MPL-2.0 -# Copyright (c) {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +# Copyright (c) 2026 Jonathan D.A. Jewell (hyperpolymath) # Authoritative source: docs/AI-CONVENTIONS.md # Read 0-AI-MANIFEST.a2ml in the repo root FIRST for canonical file locations. @@ -7,7 +7,7 @@ # LICENSE # All original code: MPL-2.0 (SPDX header required on every file). # Never use AGPL-3.0. Fallback to MPL-2.0 only when platform requires it. -# Copyright: {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +# Copyright: Jonathan D.A. Jewell (hyperpolymath) # STATE FILES # .a2ml metadata files go in .machine_readable/ ONLY. diff --git a/.machine_readable/ai/.windsurfrules b/.machine_readable/ai/.windsurfrules index 8f38042..4818351 100644 --- a/.machine_readable/ai/.windsurfrules +++ b/.machine_readable/ai/.windsurfrules @@ -1,5 +1,5 @@ # SPDX-License-Identifier: MPL-2.0 -# Copyright (c) {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +# Copyright (c) 2026 Jonathan D.A. Jewell (hyperpolymath) # Authoritative source: docs/AI-CONVENTIONS.md # STARTUP: Read 0-AI-MANIFEST.a2ml first, then .machine_readable/6a2/STATE.a2ml. @@ -8,7 +8,7 @@ # All original code: MPL-2.0. # Never AGPL-3.0. MPL-2.0 only as platform-required fallback. # SPDX header required on every source file. -# Copyright: {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +# Copyright: Jonathan D.A. Jewell (hyperpolymath) # STATE FILES (.machine_readable/ ONLY) # Never create in repo root: STATE.a2ml, META.a2ml, ECOSYSTEM.a2ml, diff --git a/.machine_readable/ai/PLACEHOLDERS.adoc b/.machine_readable/ai/PLACEHOLDERS.adoc index b7073b6..fbc1682 100644 --- a/.machine_readable/ai/PLACEHOLDERS.adoc +++ b/.machine_readable/ai/PLACEHOLDERS.adoc @@ -20,16 +20,16 @@ validates the result, and runs k9-svc checks if available. ```bash # If you prefer manual replacement (run from repo root) -sed -i 's/{{AUTHOR}}/Jane Doe/g' $(grep -rl '{{AUTHOR}}' .) -sed -i 's/{{AUTHOR_EMAIL}}/jane@example.org/g' $(grep -rl '{{AUTHOR_EMAIL}}' .) -sed -i 's/{{OWNER}}/my-org/g' $(grep -rl '{{OWNER}}' .) -sed -i 's/{{PROJECT_NAME}}/my-project/g' $(grep -rl '{{PROJECT_NAME}}' .) -sed -i 's/{{PROJECT}}/MY_PROJECT/g' $(grep -rl '{{PROJECT}}' .) -sed -i 's/{{project}}/my_project/g' $(grep -rl '{{project}}' .) -sed -i 's/{{REPO}}/my-project/g' $(grep -rl '{{REPO}}' .) -sed -i 's/{{FORGE}}/github.com/g' $(grep -rl '{{FORGE}}' .) -sed -i "s/{{CURRENT_YEAR}}/$(date +%Y)/g" $(grep -rl '{{CURRENT_YEAR}}' .) -sed -i "s/{{CURRENT_DATE}}/$(date +%Y-%m-%d)/g" $(grep -rl '{{CURRENT_DATE}}' .) +sed -i 's/Jonathan D.A. Jewell/Jane Doe/g' $(grep -rl 'Jonathan D.A. Jewell' .) +sed -i 's/j.d.a.jewell@open.ac.uk/jane@example.org/g' $(grep -rl 'j.d.a.jewell@open.ac.uk' .) +sed -i 's/hyperpolymath/my-org/g' $(grep -rl 'hyperpolymath' .) +sed -i 's/Haec/my-project/g' $(grep -rl 'Haec' .) +sed -i 's/HAEC/MY_PROJECT/g' $(grep -rl 'HAEC' .) +sed -i 's/haec/my_project/g' $(grep -rl 'haec' .) +sed -i 's/haec/my-project/g' $(grep -rl 'haec' .) +sed -i 's/github.com/github.com/g' $(grep -rl 'github.com' .) +sed -i "s/2026/$(date +%Y)/g" $(grep -rl '2026' .) +sed -i "s/2026-06-22/$(date +%Y-%m-%d)/g" $(grep -rl '2026-06-22' .) ``` ## Placeholder Reference @@ -38,58 +38,58 @@ sed -i "s/{{CURRENT_DATE}}/$(date +%Y-%m-%d)/g" $(grep -rl '{{CURRENT_DATE}}' .) | Placeholder | Description | Example | Files | |---|---|---|---| -| `{{AUTHOR}}` | Full legal name | `Jane Doe` | SPDX headers (all files), MAINTAINERS.md, .mailmap, .reuse/dep5, docs/AI-CONVENTIONS.md | -| `{{AUTHOR_EMAIL}}` | Primary contact email | `jane@example.org` | SPDX headers (all files), .mailmap, .reuse/dep5, .well-known/humans.txt | -| `{{AUTHOR_EMAIL_ALT}}` | Previous/secondary email (for .mailmap) | `old@example.com` | .mailmap | -| `{{AUTHOR_ORG}}` | Author's organization/affiliation | `Acme University` | project-metadata.k9.ncl | -| `{{AUTHOR_LAST}}` | Author surname (for citations) | `Doe` | docs/CITATIONS.adoc | -| `{{AUTHOR_FIRST}}` | Author first name (for citations) | `Jane` | docs/CITATIONS.adoc | -| `{{AUTHOR_INITIALS}}` | Author initials (for citations) | `J.` | docs/CITATIONS.adoc | +| `Jonathan D.A. Jewell` | Full legal name | `Jane Doe` | SPDX headers (all files), MAINTAINERS.md, .mailmap, .reuse/dep5, docs/AI-CONVENTIONS.md | +| `j.d.a.jewell@open.ac.uk` | Primary contact email | `jane@example.org` | SPDX headers (all files), .mailmap, .reuse/dep5, .well-known/humans.txt | +| `` | Previous/secondary email (for .mailmap) | `old@example.com` | .mailmap | +| `` | Author's organization/affiliation | `Acme University` | project-metadata.k9.ncl | +| `Jewell` | Author surname (for citations) | `Doe` | docs/CITATIONS.adoc | +| `Jonathan D.A.` | Author first name (for citations) | `Jane` | docs/CITATIONS.adoc | +| `J.` | Author initials (for citations) | `J.` | docs/CITATIONS.adoc | ### Project Identity | Placeholder | Description | Example | Files | |---|---|---|---| -| `{{PROJECT_NAME}}` | Human-readable project name | `My Project` | SECURITY.md, CODE_OF_CONDUCT.md, TOPOLOGY.md, STATE.a2ml, Justfile, GOVERNANCE.md, MAINTAINERS.md, flake.nix, devcontainer.json | -| `{{PROJECT_DESCRIPTION}}` | One-line description | `A tool for X` | flake.nix | -| `{{PROJECT}}` | Uppercase identifier (for Idris2 modules, C macros) | `MY_PROJECT` | ABI-FFI-README.md, src/interface/abi/*.idr, src/interface/ffi/*.zig | -| `{{project}}` | Lowercase identifier (for C symbols, filenames) | `my_project` | ABI-FFI-README.md, src/interface/ffi/*.zig | -| `{{REPO}}` | Repository name (slug) | `my-project` | CONTRIBUTING.md, SECURITY.md, CODE_OF_CONDUCT.md, cliff.toml | -| `{{OWNER}}` | GitHub/GitLab org or username | `my-org` | SPDX headers, CONTRIBUTING.md, SECURITY.md, GOVERNANCE.md, MAINTAINERS.md, CODEOWNERS, mirror.yml, cliff.toml | -| `{{FORGE}}` | Git forge domain | `github.com` | CONTRIBUTING.md | +| `Haec` | Human-readable project name | `My Project` | SECURITY.md, CODE_OF_CONDUCT.md, TOPOLOGY.md, STATE.a2ml, Justfile, GOVERNANCE.md, MAINTAINERS.md, flake.nix, devcontainer.json | +| `A Turing-complete language whose type discipline is trope-particularity; it lowers programs to the language-neutral Trope IR.` | One-line description | `A tool for X` | flake.nix | +| `HAEC` | Uppercase identifier (for Idris2 modules, C macros) | `MY_PROJECT` | ABI-FFI-README.md, src/interface/abi/*.idr, src/interface/ffi/*.zig | +| `haec` | Lowercase identifier (for C symbols, filenames) | `my_project` | ABI-FFI-README.md, src/interface/ffi/*.zig | +| `haec` | Repository name (slug) | `my-project` | CONTRIBUTING.md, SECURITY.md, CODE_OF_CONDUCT.md, cliff.toml | +| `hyperpolymath` | GitHub/GitLab org or username | `my-org` | SPDX headers, CONTRIBUTING.md, SECURITY.md, GOVERNANCE.md, MAINTAINERS.md, CODEOWNERS, mirror.yml, cliff.toml | +| `github.com` | Git forge domain | `github.com` | CONTRIBUTING.md | ### Dates | Placeholder | Description | Example | Files | |---|---|---|---| -| `{{CURRENT_YEAR}}` | Current year | `2026` | SPDX headers (all files), GOVERNANCE.md, MAINTAINERS.md | -| `{{CURRENT_DATE}}` | Current date (ISO) | `2026-02-14` | STATE.a2ml, MAINTAINERS.md | -| `{{DATE}}` | Last updated date | `2026-02-14` | TOPOLOGY.md, THREAT-MODEL.md | +| `2026` | Current year | `2026` | SPDX headers (all files), GOVERNANCE.md, MAINTAINERS.md | +| `2026-06-22` | Current date (ISO) | `2026-02-14` | STATE.a2ml, MAINTAINERS.md | +| `2026-06-22` | Last updated date | `2026-02-14` | TOPOLOGY.md, THREAT-MODEL.md | ### Contact & Security | Placeholder | Description | Example | Files | |---|---|---|---| -| `{{SECURITY_EMAIL}}` | Security contact email | `security@example.org` | SECURITY.md | +| `j.d.a.jewell@open.ac.uk` | Security contact email | `security@example.org` | SECURITY.md | | `{{PGP_FINGERPRINT}}` | 40-char PGP fingerprint | `ABCD 1234 ...` | SECURITY.md | | `{{PGP_KEY_URL}}` | URL to public PGP key | `https://keys.openpgp.org/...` | SECURITY.md | -| `{{WEBSITE}}` | Project website | `https://example.org` | SECURITY.md | -| `{{CONDUCT_EMAIL}}` | Conduct reports email | `conduct@example.org` | CODE_OF_CONDUCT.md | -| `{{CONDUCT_TEAM}}` | Conduct committee name | `Code of Conduct Committee` | CODE_OF_CONDUCT.md | -| `{{RESPONSE_TIME}}` | SLA for initial response | `48 hours` | CODE_OF_CONDUCT.md | +| `https://github.com/hyperpolymath/haec` | Project website | `https://example.org` | SECURITY.md | +| `j.d.a.jewell@open.ac.uk` | Conduct reports email | `conduct@example.org` | CODE_OF_CONDUCT.md | +| `Code of Conduct Committee` | Conduct committee name | `Code of Conduct Committee` | CODE_OF_CONDUCT.md | +| `48 hours` | SLA for initial response | `48 hours` | CODE_OF_CONDUCT.md | ### Git | Placeholder | Description | Example | Files | |---|---|---|---| -| `{{MAIN_BRANCH}}` | Main branch name | `main` | CONTRIBUTING.md | +| `main` | Main branch name | `main` | CONTRIBUTING.md | ### Build | Placeholder | Description | Example | Files | |---|---|---|---| -| `{{LICENSE}}` | License name | `MPL-2.0` | ABI-FFI-README.md | -| `{{PROJECT_PURPOSE}}` | One-line project description | `FFI bridges between languages` | STATE.a2ml | +| `MPL-2.0` | License name | `MPL-2.0` | ABI-FFI-README.md | +| `A Turing-complete language whose type discipline is trope-particularity; it lowers programs to the language-neutral Trope IR.` | One-line project description | `FFI bridges between languages` | STATE.a2ml | ### AI Manifest diff --git a/.machine_readable/bot_directives/coverage.a2ml b/.machine_readable/bot_directives/coverage.a2ml index 1bd30fa..db2d522 100644 --- a/.machine_readable/bot_directives/coverage.a2ml +++ b/.machine_readable/bot_directives/coverage.a2ml @@ -1,5 +1,5 @@ # SPDX-License-Identifier: MPL-2.0 -# Copyright (c) {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +# Copyright (c) 2026 Jonathan D.A. Jewell (hyperpolymath) # # coverage.a2ml — Session coverage tracking # Updated at the end of each AI agent session. @@ -9,7 +9,7 @@ [metadata] version = "1.0.0" -last-updated = "{{CURRENT_DATE}}" +last-updated = "2026-06-22" # ============================================================================ # COVERAGE STATE diff --git a/.machine_readable/bot_directives/debt.a2ml b/.machine_readable/bot_directives/debt.a2ml index 3289cbe..6f98ce1 100644 --- a/.machine_readable/bot_directives/debt.a2ml +++ b/.machine_readable/bot_directives/debt.a2ml @@ -1,5 +1,5 @@ # SPDX-License-Identifier: MPL-2.0 -# Copyright (c) {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +# Copyright (c) 2026 Jonathan D.A. Jewell (hyperpolymath) # # debt.a2ml — Meander debt list # Things found but not fixed. Carried between sessions. @@ -9,7 +9,7 @@ [metadata] version = "1.0.0" -last-updated = "{{CURRENT_DATE}}" +last-updated = "2026-06-22" # ============================================================================ # DEBT ITEMS diff --git a/.machine_readable/bot_directives/methodology.a2ml b/.machine_readable/bot_directives/methodology.a2ml index a88ab49..b3dfc21 100644 --- a/.machine_readable/bot_directives/methodology.a2ml +++ b/.machine_readable/bot_directives/methodology.a2ml @@ -1,5 +1,5 @@ # SPDX-License-Identifier: MPL-2.0 -# Copyright (c) {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +# Copyright (c) 2026 Jonathan D.A. Jewell (hyperpolymath) # # methodology.a2ml — AI agent methodology configuration # Declares how agents should approach work in this repository. @@ -9,7 +9,7 @@ [metadata] version = "1.0.0" -last-updated = "{{CURRENT_DATE}}" +last-updated = "2026-06-22" spec = "https://github.com/hyperpolymath/standards/blob/main/agentic-a2ml/docs/ADR-002-methodology-layer.adoc" # ============================================================================ @@ -101,7 +101,7 @@ constraints = [ # These rules detect corrupt/template/stale state files. [methodology.state-validation] -reject-if-contains = ["{{PLACEHOLDER}}", "{{PROJECT}}", "rsr-template-repo"] +reject-if-contains = ["{{PLACEHOLDER}}", "HAEC", "rsr-template-repo"] reject-if-project-name-mismatch = true staleness-threshold-days = 90 fallback-files = ["TODO.md", "TODO.adoc", "ROADMAP.adoc", "README.adoc"] diff --git a/.machine_readable/compliance/reuse/dep5 b/.machine_readable/compliance/reuse/dep5 index 49aaed6..641472f 100644 --- a/.machine_readable/compliance/reuse/dep5 +++ b/.machine_readable/compliance/reuse/dep5 @@ -1,54 +1,54 @@ Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ -Upstream-Name: {{PROJECT_NAME}} -Upstream-Contact: {{AUTHOR}} <{{AUTHOR_EMAIL}}> -Source: https://github.com/{{OWNER}}/{{REPO}} +Upstream-Name: Haec +Upstream-Contact: Jonathan D.A. Jewell +Source: https://github.com/hyperpolymath/haec # Default: all files are MPL-2.0 Files: * -Copyright: {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +Copyright: 2026 Jonathan D.A. Jewell (hyperpolymath) License: MPL-2.0 # Configuration files that cannot carry headers Files: .editorconfig .gitignore .gitattributes .tool-versions .mailmap -Copyright: {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +Copyright: 2026 Jonathan D.A. Jewell (hyperpolymath) License: MPL-2.0 # Machine-readable state files Files: .machine_readable/*.a2ml -Copyright: {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +Copyright: 2026 Jonathan D.A. Jewell (hyperpolymath) License: MPL-2.0 # Bot directives Files: .machine_readable/bot_directives/* -Copyright: {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +Copyright: 2026 Jonathan D.A. Jewell (hyperpolymath) License: MPL-2.0 # Contractiles Files: .machine_readable/contractiles/* -Copyright: {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +Copyright: 2026 Jonathan D.A. Jewell (hyperpolymath) License: MPL-2.0 # GitHub/CI configuration Files: .github/* .github/**/* -Copyright: {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +Copyright: 2026 Jonathan D.A. Jewell (hyperpolymath) License: MPL-2.0 # Generated files Files: generated/* -Copyright: {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +Copyright: 2026 Jonathan D.A. Jewell (hyperpolymath) License: MPL-2.0 # Lockfiles and auto-generated Files: *.lock Cargo.lock flake.lock -Copyright: {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +Copyright: 2026 Jonathan D.A. Jewell (hyperpolymath) License: MPL-2.0 # Devcontainer config (JSON, no comments) Files: .devcontainer/*.json -Copyright: {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +Copyright: 2026 Jonathan D.A. Jewell (hyperpolymath) License: MPL-2.0 # Git-cliff config Files: cliff.toml -Copyright: {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +Copyright: 2026 Jonathan D.A. Jewell (hyperpolymath) License: MPL-2.0 diff --git a/.machine_readable/configs/eclexiaiser.toml b/.machine_readable/configs/eclexiaiser.toml index abc542e..4ad59b6 100644 --- a/.machine_readable/configs/eclexiaiser.toml +++ b/.machine_readable/configs/eclexiaiser.toml @@ -2,7 +2,7 @@ # SPDX-License-Identifier: MPL-2.0 [project] -name = "{{REPO}}" +name = "haec" [[functions]] name = "build" diff --git a/.machine_readable/configs/git-cliff/cliff.toml b/.machine_readable/configs/git-cliff/cliff.toml index 5c39b48..86d3efc 100644 --- a/.machine_readable/configs/git-cliff/cliff.toml +++ b/.machine_readable/configs/git-cliff/cliff.toml @@ -1,12 +1,12 @@ # SPDX-License-Identifier: MPL-2.0 -# Copyright (c) {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +# Copyright (c) 2026 Jonathan D.A. Jewell (hyperpolymath) # # git-cliff configuration for conventional commit changelog generation. # https://git-cliff.org/docs/configuration # # Placeholders — replace before first use: -# {{OWNER}} — GitHub organization or username -# {{REPO}} — GitHub repository name +# hyperpolymath — GitHub organization or username +# haec — GitHub repository name [changelog] # Changelog header @@ -21,7 +21,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 # https://keats.github.io/tera/docs/#introduction body = """ {%- macro remote_url() -%} - https://github.com/{{OWNER}}/{{REPO}} + https://github.com/hyperpolymath/haec {%- endmacro -%} {% if version -%} @@ -57,7 +57,7 @@ body = """ # Template for the changelog footer footer = """ {%- macro remote_url() -%} - https://github.com/{{OWNER}}/{{REPO}} + https://github.com/hyperpolymath/haec {%- endmacro -%} {% for release in releases -%} diff --git a/.machine_readable/configs/selur-compose.toml b/.machine_readable/configs/selur-compose.toml index e7f831a..6394b36 100644 --- a/.machine_readable/configs/selur-compose.toml +++ b/.machine_readable/configs/selur-compose.toml @@ -1,14 +1,14 @@ # SPDX-License-Identifier: MPL-2.0 # Copyright (c) 2026 Jonathan D.A. Jewell (hyperpolymath) # -# Stapeln service definition for {{SERVICE_NAME}} +# Stapeln service definition for haec # # Usage: # podman-compose -f selur-compose.toml up -d # just stack-up [project] -name = "{{SERVICE_NAME}}" +name = "haec" [services.app] build = { context = ".", dockerfile = "Containerfile" } diff --git a/.machine_readable/configs/stapeln.toml b/.machine_readable/configs/stapeln.toml index 7bf5d48..aa3e923 100644 --- a/.machine_readable/configs/stapeln.toml +++ b/.machine_readable/configs/stapeln.toml @@ -1,16 +1,16 @@ # SPDX-License-Identifier: MPL-2.0 -# stapeln.toml — Layer-based container build for {{SERVICE_NAME}} +# stapeln.toml — Layer-based container build for haec # # stapeln builds containers as composable layers (German: "to stack"). # Each layer is independently cacheable, verifiable, and signable. [metadata] -name = "{{SERVICE_NAME}}" +name = "haec" version = "0.1.0" -description = "{{SERVICE_NAME}} container service" +description = "haec container service" author = "Jonathan D.A. Jewell " license = "MPL-2.0" -registry = "{{REGISTRY}}" +registry = "ghcr.io/hyperpolymath" [build] containerfile = "Containerfile" @@ -32,7 +32,7 @@ packages = [] cache = true [layers.build] -description = "{{SERVICE_NAME}} build" +description = "haec build" extends = "toolchain" commands = [] @@ -43,7 +43,7 @@ packages = ["ca-certificates", "curl"] copy-from = [ { layer = "build", src = "/app/", dst = "/app/" }, ] -entrypoint = ["/app/{{SERVICE_NAME}}"] +entrypoint = ["/app/haec"] user = "nonroot" # ── Security ─────────────────────────────────────────────────── diff --git a/.machine_readable/contractiles/Justfile b/.machine_readable/contractiles/Justfile index 2db3d94..42bd1bb 100644 --- a/.machine_readable/contractiles/Justfile +++ b/.machine_readable/contractiles/Justfile @@ -48,7 +48,7 @@ help recipe="": # Show this project's info info: - @echo "Project: {{project}}" + @echo "Project: haec" @echo "Version: {{version}}" @echo "RSR Tier: {{tier}}" @echo "Recipes: $(just --summary | wc -w)" @@ -82,7 +82,7 @@ import? "build/just/assess.just" # Build the project (debug mode) build *args: - @echo "Building {{project}} (debug)..." + @echo "Building haec (debug)..." # TODO: Replace with your build command # Examples: # cargo build {{args}} # Rust @@ -93,7 +93,7 @@ build *args: # Build in release mode with optimizations build-release *args: - @echo "Building {{project}} (release)..." + @echo "Building haec (release)..." # TODO: Replace with your release build command # Examples: # cargo build --release {{args}} @@ -268,7 +268,7 @@ run-verbose *args: build # Install to user path install: build-release - @echo "Installing {{project}}..." + @echo "Installing haec..." # TODO: Replace with your install command # ═══════════════════════════════════════════════════════════════════════════════ @@ -311,7 +311,7 @@ cookbook: #!/usr/bin/env bash mkdir -p docs OUTPUT="docs/just-cookbook.adoc" - echo "= {{project}} Justfile Cookbook" > "$OUTPUT" + echo "= haec Justfile Cookbook" > "$OUTPUT" echo ":toc: left" >> "$OUTPUT" echo ":toclevels: 3" >> "$OUTPUT" echo "" >> "$OUTPUT" @@ -337,10 +337,10 @@ cookbook: man: #!/usr/bin/env bash mkdir -p docs/man - cat > docs/man/{{project}}.1 << EOF - .TH {{project}} 1 "$(date +%Y-%m-%d)" "{{version}}" "{{project}} Manual" + cat > docs/man/haec.1 << EOF + .TH haec 1 "$(date +%Y-%m-%d)" "{{version}}" "haec Manual" .SH NAME - {{project}} \- RSR-compliant project + haec \- RSR-compliant project .SH SYNOPSIS .B just [recipe] [args...] @@ -349,7 +349,7 @@ man: .SH AUTHOR $(git config user.name 2>/dev/null || echo "Author") <$(git config user.email 2>/dev/null || echo "email")> EOF - echo "Generated: docs/man/{{project}}.1" + echo "Generated: docs/man/haec.1" # ═══════════════════════════════════════════════════════════════════════════════ # CONTAINERS (stapeln ecosystem — Podman + Chainguard Wolfi) @@ -379,14 +379,14 @@ container-init: fi # Prompt for container-specific values - read -rp "Service name (e.g. my-api) [{{project}}]: " _SERVICE_NAME - SERVICE_NAME="${_SERVICE_NAME:-{{project}}}" + read -rp "Service name (e.g. my-api) [haec]: " _SERVICE_NAME + SERVICE_NAME="${_SERVICE_NAME:-haec}" read -rp "Primary port [8080]: " _PORT PORT="${_PORT:-8080}" - read -rp "Container registry [ghcr.io/${OWNER:-{{OWNER}}}]: " _REGISTRY - REGISTRY="${_REGISTRY:-ghcr.io/${OWNER:-{{OWNER}}}}" + read -rp "Container registry [ghcr.io/${OWNER:-hyperpolymath}]: " _REGISTRY + REGISTRY="${_REGISTRY:-ghcr.io/${OWNER:-hyperpolymath}}" echo "" echo " Service: $SERVICE_NAME" @@ -429,11 +429,11 @@ container-build *args: if [ -f "container/ct-build.sh" ]; then cd container && ./ct-build.sh {{args}} elif [ -f "container/Containerfile" ]; then - podman build -t {{project}}:latest -f container/Containerfile . + podman build -t haec:latest -f container/Containerfile . elif [ -f "build/Containerfile" ]; then - podman build -t {{project}}:latest -f build/Containerfile . + podman build -t haec:latest -f build/Containerfile . elif [ -f "Containerfile" ]; then - podman build -t {{project}}:latest -f Containerfile . + podman build -t haec:latest -f Containerfile . else echo "No Containerfile found in container/, build/, or project root" exit 1 @@ -495,12 +495,12 @@ container-push: cd container && ./ct-build.sh --push else echo "No container/ct-build.sh found — falling back to podman push" - podman push {{project}}:latest + podman push haec:latest fi # Run container interactively (for debugging) container-run *args: - podman run --rm -it {{project}}:latest {{args}} + podman run --rm -it haec:latest {{args}} # ═══════════════════════════════════════════════════════════════════════════════ # CI & AUTOMATION @@ -601,7 +601,7 @@ test-matrix suite="unit" verbosity="normal" parallel="true": @echo "Test matrix: suite={{suite}} verbosity={{verbosity}} parallel={{parallel}}" # Container matrix: [build|run|push|shell|scan] x [registry] x [tag] -container-matrix action="build" registry="ghcr.io/{{OWNER}}" tag="latest": +container-matrix action="build" registry="ghcr.io/hyperpolymath" tag="latest": @echo "Container matrix: action={{action}} registry={{registry}} tag={{tag}}" # CI matrix: [lint|test|build|security|all] x [quick|full] diff --git a/.machine_readable/contractiles/dust/Dustfile.a2ml b/.machine_readable/contractiles/dust/Dustfile.a2ml index c6bf986..5c50854 100644 --- a/.machine_readable/contractiles/dust/Dustfile.a2ml +++ b/.machine_readable/contractiles/dust/Dustfile.a2ml @@ -54,7 +54,7 @@ to new repositories. - description: No references to rsr-template-repo in generic template files - run: test -z "$(grep -r 'rsr-template-repo' machine-readable-design/ 2>/dev/null)" - severity: warning -- notes: Generic templates should use {{PROJECT_NAME}} or similar placeholders +- notes: Generic templates should use Haec or similar placeholders ### version-sync-checked - description: Version in canonical-directory-structure matches .machine_readable/contractiles diff --git a/.machine_readable/integrations/groove.a2ml b/.machine_readable/integrations/groove.a2ml index ea3fb8b..278515a 100644 --- a/.machine_readable/integrations/groove.a2ml +++ b/.machine_readable/integrations/groove.a2ml @@ -9,8 +9,8 @@ (groove-manifest (version "1.0") - ; Service identity — replace {{REPO}} with your project name - (service "{{REPO}}") + ; Service identity — replace haec with your project name + (service "haec") (service-version "0.1.0") ; Primary port — MUST be unique across the ecosystem. diff --git a/.machine_readable/policies/MAINTENANCE-AXES.a2ml b/.machine_readable/policies/MAINTENANCE-AXES.a2ml index c251de6..a287951 100644 --- a/.machine_readable/policies/MAINTENANCE-AXES.a2ml +++ b/.machine_readable/policies/MAINTENANCE-AXES.a2ml @@ -1,11 +1,11 @@ # SPDX-License-Identifier: MPL-2.0 -# Copyright (c) {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +# Copyright (c) 2026 Jonathan D.A. Jewell (hyperpolymath) # # Canonical maintenance governance model [metadata] version = "1.0.0" -last-updated = "{{CURRENT_DATE}}" +last-updated = "2026-06-22" scope = "repo" [discovery] diff --git a/.machine_readable/root-allow.txt b/.machine_readable/root-allow.txt index 2436e1c..4f1bc0b 100644 --- a/.machine_readable/root-allow.txt +++ b/.machine_readable/root-allow.txt @@ -64,3 +64,9 @@ container/ # may host Containerfile if not at build/ .pre-commit-config.yaml # TODO: relocate to ci/.pre-commit-config.yaml after invocation pattern decided affinescript/ # AffineScript source subtree consumed by this template tools/ # TODO: consolidate with scripts/ or document the split (pending decision) + +# ─── Haec (trope front-end) additions (build brief, 2026-06-22) ────────────── +design/ # surface grammar, elaboration table, vendored IR schema +compiler/ # planned: parser/type-checker/elaborator/codegen (STATUS.adoc) +lsp/ # planned: editor support (STATUS.adoc) +LICENSES/ # REUSE texts: MPL-2.0 (code) + CC-BY-SA-4.0 (prose docs) diff --git a/.machine_readable/scripts/maintenance/maint-assault.sh b/.machine_readable/scripts/maintenance/maint-assault.sh index f170cab..014fa97 100644 --- a/.machine_readable/scripts/maintenance/maint-assault.sh +++ b/.machine_readable/scripts/maintenance/maint-assault.sh @@ -8,7 +8,7 @@ set -euo pipefail -BINARY_NAME="{{project}}" +BINARY_NAME="haec" REPORT_PATH="docs/reports/security/assault-latest.json" PA_BIN="${PANIC_ATTACK_BIN:-panic-attack}" diff --git a/.machine_readable/self-validating/README.adoc b/.machine_readable/self-validating/README.adoc index 44a538f..3be2b8a 100644 --- a/.machine_readable/self-validating/README.adoc +++ b/.machine_readable/self-validating/README.adoc @@ -131,7 +131,7 @@ K9 contractiles integrate with other RSR standards: ⚠️ **Never run as root unless required** + ⚠️ **Sandbox external components** -**See:** https://github.com/{{OWNER}}/k9-svc/blob/main/docs/SECURITY-BEST-PRACTICES.adoc +**See:** https://github.com/hyperpolymath/k9-svc/blob/main/docs/SECURITY-BEST-PRACTICES.adoc == Template Files @@ -155,14 +155,14 @@ chmod +x nickel && sudo mv nickel /usr/local/bin/ cargo install just # Clone K9-SVC (for must shim and tooling) -git clone https://github.com/{{OWNER}}/k9-svc.git +git clone https://github.com/hyperpolymath/k9-svc.git ---- == Learn More -- **K9-SVC Specification:** https://github.com/{{OWNER}}/k9-svc/blob/main/SPEC.adoc -- **K9 User Guide:** https://github.com/{{OWNER}}/k9-svc/blob/main/GUIDE.adoc -- **Security Documentation:** https://github.com/{{OWNER}}/k9-svc/blob/main/docs/SECURITY-FAQ.adoc +- **K9-SVC Specification:** https://github.com/hyperpolymath/k9-svc/blob/main/SPEC.adoc +- **K9 User Guide:** https://github.com/hyperpolymath/k9-svc/blob/main/GUIDE.adoc +- **Security Documentation:** https://github.com/hyperpolymath/k9-svc/blob/main/docs/SECURITY-FAQ.adoc - **IANA Media Type:** `application/vnd.k9+nickel` == Contributing @@ -175,4 +175,4 @@ When adding K9 contractiles to your repository: 4. Sign Hunt-level components before committing 5. Add K9 validation to CI/CD pipeline -**Questions?** Open an issue on https://github.com/{{OWNER}}/k9-svc +**Questions?** Open an issue on https://github.com/hyperpolymath/k9-svc diff --git a/.machine_readable/self-validating/examples/ci-config.k9.ncl b/.machine_readable/self-validating/examples/ci-config.k9.ncl index 1f38e2d..9fe314e 100644 --- a/.machine_readable/self-validating/examples/ci-config.k9.ncl +++ b/.machine_readable/self-validating/examples/ci-config.k9.ncl @@ -19,7 +19,7 @@ K9! name = "ci-config", version = "1.0.0", description = "CI/CD configuration with runtime validation", - author = "{{AUTHOR}} <{{AUTHOR_EMAIL}}>", + author = "Jonathan D.A. Jewell ", }, }, diff --git a/.machine_readable/self-validating/examples/project-metadata.k9.ncl b/.machine_readable/self-validating/examples/project-metadata.k9.ncl index c8e6ebf..5de965d 100644 --- a/.machine_readable/self-validating/examples/project-metadata.k9.ncl +++ b/.machine_readable/self-validating/examples/project-metadata.k9.ncl @@ -19,7 +19,7 @@ K9! name = "project-metadata", version = "1.0.0", description = "Pure data configuration for project metadata", - author = "{{AUTHOR}} <{{AUTHOR_EMAIL}}>", + author = "Jonathan D.A. Jewell ", }, }, @@ -30,14 +30,14 @@ K9! description = "A project following Rhodium Standard Repositories", repository = { - url = "https://github.com/{{OWNER}}/my-project", + url = "https://github.com/hyperpolymath/my-project", type = "git", }, author = { - name = "{{AUTHOR}}", - email = "{{AUTHOR_EMAIL}}", - organization = "{{AUTHOR_ORG}}", + name = "Jonathan D.A. Jewell", + email = "j.d.a.jewell@open.ac.uk", + organization = "", }, license = "MPL-2.0", @@ -45,7 +45,7 @@ K9! keywords = [ "rhodium-standard", "rsr", - "{{OWNER}}", + "hyperpolymath", ], }, diff --git a/.machine_readable/self-validating/examples/setup-repo.k9.ncl b/.machine_readable/self-validating/examples/setup-repo.k9.ncl index df79a55..d1fc8bb 100644 --- a/.machine_readable/self-validating/examples/setup-repo.k9.ncl +++ b/.machine_readable/self-validating/examples/setup-repo.k9.ncl @@ -20,7 +20,7 @@ K9! name = "setup-repo", version = "1.0.0", description = "Automated repository setup with RSR standards", - author = "{{AUTHOR}} <{{AUTHOR_EMAIL}}>", + author = "Jonathan D.A. Jewell ", }, warnings = [ "This component has full system access", @@ -104,8 +104,8 @@ K9! description = "Initialize Git repository", commands = [ "git init -b %{config.git.default_branch}", - "git config user.name '{{AUTHOR}}'", - "git config user.email '{{AUTHOR_EMAIL}}'", + "git config user.name 'Jonathan D.A. Jewell'", + "git config user.email 'j.d.a.jewell@open.ac.uk'", "echo '✓ Git initialized'", ], }, @@ -132,7 +132,7 @@ K9! "add-license" = { description = "Add PMPL-1.0 license", commands = [ - "curl -sL https://raw.githubusercontent.com/{{OWNER}}/pmpl/main/LICENSE -o LICENSE", + "curl -sL https://raw.githubusercontent.com/hyperpolymath/pmpl/main/LICENSE -o LICENSE", "echo '✓ License added'", ], }, diff --git a/.machine_readable/self-validating/methodology-guard.k9.ncl b/.machine_readable/self-validating/methodology-guard.k9.ncl index 4c43325..17f1409 100644 --- a/.machine_readable/self-validating/methodology-guard.k9.ncl +++ b/.machine_readable/self-validating/methodology-guard.k9.ncl @@ -1,5 +1,5 @@ # SPDX-License-Identifier: MPL-2.0 -# Copyright (c) {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +# Copyright (c) 2026 Jonathan D.A. Jewell (hyperpolymath) # # K9 Validator: Methodology Guard # Checks that agent work respects methodology constraints declared in diff --git a/.machine_readable/self-validating/template-hunt.k9.ncl b/.machine_readable/self-validating/template-hunt.k9.ncl index a9cc350..b3fcb47 100644 --- a/.machine_readable/self-validating/template-hunt.k9.ncl +++ b/.machine_readable/self-validating/template-hunt.k9.ncl @@ -20,7 +20,7 @@ K9! name = "TODO: component-name", version = "1.0.0", description = "TODO: Detailed description of what this component does", - author = "{{AUTHOR}} <{{AUTHOR_EMAIL}}>", + author = "Jonathan D.A. Jewell ", }, warnings = [ "This component has full system access", diff --git a/.machine_readable/self-validating/template-kennel.k9.ncl b/.machine_readable/self-validating/template-kennel.k9.ncl index fa7e3f3..4228b26 100644 --- a/.machine_readable/self-validating/template-kennel.k9.ncl +++ b/.machine_readable/self-validating/template-kennel.k9.ncl @@ -19,7 +19,7 @@ K9! name = "TODO: component-name", version = "1.0.0", description = "TODO: Brief description of what this component contains", - author = "{{AUTHOR}} <{{AUTHOR_EMAIL}}>", + author = "Jonathan D.A. Jewell ", }, }, diff --git a/.machine_readable/self-validating/template-yard.k9.ncl b/.machine_readable/self-validating/template-yard.k9.ncl index 358671c..a723f5a 100644 --- a/.machine_readable/self-validating/template-yard.k9.ncl +++ b/.machine_readable/self-validating/template-yard.k9.ncl @@ -19,7 +19,7 @@ K9! name = "TODO: component-name", version = "1.0.0", description = "TODO: Brief description with validation details", - author = "{{AUTHOR}} <{{AUTHOR_EMAIL}}>", + author = "Jonathan D.A. Jewell ", }, }, diff --git a/.well-known/humans.txt b/.well-known/humans.txt index e062f4b..a373ac0 100644 --- a/.well-known/humans.txt +++ b/.well-known/humans.txt @@ -2,12 +2,12 @@ # humanstxt.org /* TEAM */ -Maintainer: {{AUTHOR}} ({{OWNER}}) -Contact: {{AUTHOR_EMAIL}} +Maintainer: Jonathan D.A. Jewell (hyperpolymath) +Contact: j.d.a.jewell@open.ac.uk From: United Kingdom /* SITE */ -Last update: {{CURRENT_DATE}} +Last update: 2026-06-22 Standards: RSR (Rhodium Standard Repository) License: MPL-2.0 (Palimpsest MPL) Components: Idris2 ABI, Zig FFI diff --git a/.well-known/security.txt b/.well-known/security.txt index 5414d50..49cc446 100644 --- a/.well-known/security.txt +++ b/.well-known/security.txt @@ -2,10 +2,10 @@ # RFC 9116 - security.txt # https://securitytxt.org/ -Contact: mailto:{{SECURITY_EMAIL}} -Expires: {{CURRENT_YEAR}}-12-31T23:59:59.000Z +Contact: mailto:j.d.a.jewell@open.ac.uk +Expires: 2026-12-31T23:59:59.000Z Encryption: {{PGP_KEY_URL}} Preferred-Languages: en -Canonical: https://{{FORGE}}/{{OWNER}}/{{REPO}}/.well-known/security.txt -Policy: https://{{FORGE}}/{{OWNER}}/{{REPO}}/blob/main/SECURITY.md -Hiring: https://{{WEBSITE}}/careers +Canonical: https://github.com/hyperpolymath/haec/.well-known/security.txt +Policy: https://github.com/hyperpolymath/haec/blob/main/SECURITY.md +Hiring: https://https://github.com/hyperpolymath/haec/careers diff --git a/0-AI-MANIFEST.a2ml b/0-AI-MANIFEST.a2ml index 68aad8c..cdc1c83 100644 --- a/0-AI-MANIFEST.a2ml +++ b/0-AI-MANIFEST.a2ml @@ -5,11 +5,11 @@ # [metadata] version = "0.1.0" -last-updated = "{{CURRENT_DATE}}" +last-updated = "2026-06-22" [project] -name = "[YOUR-REPO-NAME]" -purpose = "{{PROJECT_DESCRIPTION}}" +name = "Haec" +purpose = "A Turing-complete language whose type discipline is trope-particularity; it lowers programs to the language-neutral Trope IR." [ai-allocation] agents = [ diff --git a/Justfile b/Justfile index 9b2f200..4cdfa99 100644 --- a/Justfile +++ b/Justfile @@ -17,11 +17,12 @@ set positional-arguments := true # Import auto-generated contractile recipes (must-check, trust-verify, etc.) # Re-generate with: contractile gen-just import? "build/contractile.just" +import? "build/just/trope.just" # Project metadata — customize these -project := "rsr-template-repo" +project := "haec" OWNER := "hyperpolymath" -REPO := "rsr-template-repo" +REPO := "haec" version := "0.1.0" tier := "infrastructure" # 1 | 2 | infrastructure @@ -48,7 +49,7 @@ help recipe="": # Show this project's info info: - @echo "Project: {{project}}" + @echo "Project: haec" @echo "Version: {{version}}" @echo "RSR Tier: {{tier}}" @echo "Recipes: $(just --summary | wc -w)" @@ -82,7 +83,7 @@ import? "build/just/assess.just" # Build the project (debug mode) build *args: - @echo "Building {{project}} (debug)..." + @echo "Building haec (debug)..." # TODO: Replace with your build command # Examples: # cargo build {{args}} # Rust @@ -93,7 +94,7 @@ build *args: # Build in release mode with optimizations build-release *args: - @echo "Building {{project}} (release)..." + @echo "Building haec (release)..." # TODO: Replace with your release build command # Examples: # cargo build --release {{args}} @@ -268,7 +269,7 @@ run-verbose *args: build # Install to user path install: build-release - @echo "Installing {{project}}..." + @echo "Installing haec..." # TODO: Replace with your install command # ═══════════════════════════════════════════════════════════════════════════════ @@ -311,7 +312,7 @@ cookbook: #!/usr/bin/env bash mkdir -p docs OUTPUT="docs/just-cookbook.adoc" - echo "= {{project}} Justfile Cookbook" > "$OUTPUT" + echo "= haec Justfile Cookbook" > "$OUTPUT" echo ":toc: left" >> "$OUTPUT" echo ":toclevels: 3" >> "$OUTPUT" echo "" >> "$OUTPUT" @@ -337,10 +338,10 @@ cookbook: man: #!/usr/bin/env bash mkdir -p docs/man - cat > docs/man/{{project}}.1 << EOF - .TH {{project}} 1 "$(date +%Y-%m-%d)" "{{version}}" "{{project}} Manual" + cat > docs/man/haec.1 << EOF + .TH haec 1 "$(date +%Y-%m-%d)" "{{version}}" "haec Manual" .SH NAME - {{project}} \- RSR-compliant project + haec \- RSR-compliant project .SH SYNOPSIS .B just [recipe] [args...] @@ -349,7 +350,7 @@ man: .SH AUTHOR $(git config user.name 2>/dev/null || echo "Author") <$(git config user.email 2>/dev/null || echo "email")> EOF - echo "Generated: docs/man/{{project}}.1" + echo "Generated: docs/man/haec.1" # ═══════════════════════════════════════════════════════════════════════════════ # CONTAINERS (stapeln ecosystem — Podman + Chainguard Wolfi) @@ -379,14 +380,14 @@ container-init: fi # Prompt for container-specific values - read -rp "Service name (e.g. my-api) [{{project}}]: " _SERVICE_NAME - SERVICE_NAME="${_SERVICE_NAME:-{{project}}}" + read -rp "Service name (e.g. my-api) [haec]: " _SERVICE_NAME + SERVICE_NAME="${_SERVICE_NAME:-haec}" read -rp "Primary port [8080]: " _PORT PORT="${_PORT:-8080}" - read -rp "Container registry [ghcr.io/${OWNER:-{{OWNER}}}]: " _REGISTRY - REGISTRY="${_REGISTRY:-ghcr.io/${OWNER:-{{OWNER}}}}" + read -rp "Container registry [ghcr.io/${OWNER:-hyperpolymath}]: " _REGISTRY + REGISTRY="${_REGISTRY:-ghcr.io/${OWNER:-hyperpolymath}}" echo "" echo " Service: $SERVICE_NAME" @@ -429,11 +430,11 @@ container-build *args: if [ -f "container/ct-build.sh" ]; then cd container && ./ct-build.sh {{args}} elif [ -f "container/Containerfile" ]; then - podman build -t {{project}}:latest -f container/Containerfile . + podman build -t haec:latest -f container/Containerfile . elif [ -f "build/Containerfile" ]; then - podman build -t {{project}}:latest -f build/Containerfile . + podman build -t haec:latest -f build/Containerfile . elif [ -f "Containerfile" ]; then - podman build -t {{project}}:latest -f Containerfile . + podman build -t haec:latest -f Containerfile . else echo "No Containerfile found in container/, build/, or project root" exit 1 @@ -495,12 +496,12 @@ container-push: cd container && ./ct-build.sh --push else echo "No container/ct-build.sh found — falling back to podman push" - podman push {{project}}:latest + podman push haec:latest fi # Run container interactively (for debugging) container-run *args: - podman run --rm -it {{project}}:latest {{args}} + podman run --rm -it haec:latest {{args}} # ═══════════════════════════════════════════════════════════════════════════════ # CI & AUTOMATION @@ -601,7 +602,7 @@ test-matrix suite="unit" verbosity="normal" parallel="true": @echo "Test matrix: suite={{suite}} verbosity={{verbosity}} parallel={{parallel}}" # Container matrix: [build|run|push|shell|scan] x [registry] x [tag] -container-matrix action="build" registry="ghcr.io/{{OWNER}}" tag="latest": +container-matrix action="build" registry="ghcr.io/hyperpolymath" tag="latest": @echo "Container matrix: action={{action}} registry={{registry}} tag={{tag}}" # CI matrix: [lint|test|build|security|all] x [quick|full] diff --git a/LICENSES/CC-BY-SA-4.0.txt b/LICENSES/CC-BY-SA-4.0.txt new file mode 100644 index 0000000..835a683 --- /dev/null +++ b/LICENSES/CC-BY-SA-4.0.txt @@ -0,0 +1,170 @@ +Creative Commons Attribution-ShareAlike 4.0 International + + Creative Commons Corporation (“Creative Commons”) is not a law firm and does not provide legal services or legal advice. Distribution of Creative Commons public licenses does not create a lawyer-client or other relationship. Creative Commons makes its licenses and related information available on an “as-is” basis. Creative Commons gives no warranties regarding its licenses, any material licensed under their terms and conditions, or any related information. Creative Commons disclaims all liability for damages resulting from their use to the fullest extent possible. + +Using Creative Commons Public Licenses + +Creative Commons public licenses provide a standard set of terms and conditions that creators and other rights holders may use to share original works of authorship and other material subject to copyright and certain other rights specified in the public license below. The following considerations are for informational purposes only, are not exhaustive, and do not form part of our licenses. + +Considerations for licensors: Our public licenses are intended for use by those authorized to give the public permission to use material in ways otherwise restricted by copyright and certain other rights. Our licenses are irrevocable. Licensors should read and understand the terms and conditions of the license they choose before applying it. Licensors should also secure all rights necessary before applying our licenses so that the public can reuse the material as expected. Licensors should clearly mark any material not subject to the license. This includes other CC-licensed material, or material used under an exception or limitation to copyright. More considerations for licensors. + +Considerations for the public: By using one of our public licenses, a licensor grants the public permission to use the licensed material under specified terms and conditions. If the licensor’s permission is not necessary for any reason–for example, because of any applicable exception or limitation to copyright–then that use is not regulated by the license. Our licenses grant only permissions under copyright and certain other rights that a licensor has authority to grant. Use of the licensed material may still be restricted for other reasons, including because others have copyright or other rights in the material. A licensor may make special requests, such as asking that all changes be marked or described. + +Although not required by our licenses, you are encouraged to respect those requests where reasonable. More considerations for the public. + +Creative Commons Attribution-ShareAlike 4.0 International Public License + +By exercising the Licensed Rights (defined below), You accept and agree to be bound by the terms and conditions of this Creative Commons Attribution-ShareAlike 4.0 International Public License ("Public License"). To the extent this Public License may be interpreted as a contract, You are granted the Licensed Rights in consideration of Your acceptance of these terms and conditions, and the Licensor grants You such rights in consideration of benefits the Licensor receives from making the Licensed Material available under these terms and conditions. + +Section 1 – Definitions. + + a. Adapted Material means material subject to Copyright and Similar Rights that is derived from or based upon the Licensed Material and in which the Licensed Material is translated, altered, arranged, transformed, or otherwise modified in a manner requiring permission under the Copyright and Similar Rights held by the Licensor. For purposes of this Public License, where the Licensed Material is a musical work, performance, or sound recording, Adapted Material is always produced where the Licensed Material is synched in timed relation with a moving image. + + b. Adapter's License means the license You apply to Your Copyright and Similar Rights in Your contributions to Adapted Material in accordance with the terms and conditions of this Public License. + + c. BY-SA Compatible License means a license listed at creativecommons.org/compatiblelicenses, approved by Creative Commons as essentially the equivalent of this Public License. + + d. Copyright and Similar Rights means copyright and/or similar rights closely related to copyright including, without limitation, performance, broadcast, sound recording, and Sui Generis Database Rights, without regard to how the rights are labeled or categorized. For purposes of this Public License, the rights specified in Section 2(b)(1)-(2) are not Copyright and Similar Rights. + + e. Effective Technological Measures means those measures that, in the absence of proper authority, may not be circumvented under laws fulfilling obligations under Article 11 of the WIPO Copyright Treaty adopted on December 20, 1996, and/or similar international agreements. + + f. Exceptions and Limitations means fair use, fair dealing, and/or any other exception or limitation to Copyright and Similar Rights that applies to Your use of the Licensed Material. + + g. License Elements means the license attributes listed in the name of a Creative Commons Public License. The License Elements of this Public License are Attribution and ShareAlike. + + h. Licensed Material means the artistic or literary work, database, or other material to which the Licensor applied this Public License. + + i. Licensed Rights means the rights granted to You subject to the terms and conditions of this Public License, which are limited to all Copyright and Similar Rights that apply to Your use of the Licensed Material and that the Licensor has authority to license. + + j. Licensor means the individual(s) or entity(ies) granting rights under this Public License. + + k. Share means to provide material to the public by any means or process that requires permission under the Licensed Rights, such as reproduction, public display, public performance, distribution, dissemination, communication, or importation, and to make material available to the public including in ways that members of the public may access the material from a place and at a time individually chosen by them. + + l. Sui Generis Database Rights means rights other than copyright resulting from Directive 96/9/EC of the European Parliament and of the Council of 11 March 1996 on the legal protection of databases, as amended and/or succeeded, as well as other essentially equivalent rights anywhere in the world. + + m. You means the individual or entity exercising the Licensed Rights under this Public License. Your has a corresponding meaning. + +Section 2 – Scope. + + a. License grant. + + 1. Subject to the terms and conditions of this Public License, the Licensor hereby grants You a worldwide, royalty-free, non-sublicensable, non-exclusive, irrevocable license to exercise the Licensed Rights in the Licensed Material to: + + A. reproduce and Share the Licensed Material, in whole or in part; and + + B. produce, reproduce, and Share Adapted Material. + + 2. Exceptions and Limitations. For the avoidance of doubt, where Exceptions and Limitations apply to Your use, this Public License does not apply, and You do not need to comply with its terms and conditions. + + 3. Term. The term of this Public License is specified in Section 6(a). + + 4. Media and formats; technical modifications allowed. The Licensor authorizes You to exercise the Licensed Rights in all media and formats whether now known or hereafter created, and to make technical modifications necessary to do so. The Licensor waives and/or agrees not to assert any right or authority to forbid You from making technical modifications necessary to exercise the Licensed Rights, including technical modifications necessary to circumvent Effective Technological Measures. For purposes of this Public License, simply making modifications authorized by this Section 2(a)(4) never produces Adapted Material. + + 5. Downstream recipients. + + A. Offer from the Licensor – Licensed Material. Every recipient of the Licensed Material automatically receives an offer from the Licensor to exercise the Licensed Rights under the terms and conditions of this Public License. + + B. Additional offer from the Licensor – Adapted Material. Every recipient of Adapted Material from You automatically receives an offer from the Licensor to exercise the Licensed Rights in the Adapted Material under the conditions of the Adapter’s License You apply. + + C. No downstream restrictions. You may not offer or impose any additional or different terms or conditions on, or apply any Effective Technological Measures to, the Licensed Material if doing so restricts exercise of the Licensed Rights by any recipient of the Licensed Material. + + 6. No endorsement. Nothing in this Public License constitutes or may be construed as permission to assert or imply that You are, or that Your use of the Licensed Material is, connected with, or sponsored, endorsed, or granted official status by, the Licensor or others designated to receive attribution as provided in Section 3(a)(1)(A)(i). + + b. Other rights. + + 1. Moral rights, such as the right of integrity, are not licensed under this Public License, nor are publicity, privacy, and/or other similar personality rights; however, to the extent possible, the Licensor waives and/or agrees not to assert any such rights held by the Licensor to the limited extent necessary to allow You to exercise the Licensed Rights, but not otherwise. + + 2. Patent and trademark rights are not licensed under this Public License. + + 3. To the extent possible, the Licensor waives any right to collect royalties from You for the exercise of the Licensed Rights, whether directly or through a collecting society under any voluntary or waivable statutory or compulsory licensing scheme. In all other cases the Licensor expressly reserves any right to collect such royalties. + +Section 3 – License Conditions. + +Your exercise of the Licensed Rights is expressly made subject to the following conditions. + + a. Attribution. + + 1. If You Share the Licensed Material (including in modified form), You must: + + A. retain the following if it is supplied by the Licensor with the Licensed Material: + + i. identification of the creator(s) of the Licensed Material and any others designated to receive attribution, in any reasonable manner requested by the Licensor (including by pseudonym if designated); + + ii. a copyright notice; + + iii. a notice that refers to this Public License; + + iv. a notice that refers to the disclaimer of warranties; + + v. a URI or hyperlink to the Licensed Material to the extent reasonably practicable; + + B. indicate if You modified the Licensed Material and retain an indication of any previous modifications; and + + C. indicate the Licensed Material is licensed under this Public License, and include the text of, or the URI or hyperlink to, this Public License. + + 2. You may satisfy the conditions in Section 3(a)(1) in any reasonable manner based on the medium, means, and context in which You Share the Licensed Material. For example, it may be reasonable to satisfy the conditions by providing a URI or hyperlink to a resource that includes the required information. + + 3. If requested by the Licensor, You must remove any of the information required by Section 3(a)(1)(A) to the extent reasonably practicable. + + b. ShareAlike.In addition to the conditions in Section 3(a), if You Share Adapted Material You produce, the following conditions also apply. + + 1. The Adapter’s License You apply must be a Creative Commons license with the same License Elements, this version or later, or a BY-SA Compatible License. + + 2. You must include the text of, or the URI or hyperlink to, the Adapter's License You apply. You may satisfy this condition in any reasonable manner based on the medium, means, and context in which You Share Adapted Material. + + 3. You may not offer or impose any additional or different terms or conditions on, or apply any Effective Technological Measures to, Adapted Material that restrict exercise of the rights granted under the Adapter's License You apply. + +Section 4 – Sui Generis Database Rights. + +Where the Licensed Rights include Sui Generis Database Rights that apply to Your use of the Licensed Material: + + a. for the avoidance of doubt, Section 2(a)(1) grants You the right to extract, reuse, reproduce, and Share all or a substantial portion of the contents of the database; + + b. if You include all or a substantial portion of the database contents in a database in which You have Sui Generis Database Rights, then the database in which You have Sui Generis Database Rights (but not its individual contents) is Adapted Material, including for purposes of Section 3(b); and + + c. You must comply with the conditions in Section 3(a) if You Share all or a substantial portion of the contents of the database. +For the avoidance of doubt, this Section 4 supplements and does not replace Your obligations under this Public License where the Licensed Rights include other Copyright and Similar Rights. + +Section 5 – Disclaimer of Warranties and Limitation of Liability. + + a. Unless otherwise separately undertaken by the Licensor, to the extent possible, the Licensor offers the Licensed Material as-is and as-available, and makes no representations or warranties of any kind concerning the Licensed Material, whether express, implied, statutory, or other. This includes, without limitation, warranties of title, merchantability, fitness for a particular purpose, non-infringement, absence of latent or other defects, accuracy, or the presence or absence of errors, whether or not known or discoverable. Where disclaimers of warranties are not allowed in full or in part, this disclaimer may not apply to You. + + b. To the extent possible, in no event will the Licensor be liable to You on any legal theory (including, without limitation, negligence) or otherwise for any direct, special, indirect, incidental, consequential, punitive, exemplary, or other losses, costs, expenses, or damages arising out of this Public License or use of the Licensed Material, even if the Licensor has been advised of the possibility of such losses, costs, expenses, or damages. Where a limitation of liability is not allowed in full or in part, this limitation may not apply to You. + + c. The disclaimer of warranties and limitation of liability provided above shall be interpreted in a manner that, to the extent possible, most closely approximates an absolute disclaimer and waiver of all liability. + +Section 6 – Term and Termination. + + a. This Public License applies for the term of the Copyright and Similar Rights licensed here. However, if You fail to comply with this Public License, then Your rights under this Public License terminate automatically. + + b. Where Your right to use the Licensed Material has terminated under Section 6(a), it reinstates: + + 1. automatically as of the date the violation is cured, provided it is cured within 30 days of Your discovery of the violation; or + + 2. upon express reinstatement by the Licensor. + + c. For the avoidance of doubt, this Section 6(b) does not affect any right the Licensor may have to seek remedies for Your violations of this Public License. + + d. For the avoidance of doubt, the Licensor may also offer the Licensed Material under separate terms or conditions or stop distributing the Licensed Material at any time; however, doing so will not terminate this Public License. + + e. Sections 1, 5, 6, 7, and 8 survive termination of this Public License. + +Section 7 – Other Terms and Conditions. + + a. The Licensor shall not be bound by any additional or different terms or conditions communicated by You unless expressly agreed. + + b. Any arrangements, understandings, or agreements regarding the Licensed Material not stated herein are separate from and independent of the terms and conditions of this Public License. + +Section 8 – Interpretation. + + a. For the avoidance of doubt, this Public License does not, and shall not be interpreted to, reduce, limit, restrict, or impose conditions on any use of the Licensed Material that could lawfully be made without permission under this Public License. + + b. To the extent possible, if any provision of this Public License is deemed unenforceable, it shall be automatically reformed to the minimum extent necessary to make it enforceable. If the provision cannot be reformed, it shall be severed from this Public License without affecting the enforceability of the remaining terms and conditions. + + c. No term or condition of this Public License will be waived and no failure to comply consented to unless expressly agreed to by the Licensor. + + d. Nothing in this Public License constitutes or may be interpreted as a limitation upon, or waiver of, any privileges and immunities that apply to the Licensor or You, including from the legal processes of any jurisdiction or authority. + +Creative Commons is not a party to its public licenses. Notwithstanding, Creative Commons may elect to apply one of its public licenses to material it publishes and in those instances will be considered the “Licensor.” Except for the limited purpose of indicating that material is shared under a Creative Commons public license or as otherwise permitted by the Creative Commons policies published at creativecommons.org/policies, Creative Commons does not authorize the use of the trademark “Creative Commons” or any other trademark or logo of Creative Commons without its prior written consent including, without limitation, in connection with any unauthorized modifications to any of its public licenses or any other arrangements, understandings, or agreements concerning use of licensed material. For the avoidance of doubt, this paragraph does not form part of the public licenses. + +Creative Commons may be contacted at creativecommons.org. diff --git a/LICENSES/MPL-2.0.txt b/LICENSES/MPL-2.0.txt new file mode 100644 index 0000000..14e2f77 --- /dev/null +++ b/LICENSES/MPL-2.0.txt @@ -0,0 +1,373 @@ +Mozilla Public License Version 2.0 +================================== + +1. Definitions +-------------- + +1.1. "Contributor" + means each individual or legal entity that creates, contributes to + the creation of, or owns Covered Software. + +1.2. "Contributor Version" + means the combination of the Contributions of others (if any) used + by a Contributor and that particular Contributor's Contribution. + +1.3. "Contribution" + means Covered Software of a particular Contributor. + +1.4. "Covered Software" + means Source Code Form to which the initial Contributor has attached + the notice in Exhibit A, the Executable Form of such Source Code + Form, and Modifications of such Source Code Form, in each case + including portions thereof. + +1.5. "Incompatible With Secondary Licenses" + means + + (a) that the initial Contributor has attached the notice described + in Exhibit B to the Covered Software; or + + (b) that the Covered Software was made available under the terms of + version 1.1 or earlier of the License, but not also under the + terms of a Secondary License. + +1.6. "Executable Form" + means any form of the work other than Source Code Form. + +1.7. "Larger Work" + means a work that combines Covered Software with other material, in + a separate file or files, that is not Covered Software. + +1.8. "License" + means this document. + +1.9. "Licensable" + means having the right to grant, to the maximum extent possible, + whether at the time of the initial grant or subsequently, any and + all of the rights conveyed by this License. + +1.10. "Modifications" + means any of the following: + + (a) any file in Source Code Form that results from an addition to, + deletion from, or modification of the contents of Covered + Software; or + + (b) any new file in Source Code Form that contains any Covered + Software. + +1.11. "Patent Claims" of a Contributor + means any patent claim(s), including without limitation, method, + process, and apparatus claims, in any patent Licensable by such + Contributor that would be infringed, but for the grant of the + License, by the making, using, selling, offering for sale, having + made, import, or transfer of either its Contributions or its + Contributor Version. + +1.12. "Secondary License" + means either the GNU General Public License, Version 2.0, the GNU + Lesser General Public License, Version 2.1, the GNU Affero General + Public License, Version 3.0, or any later versions of those + licenses. + +1.13. "Source Code Form" + means the form of the work preferred for making modifications. + +1.14. "You" (or "Your") + means an individual or a legal entity exercising rights under this + License. For legal entities, "You" includes any entity that + controls, is controlled by, or is under common control with You. For + purposes of this definition, "control" means (a) the power, direct + or indirect, to cause the direction or management of such entity, + whether by contract or otherwise, or (b) ownership of more than + fifty percent (50%) of the outstanding shares or beneficial + ownership of such entity. + +2. License Grants and Conditions +-------------------------------- + +2.1. Grants + +Each Contributor hereby grants You a world-wide, royalty-free, +non-exclusive license: + +(a) under intellectual property rights (other than patent or trademark) + Licensable by such Contributor to use, reproduce, make available, + modify, display, perform, distribute, and otherwise exploit its + Contributions, either on an unmodified basis, with Modifications, or + as part of a Larger Work; and + +(b) under Patent Claims of such Contributor to make, use, sell, offer + for sale, have made, import, and otherwise transfer either its + Contributions or its Contributor Version. + +2.2. Effective Date + +The licenses granted in Section 2.1 with respect to any Contribution +become effective for each Contribution on the date the Contributor first +distributes such Contribution. + +2.3. Limitations on Grant Scope + +The licenses granted in this Section 2 are the only rights granted under +this License. No additional rights or licenses will be implied from the +distribution or licensing of Covered Software under this License. +Notwithstanding Section 2.1(b) above, no patent license is granted by a +Contributor: + +(a) for any code that a Contributor has removed from Covered Software; + or + +(b) for infringements caused by: (i) Your and any other third party's + modifications of Covered Software, or (ii) the combination of its + Contributions with other software (except as part of its Contributor + Version); or + +(c) under Patent Claims infringed by Covered Software in the absence of + its Contributions. + +This License does not grant any rights in the trademarks, service marks, +or logos of any Contributor (except as may be necessary to comply with +the notice requirements in Section 3.4). + +2.4. Subsequent Licenses + +No Contributor makes additional grants as a result of Your choice to +distribute the Covered Software under a subsequent version of this +License (see Section 10.2) or under the terms of a Secondary License (if +permitted under the terms of Section 3.3). + +2.5. Representation + +Each Contributor represents that the Contributor believes its +Contributions are its original creation(s) or it has sufficient rights +to grant the rights to its Contributions conveyed by this License. + +2.6. Fair Use + +This License is not intended to limit any rights You have under +applicable copyright doctrines of fair use, fair dealing, or other +equivalents. + +2.7. Conditions + +Sections 3.1, 3.2, 3.3, and 3.4 are conditions of the licenses granted +in Section 2.1. + +3. Responsibilities +------------------- + +3.1. Distribution of Source Form + +All distribution of Covered Software in Source Code Form, including any +Modifications that You create or to which You contribute, must be under +the terms of this License. You must inform recipients that the Source +Code Form of the Covered Software is governed by the terms of this +License, and how they can obtain a copy of this License. You may not +attempt to alter or restrict the recipients' rights in the Source Code +Form. + +3.2. Distribution of Executable Form + +If You distribute Covered Software in Executable Form then: + +(a) such Covered Software must also be made available in Source Code + Form, as described in Section 3.1, and You must inform recipients of + the Executable Form how they can obtain a copy of such Source Code + Form by reasonable means in a timely manner, at a charge no more + than the cost of distribution to the recipient; and + +(b) You may distribute such Executable Form under the terms of this + License, or sublicense it under different terms, provided that the + license for the Executable Form does not attempt to limit or alter + the recipients' rights in the Source Code Form under this License. + +3.3. Distribution of a Larger Work + +You may create and distribute a Larger Work under terms of Your choice, +provided that You also comply with the requirements of this License for +the Covered Software. If the Larger Work is a combination of Covered +Software with a work governed by one or more Secondary Licenses, and the +Covered Software is not Incompatible With Secondary Licenses, this +License permits You to additionally distribute such Covered Software +under the terms of such Secondary License(s), so that the recipient of +the Larger Work may, at their option, further distribute the Covered +Software under the terms of either this License or such Secondary +License(s). + +3.4. Notices + +You may not remove or alter the substance of any license notices +(including copyright notices, patent notices, disclaimers of warranty, +or limitations of liability) contained within the Source Code Form of +the Covered Software, except that You may alter any license notices to +the extent required to remedy known factual inaccuracies. + +3.5. Application of Additional Terms + +You may choose to offer, and to charge a fee for, warranty, support, +indemnity or liability obligations to one or more recipients of Covered +Software. However, You may do so only on Your own behalf, and not on +behalf of any Contributor. You must make it absolutely clear that any +such warranty, support, indemnity, or liability obligation is offered by +You alone, and You hereby agree to indemnify every Contributor for any +liability incurred by such Contributor as a result of warranty, support, +indemnity or liability terms You offer. You may include additional +disclaimers of warranty and limitations of liability specific to any +jurisdiction. + +4. Inability to Comply Due to Statute or Regulation +--------------------------------------------------- + +If it is impossible for You to comply with any of the terms of this +License with respect to some or all of the Covered Software due to +statute, judicial order, or regulation then You must: (a) comply with +the terms of this License to the maximum extent possible; and (b) +describe the limitations and the code they affect. Such description must +be placed in a text file included with all distributions of the Covered +Software under this License. Except to the extent prohibited by statute +or regulation, such description must be sufficiently detailed for a +recipient of ordinary skill to be able to understand it. + +5. Termination +-------------- + +5.1. The rights granted under this License will terminate automatically +if You fail to comply with any of its terms. However, if You become +compliant, then the rights granted under this License from a particular +Contributor are reinstated (a) provisionally, unless and until such +Contributor explicitly and finally terminates Your grants, and (b) on an +ongoing basis, if such Contributor fails to notify You of the +non-compliance by some reasonable means prior to 60 days after You have +come back into compliance. Moreover, Your grants from a particular +Contributor are reinstated on an ongoing basis if such Contributor +notifies You of the non-compliance by some reasonable means, this is the +first time You have received notice of non-compliance with this License +from such Contributor, and You become compliant prior to 30 days after +Your receipt of the notice. + +5.2. If You initiate litigation against any entity by asserting a patent +infringement claim (excluding declaratory judgment actions, +counter-claims, and cross-claims) alleging that a Contributor Version +directly or indirectly infringes any patent, then the rights granted to +You by any and all Contributors for the Covered Software under Section +2.1 of this License shall terminate. + +5.3. In the event of termination under Sections 5.1 or 5.2 above, all +end user license agreements (excluding distributors and resellers) which +have been validly granted by You or Your distributors under this License +prior to termination shall survive termination. + +************************************************************************ +* * +* 6. Disclaimer of Warranty * +* ------------------------- * +* * +* Covered Software is provided under this License on an "as is" * +* basis, without warranty of any kind, either expressed, implied, or * +* statutory, including, without limitation, warranties that the * +* Covered Software is free of defects, merchantable, fit for a * +* particular purpose or non-infringing. The entire risk as to the * +* quality and performance of the Covered Software is with You. * +* Should any Covered Software prove defective in any respect, You * +* (not any Contributor) assume the cost of any necessary servicing, * +* repair, or correction. This disclaimer of warranty constitutes an * +* essential part of this License. No use of any Covered Software is * +* authorized under this License except under this disclaimer. * +* * +************************************************************************ + +************************************************************************ +* * +* 7. Limitation of Liability * +* -------------------------- * +* * +* Under no circumstances and under no legal theory, whether tort * +* (including negligence), contract, or otherwise, shall any * +* Contributor, or anyone who distributes Covered Software as * +* permitted above, be liable to You for any direct, indirect, * +* special, incidental, or consequential damages of any character * +* including, without limitation, damages for lost profits, loss of * +* goodwill, work stoppage, computer failure or malfunction, or any * +* and all other commercial damages or losses, even if such party * +* shall have been informed of the possibility of such damages. This * +* limitation of liability shall not apply to liability for death or * +* personal injury resulting from such party's negligence to the * +* extent applicable law prohibits such limitation. Some * +* jurisdictions do not allow the exclusion or limitation of * +* incidental or consequential damages, so this exclusion and * +* limitation may not apply to You. * +* * +************************************************************************ + +8. Litigation +------------- + +Any litigation relating to this License may be brought only in the +courts of a jurisdiction where the defendant maintains its principal +place of business and such litigation shall be governed by laws of that +jurisdiction, without reference to its conflict-of-law provisions. +Nothing in this Section shall prevent a party's ability to bring +cross-claims or counter-claims. + +9. Miscellaneous +---------------- + +This License represents the complete agreement concerning the subject +matter hereof. If any provision of this License is held to be +unenforceable, such provision shall be reformed only to the extent +necessary to make it enforceable. Any law or regulation which provides +that the language of a contract shall be construed against the drafter +shall not be used to construe this License against a Contributor. + +10. Versions of the License +--------------------------- + +10.1. New Versions + +Mozilla Foundation is the license steward. Except as provided in Section +10.3, no one other than the license steward has the right to modify or +publish new versions of this License. Each version will be given a +distinguishing version number. + +10.2. Effect of New Versions + +You may distribute the Covered Software under the terms of the version +of the License under which You originally received the Covered Software, +or under the terms of any subsequent version published by the license +steward. + +10.3. Modified Versions + +If you create software not governed by this License, and you want to +create a new license for such software, you may create and use a +modified version of this License if you rename the license and remove +any references to the name of the license steward (except to note that +such modified license differs from this License). + +10.4. Distributing Source Code Form that is Incompatible With Secondary +Licenses + +If You choose to distribute Source Code Form that is Incompatible With +Secondary Licenses under the terms of this version of the License, the +notice described in Exhibit B of this License must be attached. + +Exhibit A - Source Code Form License Notice +------------------------------------------- + + This Source Code Form is subject to the terms of the Mozilla Public + License, v. 2.0. If a copy of the MPL was not distributed with this + file, You can obtain one at http://mozilla.org/MPL/2.0/. + +If it is not possible or desirable to put the notice in a particular +file, then You may include the notice in a location (such as a LICENSE +file in a relevant directory) where a recipient would be likely to look +for such a notice. + +You may add additional accurate notices of copyright ownership. + +Exhibit B - "Incompatible With Secondary Licenses" Notice +--------------------------------------------------------- + + This Source Code Form is "Incompatible With Secondary Licenses", as + defined by the Mozilla Public License, v. 2.0. diff --git a/build/.guix-channel b/build/.guix-channel index f9bdf68..2c0ad55 100644 --- a/build/.guix-channel +++ b/build/.guix-channel @@ -1,20 +1,20 @@ ;; SPDX-License-Identifier: MPL-2.0 -;; Copyright (c) {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +;; Copyright (c) 2026 Jonathan D.A. Jewell (hyperpolymath) ;; -;; Guix channel definition for {{PROJECT_NAME}} +;; Guix channel definition for Haec ;; ;; To use this channel, add to ~/.config/guix/channels.scm: ;; ;; (channel -;; (name '{{PROJECT_NAME}}) -;; (url "https://github.com/{{OWNER}}/{{PROJECT_NAME}}") +;; (name 'Haec) +;; (url "https://github.com/hyperpolymath/Haec") ;; (branch "main")) ;; ;; Then: guix pull (channel (version 0) - (url "https://github.com/{{OWNER}}/{{PROJECT_NAME}}") + (url "https://github.com/hyperpolymath/Haec") (dependencies (channel (name 'guix) diff --git a/build/Containerfile b/build/Containerfile index d7266bc..39578b2 100644 --- a/build/Containerfile +++ b/build/Containerfile @@ -1,10 +1,10 @@ # SPDX-License-Identifier: MPL-2.0 -# Copyright (c) {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +# Copyright (c) 2026 Jonathan D.A. Jewell (hyperpolymath) # -# Containerfile for {{PROJECT_NAME}} -# Build: podman build -t {{project}}:latest -f Containerfile . -# Run: podman run --rm -it {{project}}:latest -# Seal: selur seal {{project}}:latest +# Containerfile for Haec +# Build: podman build -t haec:latest -f Containerfile . +# Run: podman run --rm -it haec:latest +# Seal: selur seal haec:latest # --- Build stage --- FROM cgr.dev/chainguard/wolfi-base:latest AS build @@ -30,12 +30,12 @@ FROM cgr.dev/chainguard/static:latest # Copy built artifact from build stage # TODO: Replace with your binary/artifact path # Examples: -# COPY --from=build /build/target/release/{{project}} /usr/local/bin/ -# COPY --from=build /build/_build/prod/rel/{{project}} /app/ -# COPY --from=build /build/zig-out/bin/{{project}} /usr/local/bin/ +# COPY --from=build /build/target/release/haec /usr/local/bin/ +# COPY --from=build /build/_build/prod/rel/haec /app/ +# COPY --from=build /build/zig-out/bin/haec /usr/local/bin/ # Non-root user (chainguard images default to nonroot) USER nonroot # TODO: Replace with your entrypoint -# ENTRYPOINT ["/usr/local/bin/{{project}}"] +# ENTRYPOINT ["/usr/local/bin/haec"] diff --git a/build/guix.scm b/build/guix.scm index 33b1a9a..10d714b 100644 --- a/build/guix.scm +++ b/build/guix.scm @@ -1,13 +1,13 @@ ;; SPDX-License-Identifier: MPL-2.0 -;; Copyright (c) {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +;; Copyright (c) 2026 Jonathan D.A. Jewell (hyperpolymath) ;; -;; Guix package definition for {{PROJECT_NAME}} +;; Guix package definition for Haec ;; ;; Usage: ;; guix shell -D -f guix.scm # Enter development shell ;; guix build -f guix.scm # Build package ;; -;; TODO: Replace {{PROJECT_NAME}} and customize inputs for your language/stack. +;; TODO: Replace Haec and customize inputs for your language/stack. ;; See: https://guix.gnu.org/manual/en/html_node/Defining-Packages.html (use-modules (guix packages) @@ -18,7 +18,7 @@ (gnu packages base)) (package - (name "{{PROJECT_NAME}}") + (name "Haec") (version "0.1.0") (source (local-file "." "source" #:recursive? #t @@ -63,8 +63,8 @@ (list ;; TODO: Add runtime dependencies )) - (home-page "https://github.com/{{OWNER}}/{{PROJECT_NAME}}") - (synopsis "{{PROJECT_PURPOSE}}") + (home-page "https://github.com/hyperpolymath/Haec") + (synopsis "A Turing-complete language whose type discipline is trope-particularity; it lowers programs to the language-neutral Trope IR.") (description "RSR-compliant project. See README.adoc for details.") (license (list ;; MPL-2.0 extends MPL-2.0 diff --git a/build/just/trope.just b/build/just/trope.just new file mode 100644 index 0000000..ba454e4 --- /dev/null +++ b/build/just/trope.just @@ -0,0 +1,15 @@ +# SPDX-License-Identifier: MPL-2.0 +# Copyright (c) 2026 Jonathan D.A. Jewell (hyperpolymath) +# +# Haec (trope-particularity front-end) recipes. Imported by the root Justfile via +# import? "build/just/trope.just" + +# Validate that every example lowers to a well-formed Trope IR document. +check: haec-examples + +haec-examples: + python3 tests/check-examples.py + +# Full round-trip (verdicts) needs a checkout of the sibling trope-checker. +haec-roundtrip: + @for f in examples/*.ir.json; do echo "== $f =="; python3 ../trope-checker/src/checker/tropecheck.py "$f" || true; done diff --git a/container/.gatekeeper.yaml b/container/.gatekeeper.yaml index 4aac671..64cc67f 100644 --- a/container/.gatekeeper.yaml +++ b/container/.gatekeeper.yaml @@ -1,6 +1,6 @@ # SPDX-License-Identifier: MPL-2.0 # -# Svalinn gatekeeper policy for {{PROJECT_NAME}} +# Svalinn gatekeeper policy for Haec # # Controls which operations are permitted through the edge gateway. # This template provides moderate security defaults — not wide-open test @@ -65,9 +65,9 @@ rate_limits: trust: # Only accept .ctp bundles signed by these keys. trusted_signers: - - key_id: "{{SERVICE_NAME}}-release" + - key_id: "haec-release" algorithm: "Ed25519" - public_key_file: "/etc/svalinn/keys/{{SERVICE_NAME}}-release.pub" + public_key_file: "/etc/svalinn/keys/haec-release.pub" # Require these attestations on all .ctp bundles. required_attestations: diff --git a/container/Containerfile b/container/Containerfile index ba85260..6cdd04c 100644 --- a/container/Containerfile +++ b/container/Containerfile @@ -1,18 +1,18 @@ # SPDX-License-Identifier: MPL-2.0 -# {{PROJECT_NAME}} Container Image +# Haec Container Image # # Multi-stage build template for Chainguard Wolfi base images. # Customise the builder stage for your language and copy the # resulting binary/release into the minimal runtime stage. # # Build with Podman: -# podman build -t {{SERVICE_NAME}}:latest -f container/Containerfile . +# podman build -t haec:latest -f container/Containerfile . # # Run: -# podman run -p {{PORT}}:{{PORT}} {{SERVICE_NAME}}:latest +# podman run -p 8080:8080 haec:latest # # Run with persistent volume: -# podman run -p {{PORT}}:{{PORT}} -v {{SERVICE_NAME}}-data:/data {{SERVICE_NAME}}:latest +# podman run -p 8080:8080 -v haec-data:/data haec:latest # ============================================================================ # Stage 1: Builder @@ -29,7 +29,7 @@ # COPY Cargo.toml Cargo.lock ./ # COPY src/ ./src/ # RUN cargo build --release -# # Output: /build/target/release/{{SERVICE_NAME}} +# # Output: /build/target/release/haec # # --- Elixir --- # RUN apk add --no-cache erl27-elixir-1.18 erlang-27 erlang-27-dev git build-base @@ -39,14 +39,14 @@ # ENV MIX_ENV=prod # RUN mix local.hex --force && mix local.rebar --force && \ # mix deps.get --only prod && mix compile && mix release -# # Output: /build/_build/prod/rel/{{SERVICE_NAME}}/ +# # Output: /build/_build/prod/rel/haec/ # # --- Zig --- # RUN apk add --no-cache zig build-base # COPY build.zig build.zig.zon ./ # COPY src/ ./src/ # RUN zig build -Doptimize=ReleaseFast -# # Output: /build/zig-out/bin/{{SERVICE_NAME}} +# # Output: /build/zig-out/bin/haec # FROM cgr.dev/chainguard/wolfi-base:latest AS builder @@ -69,13 +69,13 @@ COPY . . FROM cgr.dev/chainguard/wolfi-base:latest # OCI image labels (compatible with cerro-torre .ctp bundle metadata) -LABEL org.opencontainers.image.title="{{PROJECT_NAME}}" \ - org.opencontainers.image.description="{{PROJECT_DESCRIPTION}}" \ - org.opencontainers.image.url="https://{{FORGE}}/{{OWNER}}/{{REPO}}" \ - org.opencontainers.image.source="https://{{FORGE}}/{{OWNER}}/{{REPO}}" \ - org.opencontainers.image.vendor="{{OWNER}}" \ - org.opencontainers.image.licenses="{{LICENSE}}" \ - org.opencontainers.image.authors="{{AUTHOR}} <{{AUTHOR_EMAIL}}>" \ +LABEL org.opencontainers.image.title="Haec" \ + org.opencontainers.image.description="A Turing-complete language whose type discipline is trope-particularity; it lowers programs to the language-neutral Trope IR." \ + org.opencontainers.image.url="https://github.com/hyperpolymath/haec" \ + org.opencontainers.image.source="https://github.com/hyperpolymath/haec" \ + org.opencontainers.image.vendor="hyperpolymath" \ + org.opencontainers.image.licenses="MPL-2.0" \ + org.opencontainers.image.authors="Jonathan D.A. Jewell " \ dev.cerrotorre.manifest="container/manifest.toml" \ dev.cerrotorre.gatekeeper="container/.gatekeeper.yaml" \ dev.stapeln.compose="container/compose.toml" @@ -96,9 +96,9 @@ WORKDIR /app # TODO: Copy compiled binary/release from builder stage. # Examples: -# COPY --from=builder /build/target/release/{{SERVICE_NAME}} /app/{{SERVICE_NAME}} -# COPY --from=builder /build/_build/prod/rel/{{SERVICE_NAME}} /app/release/ -# COPY --from=builder /build/zig-out/bin/{{SERVICE_NAME}} /app/{{SERVICE_NAME}} +# COPY --from=builder /build/target/release/haec /app/haec +# COPY --from=builder /build/_build/prod/rel/haec /app/release/ +# COPY --from=builder /build/zig-out/bin/haec /app/haec # Copy entrypoint script COPY container/entrypoint.sh /app/entrypoint.sh @@ -116,7 +116,7 @@ RUN chown -R appuser:appuser /app # Environment variables — customise for your application ENV APP_HOST=[::] -ENV APP_PORT={{PORT}} +ENV APP_PORT=8080 ENV APP_LOG_FORMAT=json ENV APP_DATA_DIR=/data @@ -127,7 +127,7 @@ VOLUME ["/data"] USER appuser # Expose the application port -EXPOSE {{PORT}} +EXPOSE 8080 # Health check — the application must respond 2xx at /health HEALTHCHECK --interval=30s --timeout=5s --start-period=10s --retries=3 \ diff --git a/container/README.adoc b/container/README.adoc index 0db8201..c48d49e 100644 --- a/container/README.adoc +++ b/container/README.adoc @@ -1,6 +1,6 @@ // SPDX-License-Identifier: MPL-2.0 // Copyright (c) Jonathan D.A. Jewell -= {{PROJECT_NAME}} Container Templates += Haec Container Templates :toc: left :toclevels: 3 :sectnums: diff --git a/container/compose.toml b/container/compose.toml index a14f8a0..b994079 100644 --- a/container/compose.toml +++ b/container/compose.toml @@ -1,6 +1,6 @@ # SPDX-License-Identifier: MPL-2.0 # -# {{PROJECT_NAME}} selur-compose configuration +# Haec selur-compose configuration # # Orchestrates the container stack as verified container bundles (.ctp). # Uses selur zero-copy IPC between services on the same host. @@ -10,7 +10,7 @@ # selur-compose up --detach # Start in background # selur-compose verify # Verify all .ctp signatures # selur-compose ps # Check status -# selur-compose logs -f {{SERVICE_NAME}} # Stream logs +# selur-compose logs -f haec # Stream logs # selur-compose down # Stop all services # # Fallback (when selur is not installed): @@ -23,30 +23,30 @@ version = "1.0" # ============================================================================ # Primary application service -[services.{{SERVICE_NAME}}] -image = "{{REGISTRY}}/{{SERVICE_NAME}}:latest.ctp" -ports = ["{{PORT}}:{{PORT}}"] +[services.haec] +image = "ghcr.io/hyperpolymath/haec:latest.ctp" +ports = ["8080:8080"] environment = { APP_HOST = "[::]", - APP_PORT = "{{PORT}}", + APP_PORT = "8080", APP_LOG_FORMAT = "json", APP_DATA_DIR = "/data", } -volumes = ["{{SERVICE_NAME}}-data:/data"] +volumes = ["haec-data:/data"] restart = "always" -healthcheck = { test = "curl -sf http://localhost:{{PORT}}/health", interval = "30s", timeout = "5s", retries = 3 } +healthcheck = { test = "curl -sf http://localhost:8080/health", interval = "30s", timeout = "5s", retries = 3 } # Svalinn edge gateway: validates requests, enforces policies, TLS termination [services.svalinn] image = "ghcr.io/hyperpolymath/svalinn:latest.ctp" ports = ["443:443", "80:80"] environment = { - SVALINN_BACKEND = "http://{{SERVICE_NAME}}:{{PORT}}", + SVALINN_BACKEND = "http://haec:8080", SVALINN_POLICY_FILE = "/etc/svalinn/gatekeeper.yaml", SVALINN_TLS_AUTO = "true", } volumes = ["svalinn-config:/etc/svalinn:ro"] -depends_on = ["{{SERVICE_NAME}}"] +depends_on = ["haec"] restart = "always" healthcheck = { test = "curl -sf http://localhost:80/health", interval = "30s", timeout = "5s", retries = 3 } @@ -54,7 +54,7 @@ healthcheck = { test = "curl -sf http://localhost:80/health", interval = "30s", # Volumes # ============================================================================ -[volumes.{{SERVICE_NAME}}-data] +[volumes.haec-data] driver = "local" [volumes.svalinn-config] diff --git a/container/ct-build.sh b/container/ct-build.sh index a54a541..5be7a2f 100755 --- a/container/ct-build.sh +++ b/container/ct-build.sh @@ -1,7 +1,7 @@ #!/usr/bin/env bash # SPDX-License-Identifier: MPL-2.0 # -# {{PROJECT_NAME}} — Cerro Torre build, sign, and verify pipeline +# Haec — Cerro Torre build, sign, and verify pipeline # # Builds the container image, packages it as a verified .ctp bundle, # signs it with Ed25519, and verifies the result. Gracefully degrades @@ -18,8 +18,8 @@ # CT_KEY_ID=my-key ./ct-build.sh # Use specific signing key # # Environment variables: -# CT_KEY_ID — Signing key identifier (default: {{SERVICE_NAME}}-release) -# CT_REGISTRY — OCI registry to push to (default: {{REGISTRY}}) +# CT_KEY_ID — Signing key identifier (default: haec-release) +# CT_REGISTRY — OCI registry to push to (default: ghcr.io/hyperpolymath) # CT_TAG — Image tag (default: latest) set -euo pipefail @@ -38,15 +38,15 @@ for arg in "$@"; do fi done -CT_KEY_ID="${CT_KEY_ID:-{{SERVICE_NAME}}-release}" -CT_REGISTRY="${CT_REGISTRY:-{{REGISTRY}}}" +CT_KEY_ID="${CT_KEY_ID:-haec-release}" +CT_REGISTRY="${CT_REGISTRY:-ghcr.io/hyperpolymath}" CT_TAG="${CT_TAG:-latest}" -IMAGE_NAME="{{SERVICE_NAME}}" +IMAGE_NAME="haec" FULL_IMAGE="${CT_REGISTRY}/${IMAGE_NAME}:${CT_TAG}" CTP_FILE="${SCRIPT_DIR}/${IMAGE_NAME}-${CT_TAG}.ctp" -echo "=== {{PROJECT_NAME}} Cerro Torre Build Pipeline ===" +echo "=== Haec Cerro Torre Build Pipeline ===" echo " Image: ${FULL_IMAGE}" echo " Key: ${CT_KEY_ID}" echo " Bundle: ${CTP_FILE}" diff --git a/container/deploy.k9.ncl b/container/deploy.k9.ncl index 0ad0d04..d08054e 100644 --- a/container/deploy.k9.ncl +++ b/container/deploy.k9.ncl @@ -1,5 +1,5 @@ # SPDX-License-Identifier: MPL-2.0 -# deploy.k9.ncl — {{PROJECT_NAME}} deployment component (Hunt level) +# deploy.k9.ncl — Haec deployment component (Hunt level) # # k9-svc deployment specification with full pedigree (L1-L5). # Security Level: 'Hunt (requires cryptographic handshake for execution). @@ -18,11 +18,11 @@ let component_pedigree = { # L1: The Snout — Identity # ───────────────────────────────────────────────────────────── metadata = { - name = "{{SERVICE_NAME}}-deploy", - version = "{{VERSION}}", + name = "haec-deploy", + version = "0.1.0", breed = "application/vnd.k9+nickel", magic_number = "K9!", - description = "{{PROJECT_NAME}} deployment component (Hunt level)", + description = "Haec deployment component (Hunt level)", }, # ───────────────────────────────────────────────────────────── @@ -93,8 +93,8 @@ let deployment = { # Container configuration container = { - image = "{{REGISTRY}}/{{SERVICE_NAME}}", - port = {{PORT}}, + image = "ghcr.io/hyperpolymath/haec", + port = 8080, health_check = "/health", readiness_check = "/ready", }, @@ -113,7 +113,7 @@ let scripts = { pre_deploy = m%" #!/bin/sh set -eu -echo "K9: Pre-deployment validation for {{SERVICE_NAME}}..." +echo "K9: Pre-deployment validation for haec..." cd container && selur-compose verify || podman compose --file compose.toml config echo "K9: Validation passed." "%, @@ -123,7 +123,7 @@ echo "K9: Validation passed." #!/bin/sh set -eu ENV="${1:-dev}" -echo "K9: Deploying {{SERVICE_NAME}} to $ENV environment..." +echo "K9: Deploying haec to $ENV environment..." cd container ./ct-build.sh selur-compose up --detach || podman compose --file compose.toml up --detach @@ -134,7 +134,7 @@ echo "K9: Deployment to $ENV complete." rollback = m%" #!/bin/sh set -eu -echo "K9: Rolling back {{SERVICE_NAME}} deployment..." +echo "K9: Rolling back haec deployment..." cd container selur-compose down || podman compose --file compose.toml down echo "K9: Rollback complete." diff --git a/container/entrypoint.sh b/container/entrypoint.sh index a7a0369..6f92b79 100755 --- a/container/entrypoint.sh +++ b/container/entrypoint.sh @@ -1,6 +1,6 @@ #!/bin/sh # SPDX-License-Identifier: MPL-2.0 -# {{PROJECT_NAME}} container entrypoint +# Haec container entrypoint # # Handles signal propagation, startup logging, and health check # preparation before exec-ing into the main application process. @@ -15,7 +15,7 @@ set -e # when Podman sends stop signals (e.g. `podman stop`, `selur-compose down`). cleanup() { - echo "Received shutdown signal — stopping {{SERVICE_NAME}}..." + echo "Received shutdown signal — stopping haec..." # If the main process is backgrounded, kill it here: # kill "$MAIN_PID" 2>/dev/null || true # wait "$MAIN_PID" 2>/dev/null || true @@ -27,9 +27,9 @@ trap cleanup TERM INT # Startup logging # --------------------------------------------------------------------------- -echo "Starting {{SERVICE_NAME}}..." +echo "Starting haec..." echo " Host: ${APP_HOST:-[::]}" -echo " Port: ${APP_PORT:-{{PORT}}}" +echo " Port: ${APP_PORT:-8080}" echo " Data: ${APP_DATA_DIR:-/data}" echo " Log: ${APP_LOG_FORMAT:-json}" @@ -56,8 +56,8 @@ fi # # TODO: Replace the command below with your application binary. # Examples: -# exec /app/{{SERVICE_NAME}} -# exec /app/release/bin/{{SERVICE_NAME}} start -# exec /app/{{SERVICE_NAME}} serve --host "${APP_HOST}" --port "${APP_PORT}" +# exec /app/haec +# exec /app/release/bin/haec start +# exec /app/haec serve --host "${APP_HOST}" --port "${APP_PORT}" exec "$@" diff --git a/container/manifest.toml b/container/manifest.toml index f55fcb3..7843055 100644 --- a/container/manifest.toml +++ b/container/manifest.toml @@ -1,27 +1,27 @@ # SPDX-License-Identifier: MPL-2.0 # -# Cerro Torre manifest for {{PROJECT_NAME}} .ctp bundle +# Cerro Torre manifest for Haec .ctp bundle # # This manifest describes the container image for verified # container packaging. Used by `ct pack` to create .ctp bundles. [metadata] -name = "{{SERVICE_NAME}}" -version = "{{VERSION}}" +name = "haec" +version = "0.1.0" revision = 1 -summary = "{{PROJECT_DESCRIPTION}}" +summary = "A Turing-complete language whose type discipline is trope-particularity; it lowers programs to the language-neutral Trope IR." description = """ -{{PROJECT_NAME}} — containerised service packaged as a verified +Haec — containerised service packaged as a verified cerro-torre .ctp bundle with Ed25519 signing and full provenance tracking. """ -license = "{{LICENSE}}" -homepage = "https://{{FORGE}}/{{OWNER}}/{{REPO}}" -maintainer = "{{AUTHOR}} <{{EMAIL}}>" +license = "MPL-2.0" +homepage = "https://github.com/hyperpolymath/haec" +maintainer = "Jonathan D.A. Jewell " [provenance] -upstream = "https://{{FORGE}}/{{OWNER}}/{{REPO}}" -import_date = {{CURRENT_DATE}}T00:00:00Z +upstream = "https://github.com/hyperpolymath/haec" +import_date = 2026-06-22T00:00:00Z [dependencies] runtime = ["ca-certificates", "curl"] @@ -32,10 +32,10 @@ system = "podman" [build.environment] APP_HOST = "[::]" -APP_PORT = "{{PORT}}" +APP_PORT = "8080" [outputs] -primary = "{{SERVICE_NAME}}" +primary = "haec" split = [] [attestations] @@ -54,7 +54,7 @@ drop = ["ALL"] add = ["NET_BIND_SERVICE"] [security.network] -listen_tcp = [{{PORT}}] +listen_tcp = [8080] [security.filesystem] read = ["/app/", "/data/"] diff --git a/container/vordr.toml b/container/vordr.toml index af38fc5..4101956 100644 --- a/container/vordr.toml +++ b/container/vordr.toml @@ -1,6 +1,6 @@ # SPDX-License-Identifier: MPL-2.0 # -# Vordr runtime monitoring configuration for {{PROJECT_NAME}} +# Vordr runtime monitoring configuration for Haec # # Vordr watches container health, detects crashes, tracks resource usage, # and emits structured logs. It runs alongside the application stack and @@ -12,8 +12,8 @@ # vordr report [metadata] -name = "{{SERVICE_NAME}}" -version = "{{VERSION}}" +name = "haec" +version = "0.1.0" # ============================================================================ # Health Monitoring @@ -25,13 +25,13 @@ version = "{{VERSION}}" [health] # Primary health endpoint — must return 2xx. -endpoint = "http://localhost:{{PORT}}/health" +endpoint = "http://localhost:8080/health" interval = "30s" timeout = "5s" failure_threshold = 3 # Readiness endpoint — checked during startup and after restarts. -readiness_endpoint = "http://localhost:{{PORT}}/ready" +readiness_endpoint = "http://localhost:8080/ready" readiness_timeout = "10s" # Action on failure: "alert" (log + notify) or "restart" (alert + podman restart). @@ -79,7 +79,7 @@ format = "json" level = "info" # Write vordr logs to stdout (captured by Podman) and optionally to file. output = "stdout" -# file = "/var/log/vordr/{{SERVICE_NAME}}.log" +# file = "/var/log/vordr/haec.log" # ============================================================================ # Notifications (optional) @@ -94,7 +94,7 @@ output = "stdout" # on = ["failure", "recovery", "resource_critical"] # [notifications.email] -# to = "{{EMAIL}}" -# from = "vordr@{{SERVICE_NAME}}.local" +# to = "j.d.a.jewell@open.ac.uk" +# from = "vordr@haec.local" # smtp = "smtp://localhost:25" # on = ["failure", "resource_critical"] diff --git a/docs-template/README.adoc b/docs-template/README.adoc index 3640e4c..46d0b81 100644 --- a/docs-template/README.adoc +++ b/docs-template/README.adoc @@ -10,8 +10,8 @@ This directory is the *minimum heavy-wiki seed* for a hyperpolymath repo. == How to adopt . Copy `docs-template/` → `docs/` in your repo. -. Replace `{{PROJECT_NAME}}`, `{{OWNER}}`, `{{AUTHOR}}`, `{{AUTHOR_EMAIL}}`, - `{{CURRENT_YEAR}}` placeholders. +. Replace `Haec`, `hyperpolymath`, `Jonathan D.A. Jewell`, `j.d.a.jewell@open.ac.uk`, + `2026` placeholders. . Delete any sections that genuinely do not apply (don't leave empty scaffolding — the 2026-05-26 doc-debt audit flagged 61 estate repos with empty `docs/` dirs as a separate category of debt). diff --git a/docs-template/architecture.adoc b/docs-template/architecture.adoc index da49a38..67050d2 100644 --- a/docs-template/architecture.adoc +++ b/docs-template/architecture.adoc @@ -1,8 +1,8 @@ // SPDX-License-Identifier: MPL-2.0 // Copyright (c) Jonathan D.A. Jewell -// SPDX-FileCopyrightText: {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> -= Architecture — {{PROJECT_NAME}} -:revdate: {{CURRENT_YEAR}}-MM-DD +// SPDX-FileCopyrightText: 2026 Jonathan D.A. Jewell (hyperpolymath) += Architecture — Haec +:revdate: 2026-MM-DD == System overview diff --git a/docs-template/contributing.adoc b/docs-template/contributing.adoc index cb49ce6..f498385 100644 --- a/docs-template/contributing.adoc +++ b/docs-template/contributing.adoc @@ -1,12 +1,12 @@ // SPDX-License-Identifier: MPL-2.0 // Copyright (c) Jonathan D.A. Jewell -// SPDX-FileCopyrightText: {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> -= Contributing — {{PROJECT_NAME}} -:revdate: {{CURRENT_YEAR}}-MM-DD +// SPDX-FileCopyrightText: 2026 Jonathan D.A. Jewell (hyperpolymath) += Contributing — Haec +:revdate: 2026-MM-DD == Audience -Developers working *on* `{{PROJECT_NAME}}`. For consumers (people calling +Developers working *on* `Haec`. For consumers (people calling or depending on it) see link:./usage.adoc[usage.adoc]. == Local-dev setup @@ -23,8 +23,8 @@ One-shot setup: [source,bash] ---- -git clone git@github.com:{{OWNER}}/{{PROJECT_NAME}}.git -cd {{PROJECT_NAME}} +git clone git@github.com:hyperpolymath/Haec.git +cd Haec just setup # installs deps, sets up hooks just test # runs the full test suite ---- @@ -86,6 +86,6 @@ When you make a non-obvious design decision, write it down: == Reporting issues -* Bugs in `{{PROJECT_NAME}}`: file at `{{OWNER}}/{{PROJECT_NAME}}/issues`. +* Bugs in `Haec`: file at `hyperpolymath/Haec/issues`. * Estate-wide concerns (policy, conventions, CI): file at `hyperpolymath/standards/issues`. diff --git a/docs-template/decisions/0001-template.adoc b/docs-template/decisions/0001-template.adoc index 6b57cbe..bc6da8d 100644 --- a/docs-template/decisions/0001-template.adoc +++ b/docs-template/decisions/0001-template.adoc @@ -1,8 +1,8 @@ // SPDX-License-Identifier: MPL-2.0 // Copyright (c) Jonathan D.A. Jewell -// SPDX-FileCopyrightText: {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> +// SPDX-FileCopyrightText: 2026 Jonathan D.A. Jewell (hyperpolymath) = ADR-0001 — Use Architecture Decision Records -:revdate: {{CURRENT_YEAR}}-MM-DD +:revdate: 2026-MM-DD :status: ACCEPTED == Context diff --git a/docs-template/troubleshooting.adoc b/docs-template/troubleshooting.adoc index 29f1a74..f707d48 100644 --- a/docs-template/troubleshooting.adoc +++ b/docs-template/troubleshooting.adoc @@ -1,8 +1,8 @@ // SPDX-License-Identifier: MPL-2.0 // Copyright (c) Jonathan D.A. Jewell -// SPDX-FileCopyrightText: {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> -= Troubleshooting — {{PROJECT_NAME}} -:revdate: {{CURRENT_YEAR}}-MM-DD +// SPDX-FileCopyrightText: 2026 Jonathan D.A. Jewell (hyperpolymath) += Troubleshooting — Haec +:revdate: 2026-MM-DD This file is a *living FAQ* — known failure modes and recovery paths. Add a new entry every time you debug something that took more than 15 @@ -54,5 +54,5 @@ just log-tail # last N lines of logs * `docs/architecture.adoc` — internals. * `docs/decisions/` — historical record of why things are this shape. -* `https://github.com/{{OWNER}}/{{PROJECT_NAME}}/issues?q=is%3Aissue+` — has anyone hit this before? +* `https://github.com/hyperpolymath/Haec/issues?q=is%3Aissue+` — has anyone hit this before? * `https://github.com/hyperpolymath/standards/issues` — for estate-wide problems. diff --git a/docs-template/usage.adoc b/docs-template/usage.adoc index 0154cbb..1a00900 100644 --- a/docs-template/usage.adoc +++ b/docs-template/usage.adoc @@ -1,12 +1,12 @@ // SPDX-License-Identifier: MPL-2.0 // Copyright (c) Jonathan D.A. Jewell -// SPDX-FileCopyrightText: {{CURRENT_YEAR}} {{AUTHOR}} ({{OWNER}}) <{{AUTHOR_EMAIL}}> -= Usage — {{PROJECT_NAME}} -:revdate: {{CURRENT_YEAR}}-MM-DD +// SPDX-FileCopyrightText: 2026 Jonathan D.A. Jewell (hyperpolymath) += Usage — Haec +:revdate: 2026-MM-DD == Audience -This document is for *consumers* of `{{PROJECT_NAME}}` — people who depend +This document is for *consumers* of `Haec` — people who depend on it, call it, or include it. For developers working *on* it, see link:./contributing.adoc[contributing.adoc]. @@ -31,7 +31,7 @@ Expected output: [source] ---- -{{PROJECT_NAME}} v0.0.0 +Haec v0.0.0 Listening on 127.0.0.1:8080 ---- diff --git a/machine-readable-design/canonical-directory-structure/Intentfile.a2ml b/machine-readable-design/canonical-directory-structure/Intentfile.a2ml index 11509ca..09ac435 100644 --- a/machine-readable-design/canonical-directory-structure/Intentfile.a2ml +++ b/machine-readable-design/canonical-directory-structure/Intentfile.a2ml @@ -29,7 +29,7 @@ committed next-actions and aspirational wishes. [REPLACE WITH PROJECT-SPECIFIC PURPOSE] -Example: The {{PROJECT_NAME}} provides {{MAIN_FUNCTION}} for {{TARGET_AUDIENCE}}. +Example: The Haec provides {{MAIN_FUNCTION}} for {{TARGET_AUDIENCE}}. ## Anti-Purpose diff --git a/machine-readable-design/canonical-directory-structure/README.adoc b/machine-readable-design/canonical-directory-structure/README.adoc index 1968814..6b79396 100644 --- a/machine-readable-design/canonical-directory-structure/README.adoc +++ b/machine-readable-design/canonical-directory-structure/README.adoc @@ -99,7 +99,7 @@ To initialize a new repository with contractiles: . Create `.machine_readable/contractiles/` directory . Copy all files from this `canonical-directory-structure/` directory . Customize each file with your project-specific content -. Remove all template markers (e.g., `{{PROJECT_NAME}}`) +. Remove all template markers (e.g., `Haec`) . Ensure all checks pass: `must check`, `adjust check`, etc. == See Also diff --git a/machine-readable-design/canonical-directory-structure/Trustfile.a2ml b/machine-readable-design/canonical-directory-structure/Trustfile.a2ml index 342fe03..f0dcc72 100644 --- a/machine-readable-design/canonical-directory-structure/Trustfile.a2ml +++ b/machine-readable-design/canonical-directory-structure/Trustfile.a2ml @@ -13,7 +13,7 @@ plus checks that verify repository integrity. ## Trust Levels -The {{PROJECT_NAME}} operates at trust level: [maximal | standard | restricted | minimal] +The Haec operates at trust level: [maximal | standard | restricted | minimal] Trust levels: - maximal: Agent may read, build, test, lint, format, heal freely. diff --git a/machine-readable-design/canonical-directory-structure/bust/Bustfile.a2ml b/machine-readable-design/canonical-directory-structure/bust/Bustfile.a2ml index 992851f..ca76f3d 100644 --- a/machine-readable-design/canonical-directory-structure/bust/Bustfile.a2ml +++ b/machine-readable-design/canonical-directory-structure/bust/Bustfile.a2ml @@ -2,7 +2,7 @@ // SPDX-License-Identifier: MPL-2.0 Bust { - name: "{{PROJECT_NAME}}" + name: "Haec" version: "1.0.0" description: "Rollback procedures when something breaks in this repository" diff --git a/src/interface/ffi/src/main.zig b/src/interface/ffi/src/main.zig index f1b2633..3b3707b 100644 --- a/src/interface/ffi/src/main.zig +++ b/src/interface/ffi/src/main.zig @@ -1,6 +1,6 @@ // SPDX-License-Identifier: MPL-2.0 // Copyright (c) Jonathan D.A. Jewell -// {{PROJECT}} FFI Implementation +// HAEC FFI Implementation // // This module implements the C-compatible FFI declared in src/abi/Foreign.idr // All types and layouts must match the Idris2 ABI definitions. @@ -10,7 +10,7 @@ const std = @import("std"); // Version information (keep in sync with project) const VERSION = "0.1.0"; -const BUILD_INFO = "{{PROJECT}} built with Zig " ++ @import("builtin").zig_version_string; +const BUILD_INFO = "HAEC built with Zig " ++ @import("builtin").zig_version_string; /// Thread-local error storage threadlocal var last_error: ?[]const u8 = null; @@ -52,7 +52,7 @@ pub const Handle = opaque { /// Initialize the library /// Returns a handle, or null on failure -export fn {{project}}_init() ?*Handle { +export fn haec_init() ?*Handle { const allocator = std.heap.c_allocator; const handle = allocator.create(Handle) catch { @@ -71,7 +71,7 @@ export fn {{project}}_init() ?*Handle { } /// Free the library handle -export fn {{project}}_free(handle: ?*Handle) void { +export fn haec_free(handle: ?*Handle) void { const h = handle orelse return; const allocator = h.allocator; @@ -87,7 +87,7 @@ export fn {{project}}_free(handle: ?*Handle) void { //============================================================================== /// Process data (example operation) -export fn {{project}}_process(handle: ?*Handle, input: u32) Result { +export fn haec_process(handle: ?*Handle, input: u32) Result { const h = handle orelse { setError("Null handle"); return .null_pointer; @@ -111,7 +111,7 @@ export fn {{project}}_process(handle: ?*Handle, input: u32) Result { /// Get a string result (example) /// Caller must free the returned string -export fn {{project}}_get_string(handle: ?*Handle) ?[*:0]const u8 { +export fn haec_get_string(handle: ?*Handle) ?[*:0]const u8 { const h = handle orelse { setError("Null handle"); return null; @@ -133,7 +133,7 @@ export fn {{project}}_get_string(handle: ?*Handle) ?[*:0]const u8 { } /// Free a string allocated by the library -export fn {{project}}_free_string(str: ?[*:0]const u8) void { +export fn haec_free_string(str: ?[*:0]const u8) void { const s = str orelse return; const allocator = std.heap.c_allocator; @@ -146,7 +146,7 @@ export fn {{project}}_free_string(str: ?[*:0]const u8) void { //============================================================================== /// Process an array of data -export fn {{project}}_process_array( +export fn haec_process_array( handle: ?*Handle, buffer: ?[*]const u8, len: u32, @@ -182,7 +182,7 @@ export fn {{project}}_process_array( /// Get the last error message /// Returns null if no error -export fn {{project}}_last_error() ?[*:0]const u8 { +export fn haec_last_error() ?[*:0]const u8 { const err = last_error orelse return null; // Return C string (static storage, no need to free) @@ -196,12 +196,12 @@ export fn {{project}}_last_error() ?[*:0]const u8 { //============================================================================== /// Get the library version -export fn {{project}}_version() [*:0]const u8 { +export fn haec_version() [*:0]const u8 { return VERSION.ptr; } /// Get build information -export fn {{project}}_build_info() [*:0]const u8 { +export fn haec_build_info() [*:0]const u8 { return BUILD_INFO.ptr; } @@ -213,7 +213,7 @@ export fn {{project}}_build_info() [*:0]const u8 { pub const Callback = *const fn (u64, u32) callconv(.C) u32; /// Register a callback -export fn {{project}}_register_callback( +export fn haec_register_callback( handle: ?*Handle, callback: ?Callback, ) Result { @@ -244,7 +244,7 @@ export fn {{project}}_register_callback( //============================================================================== /// Check if handle is initialized -export fn {{project}}_is_initialized(handle: ?*Handle) u32 { +export fn haec_is_initialized(handle: ?*Handle) u32 { const h = handle orelse return 0; return if (h.initialized) 1 else 0; } @@ -254,22 +254,22 @@ export fn {{project}}_is_initialized(handle: ?*Handle) u32 { //============================================================================== test "lifecycle" { - const handle = {{project}}_init() orelse return error.InitFailed; - defer {{project}}_free(handle); + const handle = haec_init() orelse return error.InitFailed; + defer haec_free(handle); - try std.testing.expect({{project}}_is_initialized(handle) == 1); + try std.testing.expect(haec_is_initialized(handle) == 1); } test "error handling" { - const result = {{project}}_process(null, 0); + const result = haec_process(null, 0); try std.testing.expectEqual(Result.null_pointer, result); - const err = {{project}}_last_error(); + const err = haec_last_error(); try std.testing.expect(err != null); } test "version" { - const ver = {{project}}_version(); + const ver = haec_version(); const ver_str = std.mem.span(ver); try std.testing.expectEqualStrings(VERSION, ver_str); }