mirror of
https://github.com/browseros-ai/BrowserOS.git
synced 2026-05-21 04:45:12 +00:00
* feat: generalized compaction prompts with split turn handling Replace browser-specific XML prompts with domain-agnostic markdown format. Add split turn detection and parallel summarization for large single-turn conversations. Switch compaction from generateText to streamText for Fireworks API compatibility. Add comprehensive unit and E2E tests (84 total). * fix: address code review issues for compaction (PR #391) Enforce COMPACTION_MAX_SUMMARIZATION_INPUT cap, extract shared callSummarizer helper, add runtime type guard for experimental_context, move magic constants to AGENT_LIMITS, and remove dead constants. * fix: cap truncatedTurnPrefix input to maxSummarizationInput Apply the same sliding window cap to turn prefix messages that was already applied to toSummarize, preventing unbounded LLM input for long single-turn conversations with many tool calls. * fix: reduce browseros-auto default context window to 200K The 400K setting caused compaction to trigger at ~383K, but the actual model limit is 262K. Conversations hit the hard limit before compaction could kick in.