arize-phoenix 3.15.0__py3-none-any.whl → 3.16.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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: arize-phoenix
3
- Version: 3.15.0
3
+ Version: 3.16.0
4
4
  Summary: AI Observability and Evaluation
5
5
  Project-URL: Documentation, https://docs.arize.com/phoenix/
6
6
  Project-URL: Issues, https://github.com/Arize-ai/phoenix/issues
@@ -4,7 +4,7 @@ phoenix/datetime_utils.py,sha256=D955QLrkgrrSdUM6NyqbCeAu2SMsjhR5rHVQEsVUdng,277
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=J-RNnUtG3KXQUxCskuOvUbJtBakEXz0p3uLA1teKUpk,23
7
+ phoenix/version.py,sha256=usla5OUN6NvnMIYTIZvXGwZwrYGCZFNM-Ypg4W8W2Ho,23
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/model.py,sha256=C-kDATyJEgP-oqYVKOiQM76Ljs66F6VZdT93_b8kTGk,4725
@@ -109,7 +109,7 @@ phoenix/server/api/types/Retrieval.py,sha256=OhMK2ncjoyp5h1yjKhjlKpoTbQrMHuxmgSF
109
109
  phoenix/server/api/types/ScalarDriftMetricEnum.py,sha256=IUAcRPpgL41WdoIgK6cNk2Te38SspXGyEs-S1fY23_A,232
110
110
  phoenix/server/api/types/Segments.py,sha256=B6UUWjalZONjWjl_l61A6USPSu15ICXRgzZ4m3vA1yw,2921
111
111
  phoenix/server/api/types/SortDir.py,sha256=OUpXhlCzCxPoXSDkJJygEs9Rw9pMymfaZUG5zPTrw4Y,152
112
- phoenix/server/api/types/Span.py,sha256=VvwYVlX4kOEFDPj63nHaOOilJTQqooSqRZ8HWsF0jgA,12317
112
+ phoenix/server/api/types/Span.py,sha256=qyJgHpj9MkYl_xsLfVm5XvoDCRkFYEt-xVNQJ4MUVow,12678
113
113
  phoenix/server/api/types/TimeSeries.py,sha256=QbLfxHnwYsMsirpq4tx9us6ha7YtAVzK4m8mAL3fMt0,5200
114
114
  phoenix/server/api/types/UMAPPoints.py,sha256=8l9RJXi308qty4MdHb2pBbiU6ZuLbrRRxXNbPhXoxKI,1639
115
115
  phoenix/server/api/types/ValidationResult.py,sha256=pHwdYk4J7SJ5xhlWWHg_6qWkfk4rjOx-bSkGHvkDE3Q,142
@@ -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=BiowVdHNX_auo5iceVwOMavsVQFFXSh-FG0HH8ybheQ,3176868
130
+ phoenix/server/static/index.js,sha256=ama86RKEPj-mNPhSYzsYXDngLW73aExeCgI3I5ByjO0,3182471
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=lO2wGA5XsftPg03rw_VcyaYf_4vegtlWbIT5ms4fA_c,1982
@@ -171,8 +171,8 @@ phoenix/utilities/error_handling.py,sha256=7b5rpGFj9EWZ8yrZK1IHvxB89suWk3lggDayU
171
171
  phoenix/utilities/logging.py,sha256=lDXd6EGaamBNcQxL4vP1au9-i_SXe0OraUDiJOcszSw,222
172
172
  phoenix/utilities/project.py,sha256=qWsvKnG1oKhOFUowXf9qiOL2ia7jaFe_ijFFHEt8GJo,431
173
173
  phoenix/utilities/span_store.py,sha256=13UK0rE4wQd70yl___WsDRnH0ru-xErng9_Ml7zfEwE,978
174
- arize_phoenix-3.15.0.dist-info/METADATA,sha256=gKH9s1rkv3nk2_cIE_C2RJBhDdWBzyES0a_v-4gVuhU,29204
175
- arize_phoenix-3.15.0.dist-info/WHEEL,sha256=TJPnKdtrSue7xZ_AVGkp9YXcvDrobsjBds1du3Nx6dc,87
176
- arize_phoenix-3.15.0.dist-info/licenses/IP_NOTICE,sha256=JBqyyCYYxGDfzQ0TtsQgjts41IJoa-hiwDrBjCb9gHM,469
177
- arize_phoenix-3.15.0.dist-info/licenses/LICENSE,sha256=HFkW9REuMOkvKRACuwLPT0hRydHb3zNg-fdFt94td18,3794
178
- arize_phoenix-3.15.0.dist-info/RECORD,,
174
+ arize_phoenix-3.16.0.dist-info/METADATA,sha256=bQ0xDq3mM6GwLknOth_amcbQOMMAtPlSpICCHLPsxS0,29204
175
+ arize_phoenix-3.16.0.dist-info/WHEEL,sha256=TJPnKdtrSue7xZ_AVGkp9YXcvDrobsjBds1du3Nx6dc,87
176
+ arize_phoenix-3.16.0.dist-info/licenses/IP_NOTICE,sha256=JBqyyCYYxGDfzQ0TtsQgjts41IJoa-hiwDrBjCb9gHM,469
177
+ arize_phoenix-3.16.0.dist-info/licenses/LICENSE,sha256=HFkW9REuMOkvKRACuwLPT0hRydHb3zNg-fdFt94td18,3794
178
+ arize_phoenix-3.16.0.dist-info/RECORD,,
@@ -4,6 +4,7 @@ from datetime import datetime
4
4
  from enum import Enum
5
5
  from typing import Any, DefaultDict, Dict, List, Mapping, Optional, Sized, cast
6
6
 
7
+ import numpy as np
7
8
  import strawberry
8
9
  from openinference.semconv.trace import EmbeddingAttributes, SpanAttributes
9
10
  from strawberry import ID, UNSET
@@ -249,7 +250,7 @@ def to_gql_span(span: WrappedSpan, project: Project) -> "Span":
249
250
  ),
250
251
  attributes=json.dumps(
251
252
  _nested_attributes(_hide_embedding_vectors(span.attributes)),
252
- default=_json_encode,
253
+ cls=_JSONEncoder,
253
254
  ),
254
255
  metadata=_convert_metadata_to_string(span.attributes.get(METADATA)),
255
256
  num_documents=num_documents,
@@ -302,10 +303,19 @@ def to_gql_span(span: WrappedSpan, project: Project) -> "Span":
302
303
  )
303
304
 
304
305
 
305
- def _json_encode(v: Any) -> str:
306
- if isinstance(v, datetime):
307
- return v.isoformat()
308
- return str(v)
306
+ class _JSONEncoder(json.JSONEncoder):
307
+ def default(self, obj: Any) -> Any:
308
+ if isinstance(obj, datetime):
309
+ return obj.isoformat()
310
+ if isinstance(obj, Enum):
311
+ return obj.value
312
+ if isinstance(obj, np.ndarray):
313
+ return list(obj)
314
+ if isinstance(obj, np.integer):
315
+ return int(obj)
316
+ if isinstance(obj, np.floating):
317
+ return float(obj)
318
+ return super().default(obj)
309
319
 
310
320
 
311
321
  def _trie() -> DefaultDict[str, Any]: