Skip to content

Add major model providers (Western + all major Chinese) - #70

Merged
YASSERRMD merged 7 commits into
mainfrom
feat_model_providers
Jun 9, 2026
Merged

Add major model providers (Western + all major Chinese)#70
YASSERRMD merged 7 commits into
mainfrom
feat_model_providers

Conversation

@YASSERRMD

Copy link
Copy Markdown
Owner

Multi-provider support

ClawForge is no longer effectively OpenRouter-only. Adds a generic OpenAI-compatible client, a native Anthropic client, and a catalog covering 24 providers wired up from environment variables.

Runtime (backend/planner/src/providers/)

  • openai_compatible.rs — generic /chat/completions client (covers OpenAI, Gemini, Mistral, xAI, Groq, Together, Fireworks, Perplexity, Cohere, and every catalog Chinese provider).
  • anthropic.rs — native Anthropic Messages API client.
  • catalog.rsProviderInfo catalog + register_from_env, with Region/Wire metadata and a needs_residency_review() helper.

Providers covered

Global/Western: OpenRouter, OpenAI, Anthropic, Google Gemini, Mistral, xAI Grok, Groq, Together, Fireworks, Perplexity, Cohere, Ollama (local).
Chinese: DeepSeek, Alibaba Qwen (DashScope), Zhipu GLM, Moonshot/Kimi, Baidu ERNIE, MiniMax, Tencent Hunyuan, 01.AI Yi, StepFun, Baichuan, iFlytek Spark, SenseTime SenseNova.

Wiring & docs

  • cli serve registers every provider whose API key is set in the env.
  • .env.example lists all provider keys; new docs/model-providers.md documents them, including data-residency notes for government use.

Build fixes (pre-existing, unblock the runtime build)

  • executor: import Capabilities (the CLI/runtime did not compile on main without this).
  • cli: enable the tower-http limit feature used by RequestBodyLimitLayer.

Verification

  • cargo test -p clawforge-planner — passing (incl. catalog tests; unique ids, Chinese coverage, env registration).
  • cargo build -p clawforge-cli — now builds.

@YASSERRMD
YASSERRMD merged commit 7fa9c0d into main Jun 9, 2026
0 of 2 checks passed
@YASSERRMD
YASSERRMD deleted the feat_model_providers branch June 9, 2026 15:50
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