# loumaloulongtin/eparch architecture

> Architecture diagram of the GitHub repository loumaloulongtin/eparch, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-05). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/loumaloulongtin/eparch
- Repository: https://github.com/loumaloulongtin/eparch

## Overview

EpArch is a Lean 4 formalization, not a runtime service: its main workflow is to state agent constraints, goals, and bridge conditions, then machine-check conditional structural claims and commitments. It also formalizes typed operational transitions, supplies concrete witnesses, and provides modularity and transport results. The README documents these capabilities and some key modules, but no source excerpts were supplied; edges below therefore represent only documented relationships, not inspected call paths.

Main entry points: [`EpArch/WorldBridges.lean`](https://github.com/loumaloulongtin/eparch/blob/main/EpArch/WorldBridges.lean) (Core theorems), [`EpArch/Meta/Modular.lean`](https://github.com/loumaloulongtin/eparch/blob/main/EpArch/Meta/Modular.lean) (Constraint modularity), [`EpArch/Agent/Constraints.lean`](https://github.com/loumaloulongtin/eparch/blob/main/EpArch/Agent/Constraints.lean) (Agent constraints), [`EpArch/Health.lean`](https://github.com/loumaloulongtin/eparch/blob/main/EpArch/Health.lean) (System health)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_conditions["Conditions and pressure"]
  node_constraints["Agent constraints<br/>[Constraints.lean]"]
  node_pressure["Pressure witnesses<br/>[WorldBridges.lean]"]
  node_health["System health<br/>[Health.lean]"]
end

subgraph group_formalization["Core formalization"]
  node_commitments["Structural commitments<br/>[Commitments.lean]"]
  node_core_theorems["Core theorems<br/>[WorldBridges.lean]"]
end

subgraph group_operational["Operational model"]
  node_semantics["Step semantics<br/>[StepSemantics.lean]"]
  node_lifecycle["Lifecycle model<br/>[LTS.lean]"]
end

subgraph group_witnesses["Concrete witnesses"]
  node_concrete["Constructive witnesses"]
  node_world_witness["World witnesses<br/>[WorldWitness.lean]"]
  node_adversarial["Attack obligations"]
end

subgraph group_meta["Meta certification"]
  node_modularity["Constraint modularity<br/>[Modular.lean]"]
  node_transport["Theorem transport"]
  node_registry["Cluster registry"]
  node_optional_kernel["Kernel example"]
end

node_reader(("Proof reader"))

node_reader -->|"reviews claims"| node_core_theorems
node_constraints -->|"constrain forcing"| node_core_theorems
node_health -->|"constrain forcing"| node_core_theorems
node_pressure -->|"witness pressures"| node_core_theorems
node_core_theorems -->|"prove commitments"| node_commitments
node_semantics -->|"types transitions"| node_lifecycle
node_concrete -->|"provide inhabitants"| node_world_witness
node_modularity -->|"supports transport"| node_transport
node_modularity -->|"certifies clusters"| node_registry

click node_constraints "https://github.com/loumaloulongtin/eparch/blob/main/EpArch/Agent/Constraints.lean"
click node_pressure "https://github.com/loumaloulongtin/eparch/blob/main/EpArch/WorldBridges.lean"
click node_health "https://github.com/loumaloulongtin/eparch/blob/main/EpArch/Health.lean"
click node_commitments "https://github.com/loumaloulongtin/eparch/blob/main/EpArch/Commitments.lean"
click node_core_theorems "https://github.com/loumaloulongtin/eparch/blob/main/EpArch/WorldBridges.lean"
click node_semantics "https://github.com/loumaloulongtin/eparch/blob/main/EpArch/Semantics/StepSemantics.lean"
click node_lifecycle "https://github.com/loumaloulongtin/eparch/blob/main/EpArch/Semantics/LTS.lean"
click node_concrete "https://github.com/loumaloulongtin/eparch/tree/main/EpArch/Concrete"
click node_world_witness "https://github.com/loumaloulongtin/eparch/blob/main/EpArch/WorldWitness.lean"
click node_adversarial "https://github.com/loumaloulongtin/eparch/tree/main/EpArch/Adversarial"
click node_modularity "https://github.com/loumaloulongtin/eparch/blob/main/EpArch/Meta/Modular.lean"
click node_transport "https://github.com/loumaloulongtin/eparch/blob/main/EpArch/Meta/TheoremTransport.lean"
click node_registry "https://github.com/loumaloulongtin/eparch/blob/main/EpArch/Meta/ClusterRegistry.lean"
click node_optional_kernel "https://github.com/loumaloulongtin/eparch/tree/main/EpArch/Meta/LeanKernel"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_constraints,node_pressure,node_health toneBlue
class node_commitments,node_core_theorems toneAmber
class node_semantics,node_lifecycle toneMint
class node_concrete,node_world_witness,node_adversarial toneRose
class node_modularity,node_transport,node_registry,node_optional_kernel,node_reader toneIndigo
```

## Components

### Conditions and pressure

- [Agent constraints](https://github.com/loumaloulongtin/eparch/blob/main/EpArch/Agent/Constraints.lean): `EpArch/Agent/Constraints.lean`
- [Pressure witnesses](https://github.com/loumaloulongtin/eparch/blob/main/EpArch/WorldBridges.lean): `EpArch/WorldBridges.lean`
- [System health](https://github.com/loumaloulongtin/eparch/blob/main/EpArch/Health.lean): `EpArch/Health.lean`

### Core formalization

- [Structural commitments](https://github.com/loumaloulongtin/eparch/blob/main/EpArch/Commitments.lean): `EpArch/Commitments.lean`
- [Core theorems](https://github.com/loumaloulongtin/eparch/blob/main/EpArch/WorldBridges.lean): `EpArch/WorldBridges.lean`

### Operational model

- [Step semantics](https://github.com/loumaloulongtin/eparch/blob/main/EpArch/Semantics/StepSemantics.lean): `EpArch/Semantics/StepSemantics.lean`
- [Lifecycle model](https://github.com/loumaloulongtin/eparch/blob/main/EpArch/Semantics/LTS.lean): `EpArch/Semantics/LTS.lean`

### Concrete witnesses

- [Constructive witnesses](https://github.com/loumaloulongtin/eparch/tree/main/EpArch/Concrete): `EpArch/Concrete`
- [World witnesses](https://github.com/loumaloulongtin/eparch/blob/main/EpArch/WorldWitness.lean): `EpArch/WorldWitness.lean`
- [Attack obligations](https://github.com/loumaloulongtin/eparch/tree/main/EpArch/Adversarial): `EpArch/Adversarial`

### Meta certification

- [Constraint modularity](https://github.com/loumaloulongtin/eparch/blob/main/EpArch/Meta/Modular.lean): `EpArch/Meta/Modular.lean`
- [Theorem transport](https://github.com/loumaloulongtin/eparch/blob/main/EpArch/Meta/TheoremTransport.lean): `EpArch/Meta/TheoremTransport.lean`
- [Cluster registry](https://github.com/loumaloulongtin/eparch/blob/main/EpArch/Meta/ClusterRegistry.lean): `EpArch/Meta/ClusterRegistry.lean`
- [Kernel example](https://github.com/loumaloulongtin/eparch/tree/main/EpArch/Meta/LeanKernel): `EpArch/Meta/LeanKernel`

### Other components

- **Proof reader**

## Connections

- Proof reader → Core theorems: reviews claims (evidence: `README.md`)
- Agent constraints → Core theorems: constrain forcing (evidence: `README.md`)
- System health → Core theorems: constrain forcing (evidence: `README.md`)
- Pressure witnesses → Core theorems: witness pressures (evidence: `README.md`)
- Core theorems → Structural commitments: prove commitments (evidence: `README.md`)
- Step semantics → Lifecycle model: types transitions (evidence: `README.md`)
- Constructive witnesses → World witnesses: provide inhabitants (evidence: `README.md`)
- Constraint modularity → Theorem transport: supports transport (evidence: `README.md`)
- Constraint modularity → Cluster registry: certifies clusters (evidence: `README.md`)
