feat: add placeholder model metas (#15753)

### What problem does this PR solve?

add placeholder model metas

### Type of change

- [x] Bug Fix (non-breaking change which fixes an issue)
This commit is contained in:
buua436
2026-06-08 14:54:59 +08:00
committed by GitHub
parent c935f305e2
commit 6bf7056422
3 changed files with 163 additions and 2 deletions

View File

@@ -184,7 +184,14 @@ async def list_provider_models(provider_name: str, api_key: str = None, base_url
"name": llm["name"],
"max_tokens": llm["max_tokens"],
"model_types": [llm["model_type"]],
"features": None
"features": (
llm.get("features")
if llm.get("features") is not None
else (
(["is_tools"] if llm.get("is_tools") else [])
+ (["thinking"] if llm.get("thinking") else [])
)
)
} for llm in factory_info[0]["llm"]]
model_base_url = base_url or factory_info[0].get("url", "")