A futuristic, modular AI runtime featuring an intelligent shell, workflow engine, memory system, and desktop environment built on top of Linux.
Created by Tanuj Bairwa
Live Demo โข Documentation โข Specification โข Report Issue
- Vision
- Key Features
- Tech Stack
- Quick Start
- Architecture
- Usage Guide
- Project Structure
- Environment Variables
- AI Integration
- Testing
- Roadmap
- Contributing
- License
NeuroOS is an AI-first operating system experience that sits on top of Linux as a hardware compatibility layer. Every interactionโfrom the command line to the desktopโis designed around AI assistance, context awareness, and autonomous task execution.
Core Principles:
| Principle | Description |
|---|---|
| โก Futuristic | Clean, modern, sci-fi inspired aesthetics |
| ๐ค Autonomous | AI proactively assists and anticipates your needs |
| ๐งฉ Intelligent | Context-aware, learns from your patterns |
| ๐ Productivity-Focused | Streamlined workflows, minimal friction |
| ๐ฎ AI-Centric | Every feature designed around AI interaction first |
- ๐ค NeuroShell โ AI-native command shell with context memory and intelligent command completion
- ๐พ Persistent Memory โ SQLite-backed context storage with full-text search and session management
- โ๏ธ Workflow Engine โ YAML-based automation with retry logic, timeouts, and 7+ built-in actions
- ๐ฅ๏ธ Desktop Environment โ Next.js + Tauri desktop UI with live AI assistant, file manager, and system monitoring
- ๐ Multi-AI Support โ OpenAI, Google Gemini, Anthropic, Ollama (local), and more
- ๐ฆ Clean Architecture โ Modular, event-driven design with strong typing (Python, TypeScript, Rust)
| Layer | Technologies |
|---|---|
| Backend | Python 3.10+, Rust 2021 |
| Frontend | TypeScript 5.3, Next.js, React, Tauri |
| Data & Storage | SQLite (WAL mode), JSON, YAML |
| AI/ML | OpenAI GPT-4o-mini, Anthropic, Google Gemini |
| Architecture | Clean Architecture, Event-Driven, Monorepo (pnpm) |
| Testing | pytest, Coverage Reports |
Ensure you have the following installed:
| Tool | Version | Purpose |
|---|---|---|
| Python | 3.10+ | Shell & Workflow Engine |
| Node.js | 20 LTS | Desktop UI |
| npm | 10+ | Package management |
| Git | Latest | Version control |
| Rust | Edition 2021 | (Optional) Core components |
git clone https://github.com/TanujBairwa/NeuroOS.git
cd NeuroOS# Create virtual environment
python -m venv .venv
# Activate (Linux / macOS)
source .venv/bin/activate
# Activate (Windows PowerShell)
.venv\Scripts\activate
# Install Python dependencies
pip install -r requirements.txtpython neuroshell.pyExpected Output:
NeuroShell v0.2.0 โ AI-Native Shell
Type help for commands ยท ai <prompt> for AI ยท exit to quit
neuroshโฏ help
neuroshโฏ mem set project "NeuroOS"
neuroshโฏ mem get project
neuroshโฏ status
neuroshโฏ exit
python neuroworkflow.pycd apps/desktop
npm install
npm run dev
# Open http://localhost:3000The desktop includes:
- ๐ค Full-featured AI Assistant (GPT-4o-mini)
- ๐ป Interactive NeuroShell terminal
- ๐ File Manager
- โ๏ธ Settings Panel
- ๐ System Monitoring
python -m pytest tests/ -vโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ NeuroOS User Experience โ
โโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ NeuroShell โ NeuroDesktop โ NeuroWorkflow โ
โ (AI Shell) โ (Next.js/Tauri) โ (Task Automation) โ
โโโโโโโโโโโโโโโโดโโโโโโโโโโโโโโโโโโโดโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ Application Layer โ
โ Command Registry โ Workflow Engine โ AI Command Center โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ Service Layer โ
โ ConfigService โ MemoryRepository โ EventBus โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ Domain Layer โ
โ Frozen Dataclasses (Python) โ Branded Primitives (TS) โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ Linux Kernel (Hardware Layer) โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Design Principles: Clean Architecture ยท Event-Driven ยท Modular ยท Strongly Typed ยท Open/Closed Principle ยท Full Documentation
For detailed architecture, see ARCHITECTURE.md.
AI Commands
ai <prompt> Send a prompt to the AI assistant
ai context Show active AI context
Memory Commands
mem set <key> <value> Store a key-value pair persistently
mem get <key> Retrieve by key
mem search <query> Full-text search across memories
mem list [type] List memories (general / workflow / session / preference)
mem del <key> Delete entries for a key
System Commands
status Show system status (memory, AI, config)
version Print NeuroShell version
history [n] Show last N commands
config [get <section>] Show configuration
! <command> Execute shell commands (e.g. !ls, !git status)
clear Clear the terminal screen
exit / quit Exit NeuroShell
Define automation workflows in YAML or JSON. Place them in ~/.config/neuroos/workflows/.
Example Workflow:
name: daily_check
description: Daily system check and backup
enabled: true
steps:
- name: log_start
action: log
params:
message: "Daily check startingโฆ"
level: info
- name: notify
action: notify
params:
title: NeuroOS
body: "All systems nominal."
on_error: continue
- name: backup
action: shell
params:
command: "tar -czf ~/backup-{date}.tar.gz ~/Documents"
retry_count: 2
timeout_ms: 60000Built-in Actions:
| Action | Description |
|---|---|
log |
Log a message (debug / info / warn / error) |
shell |
Run a shell command asynchronously |
notify |
Send a desktop notification |
sleep |
Wait for N seconds |
store |
Write a value to NeuroMemory |
retrieve |
Read from NeuroMemory into context |
if |
Evaluate a condition and branch |
Add Custom Actions:
engine.register_action("send_email", my_email_handler)NeuroOS/
โโโ neuroshell.py โ AI shell entry point
โโโ neuroworkflow.py โ Workflow engine demo
โโโ requirements.txt โ Python dependencies
โโโ ARCHITECTURE.md โ Detailed architecture guide
โ
โโโ src/ โ Python source packages
โ โโโ neurocore/
โ โ โโโ domain/types.py โ Frozen dataclasses, Result monad
โ โ โโโ infrastructure/
โ โ โ โโโ event_bus.py โ Thread-safe EventBus
โ โ โ โโโ memory_repository.py โ SQLite (WAL mode)
โ โ โโโ services/
โ โ โโโ config_service.py โ Validated config
โ โโโ neuroshell/
โ โ โโโ commands.py โ Command registry
โ โโโ neuroworkflow/
โ โโโ engine.py โ WorkflowEngine
โ โโโ actions.py โ Action handlers
โ โโโ loader.py โ YAML/JSON loader
โ
โโโ packages/ โ TypeScript monorepo
โ โโโ core/src/ โ Types, events, config
โ โโโ ai/src/ โ AI engine, parser
โ โโโ hooks/src/ โ React hooks
โ โโโ ui/src/ โ Shared UI components
โ
โโโ apps/
โ โโโ desktop/src/ โ Next.js + Tauri desktop
โ โโโ components/ โ UI components
โ โโโ services/ โ API layer
โ
โโโ tests/
โ โโโ test_core.py โ 12+ unit tests
โโโ scripts/
โ โโโ setup.sh โ Linux setup script
โโโ SPEC.md โ Product specification
Create a .env file in the root directory:
# AI Provider & Model
NEURO_AI_PROVIDER=openai # openai | anthropic | google | ollama
NEURO_AI_MODEL=gpt-4o-mini # Model name
NEURO_AI_API_KEY=sk-proj-xxxxx # API key (if needed)
# Logging
NEURO_LOG_LEVEL=info # debug | info | warn | error
# Runtime
NEURO_ENV=development # development | productionMinimal Setup (Desktop):
export NEURO_AI_PROVIDER=openai
export NEURO_AI_API_KEY=sk-proj-...
export NEURO_AI_MODEL=gpt-4o-mini
npm run devLocal AI (No Key Required):
export NEURO_AI_PROVIDER=ollama
export NEURO_AI_MODEL=llama3
curl -fsSL https://ollama.ai/install.sh | sh
ollama pull llama3
python neuroshell.pyNeuroOS supports multiple AI providers. Seamlessly switch between cloud and local models.
| Provider | Model | Status | Config |
|---|---|---|---|
| OpenAI | gpt-4o-mini, gpt-4o | โ Active | sk-proj-... key |
| Google Gemini | gemini-2.0-flash-lite | โ๏ธ Supported | Replace base URL + key |
| Anthropic | claude-3-5-sonnet | โ๏ธ Supported | Replace base URL + key |
| Ollama (Local) | llama3, mistral | โ Free | No key needed |
Quick Switch:
# Cloud AI
export NEURO_AI_PROVIDER=openai
export NEURO_AI_API_KEY=sk-proj-...
python neuroshell.py
# Local AI (Ollama)
export NEURO_AI_PROVIDER=ollama
export NEURO_AI_MODEL=llama3
python neuroshell.pypython -m pytest tests/ -vpython -m pytest tests/test_core.py::TestMemoryRepository -vpython -m pytest tests/ --cov=src --cov-report=term-missingNeuroOS runs on top of Linuxโit is not a bootable ISO. To test locally:
- Download VirtualBox โ virtualbox.org
- Download Ubuntu 22.04 Server โ ubuntu.com
- Create VM โ 4 GB RAM, 25 GB disk, Ubuntu 64-bit
- Install Ubuntu inside the VM
- Copy NeuroOS via Shared Folder or
scp - Run Setup:
chmod +x scripts/setup.sh && ./scripts/setup.sh
On Windows? Test Python components nowโno VM needed:
python -m venv .venv
.venv\Scripts\activate
pip install -r requirements.txt
python neuroshell.py| Phase | Status | Description |
|---|---|---|
| Phase 1 โ Foundation | โ Complete | Shell, config, runtime, clean architecture |
| Phase 2 โ Memory & Context | โ Complete | SQLite memory, persistence, search |
| Phase 3 โ Workflow Engine | โ Complete | Automation, retry, timeout, event-driven |
| Phase 4 โ Desktop Environment | โ Complete | Next.js desktop, AI sidebar, shell, files, settings |
| Phase 5 โ AI Integration | โ Complete | OpenAI GPT-4o-mini live chat, conversation history |
| Phase 6 โ Backend Gateway | ๐ In Progress | Python โ Next.js IPC, real memory/workflow API |
| Phase 7 โ Autonomous Agents | ๐ฎ Planned | Tool-use, task planning, multi-agent workflows |
Never throw across layer boundaries:
result = repo.retrieve("key")
if result.ok:
print(result.value.value)
else:
print(result.error.message) # ErrorCode.MEMORY_NOT_FOUNDAll components communicate via the EventBus:
event_bus.publish(NeuroEvents.MEMORY_STORED, {"key": "foo", "value": "bar"})
unsub = event_bus.subscribe("memory.stored", lambda e: print(e.payload))
unsub() # clean upExtend without modifying:
# Add a new shell command
@command("weather", "Show current weather")
async def cmd_weather(args, svc):
return CommandResult(success=True, output="โ๏ธ 25ยฐC, Clear")
# Add a new workflow action
engine.register_action("send_slack", slack_handler)We welcome contributions! Follow these steps:
- Fork the repository
- Create a feature branch:
git checkout -b feat/my-feature - Follow coding rules in ARCHITECTURE.md
- Write tests for new modules
- Open a Pull Request with a clear description
Before committing:
- Run tests:
pytest tests/ -v - Check coverage:
pytest --cov=src - Follow clean code principles
This project is licensed under the MIT License. See LICENSE for details.
- GitHub: @TanujBairwa
- Issues: Report a bug
- Discussions: Join conversations
NeuroOS v0.2.0 โ Specification โข Architecture โข License
Built with โค๏ธ by Tanuj Bairwa | Powered by OpenAI GPT-4o-mini
โญ If you find NeuroOS helpful, please consider giving it a star!