Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 10 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ MimiClaw turns a tiny ESP32-S3 board into a personal AI assistant. Plug it into
## Meet MimiClaw

- **Tiny** — No Linux, no Node.js, no bloat — just pure C
- **Handy** — Message it from Telegram, it handles the rest
- **Handy** — Message it from Telegram, Feishu, or MQTT, it handles the rest
- **Loyal** — Learns from memory, remembers across reboots
- **Energetic** — USB power, 0.5 W, runs 24/7
- **Lovable** — One ESP32-S3 board, $5, nothing else
Expand All @@ -31,7 +31,7 @@ MimiClaw turns a tiny ESP32-S3 board into a personal AI assistant. Plug it into

![](assets/mimiclaw.png)

You send a message on Telegram. The ESP32-S3 picks it up over WiFi, feeds it into an agent loop — the LLM thinks, calls tools, reads memory — and sends the reply back. Supports both **Anthropic (Claude)** and **OpenAI (GPT)** as providers, switchable at runtime. Everything runs on a single $5 chip with all your data stored locally on flash.
You send a message on Telegram, Feishu, or MQTT. The ESP32-S3 picks it up over WiFi, feeds it into an agent loop — the LLM thinks, calls tools, reads memory — and sends the reply back. Supports both **Anthropic (Claude)** and **OpenAI (GPT)** as providers, switchable at runtime. Everything runs on a single $5 chip with all your data stored locally on flash.

## Quick Start

Expand Down Expand Up @@ -133,6 +133,10 @@ Edit `main/mimi_secrets.h`:
#define MIMI_SECRET_TAVILY_KEY "" // optional: Tavily API key (preferred)
#define MIMI_SECRET_PROXY_HOST "" // optional: e.g. "10.0.0.1"
#define MIMI_SECRET_PROXY_PORT "" // optional: e.g. "7897"
#define MIMI_SECRET_MQTT_URI "" // optional: e.g. "mqtt://broker.hivemq.com:1883"
#define MIMI_SECRET_MQTT_CLIENT_ID "" // optional: auto-generated if empty
#define MIMI_SECRET_MQTT_USERNAME "" // optional
#define MIMI_SECRET_MQTT_PASSWORD "" // optional
```

Then build and flash:
Expand Down Expand Up @@ -175,6 +179,7 @@ mimi> set_proxy 127.0.0.1 7897 # set HTTP proxy
mimi> clear_proxy # remove proxy
mimi> set_search_key BSA... # set Brave Search API key
mimi> set_tavily_key tvly-... # set Tavily API key (preferred)
mimi> set_mqtt_config mqtt://broker:1883 [client_id] [username] [password] # set MQTT broker
mimi> config_show # show all config (masked)
mimi> config_reset # clear NVS, revert to build-time defaults
```
Expand All @@ -183,6 +188,8 @@ mimi> config_reset # clear NVS, revert to build-time defaults

```
mimi> wifi_status # am I connected?
mimi> mqtt_status # is MQTT connected?
mimi> mqtt_send topic "text" # send MQTT message to topic
mimi> memory_read # see what the bot remembers
mimi> memory_write "content" # write to MEMORY.md
mimi> heap_info # how much RAM is free?
Expand Down Expand Up @@ -277,6 +284,7 @@ This turns MimiClaw into a proactive assistant — write tasks to `HEARTBEAT.md`
## Also Included

- **WebSocket gateway** on port 18789 — connect from your LAN with any WebSocket client
- **MQTT channel** — integrate with any MQTT broker for IoT and chat bot applications
- **OTA updates** — flash new firmware over WiFi, no USB needed
- **Dual-core** — network I/O and AI processing run on separate CPU cores
- **HTTP proxy** — CONNECT tunnel support for restricted networks
Expand Down
2 changes: 2 additions & 0 deletions main/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ idf_component_register(
"wifi/wifi_manager.c"
"channels/telegram/telegram_bot.c"
"channels/feishu/feishu_bot.c"
"channels/mqtt/mqtt_bot.c"
"llm/llm_proxy.c"
"agent/agent_loop.c"
"agent/context_builder.c"
Expand All @@ -29,5 +30,6 @@ idf_component_register(
REQUIRES
nvs_flash esp_wifi esp_netif esp_http_client esp_http_server
esp_https_ota esp_event json spiffs console vfs app_update esp-tls
esp_timer esp_websocket_client mqtt
esp_timer esp_websocket_client esp_driver_gpio
)
4 changes: 4 additions & 0 deletions main/bus/message_bus.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,14 @@
/* Channel identifiers */
#define MIMI_CHAN_TELEGRAM "telegram"
#define MIMI_CHAN_FEISHU "feishu"
#define MIMI_CHAN_MQTT "mqtt"
#define MIMI_CHAN_WEBSOCKET "websocket"
#define MIMI_CHAN_CLI "cli"
#define MIMI_CHAN_SYSTEM "system"

/* Channel name max length */
#define MIMI_CHAN_NAME_MAX 16

/* Message types on the bus */
typedef struct {
char channel[16]; /* "telegram", "websocket", "cli" */
Expand Down
Loading