arize-phoenix 1.9.1rc2__tar.gz → 2.0.0__tar.gz
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-1.9.1rc2 → arize_phoenix-2.0.0}/PKG-INFO +2 -2
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/pyproject.toml +1 -1
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/__init__.py +1 -1
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/core/traces.py +1 -1
- arize_phoenix-2.0.0/src/phoenix/exceptions.py +2 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/experimental/evals/__init__.py +3 -2
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/experimental/evals/evaluators.py +89 -46
- arize_phoenix-2.0.0/src/phoenix/experimental/evals/functions/classify.py +455 -0
- arize_phoenix-2.0.0/src/phoenix/experimental/evals/functions/executor.py +353 -0
- arize_phoenix-2.0.0/src/phoenix/experimental/evals/functions/generate.py +132 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/experimental/evals/models/rate_limiters.py +25 -5
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/experimental/evals/templates/__init__.py +0 -2
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/experimental/evals/templates/template.py +2 -5
- arize_phoenix-2.0.0/src/phoenix/experimental/evals/utils/__init__.py +110 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/app.py +3 -2
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/main.py +3 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/static/index.js +548 -449
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/openai/instrumentor.py +51 -14
- arize_phoenix-1.9.1rc2/src/phoenix/experimental/evals/functions/classify.py +0 -739
- arize_phoenix-1.9.1rc2/src/phoenix/experimental/evals/functions/generate.py +0 -88
- arize_phoenix-1.9.1rc2/src/phoenix/experimental/evals/utils/__init__.py +0 -44
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/.gitignore +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/IP_NOTICE +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/LICENSE +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/README.md +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/config.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/core/__init__.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/core/embedding_dimension.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/core/evals.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/core/model.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/core/model_schema.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/core/model_schema_adapter.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/datasets/__init__.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/datasets/dataset.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/datasets/errors.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/datasets/fixtures.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/datasets/schema.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/datasets/validation.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/datetime_utils.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/experimental/__init__.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/experimental/evals/functions/__init__.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/experimental/evals/functions/processing.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/experimental/evals/models/__init__.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/experimental/evals/models/base.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/experimental/evals/models/bedrock.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/experimental/evals/models/litellm.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/experimental/evals/models/openai.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/experimental/evals/models/vertexai.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/experimental/evals/retrievals.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/experimental/evals/templates/default_templates.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/experimental/evals/utils/threads.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/metrics/README.md +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/metrics/__init__.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/metrics/binning.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/metrics/metrics.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/metrics/mixins.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/metrics/retrieval_metrics.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/metrics/timeseries.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/metrics/wrappers.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/pointcloud/__init__.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/pointcloud/clustering.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/pointcloud/pointcloud.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/pointcloud/projectors.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/pointcloud/umap_parameters.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/py.typed +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/__init__.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/__init__.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/context.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/helpers.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/input_types/ClusterInput.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/input_types/Coordinates.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/input_types/DataQualityMetricInput.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/input_types/DimensionFilter.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/input_types/DimensionInput.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/input_types/Granularity.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/input_types/PerformanceMetricInput.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/input_types/SpanSort.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/input_types/TimeRange.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/input_types/__init__.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/interceptor.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/schema.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/Cluster.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/DataQualityMetric.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/Dataset.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/DatasetInfo.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/DatasetRole.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/DatasetValues.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/Dimension.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/DimensionDataType.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/DimensionShape.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/DimensionType.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/DimensionWithValue.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/DocumentEvaluationSummary.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/DocumentRetrievalMetrics.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/EmbeddingDimension.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/EmbeddingMetadata.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/Evaluation.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/EvaluationSummary.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/Event.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/EventMetadata.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/ExportEventsMutation.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/ExportedFile.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/Functionality.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/MimeType.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/Model.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/NumericRange.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/PerformanceMetric.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/PromptResponse.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/Retrieval.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/ScalarDriftMetricEnum.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/Segments.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/SortDir.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/Span.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/TimeSeries.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/UMAPPoints.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/ValidationResult.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/VectorDriftMetricEnum.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/__init__.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/node.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/api/types/pagination.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/evaluation_handler.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/span_handler.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/static/apple-touch-icon-114x114.png +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/static/apple-touch-icon-120x120.png +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/static/apple-touch-icon-144x144.png +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/static/apple-touch-icon-152x152.png +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/static/apple-touch-icon-180x180.png +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/static/apple-touch-icon-72x72.png +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/static/apple-touch-icon-76x76.png +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/static/apple-touch-icon.png +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/static/favicon.ico +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/static/index.css +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/static/modernizr.js +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/templates/__init__.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/templates/index.html +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/server/thread_server.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/services.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/session/__init__.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/session/evaluation.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/session/session.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/__init__.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/dsl/__init__.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/dsl/filter.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/dsl/helpers.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/dsl/missing.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/dsl/query.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/evaluation_conventions.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/exporter.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/fixtures.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/langchain/__init__.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/langchain/instrumentor.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/langchain/tracer.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/llama_index/__init__.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/llama_index/callback.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/llama_index/debug_callback.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/llama_index/streaming.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/openai/__init__.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/schemas.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/semantic_conventions.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/span_evaluations.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/span_json_decoder.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/span_json_encoder.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/trace_dataset.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/tracer.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/utils.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/v1/__init__.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/v1/evaluation_pb2.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/v1/evaluation_pb2.pyi +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/v1/trace_pb2.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/v1/trace_pb2.pyi +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/trace/v1/utils.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/utilities/__init__.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/utilities/error_handling.py +0 -0
- {arize_phoenix-1.9.1rc2 → arize_phoenix-2.0.0}/src/phoenix/utilities/logging.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: arize-phoenix
|
|
3
|
-
Version:
|
|
3
|
+
Version: 2.0.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
|
|
@@ -55,7 +55,7 @@ Requires-Dist: strawberry-graphql[debug-server]==0.208.2; extra == 'dev'
|
|
|
55
55
|
Provides-Extra: experimental
|
|
56
56
|
Requires-Dist: tenacity; extra == 'experimental'
|
|
57
57
|
Provides-Extra: llama-index
|
|
58
|
-
Requires-Dist: llama-index
|
|
58
|
+
Requires-Dist: llama-index==0.9.14; extra == 'llama-index'
|
|
59
59
|
Description-Content-Type: text/markdown
|
|
60
60
|
|
|
61
61
|
<p align="center">
|
|
@@ -6,7 +6,7 @@ from .session.session import NotebookEnvironment, Session, active_session, close
|
|
|
6
6
|
from .trace.fixtures import load_example_traces
|
|
7
7
|
from .trace.trace_dataset import TraceDataset
|
|
8
8
|
|
|
9
|
-
__version__ = "
|
|
9
|
+
__version__ = "2.0.0"
|
|
10
10
|
|
|
11
11
|
# module level doc-string
|
|
12
12
|
__doc__ = """
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
from .evaluators import LLMEvaluator
|
|
1
2
|
from .functions import llm_classify, llm_generate, run_relevance_eval
|
|
2
3
|
from .models import BedrockModel, LiteLLMModel, OpenAIModel, VertexAIModel
|
|
3
4
|
from .retrievals import compute_precisions_at_k
|
|
@@ -8,7 +9,6 @@ from .templates import (
|
|
|
8
9
|
HALLUCINATION_PROMPT_TEMPLATE,
|
|
9
10
|
HUMAN_VS_AI_PROMPT_RAILS_MAP,
|
|
10
11
|
HUMAN_VS_AI_PROMPT_TEMPLATE,
|
|
11
|
-
NOT_PARSABLE,
|
|
12
12
|
QA_PROMPT_RAILS_MAP,
|
|
13
13
|
QA_PROMPT_TEMPLATE,
|
|
14
14
|
RAG_RELEVANCY_PROMPT_RAILS_MAP,
|
|
@@ -18,7 +18,7 @@ from .templates import (
|
|
|
18
18
|
ClassificationTemplate,
|
|
19
19
|
PromptTemplate,
|
|
20
20
|
)
|
|
21
|
-
from .utils import download_benchmark_dataset
|
|
21
|
+
from .utils import NOT_PARSABLE, download_benchmark_dataset
|
|
22
22
|
|
|
23
23
|
__all__ = [
|
|
24
24
|
"compute_precisions_at_k",
|
|
@@ -29,6 +29,7 @@ __all__ = [
|
|
|
29
29
|
"VertexAIModel",
|
|
30
30
|
"BedrockModel",
|
|
31
31
|
"LiteLLMModel",
|
|
32
|
+
"LLMEvaluator",
|
|
32
33
|
"PromptTemplate",
|
|
33
34
|
"ClassificationTemplate",
|
|
34
35
|
"CODE_READABILITY_PROMPT_RAILS_MAP",
|
|
@@ -1,10 +1,11 @@
|
|
|
1
|
-
from typing import List, Mapping, Optional
|
|
1
|
+
from typing import List, Mapping, Optional, Tuple
|
|
2
2
|
|
|
3
3
|
from phoenix.experimental.evals.models import set_verbosity
|
|
4
|
+
from phoenix.experimental.evals.utils import parse_openai_function_call, snap_to_rail
|
|
4
5
|
from phoenix.utilities.logging import printif
|
|
5
6
|
|
|
6
7
|
from .models import BaseEvalModel
|
|
7
|
-
from .templates import ClassificationTemplate, PromptTemplate
|
|
8
|
+
from .templates import ClassificationTemplate, PromptOptions, PromptTemplate
|
|
8
9
|
|
|
9
10
|
Record = Mapping[str, str]
|
|
10
11
|
|
|
@@ -20,51 +21,80 @@ class LLMEvaluator:
|
|
|
20
21
|
self,
|
|
21
22
|
model: BaseEvalModel,
|
|
22
23
|
template: ClassificationTemplate,
|
|
23
|
-
name: str,
|
|
24
|
-
verbose: bool = False,
|
|
25
24
|
) -> None:
|
|
26
25
|
"""Initializer for LLMEvaluator.
|
|
27
26
|
|
|
28
27
|
Args:
|
|
29
28
|
model (BaseEvalModel): The LLM model to use for evaluation.
|
|
30
29
|
template (ClassificationTemplate): The evaluation template.
|
|
31
|
-
name (str): The name of the evaluator.
|
|
32
|
-
verbose (bool, optional): Whether to print verbose output.
|
|
33
30
|
"""
|
|
34
31
|
self._model = model
|
|
35
32
|
self._template = template
|
|
36
|
-
self.name = name
|
|
37
|
-
self._verbose = verbose
|
|
38
33
|
|
|
39
|
-
def evaluate(
|
|
40
|
-
|
|
34
|
+
def evaluate(
|
|
35
|
+
self,
|
|
36
|
+
record: Record,
|
|
37
|
+
provide_explanation: bool = False,
|
|
38
|
+
verbose: bool = False,
|
|
39
|
+
) -> Tuple[str, Optional[str]]:
|
|
40
|
+
"""
|
|
41
|
+
Evaluates a single record.
|
|
41
42
|
|
|
42
43
|
Args:
|
|
43
44
|
record (Record): The record to evaluate.
|
|
44
45
|
|
|
46
|
+
provide_explanation (bool, optional): Whether to provide an
|
|
47
|
+
explanation.
|
|
48
|
+
|
|
49
|
+
verbose (bool, optional): Whether to print verbose output.
|
|
50
|
+
|
|
45
51
|
Returns:
|
|
46
|
-
|
|
52
|
+
Tuple[str, Optional[str]]: The label and explanation (if provided).
|
|
47
53
|
"""
|
|
48
|
-
prompt = self._template.format(
|
|
49
|
-
|
|
54
|
+
prompt = self._template.format(
|
|
55
|
+
record, options=PromptOptions(provide_explanation=provide_explanation)
|
|
56
|
+
)
|
|
57
|
+
with set_verbosity(self._model, verbose) as verbose_model:
|
|
50
58
|
unparsed_output = verbose_model(prompt)
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
59
|
+
label, explanation = _extract_label_and_explanation(
|
|
60
|
+
unparsed_output=unparsed_output,
|
|
61
|
+
template=self._template,
|
|
62
|
+
use_openai_function_call=False,
|
|
63
|
+
provide_explanation=provide_explanation,
|
|
64
|
+
verbose=verbose,
|
|
65
|
+
)
|
|
66
|
+
return label, explanation
|
|
67
|
+
|
|
68
|
+
async def aevaluate(
|
|
69
|
+
self, record: Record, provide_explanation: bool = False, verbose: bool = False
|
|
70
|
+
) -> Tuple[str, Optional[str]]:
|
|
71
|
+
"""
|
|
72
|
+
Evaluates a single record.
|
|
56
73
|
|
|
57
74
|
Args:
|
|
58
75
|
record (Record): The record to evaluate.
|
|
59
76
|
|
|
77
|
+
provide_explanation (bool, optional): Whether to provide an
|
|
78
|
+
explanation.
|
|
79
|
+
|
|
80
|
+
verbose (bool, optional): Whether to print verbose output.
|
|
81
|
+
|
|
60
82
|
Returns:
|
|
61
|
-
|
|
83
|
+
Tuple[str, Optional[str]]: The label and explanation (if provided).
|
|
62
84
|
"""
|
|
63
|
-
prompt = self._template.format(
|
|
64
|
-
|
|
85
|
+
prompt = self._template.format(
|
|
86
|
+
record, options=PromptOptions(provide_explanation=provide_explanation)
|
|
87
|
+
)
|
|
88
|
+
with set_verbosity(self._model, verbose) as verbose_model:
|
|
65
89
|
unparsed_output = await verbose_model._async_generate(prompt)
|
|
66
|
-
|
|
67
|
-
|
|
90
|
+
label, explanation = _extract_label_and_explanation(
|
|
91
|
+
unparsed_output=unparsed_output,
|
|
92
|
+
template=self._template,
|
|
93
|
+
use_openai_function_call=False,
|
|
94
|
+
provide_explanation=provide_explanation,
|
|
95
|
+
verbose=verbose,
|
|
96
|
+
)
|
|
97
|
+
return label, explanation
|
|
68
98
|
|
|
69
99
|
|
|
70
100
|
class MapReducer:
|
|
@@ -202,33 +232,46 @@ class Refiner:
|
|
|
202
232
|
return model(reduce_prompt)
|
|
203
233
|
|
|
204
234
|
|
|
205
|
-
def
|
|
235
|
+
def _extract_label_and_explanation(
|
|
236
|
+
unparsed_output: str,
|
|
237
|
+
template: ClassificationTemplate,
|
|
238
|
+
provide_explanation: bool,
|
|
239
|
+
use_openai_function_call: bool,
|
|
240
|
+
verbose: bool,
|
|
241
|
+
) -> Tuple[str, Optional[str]]:
|
|
206
242
|
"""
|
|
207
|
-
|
|
208
|
-
snapped to a rail.
|
|
243
|
+
Extracts the label and explanation from the unparsed output.
|
|
209
244
|
|
|
210
245
|
Args:
|
|
211
|
-
|
|
246
|
+
unparsed_output (str): The raw output to be parsed.
|
|
247
|
+
|
|
248
|
+
template (ClassificationTemplate): The template used to generate the
|
|
249
|
+
output.
|
|
212
250
|
|
|
213
|
-
|
|
251
|
+
provide_explanation (bool): Whether the output includes an explanation.
|
|
252
|
+
|
|
253
|
+
use_openai_function_call (bool): Whether the output was generated using
|
|
254
|
+
function calling.
|
|
255
|
+
|
|
256
|
+
verbose (bool): If True, print verbose output to stdout.
|
|
214
257
|
|
|
215
258
|
Returns:
|
|
216
|
-
str: A
|
|
217
|
-
|
|
259
|
+
Tuple[str, Optional[str]]: A tuple containing the label and an
|
|
260
|
+
explanation (if one is provided).
|
|
218
261
|
"""
|
|
219
|
-
if not
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
return
|
|
262
|
+
if not use_openai_function_call:
|
|
263
|
+
if provide_explanation:
|
|
264
|
+
unrailed_label, explanation = (
|
|
265
|
+
template.extract_label_from_explanation(unparsed_output),
|
|
266
|
+
unparsed_output,
|
|
267
|
+
)
|
|
268
|
+
printif(
|
|
269
|
+
verbose and unrailed_label == NOT_PARSABLE,
|
|
270
|
+
f"- Could not parse {repr(unparsed_output)}",
|
|
271
|
+
)
|
|
272
|
+
else:
|
|
273
|
+
unrailed_label = unparsed_output
|
|
274
|
+
explanation = None
|
|
275
|
+
else:
|
|
276
|
+
unrailed_label, explanation = parse_openai_function_call(unparsed_output)
|
|
277
|
+
return snap_to_rail(unrailed_label, template.rails, verbose=verbose), explanation
|