feat(model): bring your own key through ai-kit — every vendor, the key's own models, no paid check - #138
Merged
Conversation
…y's own models, no paid check Per the Loki session's fleet-wide request (loki#921 is the reference): - Vendors come from @bitbaum/ai-kit BYOK_VENDORS (^1.17.0): ten instead of Heidi's own five, Anthropic and Gemini included; byokChain delegates to ai-kit's (dailyTokens pinned to 0 — Heidi's free chain shares provider ids). - /api/model/check uses probeByokKey: no tokens spent (it made a real completion), the key's own model list with the strongest suggested, the vendor's words on failure (redacted again here), 'unreachable' kept apart from 'wrong key'. - The sheet: paste -> auto-check (600 ms) -> a select of the key's models, strongest preselected and marked; free text only when no list. The key stays in this browser only. - No per-vendor 'text only' guess: ai-kit routes images on observed capability. - Also: 'no streaks' was still claimed in 7 languages (landing pillar, method claim) after streaks shipped — reworded to what is true. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
catomean
force-pushed
the
feat/byok-ai-kit
branch
from
September 26, 2026 06:14
55dfa21 to
6db5753
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Heidi's part of the fleet-wide "make it easy to power with the smartest model you have" (George, relayed by the Loki session; reference bitbaum/loki#921).
Before (measured)
BYOK_PROVIDERS: no Anthropic, no Gemini./api/model/checkspent a real completion to test a key.Now
@bitbaum/ai-kitBYOK_VENDORS(bumped to ^1.17.0), 10 in total:byokChaindelegates to ai-kit's. Heidi pinsdailyTokens: 0on the reader's link: ai-kit marks it unmetered, and Heidi's free chain shares provider ids, so an unmetered entry could otherwise read as capacity in our pool./api/model/check→probeByokKeysuggested.Also fixed: "No streaks" was still claimed in 7 languages (landing pillar, method line, a sourced method claim) after streaks shipped. Reworded to what's true: no points, no invented numbers, and a streak without reproach.
Checked
pnpm run verifygreen (913 pass).claude-opus-5 — stärkstespreselected;{provider, key, model}in localStorage;🤖 Generated with Claude Code