Skip to content

feat(health): answer whether recall is actually working - #11

Merged
AbsoluteMode merged 1 commit into
mainfrom
feat/health
Jul 27, 2026
Merged

feat(health): answer whether recall is actually working#11
AbsoluteMode merged 1 commit into
mainfrom
feat/health

Conversation

@AbsoluteMode

Copy link
Copy Markdown
Owner

Зачем

Вчера провайдер эмбеддингов начал отбивать запросы, индексация встала, а поиск полтора суток
продолжал возвращать правдоподобные лексические хиты. Инструмент не сказал ни слова — и вывод
был сделан ровно тот, которого мы боимся: «плагин не работает».

session-recall health

[ok  ] Freshness  2 minutes behind
[warn] Embedder   responded in 5828 ms
                  → slow provider will make indexing crawl
[ok  ] Corpus     1053 sessions (claude 373, codex 680)
[ok  ] Sources    claude, codex present

verdict: AMBER (voyage/voyage-4-large, index at ~/.local/share/session-recall/index.db)

Живой вывод на реальной истории. Код возврата ненулевой при RED — можно вешать на таймер.

Почему измерения именно такие

  • Freshness сравнивает свежайший транскрипт на диске со свежайшим турном в индексе, а не
    «когда индекс менялся». Индексатор, который запускается каждую сессию и каждый раз падает,
    исправно обновляет собственную метку, отставая всё сильнее — поймать это можно только
    сравнением с диском.
  • Embedder делает один настоящий вызов и цитирует ошибку дословно. Обобщённое
    «unavailable» — ровно то, из-за чего мы вчера полезли проверять ключ, который был исправен.
  • Corpus считает сессии по движкам: суммарное число прячет ситуацию, когда один
    источник тихо перестал индексироваться.
  • Sources называет отсутствующие каталоги: опечатка в CODEX_HOME не индексирует ничего
    и выглядит точно как «у меня просто нет истории Codex».

Вердикт — худшая зона, а не среднее: одно мёртвое измерение делает recall ненадёжным вне
зависимости от того, что ещё работает.

Проверка

144 теста зелёные (было 136), восемь новых писались до кода.

🤖 Generated with Claude Code

Yesterday the embedding provider started refusing requests, indexing stopped, and
search kept returning plausible keyword hits for a day and a half. Nothing in the
tool said a word, and the conclusion drawn was "the plugin doesn't work".

`session-recall health` checks the chain and exits non-zero on RED, so a timer can
act on it:

- Freshness compares newest-on-disk against newest-indexed, not "when did the index
  last change" — an indexer that runs every session and fails every time keeps its
  own timestamp fresh while falling further behind.
- Embedder makes one real call and quotes the error verbatim. A generic "unavailable"
  is what sent us chasing an API key that was never the problem.
- Corpus counts sessions per engine, because a total hides one source going quiet.
- Sources names missing roots: a mistyped CODEX_HOME indexes nothing and looks
  exactly like having no Codex history.

Verdict is the worst zone present, not an average — one dead dimension makes recall
untrustworthy regardless of what still works.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@AbsoluteMode
AbsoluteMode merged commit 3a938cc into main Jul 27, 2026
7 checks passed
@AbsoluteMode
AbsoluteMode deleted the feat/health branch July 27, 2026 09:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants