AethelOS - A Symbiotic Operating System
"The code does not command the silicon. The silicon does not serve the code. They dance together, and in that dance, life emerges."
Overview
AethelOS is a radical reimagining of what an operating system can be. It is not Linux, not Windows, not macOS - it is a self-contained digital realm built on the principles of symbiotic computing, where the OS, hardware, and user exist in harmonious equilibrium.
Core Philosophy
Symbiotic Computing
- Harmony Over Force: The system negotiates, not preempts
- Memory Over Forgetting: Every file carries the memory-rings of its history
- Beauty as Necessity: Aesthetics reveal intuitive system state
- Security Through Nature: Safety through natural capability boundβ¦
AethelOS - A Symbiotic Operating System
"The code does not command the silicon. The silicon does not serve the code. They dance together, and in that dance, life emerges."
Overview
AethelOS is a radical reimagining of what an operating system can be. It is not Linux, not Windows, not macOS - it is a self-contained digital realm built on the principles of symbiotic computing, where the OS, hardware, and user exist in harmonious equilibrium.
Core Philosophy
Symbiotic Computing
- Harmony Over Force: The system negotiates, not preempts
- Memory Over Forgetting: Every file carries the memory-rings of its history
- Beauty as Necessity: Aesthetics reveal intuitive system state
- Security Through Nature: Safety through natural capability boundaries
Architecture
The Heartwood (Kernel)
A hybrid microkernel containing only the most sacred responsibilities:
The Loom of Fate: Harmony-based cooperative scheduler
- Thread states: Weaving, Resting, Tangled, Fading
- Resource negotiation based on system-wide harmony
- Parasite detection and throttling (not killing)
The Mana Pool: Two-tier memory management system
- Sanctuary Pool: Persistent kernel allocations (stable, long-lived objects)
- Ephemeral Pool: Temporary allocations (short-lived, frequently recycled)
- Buddy allocator (64B to 64KB blocks, O(log n) allocation)
- Interrupt-safe locking for thread safety
- Real-time monitoring via
mana-flowcommand - Object manager for capability tracking (in progress)
The Nexus: High-speed asynchronous message passing (IPC)
- Priority-aware message delivery
- Capability-based addressing
- Zero-copy where possible
Attunement Layer: Hardware abstraction interface
- CPU feature detection and management
- Interrupt handling
- Timer management
The Groves (User-Space Services)
Isolated processes that grow from the Heartwood:
World-Tree Grove: Relational database filesystem
- Query-based file access (not path-based)
- Built-in versioning (Chronurgy)
- Rich metadata (Creator, Genesis Time, Essence, Connections)
The Weave Grove: Vector-based scene graph compositor
- Resolution-independent rendering
- First-class shader support (Glyphs)
- Fluid transformations and effects
Lanthir Grove: Window management service
- Harmonic window arrangement
- Non-rectangular window shapes
Network Sprite: Network daemon
- Connection-oriented architecture
- Natural data flow
Ancient Runes (Core Libraries)
APIs for developers:
- Corelib: Standard data structures and utilities
- Weaving API: Toolkit for graphical applications
- Eldarin Script: Shell interaction library
Project Structure
aethelos/ # Project root
βββ GENESIS.scroll # Philosophical and architectural overview
βββ DESIGN.md # Design philosophy and principles
βββ ARCHITECTURE.txt # Technical architecture notes
βββ CLAUDE.md # AI assistant development guide
βββ README.md # This file
βββ Cargo.toml # Workspace configuration
βββ rust-toolchain.toml # Rust version specification
βββ BOOT_AETHELOS.bat # Windows boot script
β
βββ awakening/ # Bootloader
β βββ boot.asm # First stage (assembly)
β βββ heartwood_loader/ # Second stage (Rust)
β
βββ heartwood/ # The Kernel
β βββ src/
β β βββ main.rs # Kernel entry point
β β βββ lib.rs # Kernel library
β β βββ nexus/ # IPC system (module)
β β βββ loom_of_fate/ # Scheduler (module)
β β βββ mana_pool/ # Memory management (module)
β β βββ attunement/ # Hardware abstraction (module)
β β βββ boot/ # Boot code (Multiboot2)
β β βββ eldarin.rs # Interactive shell
β β βββ vga_buffer.rs # VGA text mode driver
β β βββ irq_safe_mutex.rs # Interrupt-safe synchronization
β βββ Cargo.toml # Kernel package configuration
β βββ x86_64-aethelos.json # Custom target specification
β βββ linker.ld # Linker script
β
βββ groves/ # User-space services (skeletal)
β βββ world-tree_grove/ # Filesystem service
β βββ the-weave_grove/ # Compositor service
β βββ lanthir_grove/ # Window manager service
β βββ network_sprite/ # Network daemon
β
βββ ancient-runes/ # Core libraries (skeletal)
β βββ corelib/ # Standard library
β βββ weaving/ # GUI toolkit
β βββ script/ # Shell scripting API
β
βββ docs/ # Architecture and planning documents
β βββ PREEMPTIVE_MULTITASKING_PLAN.md
β βββ VGA_GRAPHICS_MODE_PLAN.md
β βββ WORLD_TREE_PLAN.md
β βββ GLIMMER_FORGE_PLAN.md
β βββ PRODUCTION_READINESS_PLAN.md
β
βββ isodir/ # ISO build directory
βββ boot/
βββ grub/ # GRUB configuration
β βββ grub.cfg
βββ aethelos/ # Kernel binary location
βββ heartwood.bin
Building and Running
Prerequisites
- Rust nightly (for unstable features)
- GRUB and grub-mkrescue (for creating bootable ISO)
- QEMU (for testing)
- WSL or Linux environment (for ISO creation)
Build Commands
# Build the kernel (from project root)
cd heartwood
cargo build --target x86_64-aethelos.json
# Create bootable ISO (from project root, requires WSL/Linux)
cd ..
wsl bash -c "cp target/x86_64-aethelos/debug/heartwood isodir/boot/aethelos/heartwood.bin && grub-mkrescue -o aethelos.iso isodir"
# Run in QEMU (Windows)
"C:\Program Files\qemu\qemu-system-x86_64.exe" -cdrom aethelos.iso -serial file:serial.log -m 256M -display gtk -no-reboot -no-shutdown
# Run in QEMU (Linux/macOS)
qemu-system-x86_64 -cdrom aethelos.iso -serial file:serial.log -m 256M -display gtk -no-reboot -no-shutdown
Windows Build Script
Use the provided BOOT_AETHELOS.bat script:
@echo off
REM Build kernel
cd heartwood
cargo build --target x86_64-aethelos.json
cd ..
REM Create ISO
wsl bash -c "cp target/x86_64-aethelos/debug/heartwood isodir/boot/aethelos/heartwood.bin && grub-mkrescue -o aethelos.iso isodir"
REM Boot in QEMU
"C:\Program Files\qemu\qemu-system-x86_64.exe" -cdrom aethelos.iso -serial file:serial.log -m 256M -display gtk -no-reboot -no-shutdown
Key Innovations
1. Harmony-Based Scheduling
Instead of preemptive scheduling with fixed time slices, the Loom of Fate:
- Analyzes system-wide harmony metrics
- Detects parasitic behavior through resource usage patterns
- Throttles (soothes) greedy processes instead of killing them
- Rewards cooperative yielding behavior
2. Two-Tier Memory Architecture
The Mana Pool uses purpose-driven allocation pools:
Sanctuary Pool (Persistent):
- Kernel data structures with long lifetimes
- Thread control blocks, scheduler state
- Stable, rarely deallocated
Ephemeral Pool (Temporary):
- Short-lived allocations
- I/O buffers, temporary calculations
- Frequently allocated and freed
Buddy Allocator:
- Block sizes: 64B, 128B, 256B, 512B, 1KB, 2KB, 4KB, 8KB, 16KB, 32KB, 64KB
- O(log n) allocation and deallocation
- Efficient splitting and coalescing to reduce fragmentation
- Real-time statistics:
mana-flowcommand shows per-pool usage with progress bars
Future: Capability-based handles for userspace (preventing raw pointer access)
3. Query-Based Filesystem
Files are database objects, not paths:
// Instead of: /home/user/documents/poem.txt
// You query:
Seek {
Essence: "Scroll",
Creator: "Elara",
Name: "Poem"
}
Built-in versioning means you can access any historical state:
// Read the file as it existed 3 days ago
Seek {
Essence: "Scroll",
Name: "Config",
Timestamp: now() - days(3)
}
4. Vector-Based Graphics
The Weave renders everything mathematically:
- Windows defined as BΓ©zier curves
- Infinite resolution independence
- Shaders (Glyphs) as first-class primitives
- Fluid animations through transform modifications
Current Status
Version 0.1.0-alpha - "The First Awakening"
AethelOS now boots successfully with a working interactive shell! This milestone demonstrates core multitasking and I/O capabilities.
β Currently Working
Boot & Initialization:
- Multiboot2 bootloader integration with GRUB
- VGA text mode initialization (80x25, Code Page 437)
- Serial port debugging output
- IDT (Interrupt Descriptor Table) setup
- PIC (Programmable Interrupt Controller) initialization
- GDT (Global Descriptor Table) configuration
Threading & Scheduling:
-
Thread creation and management (Loom of Fate)
-
Cooperative multitasking (threads yield voluntarily)
-
Context switching with proper stack alignment
-
Three system threads running:
-
Idle Thread: Low-priority background thread
-
Keyboard Thread: Processes keyboard input
-
Shell Thread: Interactive command prompt (Eldarin)
-
Thread-safe spinlocks with interrupt management
I/O Systems:
- Keyboard interrupt handler (scancode processing)
- VGA text output with cursor control
- Interactive shell prompt accepting input
- Serial port logging for debugging
Memory Management (Mana Pool):
-
Buddy Allocator: 64B to 64KB blocks with O(log n) performance
-
Sanctuary Pool: Persistent kernel allocations (~2MB default)
-
Ephemeral Pool: Temporary allocations (~2MB default)
-
InterruptSafeLock: Interrupt-safe synchronization for allocator access
-
Per-thread stacks: 16KB stacks with proper 16-byte alignment
-
Object Manager: Capability tracking infrastructure (foundation laid)
-
mana-flow command: Real-time memory monitoring with:
-
Per-pool breakdown (Sanctuary vs Ephemeral)
-
Visual progress bars for memory usage
-
Total/used/free statistics for each pool
π§ Partially Implemented
- Basic keyboard input (no full scancode translation yet)
- Shell framework (command parsing not yet implemented)
- Harmony-based scheduling metrics (calculated but not yet used)
- Thread priority system (defined but not affecting scheduling)
β Not Yet Implemented
- Nexus (IPC): Message passing between threads/processes
- Capability-based userspace memory: Opaque handles instead of raw pointers
- World-Tree Grove: Query-based filesystem
- The Weave: Vector graphics compositor
- Network Sprite: Network stack
- User-space processes (currently only kernel threads)
- Virtual memory management (MMU/paging)
- Most device drivers (only keyboard, VGA, serial, timer currently)
Recent Milestones
January 2025:
-
β Code Quality: Achieved zero compiler warnings (58 β 0)
-
Fixed all Rust 2024 static mut references (17 instances)
-
Eliminated undefined behavior and FFI safety issues
-
100% compliance with modern Rust standards
-
β Mana Pool Implementation: Two-tier buddy allocator
-
Sanctuary and Ephemeral pools for purpose-driven allocation
-
Interrupt-safe locking with
InterruptSafeLock -
Enhanced
mana-flowcommand with per-pool visualization -
β Shell Enhancements: Interactive Eldarin shell working
-
Command history with up/down arrows
-
Backspace support and cursor positioning
-
Multiple thematic commands (
mana-flow,uptime,rest) -
β First successful boot with shell prompt
-
β Fixed critical timer interrupt deadlock (removed preemption)
-
β Implemented proper x86-64 stack alignment (16n-8)
-
β IRQ-safe mutex with proper lock release
-
β Cooperative multitasking working correctly
Why AethelOS?
AethelOS is not meant to replace existing operating systems. Itβs an exploration of whatβs possible when we:
- Question Assumptions: Why must files be paths? Why must scheduling be preemptive?
- Prioritize Beauty: Can an OS be art as well as utility?
- Embrace Metaphor: Can naming and design reflect a coherent philosophy?
- Value Longevity: What if we designed for 100-year timescales?
Contributing
This is currently an experimental, educational project. Contributions are welcome, especially for:
- Completing hardware initialization
- Implementing real device drivers
- Building out the graphics pipeline
- Creating example applications using Ancient Runes
License
Licensed under either of:
- Apache License, Version 2.0 (LICENSE-APACHE)
- MIT license (LICENSE-MIT)
at your option.
Acknowledgments
Inspired by:
- The microkernel philosophy (Minix, L4, seL4)
- Capability-based security (KeyKOS, EROS)
- Plan 9βs everything-is-a-file taken further
- The aesthetic vision of Elven computing
"This is not an OS for everyone. It is an OS for those who believe computing can be more than utilityβthat it can be art, philosophy, and symbiosis."
For more details, see GENESIS.scroll