Skip to content

Commit a279863

Browse files
hyperpolymathclaude
andcommitted
foundation: EchoKernel re-export + funext-free certificate + kernel/derived note
Item 1 (Foundation — Echo functor core [REAL]). Audit of Echo.agda and the ~30 Echo*.agda modules (intra-repo open-import DAG, origin/main) shows a single dependency-light root: every other Echo* module transitively imports Echo, and Echo imports only agda-stdlib (no funext, no Axiom.Extensionality, zero postulates, zero escape pragmas). - proofs/agda/EchoKernel.agda: curated public re-export of that core (open import Echo public) plus a Kernel-contract submodule that pins the load-bearing lemma types by definitional equality. Its successful --safe --without-K build with no extensionality in the cone IS the funext-free certificate. - docs/echo-types/echo-kernel-note.adoc: one-page kernel-vs-derived classification (kernel = Echo; Tier-1/Tier-2 derived; retracted-framing modules flagged per R-2026-05-18; EchoApprox noted as a non-derived sibling). Honest funext boundary recorded: the pointwise-only mediator property (EchoPullback) is derived, not kernel. - All.agda: aggregate now covers EchoKernel. - MAP.adoc: Foundation entry + status tag, same PR (links, not duplicates). Honours retraction R-2026-05-18: no retracted claim re-asserted; kernel is a loss-graded reindexing surface, explicitly not a graded comonad and carrying no universal/terminal property. Verified: EchoKernel and the full All.agda aggregate typecheck --safe --without-K (exit 0) on a clean worktree off origin/docs/echo-types-master-map. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent 2b9be9c commit a279863

4 files changed

Lines changed: 244 additions & 0 deletions

File tree

docs/echo-types/MAP.adoc

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,11 @@ behind — `git fetch` and read `origin/main` before trusting any survey.
4141
remainder of information-losing computation: for `f : A → B`,
4242
`Echo f y := Σ (x : A), (f x ≡ y)`. `[REAL]`
4343

