arize-phoenix 1.9.1rc3__py3-none-any.whl → 2.0.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-1.9.1rc3.dist-info → arize_phoenix-2.0.0.dist-info}/METADATA +1 -1
- {arize_phoenix-1.9.1rc3.dist-info → arize_phoenix-2.0.0.dist-info}/RECORD +21 -19
- {arize_phoenix-1.9.1rc3.dist-info → arize_phoenix-2.0.0.dist-info}/WHEEL +1 -1
- phoenix/__init__.py +1 -1
- phoenix/core/traces.py +1 -1
- phoenix/exceptions.py +2 -0
- phoenix/experimental/evals/__init__.py +3 -2
- phoenix/experimental/evals/evaluators.py +89 -46
- phoenix/experimental/evals/functions/classify.py +103 -398
- phoenix/experimental/evals/functions/executor.py +353 -0
- phoenix/experimental/evals/functions/generate.py +76 -32
- phoenix/experimental/evals/models/rate_limiters.py +25 -5
- phoenix/experimental/evals/templates/__init__.py +0 -2
- phoenix/experimental/evals/templates/template.py +2 -5
- phoenix/experimental/evals/utils/__init__.py +66 -0
- phoenix/server/app.py +3 -2
- phoenix/server/main.py +3 -0
- phoenix/server/static/index.js +459 -436
- phoenix/trace/openai/instrumentor.py +51 -14
- {arize_phoenix-1.9.1rc3.dist-info → arize_phoenix-2.0.0.dist-info}/licenses/IP_NOTICE +0 -0
- {arize_phoenix-1.9.1rc3.dist-info → arize_phoenix-2.0.0.dist-info}/licenses/LICENSE +0 -0
phoenix/server/app.py
CHANGED
|
@@ -163,6 +163,7 @@ def create_app(
|
|
|
163
163
|
traces: Optional[Traces] = None,
|
|
164
164
|
evals: Optional[Evals] = None,
|
|
165
165
|
debug: bool = False,
|
|
166
|
+
read_only: bool = False,
|
|
166
167
|
) -> Starlette:
|
|
167
168
|
graphql = GraphQLWithContext(
|
|
168
169
|
schema=schema,
|
|
@@ -180,7 +181,7 @@ def create_app(
|
|
|
180
181
|
debug=debug,
|
|
181
182
|
routes=(
|
|
182
183
|
[]
|
|
183
|
-
if traces is None
|
|
184
|
+
if traces is None or read_only
|
|
184
185
|
else [
|
|
185
186
|
Route(
|
|
186
187
|
"/v1/spans",
|
|
@@ -194,7 +195,7 @@ def create_app(
|
|
|
194
195
|
)
|
|
195
196
|
+ (
|
|
196
197
|
[]
|
|
197
|
-
if evals is None
|
|
198
|
+
if evals is None or read_only
|
|
198
199
|
else [
|
|
199
200
|
Route(
|
|
200
201
|
"/v1/evaluations",
|
phoenix/server/main.py
CHANGED
|
@@ -93,6 +93,7 @@ if __name__ == "__main__":
|
|
|
93
93
|
parser.add_argument("--export_path")
|
|
94
94
|
parser.add_argument("--host", type=str, required=False)
|
|
95
95
|
parser.add_argument("--port", type=int, required=False)
|
|
96
|
+
parser.add_argument("--read-only", type=bool, default=False)
|
|
96
97
|
parser.add_argument("--no-internet", action="store_true")
|
|
97
98
|
parser.add_argument("--umap_params", type=str, required=False, default=DEFAULT_UMAP_PARAMS_STR)
|
|
98
99
|
parser.add_argument("--debug", action="store_false")
|
|
@@ -172,6 +173,7 @@ if __name__ == "__main__":
|
|
|
172
173
|
n_neighbors=int(umap_params_list[1]),
|
|
173
174
|
n_samples=int(umap_params_list[2]),
|
|
174
175
|
)
|
|
176
|
+
read_only = args.read_only
|
|
175
177
|
logger.info(f"Server umap params: {umap_params}")
|
|
176
178
|
app = create_app(
|
|
177
179
|
export_path=export_path,
|
|
@@ -181,6 +183,7 @@ if __name__ == "__main__":
|
|
|
181
183
|
evals=evals,
|
|
182
184
|
corpus=None if corpus_dataset is None else create_model_from_datasets(corpus_dataset),
|
|
183
185
|
debug=args.debug,
|
|
186
|
+
read_only=read_only,
|
|
184
187
|
)
|
|
185
188
|
host = args.host or get_env_host()
|
|
186
189
|
port = args.port or get_env_port()
|