lmnr 0.4.7__py3-none-any.whl → 0.4.8__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- lmnr/sdk/evaluations.py +4 -4
- lmnr/sdk/types.py +8 -8
- {lmnr-0.4.7.dist-info → lmnr-0.4.8.dist-info}/METADATA +1 -1
- {lmnr-0.4.7.dist-info → lmnr-0.4.8.dist-info}/RECORD +7 -7
- {lmnr-0.4.7.dist-info → lmnr-0.4.8.dist-info}/LICENSE +0 -0
- {lmnr-0.4.7.dist-info → lmnr-0.4.8.dist-info}/WHEEL +0 -0
- {lmnr-0.4.7.dist-info → lmnr-0.4.8.dist-info}/entry_points.txt +0 -0
lmnr/sdk/evaluations.py
CHANGED
@@ -1,6 +1,6 @@
|
|
1
|
-
from typing import Union
|
1
|
+
from typing import Any, Union
|
2
2
|
|
3
|
-
from .types import
|
3
|
+
from .types import EvaluationDatapoint
|
4
4
|
from .utils import is_async
|
5
5
|
from .laminar import Laminar as L
|
6
6
|
import asyncio
|
@@ -32,8 +32,8 @@ class Evaluation:
|
|
32
32
|
self,
|
33
33
|
name,
|
34
34
|
data: Union[EvaluationDataset, list[Union[EvaluationDatapoint, dict]]],
|
35
|
-
executor:
|
36
|
-
evaluators: list[
|
35
|
+
executor: Any,
|
36
|
+
evaluators: list[Any],
|
37
37
|
batch_size: int = DEFAULT_BATCH_SIZE,
|
38
38
|
project_api_key: str = "",
|
39
39
|
base_url: str = "https://api.lmnr.ai",
|
lmnr/sdk/types.py
CHANGED
@@ -90,19 +90,19 @@ class EvaluationDatapoint(pydantic.BaseModel):
|
|
90
90
|
ExecutorFunctionReturnType: TypeAlias = Any
|
91
91
|
EvaluatorFunctionReturnType: TypeAlias = Union[Numeric, dict[str, Numeric]]
|
92
92
|
|
93
|
-
ExecutorFunction: TypeAlias = Callable[
|
94
|
-
|
95
|
-
|
96
|
-
]
|
93
|
+
# ExecutorFunction: TypeAlias = Callable[
|
94
|
+
# [EvaluationDatapointData, *tuple[Any, ...], dict[str, Any]],
|
95
|
+
# Union[ExecutorFunctionReturnType, Awaitable[ExecutorFunctionReturnType]],
|
96
|
+
# ]
|
97
97
|
|
98
98
|
# EvaluatorFunction is a function that takes the output of the executor and the
|
99
99
|
# target data, and returns a score. The score can be a single number or a
|
100
100
|
# record of string keys and number values. The latter is useful for evaluating
|
101
101
|
# multiple criteria in one go instead of running multiple evaluators.
|
102
|
-
EvaluatorFunction: TypeAlias = Callable[
|
103
|
-
|
104
|
-
|
105
|
-
]
|
102
|
+
# EvaluatorFunction: TypeAlias = Callable[
|
103
|
+
# [ExecutorFunctionReturnType, *tuple[Any, ...], dict[str, Any]],
|
104
|
+
# Union[EvaluatorFunctionReturnType, Awaitable[EvaluatorFunctionReturnType]],
|
105
|
+
# ]
|
106
106
|
|
107
107
|
EvaluationStatus: TypeAlias = Literal["Started", "Finished", "Error"]
|
108
108
|
|
@@ -1,10 +1,10 @@
|
|
1
1
|
lmnr/__init__.py,sha256=wQwnHl662Xcz7GdSofFsEjmAK0nxioYA2Yq6Q78m4ps,194
|
2
2
|
lmnr/sdk/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
3
3
|
lmnr/sdk/decorators.py,sha256=0dLKWeKMmG_ryyK285GNsWBZSCWIyRhHgaDHlsJnDeM,2318
|
4
|
-
lmnr/sdk/evaluations.py,sha256=
|
4
|
+
lmnr/sdk/evaluations.py,sha256=EaRcwbdXxj4w2yzak1xFv-YhDuxRVentQcJ-CypBoH0,6307
|
5
5
|
lmnr/sdk/laminar.py,sha256=d5Tt_OyrhtZTfm_ehd3QZev7T6-AKTJU5xAan0-3yPA,20070
|
6
6
|
lmnr/sdk/log.py,sha256=EgAMY77Zn1bv1imCqrmflD3imoAJ2yveOkIcrIP3e98,1170
|
7
|
-
lmnr/sdk/types.py,sha256=
|
7
|
+
lmnr/sdk/types.py,sha256=yTOoVHlg_wpce4Zx1ZSE3y7Qpwh9mcLCPKUi_1nfdk4,4071
|
8
8
|
lmnr/sdk/utils.py,sha256=ZsGJ86tq8lIbvOhSb1gJWH5K3GylO_lgX68FN6rG2nM,3358
|
9
9
|
lmnr/traceloop_sdk/.flake8,sha256=bCxuDlGx3YQ55QHKPiGJkncHanh9qGjQJUujcFa3lAU,150
|
10
10
|
lmnr/traceloop_sdk/.python-version,sha256=9OLQBQVbD4zE4cJsPePhnAfV_snrPSoqEQw-PXgPMOs,6
|
@@ -46,8 +46,8 @@ lmnr/traceloop_sdk/utils/in_memory_span_exporter.py,sha256=H_4TRaThMO1H6vUQ0OpQv
|
|
46
46
|
lmnr/traceloop_sdk/utils/json_encoder.py,sha256=dK6b_axr70IYL7Vv-bu4wntvDDuyntoqsHaddqX7P58,463
|
47
47
|
lmnr/traceloop_sdk/utils/package_check.py,sha256=TZSngzJOpFhfUZLXIs38cpMxQiZSmp0D-sCrIyhz7BA,251
|
48
48
|
lmnr/traceloop_sdk/version.py,sha256=OlatFEFA4ttqSSIiV8jdE-sq3KG5zu2hnC4B4mzWF3s,23
|
49
|
-
lmnr-0.4.
|
50
|
-
lmnr-0.4.
|
51
|
-
lmnr-0.4.
|
52
|
-
lmnr-0.4.
|
53
|
-
lmnr-0.4.
|
49
|
+
lmnr-0.4.8.dist-info/LICENSE,sha256=67b_wJHVV1CBaWkrKFWU1wyqTPSdzH77Ls-59631COg,10411
|
50
|
+
lmnr-0.4.8.dist-info/METADATA,sha256=biZj3jg_XUVTA4Xgpq66VNfhfvCPi6aDmE2VK4UXXFQ,10792
|
51
|
+
lmnr-0.4.8.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
|
52
|
+
lmnr-0.4.8.dist-info/entry_points.txt,sha256=Qg7ZRax4k-rcQsZ26XRYQ8YFSBiyY2PNxYfq4a6PYXI,41
|
53
|
+
lmnr-0.4.8.dist-info/RECORD,,
|
File without changes
|
File without changes
|
File without changes
|