44+
* Kernel: `proofs/agda/EchoKernel.agda` — the funext-free,
45+
postulate-free core (re-export of `Echo` + a pinned `Kernel-contract`).
46+
`[REAL]` Everything else imports `Echo` transitively; the
47+
kernel-vs-derived classification + funext-free certificate is
48+
`docs/echo-types/echo-kernel-note.adoc`.
4449
* Proofs: `proofs/agda/Echo.agda` + ~24 `Echo*.agda` modules
4550
(`EchoCategorical`, `EchoDecidable`, `EchoCharacteristic`,
4651
`EchoApprox`, `EchoIndexed`, …).
Lines changed: 106 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,106 @@
1+
// SPDX-License-Identifier: PMPL-1.0-or-later
2+
// SPDX-FileCopyrightText: 2026 Jonathan D.A. Jewell <j.d.a.jewell@open.ac.uk>
3+
= echo-types: kernel vs derived (one-page note)
4+
:toc: macro
5+
:source-highlighter: rouge
6+
7+
[.lead]
8+
Which Agda modules are the *kernel* (the dependency-light, funext-free
9+
core everything imports) and which are *derived*. Companion to
10+
`proofs/agda/EchoKernel.agda`. Status SoT is
11+
`docs/echo-types/MAP.adoc`; honesty SoT is `docs/retractions.adoc`
12+
(R-2026-05-18). This note links, it does not duplicate.
13+
14+
== The kernel is exactly `Echo`
15+
16+
`Echo f y := Σ (x : A), (f x ≡ y)`. The audit of `Echo.agda` plus the
17+
~30 `Echo*.agda` modules (intra-repo `open import` DAG, `origin/main`,
18+
2026-05-18) shows a single root: **every other `Echo*` module
19+
transitively imports `Echo`, and `Echo` imports nothing from the repo
20+
— only agda-stdlib**:
21+
22+
[none]
23+
* `Level`, `Function.Base`, `Function.Bundles`, `Data.Product.Base`,
24+
`Relation.Binary.PropositionalEquality` (+ `.Properties`).
25+
26+
So no smaller subset is "the core": `Echo.agda` is already minimal and
27+
has no internal fat to trim (the heaviest content, the cancel-iso
28+
path algebra, is still first-order — see below). `proofs/agda/EchoKernel.agda`
29+
re-exports it (`open import Echo public`) and pins the load-bearing
30+
lemma *types* in a `Kernel-contract` submodule so the public surface
31+
cannot silently weaken.
32+
33+
=== Funext-free certificate
34+
35+
The kernel cone (`Echo` + the stdlib modules above) contains **no
36+
`Axiom.Extensionality` / funext** anywhere, **zero postulates**, and
37+
**zero escape pragmas**; it builds under `--safe --without-K`.
38+
That successful build *is* the certificate: every lemma re-exported
39+
by `EchoKernel` is funext-free by construction, mechanically, not by
40+
assertion. The kernel keeps the cancel-iso round-trips funext-free
41+
*deliberately* by taking the two triangle coherences (`triangle₁`,
42+
`triangle₂`) as explicit hypotheses; deriving them instead would need
43+
funext.
44+
45+
CAUTION: Funext-free is *not* "no funext anywhere in the project". Per
46+
R-2026-05-18, the genuine funext-relativity is the *pointwise-only*
47+
mediator property in `EchoPullback` (`echo-pullback-univ` proves only
48+
`∀ v → m' v ≡ m v`, not `m' ≡ m`). That module is **derived, not
49+
kernel** — the boundary is real and lives outside this core.
50+
51+
== Classification
52+
53+
[cols="1,2,4", options="header"]
54+
|===
55+
| Layer | Modules | Notes
56+
57+
| *Kernel*
58+
| `Echo` (via `EchoKernel`)
59+
| Funext-free, postulate-free root. Re-export + contract:
60+
`EchoKernel.agda`. `[REAL]`
61+
62+
| *Derived — Tier 1* +
63+
(only `Echo` + stdlib)
64+
| `EchoCharacteristic`, `EchoChoreo`, `EchoDecidable`,
65+
`EchoFiberBridge`, `EchoFiberCount`, `EchoIndexed`,
66+
`EchoRelational`, `EchoTruncation`, `EchoJanusBridge`,
67+
`EchoTropical`, `EchoSeparating`
68+
| One hop off the kernel. `EchoJanusBridge`/`EchoTropical` are
69+
*Directions* (see MAP). `EchoSeparating` carries retracted prose
70+
framing (below).
71+
72+
| *Derived — Tier 2* +
73+
(depend on Tier-1 `Echo*`)
74+
| `EchoCategorical`, `EchoResidue`, `EchoEpistemic`,
75+
`EchoEpistemicResidue`, `EchoExamples`, `EchoGraded`,
76+
`EchoLinear`, `EchoPullback`, `EchoRelModel`, `EchoScope`,
77+
`EchoStabilityTests`, `EchoThermodynamics`, `EchoCNOBridge`,
78+
`EchoIntegration`
79+
| Multi-hop. `EchoThermodynamics` reaches the kernel via
80+
`EchoFiberCount` (no direct `Echo` import).
81+
82+
| *Retracted framing* +
83+
(typecheck; prose withdrawn)
84+
| `EchoGradedComonad`, `EchoPullback`, `EchoRelModel`,
85+
`EchoSeparating`
86+
| Agda unchanged and `[REAL]` as mechanised; the *graded-comonad /
87+
two-models / universal-property* descriptions are `[RETRACTED]`
88+
(R-2026-05-18), under a falsifiable earn-back gate. Not kernel.
89+
90+
| *Sibling (not kernel-derived)*
91+
| `EchoApprox`
92+
| Does **not** `import Echo`; a parallel stdlib-only approximation
93+
module. Listed so the DAG audit is complete.
94+
|===
95+
96+
`EchoOrdinal` is Tier-1 off `Echo` but additionally pulls the
97+
`Ordinal/` subtree; it belongs to the Buchholz/Veblen Direction in
98+
the MAP, not the foundation kernel.
99+
100+
== Maintenance
101+
102+
Living classification. If a module's import set changes, or a
103+
retraction/earn-back moves a module between layers, update this table
104+
*and* the `[REAL]/[RETRACTED]` tag in `docs/echo-types/MAP.adoc`
105+
**in the same PR**. Never duplicate proof detail here — link the
106+
module or the canonical doc.

