Skip to content

Commit 35035dd

Browse files
committed
Add integration bridge, next-question backlog, and robust CI stdlib resolution
1 parent 0b6600e commit 35035dd

6 files changed

Lines changed: 186 additions & 8 deletions

File tree

.github/workflows/agda.yml

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -18,17 +18,21 @@ jobs:
1818
sudo apt-get update
1919
sudo apt-get install -y agda agda-stdlib
2020
21-
- name: Configure Agda standard library
21+
- name: Locate Agda standard library
22+
id: stdlib
2223
run: |
23-
STDLIB_LIB="$(find /usr/share -name 'standard-library.agda-lib' | head -n 1)"
24-
if [ -z "$STDLIB_LIB" ]; then
25-
echo "Could not locate standard-library.agda-lib"
24+
STDLIB_DIR="$(
25+
find /usr/share /usr/lib -type f -path '*/Data/Nat/Base.agda' 2>/dev/null \
26+
| head -n 1 \
27+
| sed 's#/Data/Nat/Base.agda##'
28+
)"
29+
30+
if [ -z "$STDLIB_DIR" ]; then
31+
echo "Could not locate Agda standard library directory"
2632
exit 1
2733
fi
2834
29-
mkdir -p "$HOME/.agda"
30-
printf '%s\n' "$STDLIB_LIB" > "$HOME/.agda/libraries"
31-
printf '%s\n' "standard-library" > "$HOME/.agda/defaults"
35+
echo "stdlib_dir=$STDLIB_DIR" >> "$GITHUB_OUTPUT"
3236
3337
- name: Typecheck full suite
34-
run: agda -i proofs/agda proofs/agda/All.agda
38+
run: agda -i proofs/agda -i "${{ steps.stdlib.outputs.stdlib_dir }}" proofs/agda/All.agda

docs/next-questions.adoc

Lines changed: 104 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,104 @@
1+
= Next Questions
2+
3+
Date: 2026-04-18
4+
5+
This file records the highest-value open problems after the current
6+
echo/choreo/epistemic/linear/graded/tropical integration pass.
7+
8+
== Q1. Unified Dependent Linear + Choreographic + Epistemic Calculus
9+
10+
Why it matters:
11+
12+
* This is the main synthesis target for "structured loss with controlled use."
13+
14+
Current gap:
15+
16+
* We have bridges between parts, but not one single typed calculus enforcing all
17+
constraints simultaneously.
18+
19+
Needed:
20+
21+
* A core syntax/judgment layer with usage discipline + role projection +
22+
knowledge operators, and preservation/progress-style metatheory.
23+
24+
Difficulty:
25+
26+
* Extremely hard.
27+
28+
== Q2. Quotient/Cubical Treatment of Indistinguishability
29+
30+
Why it matters:
31+
32+
* Current indistinguishability is set-level/propositional.
33+
* Rich observational equivalence classes need better identity handling.
34+
35+
Current gap:
36+
37+
* No cubical/quotient formalization of observational collapse classes.
38+
39+
Needed:
40+
41+
* A quotient-aware or cubical extension with proofs that echo constructions
42+
commute with equivalence-class semantics.
43+
44+
Difficulty:
45+
46+
* Very hard.
47+
48+
== Q3. Probabilistic Epistemic Echoes
49+
50+
Why it matters:
51+
52+
* Many realistic systems are stochastic; evidence is weighted, not binary.
53+
54+
Current gap:
55+
56+
* No probability/distribution layer over echoes.
57+
58+
Needed:
59+
60+
* Distribution-valued observation semantics and posterior-style residue objects,
61+
plus stability/transport theorems.
62+
63+
Difficulty:
64+
65+
* Very hard.
66+
67+
== Q4. Tropical Optimization Semantics Beyond Toy Candidate Sets
68+
69+
Why it matters:
70+
71+
* Current tropical development is finite/toy-level.
72+
73+
Current gap:
74+
75+
* No general optimization framework (argmin sets, ties, compositionality across
76+
larger structures).
77+
78+
Needed:
79+
80+
* Scalable tropical witness/certificate framework with composition laws and
81+
integration with graded degradation.
82+
83+
Difficulty:
84+
85+
* Hard.
86+
87+
== Q5. Automation and Regression Guardrails
88+
89+
Why it matters:
90+
91+
* Scope has grown quickly; regressions become expensive.
92+
93+
Current gap:
94+
95+
* CI gate existed but failed due environment assumptions.
96+
97+
Needed:
98+
99+
* Robust CI with full-suite typecheck, plus optional lightweight proof-smoke
100+
checks for future PRs.
101+
102+
Difficulty:
103+
104+
* Moderate.

