arize-phoenix 11.3.0__py3-none-any.whl → 11.5.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-11.3.0.dist-info → arize_phoenix-11.5.0.dist-info}/METADATA +4 -2
- {arize_phoenix-11.3.0.dist-info → arize_phoenix-11.5.0.dist-info}/RECORD +42 -40
- phoenix/config.py +51 -2
- phoenix/db/facilitator.py +15 -24
- phoenix/server/api/auth.py +1 -1
- phoenix/server/api/queries.py +34 -22
- phoenix/server/api/routers/v1/annotation_configs.py +4 -1
- phoenix/server/api/routers/v1/datasets.py +3 -1
- phoenix/server/api/routers/v1/evaluations.py +3 -1
- phoenix/server/api/routers/v1/experiment_evaluations.py +3 -2
- phoenix/server/api/routers/v1/experiment_runs.py +3 -1
- phoenix/server/api/routers/v1/experiments.py +3 -1
- phoenix/server/api/routers/v1/projects.py +4 -1
- phoenix/server/api/routers/v1/prompts.py +4 -1
- phoenix/server/api/routers/v1/spans.py +4 -1
- phoenix/server/api/routers/v1/traces.py +4 -1
- phoenix/server/api/routers/v1/users.py +2 -2
- phoenix/server/app.py +41 -2
- phoenix/server/authorization.py +9 -0
- phoenix/server/bearer_auth.py +18 -15
- phoenix/server/cost_tracking/model_cost_manifest.json +2343 -587
- phoenix/server/daemons/db_disk_usage_monitor.py +209 -0
- phoenix/server/email/sender.py +25 -0
- phoenix/server/email/templates/db_disk_usage_notification.html +16 -0
- phoenix/server/email/types.py +11 -0
- phoenix/server/grpc_server.py +3 -3
- phoenix/server/prometheus.py +22 -0
- phoenix/server/static/.vite/manifest.json +36 -36
- phoenix/server/static/assets/{components-DlL7ybQ2.js → components-Bwf6zNbg.js} +186 -187
- phoenix/server/static/assets/{index-QP9R8k34.js → index-Bfg9uQ43.js} +2 -2
- phoenix/server/static/assets/{pages-B7wCtpad.js → pages-BCR8hW_l.js} +447 -431
- phoenix/server/static/assets/{vendor-DqQvHbPa.js → vendor-DRWIRkSJ.js} +1 -1
- phoenix/server/static/assets/{vendor-arizeai-CLX44PFA.js → vendor-arizeai-DUhQaeau.js} +2 -2
- phoenix/server/static/assets/{vendor-codemirror-Du3XyJnB.js → vendor-codemirror-D_6Q6Auv.js} +1 -1
- phoenix/server/static/assets/{vendor-recharts-B2PJDrnX.js → vendor-recharts-BNBwj7vz.js} +1 -1
- phoenix/server/static/assets/{vendor-shiki-CNbrFjf9.js → vendor-shiki-k1qj_XjP.js} +1 -1
- phoenix/server/types.py +7 -0
- phoenix/version.py +1 -1
- {arize_phoenix-11.3.0.dist-info → arize_phoenix-11.5.0.dist-info}/WHEEL +0 -0
- {arize_phoenix-11.3.0.dist-info → arize_phoenix-11.5.0.dist-info}/entry_points.txt +0 -0
- {arize_phoenix-11.3.0.dist-info → arize_phoenix-11.5.0.dist-info}/licenses/IP_NOTICE +0 -0
- {arize_phoenix-11.3.0.dist-info → arize_phoenix-11.5.0.dist-info}/licenses/LICENSE +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: arize-phoenix
|
|
3
|
-
Version: 11.
|
|
3
|
+
Version: 11.5.0
|
|
4
4
|
Summary: AI Observability and Evaluation
|
|
5
5
|
Project-URL: Documentation, https://arize.com/docs/phoenix/
|
|
6
6
|
Project-URL: Issues, https://github.com/Arize-ai/phoenix/issues
|
|
@@ -39,10 +39,12 @@ Requires-Dist: opentelemetry-proto>=1.12.0
|
|
|
39
39
|
Requires-Dist: opentelemetry-sdk
|
|
40
40
|
Requires-Dist: opentelemetry-semantic-conventions
|
|
41
41
|
Requires-Dist: pandas>=1.0
|
|
42
|
+
Requires-Dist: prometheus-client
|
|
42
43
|
Requires-Dist: protobuf<6.0,>=4.25.8
|
|
43
44
|
Requires-Dist: psutil
|
|
44
45
|
Requires-Dist: pyarrow
|
|
45
46
|
Requires-Dist: pydantic>=2.1.0
|
|
47
|
+
Requires-Dist: python-dateutil
|
|
46
48
|
Requires-Dist: python-multipart
|
|
47
49
|
Requires-Dist: scikit-learn
|
|
48
50
|
Requires-Dist: scipy
|
|
@@ -95,7 +97,6 @@ Requires-Dist: pandas-stubs==2.2.2.240603; extra == 'dev'
|
|
|
95
97
|
Requires-Dist: pandas>=1.0; extra == 'dev'
|
|
96
98
|
Requires-Dist: portpicker; extra == 'dev'
|
|
97
99
|
Requires-Dist: pre-commit; extra == 'dev'
|
|
98
|
-
Requires-Dist: prometheus-client; extra == 'dev'
|
|
99
100
|
Requires-Dist: psycopg[binary,pool]; extra == 'dev'
|
|
100
101
|
Requires-Dist: pytest-asyncio; extra == 'dev'
|
|
101
102
|
Requires-Dist: pytest-cov; extra == 'dev'
|
|
@@ -108,6 +109,7 @@ Requires-Dist: tabulate; extra == 'dev'
|
|
|
108
109
|
Requires-Dist: tox-uv==1.11.3; extra == 'dev'
|
|
109
110
|
Requires-Dist: tox==4.18.1; extra == 'dev'
|
|
110
111
|
Requires-Dist: types-jsonschema; extra == 'dev'
|
|
112
|
+
Requires-Dist: types-python-dateutil; extra == 'dev'
|
|
111
113
|
Requires-Dist: types-tabulate; extra == 'dev'
|
|
112
114
|
Requires-Dist: uv==0.7.12; extra == 'dev'
|
|
113
115
|
Requires-Dist: uvloop; (platform_system != 'Windows') and extra == 'dev'
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
phoenix/__init__.py,sha256=xkpXH76HFbEDCq8IhiFp-2GnEHx39xPMdOpV5Skew1w,5481
|
|
2
2
|
phoenix/auth.py,sha256=yW78f1xWNjTE30ACGUM14nOd5BzkukhlzA9B45kSUkM,11053
|
|
3
|
-
phoenix/config.py,sha256=
|
|
3
|
+
phoenix/config.py,sha256=Xir2ke9AZluThsYeaiq57a8GyQOuumjIqqqeCh8PKw8,60350
|
|
4
4
|
phoenix/datetime_utils.py,sha256=fpISOdaeDBdfIa-psFp6FJyAUPWEsiT5s3-_aLV12bg,3576
|
|
5
5
|
phoenix/exceptions.py,sha256=n2L2KKuecrdflB9MsCdAYCiSEvGJptIsfRkXMoJle7A,169
|
|
6
6
|
phoenix/py.typed,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
|
|
7
7
|
phoenix/services.py,sha256=ngkyKGVatX3cO2WJdo2hKdaVKP-xJCMvqthvga6kJss,5196
|
|
8
8
|
phoenix/settings.py,sha256=2kHfT3BNOVd4dAO1bq-syEQbHSG8oX2-7NhOwK2QREk,896
|
|
9
|
-
phoenix/version.py,sha256=
|
|
9
|
+
phoenix/version.py,sha256=89g_4HXr4XouZfNDdwEbm-Xwu06Vvu-EUBmo-baEVQQ,23
|
|
10
10
|
phoenix/core/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
11
11
|
phoenix/core/embedding_dimension.py,sha256=zKGbcvwOXgLf-yrJBpQyKtd-LEOPRKHnUToyAU8Owis,87
|
|
12
12
|
phoenix/core/model.py,sha256=qBFraOtmwCCnWJltKNP18DDG0mULXigytlFsa6YOz6k,4837
|
|
@@ -19,7 +19,7 @@ phoenix/db/bulk_inserter.py,sha256=MbbmKip6gFtnLP1ZA3Z-mP-zy-Qnb9bPD8mRXJQOW2c,1
|
|
|
19
19
|
phoenix/db/constants.py,sha256=-YE2rkzcROG06_rerfnX5hC7fLzOHx1Gjw4nXhX_um4,46
|
|
20
20
|
phoenix/db/engines.py,sha256=tB_8iWMDz0folryVvw29sbBUxJOB2XZ-Xx0Uexj3uns,6889
|
|
21
21
|
phoenix/db/enums.py,sha256=w3O5YuJEEzVTwVDZb8b2UUFhU8yK_GosF081VVrrno0,188
|
|
22
|
-
phoenix/db/facilitator.py,sha256=
|
|
22
|
+
phoenix/db/facilitator.py,sha256=aRbkIJkIDP2zMsLKbO7Y8jJq4U2HbV7Lf6GYVWXVImU,20151
|
|
23
23
|
phoenix/db/helpers.py,sha256=rbbHcl-STzcEpcXCYx6jbKzko7r3ggrWHHsXjZ48HsM,5352
|
|
24
24
|
phoenix/db/migrate.py,sha256=oUrXH8yEbcpL4eh09aSCuUiSrhFli0eT5D_j4ZmYChY,2797
|
|
25
25
|
phoenix/db/models.py,sha256=0avhbUmDEBZ1_NgBSr9Ck9BYxXtJTraPfQqDGZFE2-Y,60388
|
|
@@ -91,28 +91,28 @@ phoenix/pointcloud/pointcloud.py,sha256=SN_1wXZcwKrtSnHGZLDZGx71orqE1WyVF7E-D58d
|
|
|
91
91
|
phoenix/pointcloud/projectors.py,sha256=TQgwc9cJDjJkin1WZyZzgl3HsYrLLiyWD7Czy4jNW3U,1088
|
|
92
92
|
phoenix/pointcloud/umap_parameters.py,sha256=db_WEPoamuWtopZx7tQfAXPnoE0MS8FkAV0_ThjEx_Q,1735
|
|
93
93
|
phoenix/server/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
94
|
-
phoenix/server/app.py,sha256=
|
|
95
|
-
phoenix/server/authorization.py,sha256=
|
|
96
|
-
phoenix/server/bearer_auth.py,sha256=
|
|
94
|
+
phoenix/server/app.py,sha256=oz5vDRGj58XUd1yOcCKVBQP6hmRiZAI3FMjnXkAxDoE,46758
|
|
95
|
+
phoenix/server/authorization.py,sha256=AGpQT6HpPn2ROOxxVBvjPV1393KF4v-K5IHJ4JaTOHM,2175
|
|
96
|
+
phoenix/server/bearer_auth.py,sha256=f4v4W94KyTdGGCPsK1tXOe0vouPuvanAEa03XSdCvPE,6650
|
|
97
97
|
phoenix/server/dml_event.py,sha256=MjJmVEKytq75chBOSyvYDusUnEbg1pHpIjR3pZkUaJA,2838
|
|
98
98
|
phoenix/server/dml_event_handler.py,sha256=gkDIONyTz9sLbSA6qOZCigiO5val-fvVcLzDrWNcVcg,8306
|
|
99
|
-
phoenix/server/grpc_server.py,sha256=
|
|
99
|
+
phoenix/server/grpc_server.py,sha256=ahHC394gFZYM3h4FmjQxZwL-a4x3mWmV2EdXYFlNEC8,4676
|
|
100
100
|
phoenix/server/jwt_store.py,sha256=B6uVildN_dQDTG_-aHHvuVSI7wIVK1yvED-_y6se2GU,16905
|
|
101
101
|
phoenix/server/main.py,sha256=UBwxrQIEE7ci-SbE6GAlRYmbMHooI6JYG6sG-UpBFFs,18905
|
|
102
102
|
phoenix/server/oauth2.py,sha256=GvUqZBoZ5dG-l2G1RMl1SUcN10jNAjaMXFznMSWz2Zs,3336
|
|
103
|
-
phoenix/server/prometheus.py,sha256=
|
|
103
|
+
phoenix/server/prometheus.py,sha256=c7G_5Rvb7teCzBHuEvwHMZjE2iYrsLLYAcg2mPU8y_c,8678
|
|
104
104
|
phoenix/server/rate_limiters.py,sha256=cFc73D2NaxqNZZDbwfIDw4So-fRVOJPBtqxOZ8Qky_s,7155
|
|
105
105
|
phoenix/server/retention.py,sha256=MQe1FWuc_NxhqgIq5q2hfFhWT8ddAmpppgI74xYEQ6c,3064
|
|
106
106
|
phoenix/server/telemetry.py,sha256=4EluDDrhdDPxAjaW6lVSbi73xkB5XeUCZWOmZGdk0hg,2755
|
|
107
107
|
phoenix/server/thread_server.py,sha256=Ea2AWreN1lwJsT2wYvGaRaiXrzBqH4kgkZpx0FO5Ocw,2144
|
|
108
|
-
phoenix/server/types.py,sha256=
|
|
108
|
+
phoenix/server/types.py,sha256=OdC56_7R7EoUPUx5t8kw9dnedH_Ut-RkVI5atya3joI,7918
|
|
109
109
|
phoenix/server/api/README.md,sha256=Pyq1PLPgTzXAswrfIhGXrjI3Skq8it2jTVnanT6Ba4Q,1162
|
|
110
110
|
phoenix/server/api/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
111
|
-
phoenix/server/api/auth.py,sha256=
|
|
111
|
+
phoenix/server/api/auth.py,sha256=Bf21wayr-Jrp0ZF9RgbOi9_M91eHE1Tclq9lDYtrkTU,1575
|
|
112
112
|
phoenix/server/api/context.py,sha256=mqsq_8Ru50e-PxKWNTzh9zptb1PFjYFUf58uW59UYL0,8996
|
|
113
113
|
phoenix/server/api/exceptions.py,sha256=TA0JuY2YRnj35qGuMSQ8d0ToHum9gWm9W--3fSKHrX0,1171
|
|
114
114
|
phoenix/server/api/interceptor.py,sha256=ykDnoC_apUd-llVli3m1CW18kNSIgjz2qZ6m5JmPDu8,1294
|
|
115
|
-
phoenix/server/api/queries.py,sha256=
|
|
115
|
+
phoenix/server/api/queries.py,sha256=BIM-6k-TGWYSalFEADWi5zpL3-6EUoQdpXLD4GmuaMw,45274
|
|
116
116
|
phoenix/server/api/schema.py,sha256=fcs36xQwFF_Qe41_5cWR8wYpDvOrnbcyTeo5WNMbDsA,1702
|
|
117
117
|
phoenix/server/api/subscriptions.py,sha256=ZOGNsLVr5TNjCWgbzO7Eq6Ls_NRdJH9AxC0cW_v0vhM,25332
|
|
118
118
|
phoenix/server/api/utils.py,sha256=quCBRcusc6PUq9tJq7M8PgwFZp7nXgVAxtbw8feribY,833
|
|
@@ -252,19 +252,19 @@ phoenix/server/api/routers/embeddings.py,sha256=BpZGJee0pdL0W5Rp1L0b30dEtZTgJeVq
|
|
|
252
252
|
phoenix/server/api/routers/oauth2.py,sha256=EUoBeh4Ix-Uwt_q_RD75xbMcdVdd0xJLDYjELdVHBTw,24051
|
|
253
253
|
phoenix/server/api/routers/utils.py,sha256=M41BoH-fl37izhRuN2aX7lWm7jOC20A_3uClv9TVUUY,583
|
|
254
254
|
phoenix/server/api/routers/v1/__init__.py,sha256=ngLMPjC7lgZxgKy_Is33KxTRnMzSqy25qTTChCVx_Mo,2696
|
|
255
|
-
phoenix/server/api/routers/v1/annotation_configs.py,sha256=
|
|
255
|
+
phoenix/server/api/routers/v1/annotation_configs.py,sha256=xp5lJmKYlRsINCUrRD9-lTAElw2v4hdFndS5BWrxICA,16048
|
|
256
256
|
phoenix/server/api/routers/v1/annotations.py,sha256=fVl2qeh_ZbWXGvFBTZgeL7aGkkINIScdjuyxnOoSzNM,6817
|
|
257
|
-
phoenix/server/api/routers/v1/datasets.py,sha256=
|
|
258
|
-
phoenix/server/api/routers/v1/evaluations.py,sha256=
|
|
259
|
-
phoenix/server/api/routers/v1/experiment_evaluations.py,sha256=
|
|
260
|
-
phoenix/server/api/routers/v1/experiment_runs.py,sha256=
|
|
261
|
-
phoenix/server/api/routers/v1/experiments.py,sha256=
|
|
257
|
+
phoenix/server/api/routers/v1/datasets.py,sha256=CnmO2fe-hNPPpLx6L1jzeLdTNrpabkKuepIihIL6u_s,37734
|
|
258
|
+
phoenix/server/api/routers/v1/evaluations.py,sha256=ni_OJcroE93ZmKoU8I8LYqEgCngG6TyHXpFlcYzoabQ,12937
|
|
259
|
+
phoenix/server/api/routers/v1/experiment_evaluations.py,sha256=_xnVqFCwZoOUPravdPixZLSQiU1H3sB5EzMknB7E1CI,4837
|
|
260
|
+
phoenix/server/api/routers/v1/experiment_runs.py,sha256=LZeCQWQIEOZ9jK5Gp_C4JbiYY6AmnnWe85cVcvdkCLE,7107
|
|
261
|
+
phoenix/server/api/routers/v1/experiments.py,sha256=osy0JG_iVSCkoRi__0tjldfS5zzBDvNfv-GimbP4ShA,20537
|
|
262
262
|
phoenix/server/api/routers/v1/models.py,sha256=p3gJN-9SWiUYTUTft4bZMsZVCBNTb4nN1Foy68eRZzQ,1997
|
|
263
|
-
phoenix/server/api/routers/v1/projects.py,sha256=
|
|
264
|
-
phoenix/server/api/routers/v1/prompts.py,sha256=
|
|
265
|
-
phoenix/server/api/routers/v1/spans.py,sha256=
|
|
266
|
-
phoenix/server/api/routers/v1/traces.py,sha256=
|
|
267
|
-
phoenix/server/api/routers/v1/users.py,sha256=
|
|
263
|
+
phoenix/server/api/routers/v1/projects.py,sha256=32GwTLsaFgQLVNdjrlrGe90XT3pIX1N7-zX9D9_J_4w,12701
|
|
264
|
+
phoenix/server/api/routers/v1/prompts.py,sha256=chRYcLkOYDJdJfVZVukVTUyIRnLPvsJCg41CuPxOIU8,26695
|
|
265
|
+
phoenix/server/api/routers/v1/spans.py,sha256=ib7kWpIpSqI53XFFU5xw80tmenajI5m8c8yfvDfTPrQ,44256
|
|
266
|
+
phoenix/server/api/routers/v1/traces.py,sha256=63T-WYiwh8X3Sp6u_OFfA9zLLKk6cNsnciiDyUzKLVk,8561
|
|
267
|
+
phoenix/server/api/routers/v1/users.py,sha256=hUZCe7ctJqEkSJBe046a0OAFMLZodtyO7NLP7U6S8Pg,11986
|
|
268
268
|
phoenix/server/api/routers/v1/utils.py,sha256=oXIOGPzPTkE0ZWUTRCoRIQQ7wTzoSwtWFaUSjlGBqts,4960
|
|
269
269
|
phoenix/server/api/types/Annotation.py,sha256=gsl8CwjIbDUbZRj4d9USwZ_w_Tkz4i7zuZh9ftV80jA,1132
|
|
270
270
|
phoenix/server/api/types/AnnotationConfig.py,sha256=TPukZUgvFC17W93Vnme21EhswasBMR-ZiuSWteiWZOU,3891
|
|
@@ -358,16 +358,18 @@ phoenix/server/cost_tracking/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NM
|
|
|
358
358
|
phoenix/server/cost_tracking/cost_details_calculator.py,sha256=ywWQO6foRZC0CmbNPGpa3DaPoWzuIp3ke9s4NqHLuUw,8736
|
|
359
359
|
phoenix/server/cost_tracking/cost_model_lookup.py,sha256=ys-jZY3cSE2_-f1glFhYgOd60kQdDL07MnChaxojTLo,6800
|
|
360
360
|
phoenix/server/cost_tracking/helpers.py,sha256=Pk6ECjnYreTxrldtRwxnwFcxIPVsvDq_yAwDA_spkOc,2122
|
|
361
|
-
phoenix/server/cost_tracking/model_cost_manifest.json,sha256=
|
|
361
|
+
phoenix/server/cost_tracking/model_cost_manifest.json,sha256=UgtshWqK3KV4tsgboS0Z4xj08PEnCwubaMhliN1fquk,54092
|
|
362
362
|
phoenix/server/cost_tracking/regex_specificity.py,sha256=9kqWuQ68C-hlwW25hr7BhFlRt5y2Nnpy0Ax3n9UN6Xk,11622
|
|
363
363
|
phoenix/server/cost_tracking/token_cost_calculator.py,sha256=2JEZnvusx2-xbhp8krp9EarjWuyGH2KO4e-ZwJX-K0s,1598
|
|
364
364
|
phoenix/server/daemons/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
365
|
+
phoenix/server/daemons/db_disk_usage_monitor.py,sha256=benip_Qomzec7P5D53JLd0mFHpR5YKDuyC89gp52H00,7810
|
|
365
366
|
phoenix/server/daemons/generative_model_store.py,sha256=CkMG0jFWtxcUNP_7iFTgzHPyl5IgnXUwwJb7584pmkI,1566
|
|
366
367
|
phoenix/server/daemons/span_cost_calculator.py,sha256=0BXMe9sHN8k5RjIQjCBzZdwvFuBHu8zDqAJc8rXbQA0,3199
|
|
367
368
|
phoenix/server/email/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
368
|
-
phoenix/server/email/sender.py,sha256=
|
|
369
|
-
phoenix/server/email/types.py,sha256=
|
|
369
|
+
phoenix/server/email/sender.py,sha256=mTZUdf_M9GRiA2_MXmWO6hXvQHXbuRUyea-_YoTC5Mo,4974
|
|
370
|
+
phoenix/server/email/types.py,sha256=f1XXk4OQJlLSCHweujrGlkZic7CtbUSnfdPXzqP9WRI,772
|
|
370
371
|
phoenix/server/email/templates/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
372
|
+
phoenix/server/email/templates/db_disk_usage_notification.html,sha256=VsGW_yPXPgspwp_xhFYANoqDENaO3En36qSw26l4fh4,733
|
|
371
373
|
phoenix/server/email/templates/password_reset.html,sha256=jv0Pe-06JloPZcubRWxPdAFHYEn9eDj_4SjmuoIwshI,441
|
|
372
374
|
phoenix/server/email/templates/welcome.html,sha256=AyVsIOtpmyYwWmmkXjuEgXwkbsag4YHHKfkmOTiNo-M,316
|
|
373
375
|
phoenix/server/middleware/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
@@ -383,16 +385,16 @@ phoenix/server/static/apple-touch-icon-76x76.png,sha256=CT_xT12I0u2i0WU8JzBZBuOQ
|
|
|
383
385
|
phoenix/server/static/apple-touch-icon.png,sha256=fOfpjqGpWYbJ0eAurKsyoZP1EAs6ZVooBJ_SGk2ZkDs,3801
|
|
384
386
|
phoenix/server/static/favicon.ico,sha256=bY0vvCKRftemZfPShwZtE93DiiQdaYaozkPGwNFr6H8,34494
|
|
385
387
|
phoenix/server/static/modernizr.js,sha256=mvK-XtkNqjOral-QvzoqsyOMECXIMu5BQwSVN_wcU9c,2564
|
|
386
|
-
phoenix/server/static/.vite/manifest.json,sha256=
|
|
387
|
-
phoenix/server/static/assets/components-
|
|
388
|
-
phoenix/server/static/assets/index-
|
|
389
|
-
phoenix/server/static/assets/pages-
|
|
390
|
-
phoenix/server/static/assets/vendor-
|
|
388
|
+
phoenix/server/static/.vite/manifest.json,sha256=ZL_0RVhWw_gqiweBE08ChN_fTip0uAUv9LpftqB_gbQ,2165
|
|
389
|
+
phoenix/server/static/assets/components-Bwf6zNbg.js,sha256=zjt5QXni04diJyCeU7EUjC9aXmgEy4z_GFbY-9sFjLU,613779
|
|
390
|
+
phoenix/server/static/assets/index-Bfg9uQ43.js,sha256=TfWnwuZRhp_gO7pmIk20FYl5gz0zQlOUQkaO8NXh6e0,61540
|
|
391
|
+
phoenix/server/static/assets/pages-BCR8hW_l.js,sha256=8_EPH5EgP4I-Z2YPV9CK3mbdmHp3LHJ4KLg5368MQDE,1142908
|
|
392
|
+
phoenix/server/static/assets/vendor-DRWIRkSJ.js,sha256=f56XLATSYmnWXn7652x9UsGk4jOQygtd7bfaXtI4I_o,2738792
|
|
391
393
|
phoenix/server/static/assets/vendor-WIZid84E.css,sha256=spZD2r7XL5GfLO13ln-IuXfnjAref8l6g_n_AvxxOlI,5517
|
|
392
|
-
phoenix/server/static/assets/vendor-arizeai-
|
|
393
|
-
phoenix/server/static/assets/vendor-codemirror-
|
|
394
|
-
phoenix/server/static/assets/vendor-recharts-
|
|
395
|
-
phoenix/server/static/assets/vendor-shiki-
|
|
394
|
+
phoenix/server/static/assets/vendor-arizeai-DUhQaeau.js,sha256=FtPCxnjNFpPwea0mcq1qokn2T5MQWpp-yxL-_ZbaUZw,181769
|
|
395
|
+
phoenix/server/static/assets/vendor-codemirror-D_6Q6Auv.js,sha256=poYtDd52iZVllnYDEqBUCz9n3h9o8DWzIsfhpP1q9pU,781264
|
|
396
|
+
phoenix/server/static/assets/vendor-recharts-BNBwj7vz.js,sha256=mskT3kobCNuJlVio5idqsqw0dJ-v94a9D0wXmKHV94o,282150
|
|
397
|
+
phoenix/server/static/assets/vendor-shiki-k1qj_XjP.js,sha256=fQi82DMPyJAp6Ng4MlL1THL26gUcYKDOM6XB5-JpoqE,8980312
|
|
396
398
|
phoenix/server/static/assets/vendor-three-C5WAXd5r.js,sha256=ELkg06u70N7h8oFmvqdoHyPuUf9VgGEWeT4LKFx4VWo,620975
|
|
397
399
|
phoenix/server/templates/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
398
400
|
phoenix/server/templates/index.html,sha256=rTdJZOlbZmm1dMCrHWikAwcecZDxduPU5zCFd2h2cbs,6819
|
|
@@ -433,9 +435,9 @@ phoenix/utilities/project.py,sha256=auVpARXkDb-JgeX5f2aStyFIkeKvGwN9l7qrFeJMVxI,
|
|
|
433
435
|
phoenix/utilities/re.py,sha256=6YyUWIkv0zc2SigsxfOWIHzdpjKA_TZo2iqKq7zJKvw,2081
|
|
434
436
|
phoenix/utilities/span_store.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
435
437
|
phoenix/utilities/template_formatters.py,sha256=gh9PJD6WEGw7TEYXfSst1UR4pWWwmjxMLrDVQ_CkpkQ,2779
|
|
436
|
-
arize_phoenix-11.
|
|
437
|
-
arize_phoenix-11.
|
|
438
|
-
arize_phoenix-11.
|
|
439
|
-
arize_phoenix-11.
|
|
440
|
-
arize_phoenix-11.
|
|
441
|
-
arize_phoenix-11.
|
|
438
|
+
arize_phoenix-11.5.0.dist-info/METADATA,sha256=cyab8qY5pMOami0zRvOPxRRprGOB2MF19X-x00QU3Ck,27761
|
|
439
|
+
arize_phoenix-11.5.0.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
|
440
|
+
arize_phoenix-11.5.0.dist-info/entry_points.txt,sha256=Pgpn8Upxx9P8z8joPXZWl2LlnAlGc3gcQoVchb06X1Q,94
|
|
441
|
+
arize_phoenix-11.5.0.dist-info/licenses/IP_NOTICE,sha256=JBqyyCYYxGDfzQ0TtsQgjts41IJoa-hiwDrBjCb9gHM,469
|
|
442
|
+
arize_phoenix-11.5.0.dist-info/licenses/LICENSE,sha256=HFkW9REuMOkvKRACuwLPT0hRydHb3zNg-fdFt94td18,3794
|
|
443
|
+
arize_phoenix-11.5.0.dist-info/RECORD,,
|
phoenix/config.py
CHANGED
|
@@ -106,7 +106,24 @@ ENV_PHOENIX_DATABASE_ALLOCATED_STORAGE_CAPACITY_GIBIBYTES = (
|
|
|
106
106
|
)
|
|
107
107
|
"""
|
|
108
108
|
The allocated storage capacity for the Phoenix database in gibibytes (2^30 bytes). Use float for
|
|
109
|
-
fractional value.
|
|
109
|
+
fractional value.
|
|
110
|
+
"""
|
|
111
|
+
ENV_PHOENIX_DATABASE_USAGE_EMAIL_WARNING_THRESHOLD_PERCENTAGE = (
|
|
112
|
+
"PHOENIX_DATABASE_USAGE_EMAIL_WARNING_THRESHOLD_PERCENTAGE"
|
|
113
|
+
)
|
|
114
|
+
"""
|
|
115
|
+
The percentage of the allocated storage capacity that, when exceeded, triggers a email notifications
|
|
116
|
+
to admin users with valid email addresses. Must be specified in conjunction with allocated storage
|
|
117
|
+
capacity. This is a percentage value between 0 and 100. This setting is ignored if SMTP is not
|
|
118
|
+
configured.
|
|
119
|
+
"""
|
|
120
|
+
ENV_PHOENIX_DATABASE_USAGE_INSERTION_BLOCKING_THRESHOLD_PERCENTAGE = (
|
|
121
|
+
"PHOENIX_DATABASE_USAGE_INSERTION_BLOCKING_THRESHOLD_PERCENTAGE"
|
|
122
|
+
)
|
|
123
|
+
"""
|
|
124
|
+
The percentage of the allocated storage capacity that blocks insertions and updates of database
|
|
125
|
+
records when exceeded. Deletions are not blocked. Must be specified in conjunction with allocated
|
|
126
|
+
storage capacity. This is a percentage value between 0 and 100.
|
|
110
127
|
"""
|
|
111
128
|
ENV_PHOENIX_ENABLE_PROMETHEUS = "PHOENIX_ENABLE_PROMETHEUS"
|
|
112
129
|
"""
|
|
@@ -1312,7 +1329,36 @@ def get_env_database_schema() -> Optional[str]:
|
|
|
1312
1329
|
|
|
1313
1330
|
|
|
1314
1331
|
def get_env_database_allocated_storage_capacity_gibibytes() -> Optional[float]:
|
|
1315
|
-
|
|
1332
|
+
ans = _float_val(ENV_PHOENIX_DATABASE_ALLOCATED_STORAGE_CAPACITY_GIBIBYTES)
|
|
1333
|
+
if ans is not None and ans <= 0:
|
|
1334
|
+
raise ValueError(
|
|
1335
|
+
f"Invalid value for environment variable "
|
|
1336
|
+
f"{ENV_PHOENIX_DATABASE_ALLOCATED_STORAGE_CAPACITY_GIBIBYTES}: "
|
|
1337
|
+
f"{ans}. Value must be a positive number."
|
|
1338
|
+
)
|
|
1339
|
+
return ans
|
|
1340
|
+
|
|
1341
|
+
|
|
1342
|
+
def get_env_database_usage_email_warning_threshold_percentage() -> Optional[float]:
|
|
1343
|
+
ans = _float_val(ENV_PHOENIX_DATABASE_USAGE_EMAIL_WARNING_THRESHOLD_PERCENTAGE)
|
|
1344
|
+
if ans is not None and not (0 <= ans <= 100):
|
|
1345
|
+
raise ValueError(
|
|
1346
|
+
f"Invalid value for environment variable "
|
|
1347
|
+
f"{ENV_PHOENIX_DATABASE_USAGE_EMAIL_WARNING_THRESHOLD_PERCENTAGE}: "
|
|
1348
|
+
f"{ans}. Value must be a percentage between 0 and 100."
|
|
1349
|
+
)
|
|
1350
|
+
return ans
|
|
1351
|
+
|
|
1352
|
+
|
|
1353
|
+
def get_env_database_usage_insertion_blocking_threshold_percentage() -> Optional[float]:
|
|
1354
|
+
ans = _float_val(ENV_PHOENIX_DATABASE_USAGE_INSERTION_BLOCKING_THRESHOLD_PERCENTAGE)
|
|
1355
|
+
if ans is not None and not (0 <= ans <= 100):
|
|
1356
|
+
raise ValueError(
|
|
1357
|
+
f"Invalid value for environment variable "
|
|
1358
|
+
f"{ENV_PHOENIX_DATABASE_USAGE_INSERTION_BLOCKING_THRESHOLD_PERCENTAGE}: "
|
|
1359
|
+
f"{ans}. Value must be a percentage between 0 and 100."
|
|
1360
|
+
)
|
|
1361
|
+
return ans
|
|
1316
1362
|
|
|
1317
1363
|
|
|
1318
1364
|
def get_env_enable_prometheus() -> bool:
|
|
@@ -1558,6 +1604,9 @@ def verify_server_environment_variables() -> None:
|
|
|
1558
1604
|
get_env_root_url()
|
|
1559
1605
|
get_env_phoenix_secret()
|
|
1560
1606
|
get_env_phoenix_admin_secret()
|
|
1607
|
+
get_env_database_allocated_storage_capacity_gibibytes()
|
|
1608
|
+
get_env_database_usage_email_warning_threshold_percentage()
|
|
1609
|
+
get_env_database_usage_insertion_blocking_threshold_percentage()
|
|
1561
1610
|
|
|
1562
1611
|
# Notify users about deprecated environment variables if they are being used.
|
|
1563
1612
|
if os.getenv("PHOENIX_ENABLE_WEBSOCKETS") is not None:
|
phoenix/db/facilitator.py
CHANGED
|
@@ -406,17 +406,6 @@ async def _ensure_model_costs(db: DbSessionFactory) -> None:
|
|
|
406
406
|
with open(_COST_MODEL_MANIFEST) as f:
|
|
407
407
|
manifest = json.load(f)
|
|
408
408
|
|
|
409
|
-
# Define all supported token types with their prompt/non-prompt classification
|
|
410
|
-
# This determines how tokens are categorized for billing purposes
|
|
411
|
-
token_types: list[_TokenTypeKey] = [
|
|
412
|
-
_TokenTypeKey("input", True), # Standard input tokens
|
|
413
|
-
_TokenTypeKey("cache_write", True), # Tokens written to cache
|
|
414
|
-
_TokenTypeKey("cache_read", True), # Tokens read from cache
|
|
415
|
-
_TokenTypeKey("output", False), # Generated output tokens
|
|
416
|
-
_TokenTypeKey("audio", True), # Audio input tokens
|
|
417
|
-
_TokenTypeKey("audio", False), # Audio output tokens
|
|
418
|
-
]
|
|
419
|
-
|
|
420
409
|
async with db() as session:
|
|
421
410
|
# Fetch all existing built-in models with their token prices eagerly loaded
|
|
422
411
|
# Using .unique() to deduplicate models when multiple token prices are joined
|
|
@@ -435,9 +424,8 @@ async def _ensure_model_costs(db: DbSessionFactory) -> None:
|
|
|
435
424
|
seen_names: set[str] = set()
|
|
436
425
|
seen_patterns: set[tuple[re.Pattern[str], str]] = set()
|
|
437
426
|
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
name = str(model_data.get("model") or "").strip()
|
|
427
|
+
for model_data in manifest["models"]:
|
|
428
|
+
name = str(model_data.get("name") or "").strip()
|
|
441
429
|
if not name:
|
|
442
430
|
logger.warning("Skipping model with empty name in manifest")
|
|
443
431
|
continue
|
|
@@ -445,7 +433,7 @@ async def _ensure_model_costs(db: DbSessionFactory) -> None:
|
|
|
445
433
|
logger.warning(f"Skipping model '{name}' with duplicate name in manifest")
|
|
446
434
|
continue
|
|
447
435
|
seen_names.add(name)
|
|
448
|
-
regex = str(model_data.get("
|
|
436
|
+
regex = str(model_data.get("name_pattern") or "").strip()
|
|
449
437
|
try:
|
|
450
438
|
pattern = re.compile(regex)
|
|
451
439
|
except re.error as e:
|
|
@@ -460,7 +448,7 @@ async def _ensure_model_costs(db: DbSessionFactory) -> None:
|
|
|
460
448
|
seen_patterns.add((pattern, provider))
|
|
461
449
|
# Remove model from built_in_models dict (for cleanup tracking)
|
|
462
450
|
# or create new model if not found
|
|
463
|
-
model = built_in_models.pop(model_data["
|
|
451
|
+
model = built_in_models.pop(model_data["name"], None)
|
|
464
452
|
if model is None:
|
|
465
453
|
# Create new built-in model from manifest data
|
|
466
454
|
model = models.GenerativeModel(
|
|
@@ -477,24 +465,27 @@ async def _ensure_model_costs(db: DbSessionFactory) -> None:
|
|
|
477
465
|
|
|
478
466
|
# Create lookup table for existing token prices by (token_type, is_prompt)
|
|
479
467
|
# Using pop() during iteration allows us to track which prices are no longer needed
|
|
480
|
-
|
|
468
|
+
existing_token_prices = {
|
|
481
469
|
_TokenTypeKey(token_price.token_type, token_price.is_prompt): token_price
|
|
482
470
|
for token_price in model.token_prices
|
|
483
471
|
}
|
|
484
472
|
|
|
485
473
|
# Synchronize token prices for all supported token types
|
|
486
|
-
for
|
|
474
|
+
for manifest_token_price in model_data["token_prices"]:
|
|
487
475
|
# Skip if this token type has no rate in the manifest
|
|
488
|
-
if not (base_rate :=
|
|
476
|
+
if not (base_rate := manifest_token_price.get("base_rate")):
|
|
489
477
|
continue
|
|
490
478
|
|
|
491
|
-
key = _TokenTypeKey(
|
|
479
|
+
key = _TokenTypeKey(
|
|
480
|
+
manifest_token_price["token_type"],
|
|
481
|
+
manifest_token_price["is_prompt"],
|
|
482
|
+
)
|
|
492
483
|
# Remove from tracking dict and get existing price (if any)
|
|
493
|
-
if not (token_price :=
|
|
484
|
+
if not (token_price := existing_token_prices.pop(key, None)):
|
|
494
485
|
# Create new token price if it doesn't exist
|
|
495
486
|
token_price = models.TokenPrice(
|
|
496
|
-
token_type=token_type,
|
|
497
|
-
is_prompt=is_prompt,
|
|
487
|
+
token_type=manifest_token_price["token_type"],
|
|
488
|
+
is_prompt=manifest_token_price["is_prompt"],
|
|
498
489
|
base_rate=base_rate,
|
|
499
490
|
)
|
|
500
491
|
model.token_prices.append(token_price)
|
|
@@ -504,7 +495,7 @@ async def _ensure_model_costs(db: DbSessionFactory) -> None:
|
|
|
504
495
|
|
|
505
496
|
# Remove any token prices that are no longer in the manifest
|
|
506
497
|
# These are prices that weren't popped from the token_prices dict above
|
|
507
|
-
for token_price in
|
|
498
|
+
for token_price in existing_token_prices.values():
|
|
508
499
|
model.token_prices.remove(token_price)
|
|
509
500
|
|
|
510
501
|
# Clean up built-in models that are no longer in the manifest
|
phoenix/server/api/auth.py
CHANGED
|
@@ -29,7 +29,7 @@ class IsLocked(Authorization):
|
|
|
29
29
|
message = "Operations that write or modify data are locked"
|
|
30
30
|
|
|
31
31
|
def has_permission(self, source: Any, info: Info, **kwargs: Any) -> bool:
|
|
32
|
-
return not info.context.
|
|
32
|
+
return not info.context.db.should_not_insert_or_update
|
|
33
33
|
|
|
34
34
|
|
|
35
35
|
MSG_ADMIN_ONLY = "Only admin can perform this action"
|
phoenix/server/api/queries.py
CHANGED
|
@@ -25,7 +25,7 @@ from phoenix.db.helpers import SupportedSQLDialect, exclude_experiment_projects
|
|
|
25
25
|
from phoenix.pointcloud.clustering import Hdbscan
|
|
26
26
|
from phoenix.server.api.auth import MSG_ADMIN_ONLY, IsAdmin
|
|
27
27
|
from phoenix.server.api.context import Context
|
|
28
|
-
from phoenix.server.api.exceptions import NotFound, Unauthorized
|
|
28
|
+
from phoenix.server.api.exceptions import BadRequest, NotFound, Unauthorized
|
|
29
29
|
from phoenix.server.api.helpers import ensure_list
|
|
30
30
|
from phoenix.server.api.helpers.experiment_run_filters import (
|
|
31
31
|
ExperimentRunFilterConditionSyntaxError,
|
|
@@ -62,7 +62,13 @@ from phoenix.server.api.types.GenerativeProvider import GenerativeProvider, Gene
|
|
|
62
62
|
from phoenix.server.api.types.InferenceModel import InferenceModel
|
|
63
63
|
from phoenix.server.api.types.InferencesRole import AncillaryInferencesRole, InferencesRole
|
|
64
64
|
from phoenix.server.api.types.node import from_global_id, from_global_id_with_expected_type
|
|
65
|
-
from phoenix.server.api.types.pagination import
|
|
65
|
+
from phoenix.server.api.types.pagination import (
|
|
66
|
+
ConnectionArgs,
|
|
67
|
+
Cursor,
|
|
68
|
+
CursorString,
|
|
69
|
+
connection_from_cursors_and_nodes,
|
|
70
|
+
connection_from_list,
|
|
71
|
+
)
|
|
66
72
|
from phoenix.server.api.types.PlaygroundModel import PlaygroundModel
|
|
67
73
|
from phoenix.server.api.types.Project import Project
|
|
68
74
|
from phoenix.server.api.types.ProjectSession import ProjectSession, to_gql_project_session
|
|
@@ -349,7 +355,10 @@ class Query:
|
|
|
349
355
|
for experiment_id in experiment_ids
|
|
350
356
|
]
|
|
351
357
|
if len(set(experiment_ids_)) != len(experiment_ids_):
|
|
352
|
-
raise
|
|
358
|
+
raise BadRequest("Experiment IDs must be unique.")
|
|
359
|
+
|
|
360
|
+
cursor = Cursor.from_string(after) if after else None
|
|
361
|
+
page_size = first or 50
|
|
353
362
|
|
|
354
363
|
async with info.context.db() as session:
|
|
355
364
|
validation_result = (
|
|
@@ -371,13 +380,13 @@ class Query:
|
|
|
371
380
|
)
|
|
372
381
|
).first()
|
|
373
382
|
if validation_result is None:
|
|
374
|
-
raise
|
|
383
|
+
raise NotFound("No experiments could be found for input IDs.")
|
|
375
384
|
|
|
376
385
|
num_datasets, dataset_id, version_id, num_resolved_experiment_ids = validation_result
|
|
377
386
|
if num_datasets != 1:
|
|
378
|
-
raise
|
|
387
|
+
raise BadRequest("Experiments must belong to the same dataset.")
|
|
379
388
|
if num_resolved_experiment_ids != len(experiment_ids_):
|
|
380
|
-
raise
|
|
389
|
+
raise NotFound("Unable to resolve one or more experiment IDs.")
|
|
381
390
|
|
|
382
391
|
revision_ids = (
|
|
383
392
|
select(func.max(models.DatasetExampleRevision.id))
|
|
@@ -407,7 +416,10 @@ class Query:
|
|
|
407
416
|
),
|
|
408
417
|
)
|
|
409
418
|
.order_by(models.DatasetExample.id.desc())
|
|
419
|
+
.limit(page_size + 1)
|
|
410
420
|
)
|
|
421
|
+
if cursor is not None:
|
|
422
|
+
examples_query = examples_query.where(models.DatasetExample.id < cursor.rowid)
|
|
411
423
|
|
|
412
424
|
if filter_condition:
|
|
413
425
|
examples_query = update_examples_query_with_filter_condition(
|
|
@@ -417,6 +429,8 @@ class Query:
|
|
|
417
429
|
)
|
|
418
430
|
|
|
419
431
|
examples = (await session.scalars(examples_query)).all()
|
|
432
|
+
has_next_page = len(examples) > page_size
|
|
433
|
+
examples = examples[:page_size]
|
|
420
434
|
|
|
421
435
|
ExampleID: TypeAlias = int
|
|
422
436
|
ExperimentID: TypeAlias = int
|
|
@@ -437,7 +451,7 @@ class Query:
|
|
|
437
451
|
):
|
|
438
452
|
runs[run.dataset_example_id][run.experiment_id].append(run)
|
|
439
453
|
|
|
440
|
-
|
|
454
|
+
cursors_and_nodes = []
|
|
441
455
|
for example in examples:
|
|
442
456
|
run_comparison_items = []
|
|
443
457
|
for experiment_id in experiment_ids_:
|
|
@@ -452,23 +466,21 @@ class Query:
|
|
|
452
466
|
],
|
|
453
467
|
)
|
|
454
468
|
)
|
|
455
|
-
|
|
456
|
-
|
|
469
|
+
experiment_comparison = ExperimentComparison(
|
|
470
|
+
id_attr=example.id,
|
|
471
|
+
example=DatasetExample(
|
|
457
472
|
id_attr=example.id,
|
|
458
|
-
example
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
),
|
|
463
|
-
run_comparison_items=run_comparison_items,
|
|
464
|
-
)
|
|
473
|
+
created_at=example.created_at,
|
|
474
|
+
version_id=version_id,
|
|
475
|
+
),
|
|
476
|
+
run_comparison_items=run_comparison_items,
|
|
465
477
|
)
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
478
|
+
cursors_and_nodes.append((Cursor(rowid=example.id), experiment_comparison))
|
|
479
|
+
|
|
480
|
+
return connection_from_cursors_and_nodes(
|
|
481
|
+
cursors_and_nodes=cursors_and_nodes,
|
|
482
|
+
has_previous_page=False,
|
|
483
|
+
has_next_page=has_next_page,
|
|
472
484
|
)
|
|
473
485
|
|
|
474
486
|
@strawberry.field
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import logging
|
|
2
2
|
from typing import Annotated, List, Literal, Optional, Union
|
|
3
3
|
|
|
4
|
-
from fastapi import APIRouter, HTTPException, Path, Query
|
|
4
|
+
from fastapi import APIRouter, Depends, HTTPException, Path, Query
|
|
5
5
|
from pydantic import Field, RootModel
|
|
6
6
|
from sqlalchemy import delete, select
|
|
7
7
|
from sqlalchemy.exc import IntegrityError as PostgreSQLIntegrityError
|
|
@@ -44,6 +44,7 @@ from phoenix.server.api.types.AnnotationConfig import (
|
|
|
44
44
|
from phoenix.server.api.types.AnnotationConfig import (
|
|
45
45
|
FreeformAnnotationConfig as FreeformAnnotationConfigType,
|
|
46
46
|
)
|
|
47
|
+
from phoenix.server.authorization import is_not_locked
|
|
47
48
|
|
|
48
49
|
logger = logging.getLogger(__name__)
|
|
49
50
|
|
|
@@ -268,6 +269,7 @@ async def get_annotation_config_by_name_or_id(
|
|
|
268
269
|
|
|
269
270
|
@router.post(
|
|
270
271
|
"/annotation_configs",
|
|
272
|
+
dependencies=[Depends(is_not_locked)],
|
|
271
273
|
summary="Create an annotation configuration",
|
|
272
274
|
)
|
|
273
275
|
async def create_annotation_config(
|
|
@@ -302,6 +304,7 @@ async def create_annotation_config(
|
|
|
302
304
|
|
|
303
305
|
@router.put(
|
|
304
306
|
"/annotation_configs/{config_id}",
|
|
307
|
+
dependencies=[Depends(is_not_locked)],
|
|
305
308
|
summary="Update an annotation configuration",
|
|
306
309
|
)
|
|
307
310
|
async def update_annotation_config(
|
|
@@ -15,7 +15,7 @@ from typing import Any, Optional, Union, cast
|
|
|
15
15
|
|
|
16
16
|
import pandas as pd
|
|
17
17
|
import pyarrow as pa
|
|
18
|
-
from fastapi import APIRouter, BackgroundTasks, HTTPException, Path, Query
|
|
18
|
+
from fastapi import APIRouter, BackgroundTasks, Depends, HTTPException, Path, Query
|
|
19
19
|
from fastapi.responses import PlainTextResponse, StreamingResponse
|
|
20
20
|
from sqlalchemy import and_, delete, func, select
|
|
21
21
|
from sqlalchemy.ext.asyncio import AsyncSession
|
|
@@ -47,6 +47,7 @@ from phoenix.server.api.types.DatasetExample import DatasetExample as DatasetExa
|
|
|
47
47
|
from phoenix.server.api.types.DatasetVersion import DatasetVersion as DatasetVersionNodeType
|
|
48
48
|
from phoenix.server.api.types.node import from_global_id_with_expected_type
|
|
49
49
|
from phoenix.server.api.utils import delete_projects, delete_traces
|
|
50
|
+
from phoenix.server.authorization import is_not_locked
|
|
50
51
|
from phoenix.server.dml_event import DatasetInsertEvent
|
|
51
52
|
|
|
52
53
|
from .models import V1RoutesBaseModel
|
|
@@ -326,6 +327,7 @@ class UploadDatasetResponseBody(ResponseBody[UploadDatasetData]):
|
|
|
326
327
|
|
|
327
328
|
@router.post(
|
|
328
329
|
"/datasets/upload",
|
|
330
|
+
dependencies=[Depends(is_not_locked)],
|
|
329
331
|
operation_id="uploadDataset",
|
|
330
332
|
summary="Upload dataset from JSON, CSV, or PyArrow",
|
|
331
333
|
responses=add_errors_to_responses(
|
|
@@ -5,7 +5,7 @@ from typing import Any, Iterator, Optional, Union, cast
|
|
|
5
5
|
|
|
6
6
|
import pandas as pd
|
|
7
7
|
import pyarrow as pa
|
|
8
|
-
from fastapi import APIRouter, Header, HTTPException, Query
|
|
8
|
+
from fastapi import APIRouter, Depends, Header, HTTPException, Query
|
|
9
9
|
from google.protobuf.message import DecodeError
|
|
10
10
|
from pandas import DataFrame
|
|
11
11
|
from sqlalchemy import select
|
|
@@ -28,6 +28,7 @@ from phoenix.db import models
|
|
|
28
28
|
from phoenix.db.insertion.types import Precursors
|
|
29
29
|
from phoenix.exceptions import PhoenixEvaluationNameIsMissing
|
|
30
30
|
from phoenix.server.api.routers.utils import table_to_bytes
|
|
31
|
+
from phoenix.server.authorization import is_not_locked
|
|
31
32
|
from phoenix.server.types import DbSessionFactory
|
|
32
33
|
from phoenix.trace.span_evaluations import (
|
|
33
34
|
DocumentEvaluations,
|
|
@@ -45,6 +46,7 @@ router = APIRouter(tags=["traces"], include_in_schema=True)
|
|
|
45
46
|
|
|
46
47
|
@router.post(
|
|
47
48
|
"/evaluations",
|
|
49
|
+
dependencies=[Depends(is_not_locked)],
|
|
48
50
|
operation_id="addEvaluations",
|
|
49
51
|
summary="Add span, trace, or document evaluations",
|
|
50
52
|
status_code=HTTP_204_NO_CONTENT,
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
from datetime import datetime
|
|
2
2
|
from typing import Any, Literal, Optional
|
|
3
3
|
|
|
4
|
+
from dateutil.parser import isoparse
|
|
4
5
|
from fastapi import APIRouter, HTTPException
|
|
5
6
|
from pydantic import Field
|
|
6
7
|
from starlette.requests import Request
|
|
@@ -95,8 +96,8 @@ async def upsert_experiment_evaluation(
|
|
|
95
96
|
explanation=explanation,
|
|
96
97
|
error=error,
|
|
97
98
|
metadata_=metadata, # `metadata_` must match database
|
|
98
|
-
start_time=
|
|
99
|
-
end_time=
|
|
99
|
+
start_time=isoparse(start_time),
|
|
100
|
+
end_time=isoparse(end_time),
|
|
100
101
|
trace_id=payload.get("trace_id"),
|
|
101
102
|
)
|
|
102
103
|
dialect = SupportedSQLDialect(session.bind.dialect.name)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
from datetime import datetime
|
|
2
2
|
from typing import Any, Optional
|
|
3
3
|
|
|
4
|
-
from fastapi import APIRouter, HTTPException
|
|
4
|
+
from fastapi import APIRouter, Depends, HTTPException
|
|
5
5
|
from pydantic import Field
|
|
6
6
|
from sqlalchemy import select
|
|
7
7
|
from sqlalchemy.exc import IntegrityError as PostgreSQLIntegrityError
|
|
@@ -13,6 +13,7 @@ from strawberry.relay import GlobalID
|
|
|
13
13
|
from phoenix.db import models
|
|
14
14
|
from phoenix.db.models import ExperimentRunOutput
|
|
15
15
|
from phoenix.server.api.types.node import from_global_id_with_expected_type
|
|
16
|
+
from phoenix.server.authorization import is_not_locked
|
|
16
17
|
from phoenix.server.dml_event import ExperimentRunInsertEvent
|
|
17
18
|
|
|
18
19
|
from .models import V1RoutesBaseModel
|
|
@@ -52,6 +53,7 @@ class CreateExperimentRunResponseBody(ResponseBody[CreateExperimentRunResponseBo
|
|
|
52
53
|
|
|
53
54
|
@router.post(
|
|
54
55
|
"/experiments/{experiment_id}/runs",
|
|
56
|
+
dependencies=[Depends(is_not_locked)],
|
|
55
57
|
operation_id="createExperimentRun",
|
|
56
58
|
summary="Create run for an experiment",
|
|
57
59
|
response_description="Experiment run created successfully",
|
|
@@ -4,7 +4,7 @@ from random import getrandbits
|
|
|
4
4
|
from typing import Any, Optional
|
|
5
5
|
|
|
6
6
|
import pandas as pd
|
|
7
|
-
from fastapi import APIRouter, HTTPException, Path, Response
|
|
7
|
+
from fastapi import APIRouter, Depends, HTTPException, Path, Response
|
|
8
8
|
from pydantic import Field
|
|
9
9
|
from sqlalchemy import and_, func, select
|
|
10
10
|
from sqlalchemy.ext.asyncio import AsyncSession
|
|
@@ -18,6 +18,7 @@ from phoenix.db import models
|
|
|
18
18
|
from phoenix.db.helpers import SupportedSQLDialect
|
|
19
19
|
from phoenix.db.insertion.helpers import insert_on_conflict
|
|
20
20
|
from phoenix.server.api.types.node import from_global_id_with_expected_type
|
|
21
|
+
from phoenix.server.authorization import is_not_locked
|
|
21
22
|
from phoenix.server.dml_event import ExperimentInsertEvent
|
|
22
23
|
|
|
23
24
|
from .models import V1RoutesBaseModel
|
|
@@ -86,6 +87,7 @@ class CreateExperimentResponseBody(ResponseBody[Experiment]):
|
|
|
86
87
|
|
|
87
88
|
@router.post(
|
|
88
89
|
"/datasets/{dataset_id}/experiments",
|
|
90
|
+
dependencies=[Depends(is_not_locked)],
|
|
89
91
|
operation_id="createExperiment",
|
|
90
92
|
summary="Create experiment on a dataset",
|
|
91
93
|
responses=add_errors_to_responses(
|