Files
kilocode/packages/core/test
Johnny Eric Amancio f0cbf8c2ff feat(core): add soft max-cost nudge state (#11831)
* feat(core): soft max-cost nudge state machine

Surface-agnostic, dependency-free MaxCostNudge: aggregates per-assistant
message cost into a session total (session.cost is written via direct SQL
and never emits session.updated), and decides when to fire a non-blocking
"keep going?" alert once a global limit is crossed.

check() alerts once per run; resolve("continue") suppresses re-alerts for
that limit; rearm() re-arms on a new run; onSessionDeleted() clears state.
Consumers own the limit (set via setLimit) and the UI/abort.

* feat(core): extend max cost nudge state

* fix(core): clear stale message cost when value becomes non-finite

* test(core): add missing cost aggregation and session isolation tests
2026-07-01 12:07:07 +02:00
..
2026-06-18 13:41:13 +02:00
2026-06-15 14:48:05 +02:00
2026-06-17 10:42:43 +02:00