arize-phoenix 3.3.0__py3-none-any.whl → 3.4.0__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.
Potentially problematic release.
This version of arize-phoenix might be problematic. Click here for more details.
- {arize_phoenix-3.3.0.dist-info → arize_phoenix-3.4.0.dist-info}/METADATA +5 -3
- {arize_phoenix-3.3.0.dist-info → arize_phoenix-3.4.0.dist-info}/RECORD +9 -9
- phoenix/__init__.py +28 -0
- phoenix/core/traces.py +1 -3
- phoenix/server/static/index.js +47 -44
- phoenix/version.py +1 -1
- {arize_phoenix-3.3.0.dist-info → arize_phoenix-3.4.0.dist-info}/WHEEL +0 -0
- {arize_phoenix-3.3.0.dist-info → arize_phoenix-3.4.0.dist-info}/licenses/IP_NOTICE +0 -0
- {arize_phoenix-3.3.0.dist-info → arize_phoenix-3.4.0.dist-info}/licenses/LICENSE +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: arize-phoenix
|
|
3
|
-
Version: 3.
|
|
3
|
+
Version: 3.4.0
|
|
4
4
|
Summary: ML Observability in your notebook
|
|
5
5
|
Project-URL: Documentation, https://docs.arize.com/phoenix/
|
|
6
6
|
Project-URL: Issues, https://github.com/Arize-ai/phoenix/issues
|
|
@@ -61,6 +61,8 @@ Requires-Dist: pytest-lazy-fixture; extra == 'dev'
|
|
|
61
61
|
Requires-Dist: pytest==7.4.4; extra == 'dev'
|
|
62
62
|
Requires-Dist: ruff==0.1.5; extra == 'dev'
|
|
63
63
|
Requires-Dist: strawberry-graphql[debug-server]==0.208.2; extra == 'dev'
|
|
64
|
+
Provides-Extra: evals
|
|
65
|
+
Requires-Dist: arize-phoenix-evals>=0.0.3; extra == 'evals'
|
|
64
66
|
Provides-Extra: experimental
|
|
65
67
|
Requires-Dist: tenacity; extra == 'experimental'
|
|
66
68
|
Provides-Extra: llama-index
|
|
@@ -303,12 +305,12 @@ df = download_benchmark_dataset(
|
|
|
303
305
|
df = df.sample(100)
|
|
304
306
|
df = df.rename(
|
|
305
307
|
columns={
|
|
306
|
-
"query_text": "
|
|
308
|
+
"query_text": "input",
|
|
307
309
|
"document_text": "reference",
|
|
308
310
|
},
|
|
309
311
|
)
|
|
310
312
|
model = OpenAIModel(
|
|
311
|
-
|
|
313
|
+
model="gpt-4",
|
|
312
314
|
temperature=0.0,
|
|
313
315
|
)
|
|
314
316
|
rails =list(RAG_RELEVANCY_PROMPT_RAILS_MAP.values())
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
phoenix/__init__.py,sha256=
|
|
1
|
+
phoenix/__init__.py,sha256=mrgR7rvpc7LnBeyLzCX9wmRP4kJSJdfKDbj2zDiDjG8,2311
|
|
2
2
|
phoenix/config.py,sha256=RT4UR5VH8JUAKQhfmlkpxq2kmBSA8G8MODrC3GXWyaI,3507
|
|
3
3
|
phoenix/datetime_utils.py,sha256=D955QLrkgrrSdUM6NyqbCeAu2SMsjhR5rHVQEsVUdng,2773
|
|
4
4
|
phoenix/exceptions.py,sha256=X5k9ipUDfwSCwZB-H5zFJLas86Gf9tAx0W4l5TZxp5k,108
|
|
5
5
|
phoenix/py.typed,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
|
|
6
6
|
phoenix/services.py,sha256=f6AeyKTuOpy9RCcTCjVH3gx5nYZhbTMFOuv1WSUOB5o,4992
|
|
7
|
-
phoenix/version.py,sha256=
|
|
7
|
+
phoenix/version.py,sha256=SaDAYHfdUx0zZwEMJs8CthhSY2X4I0doARTPgX2vOwM,22
|
|
8
8
|
phoenix/core/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
9
9
|
phoenix/core/embedding_dimension.py,sha256=zKGbcvwOXgLf-yrJBpQyKtd-LEOPRKHnUToyAU8Owis,87
|
|
10
10
|
phoenix/core/evals.py,sha256=gJyqQzpud5YjtoY8h4pgXvHDsdubGfqmEewLuZHPPmQ,10224
|
|
11
11
|
phoenix/core/model.py,sha256=vQ6RxpUPlncezJvur5u6xBN0Lkrk2gW0cTyb-qqaSqA,4713
|
|
12
12
|
phoenix/core/model_schema.py,sha256=rR9VdhL_oXxbprDTPQJBXs5hw5sMPQmzx__m6Kwsxug,50394
|
|
13
13
|
phoenix/core/model_schema_adapter.py,sha256=3GkyzqUST4fYi-Bgs8qAam5hwMCdQRZTDLjZ9Bnzdm4,8268
|
|
14
|
-
phoenix/core/traces.py,sha256=
|
|
14
|
+
phoenix/core/traces.py,sha256=IHaRP-SK0iKuGpq8hpt-0fio3LhqjTmvtfPzo_X2tS8,13798
|
|
15
15
|
phoenix/datasets/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
16
16
|
phoenix/datasets/dataset.py,sha256=scKVZ7zc6Dpc_ntt-pWhzY-KWqOJEwKePuyNnKSVTGE,30515
|
|
17
17
|
phoenix/datasets/errors.py,sha256=cGp9vxnw4SewFoWBV3ZGMkhE0Kh73lPIv3Ppz_H_RoA,8261
|
|
@@ -127,7 +127,7 @@ phoenix/server/static/apple-touch-icon-76x76.png,sha256=CT_xT12I0u2i0WU8JzBZBuOQ
|
|
|
127
127
|
phoenix/server/static/apple-touch-icon.png,sha256=fOfpjqGpWYbJ0eAurKsyoZP1EAs6ZVooBJ_SGk2ZkDs,3801
|
|
128
128
|
phoenix/server/static/favicon.ico,sha256=bY0vvCKRftemZfPShwZtE93DiiQdaYaozkPGwNFr6H8,34494
|
|
129
129
|
phoenix/server/static/index.css,sha256=KKGpx4iwF91VGRm0YN-4cn8oC-oIqC6HecoPf0x3ZM8,1885
|
|
130
|
-
phoenix/server/static/index.js,sha256=
|
|
130
|
+
phoenix/server/static/index.js,sha256=73BthyJKaIMt5o5VThZoX7kGJclvLdghL9Dn80wEdUE,3144672
|
|
131
131
|
phoenix/server/static/modernizr.js,sha256=mvK-XtkNqjOral-QvzoqsyOMECXIMu5BQwSVN_wcU9c,2564
|
|
132
132
|
phoenix/server/templates/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
133
133
|
phoenix/server/templates/index.html,sha256=DlfcGoq1V5C2QkJWqP1j4Nu6_kPfsOzOrtzYF3ogghE,1900
|
|
@@ -167,8 +167,8 @@ phoenix/trace/v1/evaluation_pb2.pyi,sha256=cCbbx06gwQmaH14s3J1X25TtaARh-k1abbxQd
|
|
|
167
167
|
phoenix/utilities/__init__.py,sha256=3TVirVnjIGyaCFuJCqeZO4tjlzQ_chZgYM0itIwsEpE,656
|
|
168
168
|
phoenix/utilities/error_handling.py,sha256=7b5rpGFj9EWZ8yrZK1IHvxB89suWk3lggDayUQcvZds,1946
|
|
169
169
|
phoenix/utilities/logging.py,sha256=lDXd6EGaamBNcQxL4vP1au9-i_SXe0OraUDiJOcszSw,222
|
|
170
|
-
arize_phoenix-3.
|
|
171
|
-
arize_phoenix-3.
|
|
172
|
-
arize_phoenix-3.
|
|
173
|
-
arize_phoenix-3.
|
|
174
|
-
arize_phoenix-3.
|
|
170
|
+
arize_phoenix-3.4.0.dist-info/METADATA,sha256=GILlx8yqFVDq1YOx3KHlqPMfYKGMUnE7ndwRhIE_nG4,28853
|
|
171
|
+
arize_phoenix-3.4.0.dist-info/WHEEL,sha256=TJPnKdtrSue7xZ_AVGkp9YXcvDrobsjBds1du3Nx6dc,87
|
|
172
|
+
arize_phoenix-3.4.0.dist-info/licenses/IP_NOTICE,sha256=JBqyyCYYxGDfzQ0TtsQgjts41IJoa-hiwDrBjCb9gHM,469
|
|
173
|
+
arize_phoenix-3.4.0.dist-info/licenses/LICENSE,sha256=HFkW9REuMOkvKRACuwLPT0hRydHb3zNg-fdFt94td18,3794
|
|
174
|
+
arize_phoenix-3.4.0.dist-info/RECORD,,
|
phoenix/__init__.py
CHANGED
|
@@ -1,3 +1,9 @@
|
|
|
1
|
+
import sys
|
|
2
|
+
from importlib.abc import Loader, MetaPathFinder
|
|
3
|
+
from importlib.machinery import ModuleSpec
|
|
4
|
+
from types import ModuleType
|
|
5
|
+
from typing import Any, Optional
|
|
6
|
+
|
|
1
7
|
from .datasets.dataset import Dataset
|
|
2
8
|
from .datasets.fixtures import ExampleDatasets, load_example
|
|
3
9
|
from .datasets.schema import EmbeddingColumnNames, RetrievalEmbeddingColumnNames, Schema
|
|
@@ -41,4 +47,26 @@ __all__ = [
|
|
|
41
47
|
"NotebookEnvironment",
|
|
42
48
|
"log_evaluations",
|
|
43
49
|
"Client",
|
|
50
|
+
"evals",
|
|
44
51
|
]
|
|
52
|
+
|
|
53
|
+
|
|
54
|
+
class PhoenixEvalsFinder(MetaPathFinder):
|
|
55
|
+
def find_spec(self, fullname: Any, path: Any, target: Any = None) -> Optional[ModuleSpec]:
|
|
56
|
+
if fullname == "phoenix.evals":
|
|
57
|
+
return ModuleSpec(fullname, PhoenixEvalsLoader())
|
|
58
|
+
return None
|
|
59
|
+
|
|
60
|
+
|
|
61
|
+
class PhoenixEvalsLoader(Loader):
|
|
62
|
+
def create_module(self, spec: ModuleSpec) -> None:
|
|
63
|
+
return None
|
|
64
|
+
|
|
65
|
+
def exec_module(self, module: ModuleType) -> None:
|
|
66
|
+
raise ImportError(
|
|
67
|
+
"The optional `phoenix.evals` package is not installed. "
|
|
68
|
+
"Please install `phoenix` with the `evals` extra: `pip install 'arize-phoenix[evals]'`."
|
|
69
|
+
)
|
|
70
|
+
|
|
71
|
+
|
|
72
|
+
sys.meta_path.append(PhoenixEvalsFinder())
|
phoenix/core/traces.py
CHANGED
|
@@ -10,7 +10,6 @@ from typing import (
|
|
|
10
10
|
Dict,
|
|
11
11
|
Iterable,
|
|
12
12
|
Iterator,
|
|
13
|
-
List,
|
|
14
13
|
Optional,
|
|
15
14
|
Set,
|
|
16
15
|
SupportsFloat,
|
|
@@ -120,7 +119,6 @@ class Traces:
|
|
|
120
119
|
self._parent_span_ids: Dict[SpanID, ParentSpanID] = {}
|
|
121
120
|
self._traces: DefaultDict[TraceID, Set[ReadableSpan]] = defaultdict(set)
|
|
122
121
|
self._child_spans: DefaultDict[SpanID, Set[ReadableSpan]] = defaultdict(set)
|
|
123
|
-
self._orphan_spans: DefaultDict[ParentSpanID, List[otlp.Span]] = defaultdict(list)
|
|
124
122
|
self._num_documents: DefaultDict[SpanID, int] = defaultdict(int)
|
|
125
123
|
self._start_time_sorted_spans: SortedKeyList[ReadableSpan] = SortedKeyList(
|
|
126
124
|
key=lambda span: span.start_time,
|
|
@@ -239,7 +237,7 @@ class Traces:
|
|
|
239
237
|
|
|
240
238
|
@property
|
|
241
239
|
def span_count(self) -> int:
|
|
242
|
-
"""Total number of spans
|
|
240
|
+
"""Total number of spans"""
|
|
243
241
|
return len(self._spans)
|
|
244
242
|
|
|
245
243
|
@property
|