Files
oh-my-pi/packages/coding-agent/src/memories
metaphorics f84ed4ddc6 fix(coding-agent): clamp learned-lessons injection budget to non-negative
`truncateByApproxTokens` appends a truncation marker, so a truncated memory
summary can exceed `limit * 4` chars and drive the remaining lessons budget
negative. Clamp to 0 and skip lessons entirely when the summary already fills the
budget, instead of feeding a negative limit to the truncator.

Addresses review thread on PR #2542 (thread 15).
2026-06-14 12:51:58 +09:00
..