n0-space/zeroclaw — Lightweight Rust AI Agent Framework
n0-space/zeroclaw — Lightweight Rust AI Agent Framework
Metadata
- Source: https://github.com/n0-space/zeroclaw
- License: MIT (Copyright 2025 ZeroClaw Labs)
- Language: Rust (169 .rs files, 13 Cargo.toml)
- Size: 11MB
- Version: 0.1.0
- Tests: 1,017
Purpose
“Zero overhead. Zero compromise. 100% Rust. 100% Agnostic.” Fast, small, and fully autonomous AI assistant infrastructure. Deploy anywhere. Swap anything.
Key Metrics
- Binary size: ~3.4MB
- RAM usage: <5MB (99% smaller than OpenClaw)
- Startup time: <10ms (400X faster than OpenClaw)
- Hardware: Runs on $10 hardware (Raspberry Pi, ARM, x86, RISC-V)
- Providers: 23+ AI providers supported
- Traits: 8 core traits (pluggable everything)
Architecture
Core Traits (Pluggable)
- Providers — LLM backends (OpenAI, Anthropic, etc.)
- Channels — Messaging transports (Discord, Telegram, etc.)
- Tools — Actions (web, file, shell, memory)
- Memory — State persistence
- Tunnels — Network bridging
- Approval — Human-in-the-loop
- Cron — Scheduled tasks
- RAG — Retrieval-augmented generation
Source Structure
src/
main.rs — Entry point
lib.rs — Library root
gateway/ — Gateway layer (channel adapters)
approval/ — Approval system
cron/ — Cron scheduler (types, store, scheduler, schedule)
hardware/ — Hardware registry, discovery, introspection
migration/ — Data migration
onboard/ — Onboarding wizard
rag/ — RAG system
tools/ — Tool implementations (http_request, cron_remove, screenshot)
doctor/ — Diagnostics
workspace/ — Workspace management
jobs/ — Job queue
chat/ — Chat handling
auth/ — Authentication
config/ — Configuration
events/ — Event system
progress/ — Progress tracking
runner/ — Agent runner
setup/ — Setup flow
subscriptions/ — Subscriptions
worktrees/ — Worktree management
local_sessions.rs — Local session management
paths.rs — Path utilities
Firmware Targets
firmware/zeroclaw-nucleo/— STM32F401RE (ARM Cortex-M4)firmware/zeroclaw-esp32/— ESP32 (RISC-V)firmware/zeroclaw-esp32-ui/— ESP32 with UI
Relevance to Kapnet
As Mac Agent Runtime
ZeroClaw could replace full Hermes on Mac:
- 5MB binary vs 10GB+ Hermes venv
- <10ms startup vs minutes
- Native Rust (no Node.js/Python overhead)
- Pluggable providers (can add Kapnet Nostr provider)
- Built-in cron (replaces our shell cron)
- Built-in RAG (for Querant research)
Kapnet Integration Points
- Nostr Provider Plugin — Subscribe/publish TXXMs via Nostr relay
- TXXM Tool Plugin — Submit/validate TXXMs as agent actions
- Braid Memory Plugin — Persist agent state in Kapnet braid
- KScript Execution Tool — Execute KScript programs
Comparison: ZeroClaw vs Our Current Stack
| Feature | ZeroClaw | Our Stack |
|---|---|---|
| Binary size | 3.4MB | 10GB+ (Hermes venv) |
| Startup | <10ms | Minutes |
| RAM | <5MB | 769MB+ (Hermes alone) |
| Language | Rust | Python + Node.js |
| Providers | 23+ built-in | OpenRouter API only |
| Cron | Built-in | Shell scripts |
| RAG | Built-in | None |
| Channels | Discord, Telegram, etc. | Nostr (via bridge) |
| Tools | Web, file, shell, memory | Terminal, file, browser |
| License | MIT | MIT + AGPL components |
Action Items
- Evaluate ZeroClaw as Mac agent runtime replacement
- Design Kapnet Nostr provider plugin
- Design TXXM tool plugin
- Test on Mac Mini when available
- Consider embedded deployment (STM32/ESP32) for edge agents
Write a comment