Skip to content

AI provider registry + universal searchable model picker (OpenRouter, OpenAI-compatible, Ollama) #144

Description

@liam-russell

Problem

SproutGit's own AI features — commit message generation, the project idea generator, and future built-ins (plan parsing, review digests, PR summaries) — are configured as CLI commands or nothing. There's no way to point the app at an API provider, and nowhere to choose a model.

Meanwhile the chat panel's model selector just renders whatever the single ACP agent exposes via session/set_config_option (ConfigOptionsBar) — a plain dropdown, not searchable, and inherently scoped to that one agent.

Proposal

  • Provider registry in Settings: presets for Anthropic, OpenAI, Google, plus a generic OpenAI-compatible endpoint (base URL + API key) which covers OpenRouter, Ollama, LM Studio, vLLM, Azure, corporate proxies. Make OpenRouter a named preset — its /models catalog (with pricing/context metadata) is ideal for populating the picker.
  • Model catalog: fetch and cache each configured provider's model list; refresh on demand.
  • One searchable model picker component: fuzzy search across all configured providers, grouped by provider, showing context window + pricing where known. Used everywhere a model is chosen: built-in AI features, per-subtask worker model in fan-out (Task fan-out: create worker worktrees with pre-seeded agent sessions in one action #137), and reused to render the ACP config-options model list (searchable instead of a raw dropdown).
  • Key storage: Electron safeStorage, never in the workspace DB or any file that could end up in a repo.

Scope note: for ACP agents the agent owns its provider/model list — SproutGit can't add OpenRouter to Claude Code. The lever there is per-agent env vars in the agent roster issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P1Differentiator — strengthens the worktree-first / agent-native storyarea:featureNew functionalityenhancementNew feature or request

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions