feat: add siliconflow provider support

This commit is contained in:
Re-bin 2026-02-18 03:52:53 +00:00
parent df09ba1232
commit 80a5a8c983
2 changed files with 4 additions and 6 deletions

View File

@ -583,6 +583,7 @@ Config file: `~/.nanobot/config.json`
| `gemini` | LLM (Gemini direct) | [aistudio.google.com](https://aistudio.google.com) |
| `minimax` | LLM (MiniMax direct) | [platform.minimax.io](https://platform.minimax.io) |
| `aihubmix` | LLM (API gateway, access to all models) | [aihubmix.com](https://aihubmix.com) |
| `siliconflow` | LLM (SiliconFlow/硅基流动, API gateway) | [siliconflow.cn](https://siliconflow.cn) |
| `dashscope` | LLM (Qwen) | [dashscope.console.aliyun.com](https://dashscope.console.aliyun.com) |
| `moonshot` | LLM (Moonshot/Kimi) | [platform.moonshot.cn](https://platform.moonshot.cn) |
| `zhipu` | LLM (Zhipu GLM) | [open.bigmodel.cn](https://open.bigmodel.cn) |

View File

@ -119,16 +119,13 @@ PROVIDERS: tuple[ProviderSpec, ...] = (
model_overrides=(),
),
# SiliconFlow (硅基流动): OpenAI-compatible gateway hosting multiple models.
# strip_model_prefix=False: SiliconFlow model names include org prefix
# (e.g. "Qwen/Qwen2.5-14B-Instruct", "deepseek-ai/DeepSeek-V3")
# which is part of the model ID and must NOT be stripped.
# SiliconFlow (硅基流动): OpenAI-compatible gateway, model names keep org prefix
ProviderSpec(
name="siliconflow",
keywords=("siliconflow",),
env_key="OPENAI_API_KEY", # OpenAI-compatible
env_key="OPENAI_API_KEY",
display_name="SiliconFlow",
litellm_prefix="openai", # → openai/{model}
litellm_prefix="openai",
skip_prefixes=(),
env_extras=(),
is_gateway=True,