chengyongru 0f3677c0d8 perf(agent): append runtime context after user content for cache stability
Runtime context (time, channel, sender) changes every turn, so placing
it before user content invalidated the prompt-cache prefix. Appending it
after user content keeps the prefix stable and improves KV cache hit
rates. The stripping logic in _save_turn was simplified from 16 lines
to 6 as a side benefit.
2026-05-15 23:06:37 +08:00
..