AetherOrchestrator/Python/AetherModelsServer/Models/CapabilitiesModel.py

33 lines
819 B
Python

from typing import Self, Any
from AetherCommon.Utils.Common import Common
class CapabilitiesModel:
text:bool
json:bool
code:bool
vision:bool
audio:bool
video:bool
tools:bool
streaming:bool
def __init__(self:Self, inputs:Any|None) -> None:
key:str
value:bool
for (key, value) in (
("text", True),
("json", False),
("code", True),
("vision", False),
("audio", False),
("video", False),
("tools", False),
("streaming", False)
):
object.__setattr__(self, key, bool(Common.get_value(key, inputs, value)))
def __setattr__(self, name: str, value: Any) -> None:
raise AttributeError(f"{self.__class__.__name__} es inmutable.")