Skip to content

feat: Agent-enhanced mindmap with incremental operations engine#8

Merged
web4zn merged 1 commit into
mainfrom
opencode
May 9, 2026
Merged

feat: Agent-enhanced mindmap with incremental operations engine#8
web4zn merged 1 commit into
mainfrom
opencode

Conversation

@web4zn
Copy link
Copy Markdown
Owner

@web4zn web4zn commented May 9, 2026

Summary

  • Agent System — Web Worker + Vercel AI SDK tool calling, ReAct loop with 2 tools (readMindmap, generateMindmapOps)
  • Streaming Chat — chat responses now stream token-by-token, decoupled from mindmap generation
  • Incremental Operationsadd_child / update / delete_leaf / add_root replace full tree replacement, ~70% token savings
  • editedByUser Protection — per-operation level guarding, not post-hoc merge
  • Smart Deduplication — chat history filtered for errors (401) and duplicate user messages
  • Dual Mode — Phase 1 enhance mode complete (Agent runs in background after AI responds)
  • Phase 2 — incremental ops engine, pattern-aware prompts, zero-LLM-call tool submission

Architecture

Chat (stream) → useConversation hook
                  ↓ onStreamComplete
Agent Worker → ReAct loop → readMindmap → generateMindmapOps → applyOperations → store

Files Changed

  • 18 new files, 6 modified
  • +1857 / -165 lines

- Agent system with Web Worker, ReAct loop, tool calling via AI SDK
- Streaming chat decoupled from mindmap generation
- Incremental operations engine (add_child/update/delete_leaf/add_root)
- editedByUser protection at operation level
- Smart message deduplication and error filtering
- Phase 1 (enhance mode) + Phase 2 (incremental ops) complete
@web4zn web4zn merged commit 3678f85 into main May 9, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant