mirror of
https://github.com/Skyvern-AI/skyvern.git
synced 2025-09-16 18:29:40 +00:00
add gpt4o mini support (#666)
This commit is contained in:
parent
a9f52c4dbb
commit
98e2f7f206
4 changed files with 49 additions and 5 deletions
|
@ -1,12 +1,18 @@
|
|||
from dataclasses import dataclass, field
|
||||
from typing import Any, Awaitable, Literal, Protocol
|
||||
from typing import Any, Awaitable, Literal, Optional, Protocol, TypedDict
|
||||
|
||||
from skyvern.forge.sdk.models import Step
|
||||
from skyvern.forge.sdk.settings_manager import SettingsManager
|
||||
|
||||
|
||||
class LiteLLMParams(TypedDict):
|
||||
api_key: str | None
|
||||
api_version: str | None
|
||||
api_base: str | None
|
||||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
class LLMConfig:
|
||||
class LLMConfigBase:
|
||||
model_name: str
|
||||
required_env_vars: list[str]
|
||||
supports_vision: bool
|
||||
|
@ -22,6 +28,11 @@ class LLMConfig:
|
|||
return missing_env_vars
|
||||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
class LLMConfig(LLMConfigBase):
|
||||
litellm_params: Optional[LiteLLMParams] = field(default=None)
|
||||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
class LLMRouterModelConfig:
|
||||
model_name: str
|
||||
|
@ -33,7 +44,7 @@ class LLMRouterModelConfig:
|
|||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
class LLMRouterConfig(LLMConfig):
|
||||
class LLMRouterConfig(LLMConfigBase):
|
||||
model_list: list[LLMRouterModelConfig]
|
||||
# All three redis parameters are required. Even if there isn't a password, it should be an empty string.
|
||||
main_model_group: str
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue