NullClaw | Autonomous AI Ecosystem
Architecture
NullClaw is a modular runtime where channel/gateway input is routed into an agent loop, then through providers and tools, and finally back to output channels.
Mental Model
- ingress: channels + gateway
- execution: agent loop + provider client
- side effects: tools + memory
- control: policy + sandbox + pairing
Core Entry Points
src/main.zig: CLI routing and command handlerssrc/daemon.zig: long-running gateway orchestrationsrc/gateway.zig: HTTP/WebSocket ingresssrc/agent/root.zig: agent loop and tool-calling behavior
Runtime Domains
src/providers/*: model providers and compatibility factorysrc/channels/*: channel integrations and dispatchsrc/tools/*: tool interface + implementationssrc/memory/*: engines, retrieval, lifecycle, vector helperssrc/security/*: policy, pairing, sandbox, auditsrc/channel_catalog.zig: source-of-truth channel registrysrc/capabilities.zig: effective runtime capability view
Request Flow
- Message enters via channel or gateway endpoint.
- Session/routing context is resolved.
- Agent loop composes context and calls provider.
- Tool calls execute under policy/sandbox constraints.
- Tool results are fed back into loop.
- Final response is emitted back to channel/gateway.
Why Capabilities Matter
Config alone is not enough: build flags can remove channels/tools/memory backends.
Use:
nullclaw capabilities
nullclaw capabilities --json
to inspect actual runtime reality.
Extension Points
- new provider: add provider module + factory registration
- new channel: implement channel interface + catalog entry
- new tool: add tool module + tool assembly wiring
- new memory backend: add engine descriptor + runtime wiring