mirror of
https://github.com/BerriAI/litellm.git
synced 2026-09-12 23:01:41 +00:00
fix: satisfy GPUStack provider CI gates
This commit is contained in:
parent
fe1c78dd23
commit
6f1b6653fb
3 changed files with 28 additions and 7 deletions
|
|
@ -116,9 +116,9 @@ class GPUStackRerankConfig(BaseRerankConfig):
|
|||
model_response: RerankResponse,
|
||||
logging_obj: object,
|
||||
api_key: str | None = None,
|
||||
request_data: dict[str, object] = {},
|
||||
optional_params: dict[str, object] = {},
|
||||
litellm_params: dict[str, object] = {},
|
||||
request_data: dict[str, object] | None = None,
|
||||
optional_params: dict[str, object] | None = None,
|
||||
litellm_params: dict[str, object] | None = None,
|
||||
) -> RerankResponse:
|
||||
response_json: Final = TypeAdapter(GPUStackRerankResponsePayload).validate_json(raw_response.content)
|
||||
total_tokens: Final = response_json.usage.total_tokens or 0
|
||||
|
|
|
|||
|
|
@ -8181,10 +8181,15 @@ class ProviderConfigManager:
|
|||
return litellm.InfinityRerankConfig()
|
||||
elif litellm.LlmProviders.JINA_AI == provider:
|
||||
return litellm.JinaAIRerankConfig()
|
||||
elif litellm.LlmProviders.GPUSTACK == provider:
|
||||
return litellm.GPUStackRerankConfig()
|
||||
elif litellm.LlmProviders.HOSTED_VLLM == provider:
|
||||
return litellm.HostedVLLMRerankConfig()
|
||||
elif provider in (
|
||||
litellm.LlmProviders.GPUSTACK,
|
||||
litellm.LlmProviders.HOSTED_VLLM,
|
||||
):
|
||||
rerank_configs: Final = {
|
||||
litellm.LlmProviders.GPUSTACK: litellm.GPUStackRerankConfig,
|
||||
litellm.LlmProviders.HOSTED_VLLM: litellm.HostedVLLMRerankConfig,
|
||||
}
|
||||
return rerank_configs[provider]()
|
||||
elif litellm.LlmProviders.HUGGINGFACE == provider:
|
||||
return litellm.HuggingFaceRerankConfig()
|
||||
elif litellm.LlmProviders.DEEPINFRA == provider:
|
||||
|
|
|
|||
|
|
@ -1226,6 +1226,22 @@
|
|||
"interactions": true
|
||||
}
|
||||
},
|
||||
"gpustack": {
|
||||
"display_name": "GPUStack (`gpustack`)",
|
||||
"url": "https://docs.litellm.ai/docs/providers/gpustack",
|
||||
"endpoints": {
|
||||
"chat_completions": false,
|
||||
"messages": false,
|
||||
"responses": false,
|
||||
"embeddings": true,
|
||||
"image_generations": false,
|
||||
"audio_transcriptions": false,
|
||||
"audio_speech": false,
|
||||
"moderations": false,
|
||||
"batches": false,
|
||||
"rerank": true
|
||||
}
|
||||
},
|
||||
"heroku": {
|
||||
"display_name": "Heroku (`heroku`)",
|
||||
"url": "https://docs.litellm.ai/docs/providers/heroku",
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue