跳到正文

Cosmicchibattle

zeroclaw-ui

UI for Zeroclaw setup

README 已保存到本站,可直接阅读

Documentation snapshot

README 快照

这篇是英文原文

下面正文是项目自己的英文 README。想读全文就用浏览器自带的整页翻译: Chrome / Edge 点地址栏右侧的翻译图标,或用右键菜单里的「翻译成中文」; 手机浏览器一般在菜单里。

本页保存的是公开项目资料快照,阅读过程不需要连接 GitHub。

🦀 ZeroClaw UI

The missing control center for ZeroClaw — the ultra-lightweight Rust AI agent runtime.

Stop editing config.toml by hand. Run, configure, and supervise your autonomous agents from one beautiful native desktop app.

图片:License: MIT 图片:Electron 图片:React 图片:TypeScript 图片:Tailwind CSS 图片:PRs Welcome 图片:Platform

Features · Install · Screenshots · For Developers · Contributing · Roadmap


Why ZeroClaw UI?

ZeroClaw is extraordinary infrastructure: a ~3.4 MB Rust binary that boots in under 10 ms, idles in <5 MB of RAM, and runs a fully autonomous AI agent on anything from a Mac mini to a $10 ARM board. Swappable providers (Anthropic, OpenAI, Ollama, ~20 more), 30+ messaging channels, persistent SQLite memory, deny-by-default security.

But its power lives in a TOML file and a CLI. ZeroClaw UI puts a face on it.

Without ZeroClaw UIWith ZeroClaw UI
Hand-edit ~/.zeroclaw/config.tomlGuided forms with live validation
zeroclaw doctor in a terminalOne-click health dashboard
Read markdown workspace files in an editorPurpose-built editors with live preview
zeroclaw skills install … per skillBrowse, install, bulk-install in one click
Guess why the daemon is unhappyReal-time status & diagnostics

⚡ One app. Every agent. Zero YAML tears.

✨ Features

  • 📊 Dashboard — Real-time daemon status, version, and health at a glance. Run zeroclaw doctor and see every check rendered as a clean report.
  • 🧭 Onboarding wizard — From zero to running agent: detect your installation, pick a provider, set your API key, configure channels, test the connection.
  • 🤖 Agent workspace — Edit the files that define your agent’s personality — Identity, Soul, Agent, User, Memory, Heartbeat, Tools — with Markdown editors and live preview.
  • 🧩 Skills manager — Browse installed skills, discover new ones from the community registry, install/uninstall with one click.
  • ⚙️ Full settings editor — Every section of config.toml: General, Gateway, Memory, Channels, Model Routes, Scheduler, and Autonomy (allowlists, denylists, rate limits, risk gates). Validated with zeroclaw doctor on every save.
  • 🔒 Secure by design — Context isolation, sandboxed renderer, zero Node.js access from the UI. Every privileged action crosses a typed IPC boundary.

🚀 Install

Prerequisites

  • Node.js ≥ 18 and npm ≥ 9
  • ZeroClaw installed and on your PATH:
    curl -fsSL https://raw.githubusercontent.com/zeroclaw-labs/zeroclaw/master/install.sh | sh

⚡ One-line install (macOS)

First grab the Xcode Command Line Tools (provides git and the compilers npm needs for native modules):

xcode-select --install

Then install the app in a single line:

mkdir -p 'zeroclawui' && cd 'zeroclawui' && npm install github:Cosmicchibattle/zeroclaw-ui

Launch it:

npx electron .

From source (all platforms)

git clone https://github.com/Cosmicchibattle/zeroclaw-ui.git
cd zeroclaw-ui
npm install
npm run dev        # hot-reload dev mode — an Electron window opens

Build a distributable app

npm run dist:mac     # .dmg + .zip for macOS (Apple Silicon & Intel)
npm run dist:win     # NSIS installer for Windows
npm run dist:linux   # AppImage for Linux

🛠 Tech Stack

Chosen to match how ZeroClaw itself is engineered: lean, typed, and swappable.

LayerTechnologyWhy
Desktop shellElectron 40Native windows on macOS/Windows/Linux from one codebase
UIReact 19 + TypeScriptStrict types end-to-end, from renderer to IPC contracts
StylingTailwind CSS 4Utility-first, tiny runtime cost
StateZustand 5Minimal store, no boilerplate
RoutingReact Router 7Hash-based routing that survives file:// packaging
Buildelectron-vite 3Sub-second HMR across main, preload, and renderer
Config parsingsmol-tomlRead/write ZeroClaw’s config.toml losslessly
Markdownreact-markdown + remark-gfmLive preview for workspace files
TestingVitest + Testing LibraryFast, jsdom-based unit tests

🏗 Architecture

┌────────────────────────────── Electron ──────────────────────────────┐
│                                                                      │
│  Renderer (React, sandboxed)      Preload (contextBridge)            │
│  ┌───────────────────────┐        ┌────────────────────────┐         │
│  │ Dashboard · Settings  │ ────▶  │ window.zeroclawUi API  │         │
│  │ Skills · Agent · ...  │ ◀────  │ (typed, minimal)       │         │
│  └───────────────────────┘        └───────────┬────────────┘         │
│                                               │ IPC (invoke/handle)  │
│  Main process (Node.js)                       ▼                      │
│  ┌────────────────────────────────────────────────────────┐          │
│  │ IPC handlers → zeroclaw-cli bridge  →  `zeroclaw` CLI  │          │
│  │              → config-store        →  ~/.zeroclaw/     │          │
│  └────────────────────────────────────────────────────────┘          │
└──────────────────────────────────────────────────────────────────────┘
  • The renderer never touches Node.js. Context isolation + sandbox are on; the only bridge is the typed window.zeroclawUi API exposed by the preload script.
  • ZeroClaw is the single source of truth. The app shells out to the real zeroclaw binary for status/diagnostics/skills and edits the real ~/.zeroclaw/config.toml — no shadow state to drift.
  • One contract file. Every IPC channel and payload type lives in src/shared/ipc.ts, imported by both processes.

📁 Project Structure

zeroclaw-ui/
├── src/
│   ├── shared/
│   │   └── ipc.ts              # IPC channel names + payload types (single contract)
│   ├── main/                   # Electron main process
│   │   ├── index.ts            # Window lifecycle, security hardening
│   │   ├── ipc/index.ts        # All ipcMain handlers
│   │   └── lib/
│   │       ├── zeroclaw-cli.ts # Typed wrapper around the zeroclaw binary
│   │       └── config-store.ts # config.toml + workspace file IO (smol-toml)
│   ├── preload/
│   │   ├── index.ts            # contextBridge → window.zeroclawUi
│   │   └── index.d.ts          # Renderer-side typings for the bridge
│   └── renderer/               # React app
│       ├── index.html
│       └── src/
│           ├── App.tsx         # Routes
│           ├── components/     # Shared UI (layout, badges, ...)
│           ├── features/
│           │   ├── dashboard/  # Status & doctor report
│           │   ├── onboarding/ # Setup wizard
│           │   ├── agent/      # Workspace markdown editors
│           │   ├── skills/     # Skill install/uninstall
│           │   └── settings/   # config.toml editor
│           ├── stores/         # Zustand stores
│           └── lib/            # Utilities
├── electron.vite.config.ts
├── electron-builder.yml
├── package.json
└── README.md

📜 Scripts

CommandDescription
npm run devDev mode with hot-reload (main + preload + renderer)
npm run buildProduction build to out/
npm run previewRun the production build
npm testRun the Vitest suite once
npm run test:watchTests in watch mode
npm run typecheckStrict TS check of both processes
npm run dist:mac / :win / :linuxBuild an installable app

👩‍💻 For Developers

This section is the audition: everything you need to evaluate, hack on, and extend the codebase.

Dev setup

git clone https://github.com/Cosmicchibattle/zeroclaw-ui.git
cd zeroclaw-ui
npm install
npm run dev

Dev mode gives you:

  • HMR in the renderer — edit a React component, see it instantly.
  • Auto-restart of main/preload — edit the CLI bridge and electron-vite reboots the process.
  • Chrome DevTools on the renderer; debug the main process with npm run dev -- --inspect and attach any Node debugger.

The mental model (read this before your first PR)

  1. Renderer is untrusted. It is sandboxed and can only call window.zeroclawUi.*. If a feature needs the filesystem, a subprocess, or the network — it goes through IPC, no exceptions.
  2. One contract file. Add a channel name and payload types to src/shared/ipc.ts, expose a method in src/preload/index.ts, implement the handler in src/main/ipc/index.ts. Three touch points, all type-checked against each other.
  3. Never reimplement ZeroClaw logic. If zeroclaw can answer it (status, doctor, skills list --json), call the CLI. If ZeroClaw owns a file (config.toml, workspace markdown), edit that file. The UI renders truth; it doesn’t manufacture it.

Adding a feature, end to end

// 1. src/shared/ipc.ts
export const IpcChannels = { ..., memorySearch: 'memory:search' } as const

// 2. src/main/ipc/index.ts
ipcMain.handle(IpcChannels.memorySearch, (_e, q: string) =>
  cli.runZeroclaw(['memory', 'search', q])
)

// 3. src/preload/index.ts
memory: { search: (q: string) => ipcRenderer.invoke(IpcChannels.memorySearch, q) }

// 4. src/renderer/src/features/memory/MemoryPage.tsx
const hits = await window.zeroclawUi.memory.search(query)

Testing

npm test              # unit tests (Vitest + Testing Library, jsdom)
npm run typecheck     # both tsconfigs must pass before a PR

Renderer components are tested with the preload API mocked. Main-process logic (zeroclaw-cli, config-store) is tested by stubbing child_process and the filesystem.

Conventions

  • TypeScript strict everywhere; no any without a comment justifying it.
  • Conventional Commits — feat:, fix:, chore:, docs: …
  • Keep components small; feature folders own their pages, hooks, and local components.
  • Tailwind for styling; shared primitives live in src/renderer/src/components/.

Release flow

  1. Bump version in package.json, update CHANGELOG.md.
  2. npm run dist:mac (and/or :win, :linux) → artifacts land in release/.
  3. Tag vX.Y.Z, push, attach artifacts to the GitHub Release.

🗺 Roadmap

  • Dashboard with live daemon status and doctor report
  • Workspace editors (Identity / Soul / Agent / User / Memory / Heartbeat / Tools)
  • Skills install/uninstall
  • Full config.toml editor with doctor validation
  • Guided onboarding: provider + API key + channel setup, connection test
  • Sectioned settings forms (Gateway, Memory, Channels, Autonomy) replacing raw editing
  • Live chat pane against the local daemon / gateway WebSocket
  • Cost & token usage charts (per-agent, per-model)
  • Cron / SOP scheduler UI
  • Multi-agent management (schema V3)
  • Auto-update via electron-updater
  • Signed & notarized macOS builds

❓ FAQ

Is this an official ZeroClaw project? No. ZeroClaw UI is an independent community project. The official runtime lives at zeroclaw-labs/zeroclaw; “ZeroClaw” is a trademark of ZeroClaw Labs, used here descriptively.

Does it bundle ZeroClaw? No — it drives the zeroclaw binary already on your PATH, so you always manage the exact runtime you installed.

Which ZeroClaw versions are supported? Built against the v0.8.x CLI surface (status, doctor, skills, memory, schema V3 config).

🤝 Contributing

Contributions, ideas, and PRs are very welcome — see CONTRIBUTING.md. New here? Grab anything tagged good first issue.

Please don’t file public issues for security vulnerabilities — see the security notes in CONTRIBUTING.md.

🙏 Acknowledgements

  • The ZeroClaw Labs team and community for the runtime this app manages.
  • Inspired by davaidev/zeroclaw-ui — proof the idea deserved a great implementation.

📄 License

MIT — use it, fork it, ship it.


If ZeroClaw UI saved you from one hand-edited TOML file, drop a ⭐ — it keeps the lights on.

⬆ Back to top

Official distribution

获取与安装

暂未发现可确认的官方软件包地址

当前 README 快照没有出现 npm、PyPI、Crates.io、pub.dev 等官方包页链接。本站不会根据仓库名称猜测下载地址。

本站不托管项目文件;需要安装时,请以项目维护者发布的官方文档为准。

使用前核验

本站保存公开资料用于阅读,不代表安全审计或功能背书。安装前请核对许可证、依赖来源和发布签名,不要直接运行来源不明的二进制文件或高权限脚本。