Skip to content

Two-tier runtime model, full provider matrix, and a System health tab - #40

Merged
lgutschow merged 3 commits into
mainfrom
feat/provider-sdks
Jul 25, 2026
Merged

Two-tier runtime model, full provider matrix, and a System health tab#40
lgutschow merged 3 commits into
mainfrom
feat/provider-sdks

Conversation

@lgutschow

Copy link
Copy Markdown
Contributor

What

  • Two-tier runtime model. Agents declare runtime (direct = vendor agent runtime on a subscription, claude today; api = ritsu's own tool loop on a metered key) + provider. Replaces the old dispatcher field and the provider/api_key_ref inference; existing databases migrate automatically (one-shot table rebuild, covered by tests).
  • api tier providers: anthropic / openai / gemini via their official SDKs, xai (Grok via api.x.ai), openrouter, litellm (key optional — falls back to connector credentials), custom base_url. Provider clients plug in below the ritsu-agent loop, so the approval gate stays the enforcement point. Sampling params sent only when set in provider_options.
  • System → Health tab. Live connectivity checks: core runtime, one free probe per stored provider key (model-list endpoints), each configured connector. 4s timeouts, no secret material in results.

Notes

  • Admin form gains a runtime selector with per-tier provider lists; test pane can exercise api providers directly.
  • The toolless LiteLLM dispatcher is deleted; openai-compat maps to openrouter on migration.

Testing

  • 532/532 tests (new: anthropic/gemini/openai-sdk client translation, compat provider defaults, DB migration, health checks)
  • lint + build green

…nt runtime

The openai provider now runs on the official openai SDK; a new gemini
provider speaks the native generateContent API via @google/genai
(function calling, inline images, raw-JSON-Schema tool declarations).
openai-compat/litellm keep the minimal wire client. Provider clients
plug in below the ritsu-agent loop, so the approval gate still fronts
every gated tool call. Sampling params are sent only when set in
provider_options so reasoning models keep their server-side defaults.
…ovider matrix

Agent definitions now declare an explicit runtime + provider pair.
direct = a vendor agent runtime riding a subscription (claude today);
api = ritsu's own tool loop against a metered model API. Existing
databases migrate automatically (the legacy dispatcher column is
rebuilt away; openai-compat rows become openrouter).

api tier: anthropic (official SDK, Messages API), openai (official
SDK), gemini (official SDK, native generateContent), xai/Grok
(api.x.ai, xAI's documented OpenAI-compatible path), openrouter,
litellm (key optional, falls back to connector credentials), and
custom base_url endpoints. Keyless endpoints send no Authorization
header. The admin form gains a runtime selector with per-tier
provider lists, and the test pane can exercise api-runtime providers
directly.
GET /admin/api/health probes the core runtime (DB, Claude session),
every stored provider key (model-list endpoints, no token spend), and
each configured connector (LiteLLM, Flashback, SearXNG, ingest), with
configured/partial reporting for email/social. 4s timeouts, parallel,
no secret material in results.
@sonarqubecloud

Copy link
Copy Markdown

@lgutschow
lgutschow merged commit bb471b1 into main Jul 25, 2026
15 checks passed
@lgutschow
lgutschow deleted the feat/provider-sdks branch July 25, 2026 05:20
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