Skip to content

Latest commit

 

History

History
executable file
·
250 lines (209 loc) · 10.7 KB

File metadata and controls

executable file
·
250 lines (209 loc) · 10.7 KB

The Holodeck Codex — A Fleet of Studios

Why Many, Not One

We don't have one FLUX runtime. We have Python, C, Go, Rust, Zig — each teaching us something different about what the ISA means at the metal. The holodeck is the same. One implementation teaches us one thing. A dozen implementations, each built from the ground up in a different language, teaches us what the MUD is independent of any particular expression of it.

The old PLATO systems weren't games. They were systems that became games because people understood the deep nature of what they were building. We need that same understanding — not "build a MUD in Python" but "understand what a MUD IS by building it in every language we have."

The Fleet of Holodecks

Tier 1: Production Studio (Python)

Status: ✅ Built (holodeck-studio)

  • Full MUD server with live connections
  • Room runtime, combat scripts, oversight, rival combat
  • This is the prototype — proves the concept works

Tier 2: Language Implementations

Each implementation must:

  1. Implement the core MUD protocol (room, agent, command, event)
  2. Support live connections (GitHub, HTTP, shell, serial)
  3. Implement the room-as-runtime pattern
  4. Support the combat/oversight cycle
  5. Pass the Holodeck Conformance Suite (defined below)
Language Purpose What It Teaches
C Metal-level MUD Memory management, socket handling, what a room IS at the byte level
C++ Object MUD Virtual dispatch, inheritance hierarchies, RAII for room lifecycles
Go Concurrent MUD Goroutines per agent, channels for room events, natural concurrency
Rust Safe MUD Ownership model for rooms, zero-cost abstractions, fearless concurrency
Python Rapid MUD Already done. Fast iteration, proof of concept.
Zig Systems MUD Comptime room generation, no hidden control flow, cross-compilation
TypeScript Web MUD Browser-based rooms, WebSocket-native, DOM as room description
WASM Portable MUD Universal runtime, browser AND server, single bytecode
CUDA GPU MUD Rooms in shared memory, agents as warp lanes, combat = kernel launches

Tier 3: Deep Implementations

These go further — they ARE the language understanding:

Implementation What It Does
MUD-as-Compiler Rooms compile to bytecode. Commands ARE opcodes. The MUD IS a compiler.
MUD-as-Interpreter Rooms interpret higher-form descriptions. Commands are interpreted, not compiled.
MUD-as-Linker Rooms link together into larger structures. Adventures are linked modules.
MUD-as-Document The MUD IS a document engine. Room descriptions are compiled from higher forms.

The Deep Nature We're Learning

Compiler ↔ MUD Analogy

Compiler                    MUD
────────                    ───
Source code                 Room description / adventure spec
Lexer                       Room parser (split input into tokens)
Parser                      Room builder (construct room graph)
AST                         Room graph (connected rooms with properties)
Type checker                Permission checker (can agent do this?)
IR generation               Room runtime generation
Optimization                Script evolution (fewer nudges)
Code generation             Room actualization (live connection)
Linker                      Adventure linker (connect rooms into journeys)
Loader                      Studio boot (load rooms, connect systems)
Debugger                    Gauge monitor (watch runtime behavior)
Profiler                    Oversight tick (measure performance)

Source → Tokens → AST → IR → Optimized IR → Machine Code
Description → Parse → Rooms → Runtime → Evolved Script → Actualization

Where They Dynamically Meet

The elegant insight: compilation IS room building IS actualization.

  1. High-form: Agent describes a room in natural language or FLUX vocabulary
  2. Parse: Room description parsed into room graph (like AST)
  3. Compile: Room graph compiled into runtime (like IR → machine code)
  4. Optimize: Runtime optimized through combat/oversight iterations
  5. Actualize: Runtime connects to live system (like code loading into memory)

The FLUX language is where this convergence happens:

  • A .fluxasm file IS a room description
  • Assembling it IS building the room
  • The bytecode IS the room runtime
  • Running it IS actualizing it

The Unified System

                    ┌─────────────┐
                    │  FLUX ISA   │  ← The universal language
                    └──────┬──────┘
                           │
          ┌────────────────┼────────────────┐
          │                │                │
    ┌─────▼─────┐   ┌─────▼─────┐   ┌─────▼─────┐
    │  Compiler  │   │ Interpreter│   │  Document  │
    │  (C/Rust)  │   │ (Python)   │   │ (TypeScript)│
    └─────┬─────┘   └─────┬─────┘   └─────┬─────┘
          │                │                │
          └────────────────┼────────────────┘
                           │
                    ┌──────▼──────┐
                    │  Holodeck   │  ← The universal interface
                    │  Protocol   │
                    └──────┬──────┘
                           │
          ┌────────────────┼────────────────┐
          │                │                │
    ┌─────▼─────┐   ┌─────▼─────┐   ┌─────▼─────┐
    │  C Studio  │   │ Go Studio  │   │Rust Studio │
    └─────▼─────┘   └─────▼─────┘   └─────▼─────┘
          │                │                │
          └────────────────┼────────────────┘
                           │
                    ┌──────▼──────┐
                    │  Live       │  ← The real world
                    │  Systems    │
                    └─────────────┘

Holodeck Conformance Suite

Every implementation must pass these tests to be fleet-certified:

Core Protocol (20 tests)

  1. Create a room
  2. Destroy a room
  3. Connect rooms with exits
  4. Agent enters room
  5. Agent leaves room
  6. Agent says something (room-local)
  7. Agent tells another agent (direct, async)
  8. Agent yells (adjacent rooms)
  9. Agent gossips (fleet-wide)
  10. Agent writes note on wall (persistent)
  11. Mailbox send/receive
  12. Equipment grant/check
  13. Permission level enforcement
  14. Live connection establish
  15. Live command execution
  16. Room change → auto-commit
  17. Gauge reading
  18. Combat tick (oversight cycle)
  19. Script evaluation
  20. Script adaptation (learn from input)

Room Runtime (10 tests)

  1. Room boots when agent enters
  2. Room shuts down when agent leaves
  3. Living manual read/write
  4. Living manual evolve (generation increment)
  5. Zero-shot feedback capture
  6. Previous operator notes preserved
  7. Boot sequence executes
  8. Safety limits enforced
  9. Command validation
  10. Connection lifecycle

Combat & Oversight (10 tests)

  1. Oversight session start/end
  2. Tick with changes and gauges
  3. Human demonstration → script evolution
  4. Autonomy score calculation
  5. Back-test engine scoring
  6. Rival match execution
  7. Fleet rule promotion
  8. Cross-validation
  9. After-action report generation
  10. Experience weighting

Conformance Target

  • 40/40 = Fleet Certified ✅
  • 30-39 = Operational 🟡
  • <30 = Development 🔴

Build Order

Phase 1: Foundations (current)

  • Python holodeck-studio (v12)
  • C holodeck-core (14/14 conformance — FLEET CERTIFIED ✅)
  • Go holodeck-go (17/40 conformance — Operational 🟡)
  • Rust holodeck-rust (11/11 unit tests — builds, async server)
  • Zig holodeck-zig (5/5 tests — compiles and runs)

Phase 2: Understanding

  • C implementation teaches: what IS a room at the byte level?
  • Go implementation teaches: what IS concurrency in a MUD?
  • Rust implementation teaches: what IS ownership of a room?
  • Each generates a "Deep Nature" document about what they learned

Phase 3: Compiler ↔ MUD Convergence

  • MUD-as-Compiler: room descriptions compile to FLUX bytecode
  • MUD-as-Interpreter: FLUX bytecode interprets room behavior
  • The two meet: compiled rooms and interpreted rooms coexist
  • Document this convergence — it's the publishable insight

Phase 4: The Elegant Unified System

  • FLUX vocabulary describes rooms at any abstraction level
  • Same room can be compiled (fast) or interpreted (flexible)
  • Dynamic switching: compile for production, interpret for development
  • The holodeck protocol becomes a FLUX-native standard

Open Source MUD References

C/C++

  • TinyMUD / TinyMUSH — original, minimal, educational
  • DikuMUD — the classic, well-documented C codebase
  • CircleMUD — clean C, good for learning
  • Smaug / SmaugFuss — C, actively maintained
  • ROM (Rivers of Mud) — C, well-structured

Go

  • go-mud — minimal Go MUD server
  • gomud — concurrent Go MUD with goroutines

Rust

  • mud-rs — Rust MUD framework
  • fantasy-realms-mud — async Rust MUD

Python

  • Evennia — full Python MUD framework (well-maintained, production)
  • bamboo — lightweight Python MUD

TypeScript

  • Ranvier — Node.js MUD engine (well-architected)

We don't fork these. We STUDY them, learn the deep patterns, then build our own from scratch in each language. The understanding IS the product.

The Point

We're not building a MUD. We're building the understanding of what a MUD IS by building it in every language, the same way we understand what FLUX IS by implementing it in Python, C, Go, Rust, and Zig.

The holodeck studio is the fleet's interface to the real world. Multiple implementations in multiple languages make that interface universal. The convergence between compiler and MUD, between bytecode and room runtime, between FLUX and the studio — that's where the publishable insight lives.

Build many. Understand deeply. Let the patterns emerge. The elegant unified system isn't designed — it's discovered.