Tiling workspace for AI coding agents
AI 编程代理的平铺式工作空间
Zig daemon + React frontend • Low memory footprint • Multi-agent orchestration
- Auto-tiling terminals — Grid layout that automatically arranges panes
- Run any CLI agent — Claude Code, Codex, Copilot CLI, or any terminal program
- Spaces — Organize work into separate spaces, each with its own terminals and tasks
- Task management — Kanban board with 5 status columns, drag-and-drop support
- Persistent workspaces — Layout and state survive restarts (SQLite-backed)
- Lightweight — ~2MB binary, ~30-50MB RAM (vs Electron's 200-300MB)
- Browser-based — Opens in your default browser, no app window needed
# Clone
git clone https://github.com/user/nexus.git && cd nexus
# Install submodules
git submodule update --init --recursive
# Install dependencies and build the frontend
pnpm install
pnpm build
# Build & run daemon
zig build runThe daemon will start on a random port and automatically open your browser.
- Zig 0.15.2+
- Node.js 20+
- pnpm 10+
┌─────────────────────────────────────────────────────────────┐
│ Zig Daemon │
│ • PTY pool (forkpty) │
│ • Session lifecycle management │
│ • SQLite persistence (~/.nexus/default.nexus.db) │
│ • HTTP static server + WebSocket JSON-RPC │
└──────────────────────────┬──────────────────────────────────┘
│ HTTP + WebSocket
┌──────────────────────────┴──────────────────────────────────┐
│ Browser (React 19 + TypeScript) │
│ • TanStack Query (server state) │
│ • Zustand (client state) │
│ • ghostty-web (terminal emulation) │
│ • Tailwind CSS v4 + shadcn/ui │
└─────────────────────────────────────────────────────────────┘
# Build frontend
pnpm build
# Run daemon (opens browser automatically)
zig build run
# Build release binary
zig build -Doptimize=ReleaseFast# Frontend + backend tests
pnpm test├── src/
│ ├── main.zig # Daemon entry point, signal handling, browser open
│ ├── ipc.zig # HTTP static server + WebSocket JSON-RPC
│ ├── pty.zig # PTY spawning and management
│ ├── session.zig # Session lifecycle
│ ├── db.zig # SQLite persistence
│ ├── macos.zig # macOS native folder picker
│ └── notify.zig # System notifications
├── apps/web/ # Active React frontend workspace
│ ├── src/
│ │ ├── app/ # Router, layout, providers
│ │ ├── features/ # Tasks, agents, terminal, chat, settings
│ │ ├── components/ui/ # shadcn/ui components
│ │ ├── rpc/ # WebSocket client, hooks, mutations, queries
│ │ └── stores/ # Zustand stores
│ └── package.json
├── ghostty-web/ # Terminal emulation (submodule)
├── pnpm-workspace.yaml
├── build.zig
└── README.md
MIT. See LICENSE.
- 自动平铺终端 — 网格布局自动排列窗格
- 运行任意 CLI 代理 — Claude Code、Codex、Copilot CLI 或任何终端程序
- 工作空间 — 将工作组织到独立空间,每个空间有自己的终端和任务
- 任务管理 — 5 列看板视图,支持拖拽
- 持久化工作空间 — 布局和状态在重启后保留(SQLite 存储)
- 轻量级 — 约 2MB 二进制文件,约 30-50MB 内存(对比 Electron 的 200-300MB)
- 浏览器运行 — 自动在浏览器中打开,无需应用窗口
# 克隆
git clone https://github.com/user/nexus.git && cd nexus
# 初始化子模块
git submodule update --init --recursive
# 安装依赖并构建前端
pnpm install
pnpm build
# 构建并运行守护进程
zig build run守护进程会在随机端口启动并自动打开浏览器。
- Zig 0.15.2+
- Node.js 20+
- pnpm 10+
MIT. 见 LICENSE。