Commit Graph

4 Commits

Author SHA1 Message Date
crispyberry
31b15aa1f9 feat: add file tools (read/write/edit/list_dir) for agent memory writes
Enable the agent to persist memories by adding 4 SPIFFS file tools
(read_file, write_file, edit_file, list_dir) with path validation,
and update the system prompt with memory guidelines pointing to
/spiffs/memory/MEMORY.md and daily notes.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-07 17:54:52 +08:00
crispyberry
0ed0febcd0 feat: add working indicator and get_current_time to system prompt
Send "mimi😗is working..." to user when processing starts.
List get_current_time in system prompt available tools so the agent
knows to call it for time/date queries. Remove auto time fetch from
system prompt builder — agent calls the tool on demand.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-07 15:54:23 +08:00
crispyberry
0e1da79b74 feat: add ReAct agent loop and build-time config (mimi_secrets.h)
Rewrite agent_loop.c with ReAct tool use loop: LLM call → tool
execution → repeat until end_turn (max 10 iterations). Add tool
guidance to system prompt. Add set_search_key CLI command.

Add mimi_secrets.h for build-time credentials with highest priority
over NVS/CLI values. All modules (wifi, telegram, llm, proxy,
web_search) check build-time secrets first, fall back to NVS.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-07 00:37:43 +08:00
crispyberry
0c517b734f feat: add agent loop and context builder
Agent loop runs on Core 1: pops inbound messages, builds system
prompt from bootstrap files + memory, calls Claude API, saves
session, pushes response to outbound queue. PSRAM-allocated buffers.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-05 18:55:38 +08:00