proofs/agda/All.agda

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ open import EchoEpistemic
1212
open import EchoLinear
1313
open import EchoGraded
1414
open import EchoTropical
15+
open import EchoIntegration
1516

1617
open import EchoIndexed
1718
open import EchoEpistemicResidue

proofs/agda/EchoIntegration.agda

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
{-# OPTIONS --safe --without-K #-}
2+
3+
module EchoIntegration where
4+
5+
open import EchoChoreo
6+
open import EchoEpistemic
7+
open import EchoGraded
8+
open import EchoCharacteristic using (echo-true; echo-false; echo-true≢echo-false)
9+
open import EchoResidue using (no-section-collapse-to-residue)
10+
11+
open import Data.Bool.Base using (Bool)
12+
open import Data.Product.Base using (Σ; _×_; _,_; proj₁)
13+
open import Relation.Binary.PropositionalEquality using (_≡_; _≢_; refl)
14+
open import Relation.Nullary using (¬_)
15+
16+
-- Choreographic observation-preserving steps preserve any epistemic predicate
17+
-- that is stable under the hidden-state update.
18+
knowledge-preserved-under-choreo :
19+
{y : Bool} {P : Global Set}
20+
( g P g P (scramble-server g))
21+
Knows Client P y
22+
e P (proj₁ (client-stability e))
23+
knowledge-preserved-under-choreo = knowledge-along-client-stability
24+
25+
-- Controlled degradation in graded echoes:
26+
-- distinct keep-grade witnesses become identified at residue grade.
27+
distinct-at-keep : echo-true ≢ echo-false
28+
distinct-at-keep = echo-true≢echo-false
29+
30+
merged-at-residue :
31+
degrade keep≤residue echo-true ≡ degrade keep≤residue echo-false
32+
merged-at-residue = refl
33+
34+
no-recovery-after-residue-degrade :
35+
¬ (Σ (GEcho residue GEcho keep)
36+
(λ raise e raise (degrade keep≤residue e) ≡ e))
37+
no-recovery-after-residue-degrade = no-section-collapse-to-residue
38+
39+
-- Integration witness: choreography can preserve knowledge while graded
40+
-- degradation still loses discriminating power in a controlled way.
41+
knowledge-and-controlled-degradation :
42+
{y : Bool} {P : Global Set}
43+
( g P g P (scramble-server g))
44+
Knows Client P y
45+
( e P (proj₁ (client-stability e)))
46+
× (degrade keep≤residue echo-true ≡ degrade keep≤residue echo-false)
47+
knowledge-and-controlled-degradation inv k =
48+
knowledge-preserved-under-choreo inv k , merged-at-residue

readme.adoc

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ Current formal foundation is in:
3535
* `proofs/agda/EchoLinear.agda`
3636
* `proofs/agda/EchoGraded.agda`
3737
* `proofs/agda/EchoTropical.agda`
38+
* `proofs/agda/EchoIntegration.agda`
3839

3940
with constructive proofs (safe Agda, no postulates):
4041

@@ -58,6 +59,7 @@ Scope-broadening stages now include:
5859
* affine/linear bridge (strict weakening from full echoes to residues)
5960
* graded bridge (grade order and compositional degradation law)
6061
* tropical bridge (argmin-style witness residues under tropical collapse)
62+
* integration bridge (knowledge preservation under choreography plus controlled graded degradation)
6163

6264
== What Echo Types Are For
6365

@@ -111,3 +113,7 @@ agda -i proofs/agda proofs/agda/All.agda
111113
Proof milestones and decision gates are in:
112114

113115
* `roadmap.adoc`
116+
117+
Open hard questions are tracked in:
118+
119+
* `docs/next-questions.adoc`

roadmap.adoc

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -292,6 +292,21 @@ cd proofs/agda
292292
for f in *.agda; do agda -i . "$f"; done
293293
----
294294

295+
M12. Cross-bridge integration:
296+
297+
* add `proofs/agda/EchoIntegration.agda`
298+
* prove a theorem combining choreographic knowledge preservation with graded
299+
controlled degradation behavior
300+
301+
Status: DONE (2026-04-18)
302+
303+
Delivered in `proofs/agda/EchoIntegration.agda`:
304+
305+
* `knowledge-preserved-under-choreo`
306+
* `merged-at-residue`
307+
* `no-recovery-after-residue-degrade`
308+
* `knowledge-and-controlled-degradation`
309+
295310
== Operating Rules
296311

297312
* No postulates unless explicitly isolated and justified.

0 commit comments

Comments
 (0)