proofs/agda/All.agda

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
module All where
44

55
open import Echo
6+
open import EchoKernel
67
open import EchoCharacteristic
78
open import EchoResidue
89
open import EchoExamples

proofs/agda/EchoKernel.agda

Lines changed: 132 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,132 @@
1+
{-# OPTIONS --safe --without-K #-}
2+
3+
-- EchoKernel — the funext-free core of echo-types.
4+
--
5+
-- This module is the *curated public surface* of the Echo foundation.
6+
-- Every other `Echo*` module in the tree transitively imports `Echo`;
7+
-- this re-export names that dependency-light core explicitly and pins
8+
-- the load-bearing lemma *types* so the kernel API cannot silently
9+
-- weaken without breaking this file's typecheck.
10+
--
11+
-- Provenance / honesty (read before citing anything here):
12+
--
13+
-- * `--safe --without-K`, zero postulates, zero escape pragmas.
14+
-- * The kernel's import cone is `Echo` + agda-stdlib only
15+
-- (`Level`, `Function.Base`, `Function.Bundles`,
16+
-- `Data.Product.Base`, `Relation.Binary.PropositionalEquality`
17+
-- [+ `.Properties`]). It contains *no* `Axiom.Extensionality` /
18+
-- funext anywhere — so every lemma re-exported below is
19+
-- funext-free, and this module's successful `--safe --without-K`
20+
-- build is itself the funext-free certificate.
21+
-- * The genuine funext-relativity in echo-types is the
22+
-- *pointwise-only* mediator property (`EchoPullback`,
23+
-- `echo-pullback-univ`), which lives strictly *outside* this
24+
-- kernel. The kernel deliberately keeps the cancel-iso
25+
-- round-trips first-order by taking the triangle identities
26+
-- (`triangle₁`, `triangle₂`) as explicit hypotheses rather than
27+
-- deriving them via funext.
28+
--
29+
-- Non-claims (per `docs/retractions.adoc` R-2026-05-18, not
30+
-- un-retracted here): the kernel is a definitionally-grounded,
31+
-- loss-graded *reindexing* surface. It is *not* a graded comonad, it
32+
-- carries *no* universal/terminal property, and it is *not* a
33+
-- conservativity metatheorem. Nothing below asserts any of those.
34+
--
35+
-- Kernel vs derived classification: see
36+
-- `docs/echo-types/echo-kernel-note.adoc` (one-page note, kept
37+
-- current in the same PR as this module).
38+
39+
module EchoKernel where
40+
41+
-- The whole funext-free core surface. Everything downstream that
42+
-- "imports Echo" is importing exactly this.
43+
open import Echo public
44+
45+
------------------------------------------------------------------------
46+
-- Kernel contract.
47+
--
48+
-- The load-bearing lemmas the derived layer actually depends on,
49+
-- restated with explicit signatures and bound by definitional
50+
-- equality to the `Echo` proofs. This is a *contract*, not new
51+
-- mathematics: it forces the kernel's public types to remain exactly
52+
-- as documented, and re-checks each in the funext-free,
53+
-- extensionality-free, `--safe --without-K` cone. If any `Echo`
54+
-- lemma is weakened, generalised, or acquires a funext dependency,
55+
-- this section fails to typecheck.
56+
------------------------------------------------------------------------
57+
58+
module Kernel-contract where
59+
60+
open import Level using (Level; _⊔_)
61+
open import Function.Base using (_∘_; id)
62+
open import Data.Product.Base using (Σ; _,_; _×_)
63+
open import Relation.Binary.PropositionalEquality
64+
using (_≡_; refl; sym; trans; cong)
65+
open import Function.Bundles using (_↔_)
66+
67+
-- Echo functor: the structured remainder of an information-losing f.
68+
kernel-Echo :
69+
{a b} {A : Set a} {B : Set b} (f : A B) B Set (a ⊔ b)
70+
kernel-Echo = Echo
71+
72+
-- Introduction into one's own fibre.
73+
kernel-echo-intro :
74+
{a b} {A : Set a} {B : Set b} (f : A B) (x : A) Echo f (f x)
75+
kernel-echo-intro = echo-intro
76+
77+
-- Fibrewise functorial action over a fixed base.
78+
kernel-map-over :
79+
{a a' b} {A : Set a} {A' : Set a'} {B : Set b}
80+
{f : A B} {f' : A' B}
81+
MapOver f f' {y : B} Echo f y Echo f' y
82+
kernel-map-over = map-over
83+
84+
-- Functoriality: identity law.
85+
kernel-map-over-id :
86+
{a b} {A : Set a} {B : Set b} {f : A B} {y : B} (e : Echo f y)
87+
map-over (id , (λ x refl)) e ≡ e
88+
kernel-map-over-id = map-over-id
89+
90+
-- Functoriality: composition law.
91+
kernel-map-over-comp :
92+
{a a' a'' b}
93+
{A : Set a} {A' : Set a'} {A'' : Set a''} {B : Set b}
94+
{f : A B} {f' : A' B} {f'' : A'' B}
95+
(u1 : A A') (c1 : x f' (u1 x) ≡ f x)
96+
(u2 : A' A'') (c2 : x f'' (u2 x) ≡ f' x)
97+
{y : B} (e : Echo f y)
98+
map-over {f = f} {f' = f''}
99+
(u2 ∘ u1 , (λ x trans (c2 (u1 x)) (c1 x))) e
100+
≡ map-over {f = f'} {f' = f''} (u2 , c2)
101+
(map-over {f = f} {f' = f'} (u1 , c1) e)
102+
kernel-map-over-comp = map-over-comp
103+
104+
-- Composition accumulation iso (unconditional; closes the
105+
-- accumulation law of composition.md §1).
106+
kernel-Echo-comp-iso :
107+
{a b c} {A : Set a} {B : Set b} {C : Set c}
108+
(f : A B) (g : B C) (y : C)
109+
Echo (g ∘ f) y ↔ Σ B (λ b Echo f b × (g b ≡ y))
110+
kernel-Echo-comp-iso = Echo-comp-iso
111+
112+
-- The single load-bearing path-algebra lemma. It is naturality of
113+
-- a homotopy `h : f ∼ id` along a path — first-order, funext-free.
114+
kernel-hom-natural-id :
115+
{a} {A : Set a} (f : A A) (h : z f z ≡ z)
116+
{x y : A} (p : x ≡ y)
117+
trans (cong f p) (h y) ≡ trans (h x) p
118+
kernel-hom-natural-id = hom-natural-id
119+
120+
-- Cancel iso, with the two triangle coherences kept as explicit
121+
-- hypotheses (this is *how* the kernel stays funext-free; funext
122+
-- would otherwise be needed to relate the two quasi-inverse laws).
123+
kernel-cancel-iso :
124+
{a b c} {A : Set a} {B : Set b} {C : Set c}
125+
(f : A B) (g : B C) (s : C B)
126+
(s-left : b s (g b) ≡ b)
127+
(s-right : y g (s y) ≡ y)
128+
(triangle₁ : b cong g (s-left b) ≡ s-right (g b))
129+
(triangle₂ : y cong s (s-right y) ≡ s-left (s y))
130+
(y : C)
131+
Echo (g ∘ f) y ↔ Echo f (s y)
132+
kernel-cancel-iso = cancel-iso

0 commit comments

Comments
 (0)