From 7b29fa20d7e55d8a229b24be7e8f301581ceb137 Mon Sep 17 00:00:00 2001 From: Asklv Date: Sat, 28 Feb 2026 19:16:00 +0800 Subject: [PATCH] chore: add feishu config defaults Signed-off-by: Asklv --- .gitignore | 13 +++++++++++++ main/bus/message_bus.h | 1 + main/mimi_config.h | 18 ++++++++++++++++++ main/mimi_secrets.h.example | 4 ++++ 4 files changed, 36 insertions(+) diff --git a/.gitignore b/.gitignore index 63f5ed0..e6140c1 100644 --- a/.gitignore +++ b/.gitignore @@ -35,6 +35,18 @@ main/mimi_secrets.h *.pyc *.bin +# Documentation (generated) +BUILD_TEST_GUIDE.md +COMPILE_TEST_REPORT.md +CURRENT_STATUS.md +FEISHU_INTEGRATION_SUMMARY.md +QUICK_START.md +QWEN_INTEGRATION_PLAN.md +QWEN_INTEGRATION_COMPLETE.md +build_test.sh +build_and_integrate_qwen.sh +verify_integration.sh + # Reference repos nanobot/ @@ -46,3 +58,4 @@ nanobot/ .DS_Store Thumbs.db references/ +.venv/ diff --git a/main/bus/message_bus.h b/main/bus/message_bus.h index 78d40f4..e4993fe 100644 --- a/main/bus/message_bus.h +++ b/main/bus/message_bus.h @@ -6,6 +6,7 @@ /* Channel identifiers */ #define MIMI_CHAN_TELEGRAM "telegram" +#define MIMI_CHAN_FEISHU "feishu" #define MIMI_CHAN_WEBSOCKET "websocket" #define MIMI_CHAN_CLI "cli" #define MIMI_CHAN_SYSTEM "system" diff --git a/main/mimi_config.h b/main/mimi_config.h index 9244f05..0b90860 100644 --- a/main/mimi_config.h +++ b/main/mimi_config.h @@ -37,6 +37,12 @@ #ifndef MIMI_SECRET_SEARCH_KEY #define MIMI_SECRET_SEARCH_KEY "" #endif +#ifndef MIMI_SECRET_FEISHU_APP_ID +#define MIMI_SECRET_FEISHU_APP_ID "" +#endif +#ifndef MIMI_SECRET_FEISHU_APP_SECRET +#define MIMI_SECRET_FEISHU_APP_SECRET "" +#endif /* WiFi */ #define MIMI_WIFI_MAX_RETRY 10 @@ -52,6 +58,15 @@ #define MIMI_TG_CARD_SHOW_MS 3000 #define MIMI_TG_CARD_BODY_SCALE 3 +/* Feishu Bot */ +#define MIMI_FEISHU_MAX_MSG_LEN 4096 +#define MIMI_FEISHU_POLL_STACK (12 * 1024) +#define MIMI_FEISHU_POLL_PRIO 5 +#define MIMI_FEISHU_POLL_CORE 0 +#define MIMI_FEISHU_WEBHOOK_PORT 18790 +#define MIMI_FEISHU_WEBHOOK_PATH "/feishu/events" +#define MIMI_FEISHU_WEBHOOK_MAX_BODY (16 * 1024) + /* Agent Loop */ #define MIMI_AGENT_STACK (24 * 1024) #define MIMI_AGENT_PRIO 6 @@ -114,6 +129,7 @@ /* NVS Namespaces */ #define MIMI_NVS_WIFI "wifi_config" #define MIMI_NVS_TG "tg_config" +#define MIMI_NVS_FEISHU "feishu_config" #define MIMI_NVS_LLM "llm_config" #define MIMI_NVS_PROXY "proxy_config" #define MIMI_NVS_SEARCH "search_config" @@ -122,6 +138,8 @@ #define MIMI_NVS_KEY_SSID "ssid" #define MIMI_NVS_KEY_PASS "password" #define MIMI_NVS_KEY_TG_TOKEN "bot_token" +#define MIMI_NVS_KEY_FEISHU_APP_ID "app_id" +#define MIMI_NVS_KEY_FEISHU_APP_SECRET "app_secret" #define MIMI_NVS_KEY_API_KEY "api_key" #define MIMI_NVS_KEY_MODEL "model" #define MIMI_NVS_KEY_PROVIDER "provider" diff --git a/main/mimi_secrets.h.example b/main/mimi_secrets.h.example index 456ecbc..ac087b0 100644 --- a/main/mimi_secrets.h.example +++ b/main/mimi_secrets.h.example @@ -17,6 +17,10 @@ /* Telegram Bot */ #define MIMI_SECRET_TG_TOKEN "" +/* Feishu Bot */ +#define MIMI_SECRET_FEISHU_APP_ID "" +#define MIMI_SECRET_FEISHU_APP_SECRET "" + /* Anthropic API */ #define MIMI_SECRET_API_KEY "" #define MIMI_SECRET_MODEL ""