Skip to content

Commit 2d5b6f0

Browse files
hyperpolymathJoshuaJewellclaude
committed
Coprocessor consolidation (10→3), hype cleanup, design docs
Coprocessor backends consolidated by concern: - Coprocessor_Compute.res: Maths + Vector + Tensor + Physics (4 nested modules) - Coprocessor_Security.res: Crypto + Neural + Quantum + Audio + Graphics (5 nested modules) - Coprocessor_IO.res: unchanged (per-device stateful filesystem) - Coprocessor_Backends.res rewritten for nested module paths - Kernel_Crypto.res and Kernel_Quantum.res comments updated - 9 old individual files deleted AI-generated multiplayer hype files deleted: - pata_orchestrator.ex, consensus_core.ex, bonding_handler.ex, pressure_monitor.ex, control_channel.ex — all dead code from Gemini/Copilot sessions, none reviewed or requested - Cleaned references from application.ex and user_socket.ex Design documents added: - DESIGN-DECISIONS.adoc: developer-facing (476 lines) — language stack, containers, formal verification, coprocessors, reversible VM, multiplayer - DESIGN-OVERVIEW.adoc: public-facing (273 lines) — plain-language explanation of what the game is and why the stack looks unusual Machine-readable docs updated: - STATE.scm v1.7.0: coprocessor consolidation, hype cleanup, stack finalized - META.scm v1.1.0: ADR-019 (consolidation), ADR-020 (5-lang stack), ADR-021 (AI audit policy) - ECOSYSTEM.scm: Axiom.jl connection, removed technologies, primary stack corrected Co-Authored-By: Joshua B. Jewell <JoshuaJewell@users.noreply.github.com> Co-Authored-By: Jonathan D.A. Jewell <6759885+hyperpolymath@users.noreply.github.com> Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 2ce0622 commit 2d5b6f0

26 files changed

+2634
-2734
lines changed

.machine_readable/ECOSYSTEM.scm

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,14 @@
4747
(project "standards"
4848
(relationship "governance")
4949
(description "RSR and protocol standards that IDApTIK follows")
50-
(location "standards/")))
50+
(location "standards/"))
51+
52+
(project "Axiom.jl"
53+
(relationship "sibling-prototype")
54+
(description "Julia neural network framework where coprocessor patterns were first prototyped; has 15 backend types in abstract.jl (2,857 lines — consolidation pending)")
55+
(location "developer-ecosystem/julia-ecosystem/packages/Axiom.jl/")))
5156

5257
(technologies
53-
(primary "ReScript" "Deno" "Elixir" "Tauri")
54-
(secondary "Idris2" "Zig" "PixiJS" "Phoenix")))
58+
(primary "ReScript" "Idris2" "Zig" "Elixir" "Rust")
59+
(secondary "Deno" "PixiJS" "Phoenix" "Tauri")
60+
(removed "V-lang" "Chapel" "Dragonfly")))

.machine_readable/META.scm

Lines changed: 29 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22
;; META.scm — Meta-level information for IDApTIK monorepo
33
;; Media Type: application/meta+scheme
44
(meta
5-
(version "1.0.0")
6-
(last-updated "2026-02-20")
5+
(version "1.1.0")
6+
(last-updated "2026-02-27")
77

88
(architecture-decisions
99
(adr "ADR-001"
@@ -150,6 +150,30 @@
150150
(decision "8-rank enemy hierarchy in 4 categories: security (BasicGuard, SecurityGuard, Sentinel, EliteGuard, SecurityChief), specialist (AntiHacker — ONLY reverser, cowardly, panics, flees mid-reversal), competitor (RivalHacker — races to complete objectives, sabotages player), unknown (Assassin — appears from hiding, deadly ambush, sets traps). SENTRY becomes dispatch coordinator — cannot undo without anti-hackers.")
151151
(consequences "Rich enemy diversity, anti-hacker management as core strategy, rival adds time pressure, assassin adds unpredictable tension, SENTRY neutered if all specialists flee")))
152152

153+
(adr "ADR-019"
154+
(title "Coprocessor consolidation: 10 files to 3")
155+
(status accepted)
156+
(date "2026-02-27")
157+
(context "10 individual coprocessor backend files (Crypto, Maths, Vector, Tensor, Physics, Neural, Quantum, Audio, Graphics, IO) duplicated open/module/registration boilerplate; scattered across 4 build directories creating 36 stale copies")
158+
(decision "Consolidate by concern: Coprocessor_Compute.res (Maths+Vector+Tensor+Physics), Coprocessor_Security.res (Crypto+Neural+Quantum+Audio+Graphics), Coprocessor_IO.res (unchanged, per-device stateful). Each old file becomes a nested module. Coprocessor_Backends.res rewritten to use nested paths.")
159+
(consequences "3 files instead of 10; zero functionality change; cleaner imports; easier contributor onboarding; mirrors IDApTIK's 3-domain grouping (Compute, Security, IO)"))
160+
161+
(adr "ADR-020"
162+
(title "Language stack finalization: 5 languages only")
163+
(status accepted)
164+
(date "2026-02-27")
165+
(context "Stack had accumulated V-lang (redundant web server), Chapel (heavy HPC runtime for simple parallel solvers), and Dragonfly (external cache when ETS is native to BEAM)")
166+
(decision "Final stack: ReScript (UI), Idris2 (ABI), Zig (FFI+solvers), Elixir (APIs+sync), Rust (Tauri shell). V-lang, Chapel, Dragonfly removed.")
167+
(consequences "5-language stack with clear separation; no redundant tools; contributors only need ReScript for game work; Elixir's BEAM provides caching natively (ETS/DETS)"))
168+
169+
(adr "ADR-021"
170+
(title "AI-generated code audit: delete-on-discovery policy")
171+
(status accepted)
172+
(date "2026-02-27")
173+
(context "Multiple AI assistants (Gemini, Copilot) generated dead code from casual conversation — PATAOrchestrator, ConsensusCore, BondingHandler, PressureMonitor, ControlChannel — none of which was reviewed or requested")
174+
(decision "Delete all AI-generated dead code immediately on discovery. No attempt to salvage or refactor. Verify references are cleaned from supervisors, routers, and config files.")
175+
(consequences "Cleaner codebase; establishes that AI code must be reviewed before merging; prevents accumulation of confabulated features"))
176+
153177
(development-practices
154178
(practice "All ReScript, no TypeScript or raw JavaScript")
155179
(practice "Deno runtime exclusively, no Node/npm/bun")
@@ -188,9 +212,9 @@
188212

189213
(infrastructure
190214
(containers
191-
(image "idaptik-game" (base "cgr.dev/chainguard/static:latest") (port 80) (note "Static browser game"))
192-
(image "idaptik-escape-hatch" (base "cgr.dev/chainguard/static:latest") (note "TUI — requires -it flag"))
193-
(image "idaptik-sync" (base "cgr.dev/chainguard/wolfi-base:latest") (port 4000) (note "Elixir OTP release")))
215+
(image "idaptik-game" (base "cgr.dev/chainguard/nginx:latest") (port 8080) (note "Static browser game; 19.9 MB; immutable cache headers, SPA fallback, gzip"))
216+
(image "idaptik-escape-hatch" (base "cgr.dev/chainguard/wolfi-base:latest") (note "TUI — requires -it flag; Podman subprocess integration"))
217+
(image "idaptik-sync" (base "cgr.dev/chainguard/wolfi-base:latest") (port 4000) (note "Elixir OTP release; ETS cache (no external deps)")))
194218
(orchestration "podman-compose.yml" (services "game sync") (note "escape-hatch runs separately"))
195219
(dlc-bundler "shared/scripts/bundle-puzzles.js" (note "Build-time: scans DLC dir → main-game/src/generated/puzzle-bundle.json")))
196220

.machine_readable/STATE.scm

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,32 @@
11
;; SPDX-License-Identifier: PMPL-1.0-or-later
2-
(state (metadata (version "1.6.0") (last-updated "2026-02-27") (status active))
2+
(state (metadata (version "1.7.0") (last-updated "2026-02-27") (status active))
33
(project-context
44
(name "idaptik")
55
(purpose "Asymmetric co-op stealth puzzle-platformer and adaptive game engine ecosystem")
66
(completion-percentage 98))
77
(components
88
(component "vm" (status "active") (completion 95) (description "Pure reversible VM library — 23 instructions (Tier 0-4), stack, memory, subroutines, I/O ports"))
9-
(component "shared" (status "active") (completion 97) (description "Cross-component types — 422/422 tests, RetryPolicy, Diagnostics, CoprocessorManager (mapBounded), OPUS-TODO roadmap"))
9+
(component "shared" (status "active") (completion 97) (description "Cross-component types — 422/422 tests, RetryPolicy, Diagnostics, CoprocessorManager; coprocessors consolidated 10→3 files (Compute, Security, IO) on 2026-02-27"))
1010
(component "dlc/idaptik-reversible" (status "active") (completion 99) (description "Puzzle DLC pack — 29 puzzles, CLI with REPL, batch validator, examples; 42/42 tests pass (4 suites: Tier-0 instrs, VM undo, PuzzleSolver, InstructionParser); build clean"))
1111
(component "main-game" (status "active") (completion 99) (description "Browser hacking sim — PWA complete (raster icons 192/512/maskable/apple-touch); HardwareWiring Phase 2 (onConnectionMade→ImprovisedLink CovertLink); build clean"))
1212
(component "multiplayer" (status "active") (completion 95) (description "Asymmetric co-op — PhoenixSocket V2 wire format (array frames + vsn=2.0.0); player_id URL param; terminal coop connect→join→chat wired; VMMessageBus.readPortOutput implemented; Playwright E2E test written (5 suites: load/connect/join/chat/disconnect)"))
13-
(component "sync-server" (status "active") (completion 88) (description "Elixir sync server — 6/6 connectivity tests pass (REST + WS channel join); GameChannel after_join pattern fixed; check_origin:false; vsn=2.0.0 WS negotiation; ConsensusCore crash fix; DRAGONFLY_HOST"))
13+
(component "sync-server" (status "active") (completion 88) (description "Elixir sync server — 6/6 connectivity tests pass (REST + WS channel join); GameChannel after_join pattern fixed; check_origin:false; vsn=2.0.0 WS negotiation; ETS cache (Dragonfly removed 2026-02-27); AI-generated resilience core deleted 2026-02-27"))
1414
(component "escape-hatch" (status "active") (completion 85) (description "Developer TUI portal — Rust + ratatui, classified mainframe theme; real Podman subprocess integration (ps/stats/inspect/logs/pull/restart); auto-refresh 5s; log scroll; command history"))
15-
(component "idaptik-level-architect" (status "active") (completion 30) (description "Tauri 2 level editor — Idris2 ABI, Zig FFI, Chapel solvers"))
15+
(component "idaptik-level-architect" (status "active") (completion 30) (description "Tauri 2 level editor — Idris2 ABI (14 modules), Zig FFI + solvers (Chapel removed 2026-02-27); V-lang server removed 2026-02-27"))
1616
(component "idaptik-developers" (status "active") (completion 85) (description "Developer portal — 17 ADRs (incl. coprocessor spec), white paper, TUI mockups"))
17-
(component "containers" (status "active") (completion 95) (description "3 Containerfiles (game, escape-hatch, sync-server) + podman-compose.yml; ALL THREE HEALTHY — dragonfly (Redis cache), sync (Elixir/Phoenix), game (Chainguard nginx serving Vite SPA); port mapping fix: Chainguard nginx listens on 8080 (non-root), not 80; vite.config.js @rescript/core alias fixes prod build")))
18-
(component "idaptiky" (status "legacy") (completion 90) (description "LEGACY — migrated to vm/ + dlc/; retained for reference")))
17+
(component "containers" (status "active") (completion 95) (description "2 services (game + sync) in podman-compose.yml; Dragonfly removed 2026-02-27 (ETS handles caching); Chainguard nginx on 8080; Elixir/Phoenix sync on 4000")))
18+
;; idaptiky/ deleted 2026-02-27 — legacy artefact, code migrated to vm/ + dlc/
1919
(critical-next-actions
20-
(action "Level Architect MVP: see WORKPLAN-2026-02-27.md in idaptik-level-architect/")
20+
(action "Level Architect MVP: implement level data model (14 Idris2 ABI modules) — see plan file")
2121
(action "Game balance: play-test levels; tune guard spawn rates and alert thresholds in LevelConfig.res")
2222
(action "Sonnet: migrate 1,723 deprecated Js.* API calls to @rescript/core equivalents")
2323
(action "Sonnet: extract duplicated %raw keyboard handler blocks (5 files) to shared utility")
24-
(action "Sonnet: migrate 24 getExn/parseExn calls in vm/idaptiky to SafeFloat/SafeJson"))
24+
(action "Sonnet: migrate 24 getExn/parseExn calls in vm/idaptiky to SafeFloat/SafeJson")
25+
(action "Axiom.jl: consolidate 2,857-line abstract.jl into 4+ focused files — see TODO-URGENT-COPROCESSOR-CONSOLIDATION.md"))
2526
(recent-changes
27+
(change "2026-02-27" "OPUS-SESSION-2: Coprocessor consolidation (10 individual files→3: Coprocessor_Compute.res [Maths+Vector+Tensor+Physics], Coprocessor_Security.res [Crypto+Neural+Quantum+Audio+Graphics], Coprocessor_IO.res [unchanged]); 36 stale copies deleted across build dirs; Kernel_Crypto.res and Kernel_Quantum.res comments updated; Coprocessor_Backends.res rewritten to use nested module paths")
28+
(change "2026-02-27" "OPUS-SESSION-2: Deleted 5 AI-generated multiplayer hype files (pata_orchestrator.ex, consensus_core.ex, bonding_handler.ex, pressure_monitor.ex, control_channel.ex); removed Resilience Core from application.ex; removed control:* channel from user_socket.ex")
29+
(change "2026-02-27" "OPUS-SESSION-2: Created DESIGN-DECISIONS.adoc (developer-facing, 476 lines) and DESIGN-OVERVIEW.adoc (public-facing, 273 lines) at repo root; language stack finalized (ReScript+Idris2+Zig+Elixir+Rust); V-lang, Chapel, Dragonfly removed")
2630
(change "2026-02-27" "OPUS-SESSION: Container port fix (8080:80→8080:8080); custom nginx.conf (immutable cache headers, security headers, SPA fallback, gzip); container security hardening (read_only rootfs, cap_drop ALL, no-new-privileges, tmpfs); dragonfly thread fix (2 threads for dev); E2E health URL bug fixed (double /health); 15/15 Playwright E2E pass; PanicHandler innerHTML XSS fixed (textContent); Tauri unsafe SAFETY comment added; PATA hardcoded path fixed; NetworkTransfer SafeFloat guard; Justfile compose recipes; level architect WORKPLAN-2026-02-27.md written")
2731
(change "2026-02-27" "CONTAINER-FIXES: dragonfly --save_schedule crash fixed; game Containerfile nginx runtime (static→nginx, bash); sync Containerfile wget; compose healthcheck -O /dev/null; vite.config.js @rescript/core alias; prod build now clean")
2832
(change "2026-02-26" "PLAYWRIGHT-E2E: multiplayer_e2e_playwright.mjs — 5 suites (game load, coop connect/join/chat/disconnect); preflight HTTP checks for game+sync servers; graceful Deno.exit(0) skip when servers not running (CI-safe); run_tests.mjs structure test updated")

0 commit comments

Comments
 (0)