Skip to content

feat: track whether the LLM chain is actually up - #36

Merged
github-actions[bot] merged 1 commit into
mainfrom
feat/llm-health-tracker
Aug 31, 2026
Merged

feat: track whether the LLM chain is actually up#36
github-actions[bot] merged 1 commit into
mainfrom
feat/llm-health-tracker

Conversation

@catomean

Copy link
Copy Markdown
Collaborator

Summary

  • Adds ai-kit's createHealthTracker (same tracker adopted fleet-wide: botsmann, hirnli, evig, kivvi, aoz-housing) at callLLM's single success return and its three throw points — no control-flow changes.
  • Adds /api/health — this app had no health endpoint at all. Plain GET is liveness, always 200 once the process is up; ?strict=1 opts into 503 once the chain has been down for 3 consecutive requests. A dead key can't be fixed by a restart, so the default check must never fail on one.

Test plan

  • npm run verify (format:check + lint + typecheck + test) — all green, 52/52 tests passing

callLLM already knew when every vendor in the chain refused; nothing
remembered that fact between requests. Adds ai-kit's
createHealthTracker (same tracker adopted fleet-wide: botsmann,
hirnli, evig, kivvi, aoz-housing) at callLLM's success return and its
three throw points, and a new /api/health route — this app had none —
exposing it. Liveness stays 200 regardless; ?strict=1 opts into 503
only once the chain has been down for 3 consecutive requests, since a
dead key can't be fixed by a restart and must never fail the check
that triggers one.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01HVwg8DKHQktxJuHeLM3xpG
@github-actions
github-actions Bot merged commit e480280 into main Aug 31, 2026
1 check passed
@github-actions
github-actions Bot deleted the feat/llm-health-tracker branch August 31, 2026 12:16
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.

1 participant