Setup Environment: Ubuntu 24.04, ZeroClaw, Lark, Minimax-M2.5.
In this guide, we will walk you through the process of deploying the ZeroClaw Agent with Lark as the messaging platform. We will cover the architecture, setup, configuration, and best practices for production deployment.
1. Overview of ZeroClaw and Lark
ZeroClaw is a prominent open-source, ultra-lightweight AI assistant framework written in Rust. It is designed as a high-performance alternative to heavier frameworks like OpenClaw.
Lark(alternative to WhatsApp/Discord) is an all-in-one productivity superapp designed for workplace communication and management. It offers a powerful API that allows developers to integrate custom applications and bots, making it an ideal platform for deploying AI assistants like ZeroClaw.
2. Architecture of ZeroClaw
The architecture of ZeroClaw is designed for efficiency and scalability. It consists of the following components:
- Core Engine: The heart of ZeroClaw, responsible for processing inputs and generating responses.
- Channels: Channels let ZeroClaw receive and reply to messages from Telegram, Discord, Slack, Mattermost, iMessage, Matrix, Signal, WhatsApp, Linq, Email, IRC, Lark, DingTalk, QQ, Nostr, Webhook, and more. All channels use a deny-by-default allowlist.
- Tools: Tools are capabilities the agent can invoke during a conversation. All built-in tools are sandboxed and workspace-scoped by default.
- Models: ZeroClaw supports subscription-native auth profiles (multi-account, encrypted at rest) for OpenAI Codex and Anthropic.
- Gateway & Daemon: The gateway exposes a webhook server for channel integrations. The daemon runs the full autonomous runtime including heartbeat, cron, and channels.
- Config File: ZeroClaw is configured via a single YAML file that defines channels, tools, models, and other settings. Config lives at
~/.zeroclaw/config.tomlโ created by zeroclaw onboard.
3. Installation and Setup
To deploy ZeroClaw with Lark, follow these steps:
- Install it on Linux:
curl -fsSL https://raw.githubusercontent.com/zeroclaw-labs/zeroclaw/main/scripts/install-release.sh | bash - Replace the binary with the new binary that supports Lark.
- Download the latest release from the zeroclaw.
- Compile command:
cargo build --release --features "channel-lark" - Copy the compiled binary to
/home/username/.cargo/bin/zeroclawor your desired location. You may check this binary location first by using:which zeroclaw. - Restart the service:
zeroclaw service restart
4. Configuration for LLMs
Just edit the config file: ~/.zeroclaw/config.toml. I’m using Minimax-M2.5 here.
api_key = ""
default_provider = "minimax-cn"
default_model = "MiniMax-M2.5"
5. Configuration for Lark Channel
Create an Bot for ZeroClaw on Lark Developer Console, and get the app_id, app_secret. Then add the following configuration to your config.toml file:
[channels_config.lark]
app_id = ""
app_secret = ""
encrypt_key = "" # optional
verification_token = "" # optional
allowed_users = ["*"]
mention_only = false # optional: require @mention in groups (DMs always allowed)
use_feishu = false
receive_mode = "websocket" # or "webhook"
port = 8081 # required for webhook mode
6. Add Lark as a Daemon Channel
Run Lark as a daemon channel by adding it to a Systemd service file. Create a file named ~/.config/systemd/user/zeroclaw-lark.service.
[Unit]
Description=ZeroClaw Lark Channel
After=zeroclaw.service
[Service]
Type=simple
ExecStart=/home/user/.cargo/bin/zeroclaw channel start
Restart=always
RestartSec=5
Environment="HOME=/home/user"
[Install]
WantedBy=default.target
Then start the service:
systemctl --user daemon-reload
systemctl --user enable zeroclaw-lark
systemctl --user restart zeroclaw-lark
# view the logs
journalctl --user -u zeroclaw-lark -f
Check the logs to ensure that the Lark channel is running correctly and connected to your Lark bot. If you see the log like this: 2026-03-14T04:18:40.545193Z INFO zeroclaw::channels::lark: Lark: WS connected, that means the connection is successful.
You can check the logs using journalctl --user -u zeroclaw-lark -f to see the real-time logs of the Lark channel. Look for any errors or connection issues that may arise during the startup process.
7. Add bot to your Lark Messager Client
Finally, add the bot to your Lark messenger client and start chatting with it! You should see the messages being processed by ZeroClaw in the logs.
Conclusion
Deploying ZeroClaw with Lark allows you to leverage the powerful capabilities of ZeroClaw in a familiar messaging environment. By following the steps outlined in this guide, you can set up and configure your ZeroClaw agent to interact seamlessly with Lark, enabling you to create a highly responsive and efficient AI assistant for your team or personal use.
Why do we use ZeroClaw? Because it is ultra-lightweight, high-performance, and designed for efficiency. It can run on edge devices and has a small memory footprint, making it ideal for production deployment.
Comments