19 lines
466 B
Python
19 lines
466 B
Python
#!/usr/bin/env python3
|
|
# -*- coding: utf-8 -*-
|
|
|
|
from typing import Self, Any, TypeVar
|
|
from abc import ABC, abstractmethod
|
|
|
|
T = TypeVar('T')
|
|
|
|
class ModelsManagerInterface(ABC):
|
|
|
|
@abstractmethod
|
|
def get(self:Self, Type:type[T], model:str|type[T]) -> type[T]|None:pass
|
|
|
|
@abstractmethod
|
|
def add(self:Self,
|
|
Type:type[T],
|
|
inputs:dict[str, Any]|list[Any|None]|tuple[Any|None, ...]|str,
|
|
overwrite:bool = False
|
|
) -> None:pass |