Hyper-Compressed, Architecturally Sovereign Rust Intelligence Runtime, Double-Wrapped Spatial Action Engine & Native macOS AppKit IDE (HEAV3NS-CODE) — structured under the HEAV3NS-JOY 5-Zone Joyzoning architecture (100% Stability Index, 0 blocking violations, 0 advisories, all 280+ workspace files < 800 lines Tier 1 Optimal).
Sovereign Charter (doc.md) · AGENTS.md · SOUL.md · Aspirational Roadmap · Documentation Hub · Ascendant Intelligence Paper · Project Map · Constitution · Validation Report · Native Product Spec
简体中文 · 日本語 · Tiếng Việt · Bahasa Indonesia · 한국어 · Español · Português · Русский · Українська · Français · Deutsch · 繁體中文 · हिन्दी · Türkçe · Italiano · Polski · العربية · Català
"Not an agent. Not a swarm. Not an operating system. A computational civilization of cooperating intelligence — where the system doesn't merely execute instructions: it understands its environment, learns its structure, remembers its experience, and acts with intent." —
doc.md
| Pillar | Designation | Core Implementation |
|---|---|---|
1. HEAV3NS-MICRO |
The Distilled Intelligence Runtime |
AgentEngine multi-turn ReAct state machine, KV-cache-deterministic SystemPromptSpec (Standard, Compact, SwarmSpecialist, SideQuestion), ContextInspectionSnapshot (/context & /prompt), 3-stage self-healing ToolCallArgParser, and FT-01..FT-05 flight_runner. |
2. SPIDER |
Structural Perception & Environmental Understanding |
environmental_diff.rs (analyze_spider_structural_relationships, classify_element_affordance, detect_modal_or_dialog), EnvironmentalObservation, and spider.check AST audits. |
3. REWIND |
Temporal Cognition, Continuity & Recoverability | 16-MiB ArenaAllocator with SlabBufferSnapshot rewind, pure-Rust SHA-256 WorkspaceSnapshotCas (WouldBlock-protected /undo, /restore, non-Git /diff), two-phase SessionVfs baseline verification, TransactionJournal rollback, and 32-deep VirtualDisplayState undo/redo. |
4. BROCCOLI |
Persistent Knowledge, Memory & Historical Evolution |
BehavioralKnowledgeStore with Laplace-smoothed confidence calibration & LearnedWorkflowProcedure synthesis, hybrid TF-IDF MemoryStore, and Kahn-verified SkillTreeCatalog DAG. |
5. SYNTHETIC SWARM |
Distributed Collective Intelligence | 5-specialist parallel consultation (ComputerUseOrchestrator::consult: VisualPerceiver, StructuralAnalyst, WorkflowNavigator, RiskAssessor, RecoverySpecialist + ConflictResolver) and 7-specialist Legion topological formations with exclusive file reservations & bounded handoffs. |
6. COMPUTER USE |
Embodied Agency: Observation, Interpretation, Action, Adaptation | 9-stage closed-loop ComputerUseOrchestrator, Double-Wrapped SpatialActionMediator (Wrapper A Grounding + Wrapper B Assurance), SpatialInteractionEngine (off-screen auto-scroll & multi-step execute_plan), and zero-trust browser_use. |
7. THE HARNESS |
The Computational Substrate That Binds It All Together | 31 native tools (tool_search 8-slot LRU + execute_tools 32-step batch) & DAG Wave Scheduler (ToolRegistry), 5-stop ExecutionPosture (Shift+Tab / fail-closed RepoConstitution), macOS Seatbelt seatbelt_profile.rs, TurnReceipt (heav3ns.receipt/v1), multiplexed "v": 1 stdio JSON-RPC worker (stdio_worker.rs), and Native macOS AppKit IDE (native/). |
Every source file belongs to one of five strictly enforced architectural zones, verified by joy-check --theme strict:
| Zone | Path | Responsibility & Invariants |
|---|---|---|
PLUMBING |
src/plumbing/ (12 modules), native/... |
Stateless leaf primitives: hash_and_math.rs, text_tokens.rs, json_repair.rs, secret_redactor.rs, seatbelt_profile.rs, shell_guard.rs, fuzzy_patch.rs, vision_and_dom.rs, spatial_geometry.rs, environmental_diff.rs, display_telemetry.rs. 0 upward imports, 0 mutable state (SPI-205). |
DOMAIN |
src/domain/ (31 modules) |
Pure entities & 64 formal I<Name> traits (interfaces/), behavioral & value types (types/, model_catalog.rs, posture_types.rs), SystemPromptSpec, PrefixStabilityTracker, BillingMetering, TurnReceipt, ArenaAllocator, VirtualDisplayState, SpatialActionMediator, SkillTreeCatalog, MemoryStore, CompactionPolicy, SwarmAssignment, and ToolCallArgParser. 0% I/O (SPI-206), <= 3 structs/file (SPI-203). |
INFRASTRUCTURE |
src/infrastructure/ (11 modules) |
Concrete I/O adapters: HttpProvider, pricing_updater (ModelPricingRegistry), ScriptedProvider, SessionVfs, WorkspaceSnapshotCas, BehavioralKnowledgeStore, TransactionJournal, execute_shell_command_sandboxed, dispatch_fs_tool, and search_tools. |
CORE |
src/core/ (20 modules) |
Use-case orchestration: AgentEngine, turn_orchestrator, batch_executor, context_inspector, ComputerUseOrchestrator, SpatialInteractionEngine, slash_and_swarm, SessionStore, ToolRegistry, tool_specs, ToolOutputGovernor, RuntimeRequestQueue, flight_runner, benchmark_runner, and test suites (substrate_tests, spatial_tests, computer_use_tests, zenith_tests, codewhale_zenith_tests). |
UI |
src/ui/ (8 modules w/ roots), native/ |
CLI presenter (cli_presenter.rs, onboarding.rs), multiplexed stdio JSON-RPC worker (stdio_worker.rs, worker_handlers.rs), desktop RPC router (rpc_dispatch.rs), AppKit Native Desktop IDE (native/Sources/Heav3nsCode/), and Composition Roots (lib.rs, main.rs). |
# 1. Run Rust unit, spatial, computer-use, zenith, codewhale & integration test suites (77 tests)
cargo test
# 2. Run Native macOS AppKit test suite (321 tests)
cd native && swift test && cd ..
# 3. Inspect live prompt & context budget HUD, outbound request manifest, receipts, and Flight Suite
cargo run -- context
cargo run -- preview-request
cargo run -- receipts
cargo run -- doctor
cargo run -- --flight
cargo run -- --smoke
# 4. Run strict Joyzoning architectural audit & Stability Doctor (100% SI, Grade A+)
node /Users/bozoegg/Desktop/HEAV3NS-JOY/bin/joy-check.mjs . --theme strict
node /Users/bozoegg/Desktop/HEAV3NS-JOY/bin/joy-check.mjs . --doctor
# 5. Run documentation guardrails check
node bin/docs-check.mjs