mirror of
https://github.com/BerriAI/litellm.git
synced 2026-10-24 05:45:11 +00:00
style(v1m): format with ruff and satisfy all type-discipline rules
This commit is contained in:
parent
73a56bb974
commit
c57c4e4272
1 changed files with 16 additions and 6 deletions
|
|
@ -2,7 +2,6 @@ from collections.abc import Mapping
|
|||
from typing import Final
|
||||
|
||||
from httpx._models import Headers
|
||||
|
||||
from litellm.llms.base_llm.chat.transformation import BaseLLMException
|
||||
from litellm.llms.openai.chat.gpt_transformation import OpenAIGPTConfig
|
||||
|
||||
|
|
@ -18,8 +17,8 @@ class V1MError(BaseLLMException):
|
|||
|
||||
|
||||
class V1MConfig(OpenAIGPTConfig):
|
||||
"""
|
||||
Configuration for v1m (System One) calibrated decision engine.
|
||||
"""Configuration for v1m (System One) calibrated decision engine.
|
||||
|
||||
Website: https://v1m.ir
|
||||
"""
|
||||
|
||||
|
|
@ -38,12 +37,23 @@ class V1MConfig(OpenAIGPTConfig):
|
|||
def get_config(cls) -> OpenAIGPTConfig:
|
||||
return super().get_config()
|
||||
|
||||
def get_supported_openai_params(self, model: str) -> list[str]: # mutable-ok: required list signature for OpenAIGPTConfig
|
||||
def get_supported_openai_params(
|
||||
self, model: str
|
||||
) -> list[str]: # mutable-ok: required list signature for OpenAIGPTConfig
|
||||
return [
|
||||
"temperature",
|
||||
"max_tokens",
|
||||
"stream",
|
||||
]
|
||||
|
||||
def get_error_class(self, error_message: str, status_code: int, headers: Mapping[str, str] | Headers) -> BaseLLMException:
|
||||
return V1MError(status_code=status_code, message=error_message, headers=headers)
|
||||
def get_error_class(
|
||||
self,
|
||||
error_message: str,
|
||||
status_code: int,
|
||||
headers: Mapping[str, str] | Headers,
|
||||
) -> BaseLLMException:
|
||||
return V1MError(
|
||||
status_code=status_code,
|
||||
message=error_message,
|
||||
headers=headers,
|
||||
)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue