rony-chat-bot/internal
Victor Hugo Vargas 7393812fba feat(agent): auto-compact long conversations in the runner
Runner.Compact folds the older portion of history into a single
system-role summary when the previous turn's input tokens cross
threshold_ratio × MaxContextWindow. When summarization fails, the
runner falls back to truncateToBudget so a flaky summarize call never
breaks the user's request.

EstimatePromptTokens / totalPromptTokens give a conservative count
(roughly 3 chars per token) used by both the compaction trigger and
BuildMessages' new limitRAGContext / fitHistory helpers to cap the
prompt inside the provider's reported window before the request goes
out. Covers the first-turn case where no usage has been reported yet.

Adds runner_compaction_test.go with table-driven coverage for the
disabled, below-threshold, short-history, unknown-window, fallback
and first-stream cases, plus a regression for the RAG-context trimmer.
2026-07-18 00:08:05 -07:00
..
agent feat(agent): auto-compact long conversations in the runner 2026-07-18 00:08:05 -07:00
config feat(config): add auto-compaction block and CLI wiring 2026-07-18 00:07:41 -07:00
i18n feat: bootstrap rony-chat-bot Go module 2026-07-17 00:56:06 -07:00
persona feat: bootstrap rony-chat-bot Go module 2026-07-17 00:56:06 -07:00
portfolio feat: persistent conversation storage (Phase 4) 2026-07-17 00:56:35 -07:00
server feat: persistent conversation storage (Phase 4) 2026-07-17 00:56:35 -07:00
streaming feat: bootstrap rony-chat-bot Go module 2026-07-17 00:56:06 -07:00