Skip to content

Class swarmauri_core.ocrs.IPredict.IPredict

swarmauri_core.ocrs.IPredict.IPredict

Bases: ABC

Interface focusing on the basic properties and settings essential for defining models.

predict abstractmethod

predict(*args, **kwargs)

Generate predictions based on the input data provided to the model.

Source code in swarmauri_core/ocrs/IPredict.py
10
11
12
13
14
15
@abstractmethod
def predict(self, *args, **kwargs) -> Any:
    """
    Generate predictions based on the input data provided to the model.
    """
    pass

apredict abstractmethod async

apredict(*args, **kwargs)

Generate predictions based on the input data provided to the model.

Source code in swarmauri_core/ocrs/IPredict.py
17
18
19
20
21
22
@abstractmethod
async def apredict(self, *args, **kwargs) -> Any:
    """
    Generate predictions based on the input data provided to the model.
    """
    pass

stream abstractmethod

stream(*args, **kwargs)

Generate predictions based on the input data provided to the model.

Source code in swarmauri_core/ocrs/IPredict.py
24
25
26
27
28
29
@abstractmethod
def stream(self, *args, **kwargs) -> Iterator[Any]:
    """
    Generate predictions based on the input data provided to the model.
    """
    pass

astream abstractmethod async

astream(*args, **kwargs)

Generate predictions based on the input data provided to the model.

Source code in swarmauri_core/ocrs/IPredict.py
31
32
33
34
35
36
@abstractmethod
async def astream(self, *args, **kwargs) -> AsyncIterator[Any]:
    """
    Generate predictions based on the input data provided to the model.
    """
    pass

batch abstractmethod

batch(*args, **kwargs)

Generate predictions based on the input data provided to the model.

Source code in swarmauri_core/ocrs/IPredict.py
38
39
40
41
42
43
@abstractmethod
def batch(self, *args, **kwargs) -> list[Any]:
    """
    Generate predictions based on the input data provided to the model.
    """
    pass

abatch abstractmethod async

abatch(*args, **kwargs)

Generate predictions based on the input data provided to the model.

Source code in swarmauri_core/ocrs/IPredict.py
45
46
47
48
49
50
@abstractmethod
async def abatch(self, *args, **kwargs) -> list[Any]:
    """
    Generate predictions based on the input data provided to the model.
    """
    pass