Issues / #3047

#3047 [Bug]: completed non-finite recovery leaves stale conversation-cache metrics

open · @oscarlius · 0 comentarios · En GitHub

Server & APISecurityWindows

Descripción

### What happened

After non-finite-logit recovery clears the native conversation cache, `/metrics` can continue reporting the old parked count and byte total. The two completed recovery messages in `src/program/generate.cpp` follow `conversations.clear()`, but neither contains the `conversation cache:` tag required by `ConvCacheLog`.

CPU-only reproduction:

1. Feed the observer normal park/restore log lines with a nonzero cache byte total.
2. Append either completed native recovery message: the restored-session path or the path that drops the live session, checkpoints, parked conversations and idle slots.
3. Poll again. The old implementation preserves the previous parked count and bytes instead of reporting zero.

`ConversationCache::clear()` removes both parked entries and retained K/V, without resetting the cumulative eviction count. Expected: set current parked entries and bytes to zero, preserve historical event/eviction counters and last-event metadata, and ignore warnings or diagnostics that merely contain recovery text.

### Strata version, GPU, OS

Upstream main at `477ac13`, Windows, Python 3.12.7. Reproduced with temporary source-derived log fixtures and the existing CPU `MockEngine` HTTP server. No live non-finite model failure was induced.

### Engine log

One of the authoritative completed messages is:

```text
strata serve: after non-finite logits (#879): the restored session replaces the live one; dropped 1 parked conversation
```

This differs from #3033 / #3034, which cover refused-parking messages. The observer also needs to recognize completed cache clears.

En el sitio

Enlaces a install, modelos, releases.