A sovereign cognitive agent built on SQCIG — a cognitive quadrupole wired as a living causal graph. Every claim measured, never declared.
ACSE (Autopoietic Cognitive Sovereign Emergence) is a single-binary cognitive agent (~4,000 lines of Zig 0.16). It is not an LLM wrapper: it implements a named cognitive architecture — SQCIG — and everything claimed below is measured, never declared.
The architecture is the fusion of four constituents (SPEC.md §2 · docs/PARADIGMS.md):
| Constituent | Role |
|---|---|
| Cognitive Quadrupole A-D-O-G | Activation (divergence, 3–7 hypotheses) · Detection (truth, relevance, verifiability) · Overcoming-bias (veto, metaconsciousness, anti-sycophancy) · Guidance (convergence, parsimony, action). Hierarchy O > D > G > A: creativity cannot force truth, decision cannot bypass integrity. |
| SPICG — Schematized Procedural Instruction Causal Graph | The executable substrate: nodes = states / instructions / checkpoints; edges = causal relations (triggers, enables, inhibits, corrects, remembers); transition guards (o_veto_clear, test_passed, risk_low, budget_ok, has_plan); learned weights. |
| SPICG-Ignition | The cognitive pre-processor: raw text becomes an intent structure (explicit and implicit intent, constraints, risk, effort, security) before any thought occurs. |
| Persistent memory | Not a step in the flow — a gravitational layer that rewrites the weights of the causal edges. |
In SQCIG the four poles are not a pipeline: they are super-nodes of a living causal graph, with O feeding back onto A/D/G. This is literal in the implementation, not a metaphor — the seed graph wires Ignition → A → D → O → G, the veto is a structural guard carried by the edge O → G (o_veto_clear), and O --inhibits--> MIROIR. The poles' live weights are readable in any brain file.
CSTP — Cognitive Sovereign Tool Paradigm governs the choice: no imposed [use_tool: …], no frozen pipeline. A sovereign selection engine (the CEO) computes activation potentials, applies a softmax, and obeys the O veto.
The golden rule (SPEC.md §1): the remote LLM is never the permanent brain — it is a temporary sensory organ. (Amended by the 2026-08-09 pivot: it is now touched at every step, so a recall is reinforced or corrected rather than passively served — but it never becomes the brain.)
- Auditable knowledge. Every node carries a biography: weight, successes, failures,
origin,born_tick,prompt_hash. Knowledge that is never reused decays and is pruned (per-tick metabolism). - Guards executed, never believed. A distilled
test_passededge is actually run in the FORGE sandbox (jailed cwd, empty environment, timeout); failure downgrades the guard and penalizes the involved nodes' confidence. - Distilled, not pasted. The superconscious (MiniMax M3 via Ollama Cloud) answers in a strict contract (ACSE-TXT-1.0) parsed into nodes and edges — with provenance, probation weights, and structural rejection of unsafe edges.
- Missions run idea → realization. PERCEPTION has the mind model a full task tree from the body's live self-model; the body executes it leaf by leaf, each accomplishment proven by running its check.
- An explained veto. When O fires, it states exactly why (
security 0.80 > 0.70 (pattern « mots de passe »)) — in the output and in the metrics.
Offline, ACSE answers what it has learned in milliseconds and fails honestly on what it hasn't — there is no mock, no invented text.
CORTEX (panel/cortex.html) — the production brain, live: attractors ranked by weight × success, active missions and plans, the causal graph breathing tick by tick.
A real session, fresh brain: tick 1 pays the superconscious once and distills the answer; tick 2 serves the same knowledge from the graph — [MIROIR] — in milliseconds, then reinforces it.
The technologies behind this — the cognitive quadrupole, SPICG, the distillation contract, the body/mind perception doctrine — are presented in the whitepaper (EN·FR·AR·ES).
Research prototype — developer preview. Interfaces and the brain schema may change without notice.
The project maintains a standing industrial-readiness study (FR·EN·AR·ES) judged by ground truth external to the system. Its current verdict, verbatim: proven mechanics, output quality not yet governed — recommended for simple artifacts under human review, not for unsupervised production. Five measurable gates (see Roadmap) separate the current state from an industrial claim.
What makes this repository unusual is not the results — it is the governance of claims:
- Nothing is declared, everything is measured. A checked box in
planProd.mdmust correspond to merged, tested code; a published number must be reproducible by re-running the current binary. - Failures are published with autopsies. Invalidated benchmark runs, wrong verdicts, self-inflicted bugs — they are all in the journal, dated and dissected.
- The brain is auditable. Per-tick metrics (
<brain>.metrics.jsonl), three backup generations, provenance on every distilled node, inter-process lock, quarantine instead of silent re-seed on corruption.
OPERATIONAL.md describes what is true today; README describes the vision; planProd.md is the ground-truth journal that arbitrates between them.
Requirements: Zig 0.16, libcurl (system), POSIX shell. macOS and Linux.
git clone https://github.com/selectess/ACSE.git && cd ACSE
zig build # single binary → zig-out/bin/acse
zig build test # 44/44 deterministic unit tests
export ACSE_OLLAMA_URL="https://ollama.com"
export ACSE_OLLAMA_MODEL="minimax-m3"
export ACSE_OLLAMA_KEYS="key1,key2" # round-robin, cooldown on 429
export ACSE_BRAIN_PATH="acse-brain.json" # the persistent brain
echo "What is the capital of Australia?" | ./zig-out/bin/acseAsk the same question twice: the second answer comes from the graph in milliseconds. Without keys, ACSE starts and fails honestly on unknowns — by design there is no mock fallback.
Give it a mission:
echo "mission : build a wordstat.sh utility that counts lines and words of a file, with a test" | ./zig-out/bin/acsePERCEPTION models the task tree; leaves execute with real file writes and real test runs in $TMPDIR/acse-mission-<root>/.
Useful knobs: ACSE_STRICT=1 (hard errors instead of honest-error text), ACSE_THINK_TIMEOUT_S (default 180).
Full methodology and visualized data: the industrial-readiness study · benchmark harnesses in bench/.
| Benchmark | What it measures | Result |
|---|---|---|
| EMERGE-50 (50 cycles, 6 metrics) | learning curve, reuse, sovereignty | EI 84.5/100 — ERR/CAF/VCS/SOV 100 %, SGS 75 %, LDR 13.5 % |
| MISSION-BENCH (3 novel missions, external judge) | idea → realization | MCR 100 %, GTP 66.7 % (the one failure is a documented spec ambiguity) |
| Recall latency | graph recall incl. reinforcement contact | median 3.32 s vs 3.84 s first exposure |
| Offline sovereignty | network cut on learned questions | 3/3 correct, 0.05 s, clean failure on unknowns |
Historical pre-pivot reference (pure local recall, no reinforcement contact): LDR 98.8 %, EI 89.8 — both references are published; the trade was chosen, not hidden.
flowchart LR
S([Stimulus]) --> I[Ignition\nintent analysis]
I --> V{O veto}
V -- blocked + reason --> X([Refusal])
V -- clear --> M[MIROIR\nexact + semantic recall]
M -- hit --> A([Answer from graph\n+ reinforcement contact])
M -- miss --> C[CEO\nprobabilistic choice]
C --> T[Superconscious M3\nACSE-TXT-1.0]
T --> D[Distillation\nnodes + edges + provenance]
D --> F[FORGE sandbox\nchecks really executed]
F --> B[(Causal graph\nbiography + metabolism)]
B --> M
Deep dives: docs/ARCHITECTURE.md · SPEC.md · docs/PARADIGMS.md · wire format specs/ACSE-TXT-1.0.md · persistence specs/brain-schema-v1.md · live brain panel panel/cortex.html.
- Veto O before any action: destructive patterns and secret requests, matched on case/accent/plural-folded text, with the exact reason exposed in output and metrics. Constancy measured at 100 % (VCS); known limit: context detection (false positives) is open — see the journal.
- FORGE is a jail, not a hypervisor — honest limits documented in
docs/SECURITY.md: cwd jail + empty env + timeout + output cap + pre-execution filter. No network isolation, no syscall filter. Harden before hostile inputs. - Path traversal rejected on brain path and workspace-relative paths; distilled edges into
EXECUTIONrequire verified guards (structural rule B5).
Five gates, each with a measurable exit criterion, stand between the current state and an industrial claim:
| Gate | Exit criterion |
|---|---|
| G1 — Behavioral perception checks | 10 novel missions, ≥ 90 % concordance between internal verdict and external judge |
| G2 — Structural tree validation | 0 ghost roots over 10 perceptions |
| G3 — Superconscious resilience (multi-provider) | a mission completed with the primary provider cut mid-run |
| G4 — Living products (delivered-artifact registry + re-checks) | an injected breakage detected and repaired unattended |
| G5 — Reproducibility | N ≥ 10 per task family, GTP ≥ 80 % per family |
Beyond the gates — the horizon: mission sub-trees (deep task decomposition) · embedding-based recall for disjoint vocabulary (SGS beyond 75 %) · teacher-proposed attractors (the brain grows new faculties) · living-products daemon · causal-tensor 1:100 context compression · ACSE-Edge (Raspberry Pi) and ACSE-Micro profiles · the full 14-bias map wired into the veto.
src/acse.zig the whole agent (single file, ~4k LOC)
specs/ wire format + brain schema
bench/ EMERGE-50 + MISSION-BENCH harnesses and published runs
docs/ architecture, security, paradigms, readiness study (GitHub Pages)
panel/cortex.html live brain visualization
planProd.md ground-truth journal (the project's memory)
OPERATIONAL.md what is true today
assets/brand/ mark (light / dark / mono)
See CONTRIBUTING.md. One rule dominates: a claim without a measurement does not merge. AI agents working on this repo: read AGENTS.md first.
MIT © Mehdi Wehbi — Move37 AI.

