WS3 frontend: local model picker, availability, and preferences
Surfaces the new "local" provider in the model picker, gated purely on
server-reported configuration (never a per-user key):
- mikeApi.ts: ApiKeyStatus gains optional local?: {configured, models}
(additive; ApiKeyProvider deliberately untouched - no BYO local key).
- UserProfileContext.tsx: UserProfile gains localModels: string[].
- ModelToggle.tsx: "Local (on-premises)" group merged in at runtime from
server-reported models, listed last, hidden entirely when unconfigured;
group header links to docs/local-models.md, each row hints "runs on your
own hardware".
- modelAvailability.ts: ModelProvider gains "local"; availability is
server-reported (localModels), never API-key-gated.
- useSelectedModel.ts: accepts localModels; a persisted local: selection
is re-validated against the reported list and falls back to
DEFAULT_MODEL_ID gracefully when no longer valid.
- ChatInput.tsx, TabularReviewView.tsx, TRChatPanel.tsx,
account/models/page.tsx: localModels threaded from useUserProfile()
through every isModelAvailable/ModelToggle call site (chat, tabular
chat, tabular generation gating, title/tabular account preferences).
ApiKeyMissingModal needed no changes: it only fires when isModelAvailable
returns false, which a hidden (unconfigured) local model never triggers.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
| Repository | Sloth-ninja/JessicaOSS |
|---|---|
| Author | sloth-ninja <ezanahaddis@gmail.com> |
| Authored | |
| Committed | |
| Parents | 510eda76 |
| Stats | 10 files changed , +181 , -42 |
| Part of | WS3: local/on-premises OpenAI-compatible model provider |
Capture this commit into my fork
Download a Markdown prompt that tells Claude how to port this
exact commit into your working tree. Run it via
claude -p < capture-commit-db46dd58.md
from inside the repo you want the change in.