evalrouter 0.3.8__tar.gz → 0.3.9__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.
- {evalrouter-0.3.8 → evalrouter-0.3.9}/PKG-INFO +72 -23
- {evalrouter-0.3.8 → evalrouter-0.3.9}/README.md +71 -22
- {evalrouter-0.3.8 → evalrouter-0.3.9}/pyproject.toml +1 -1
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/evalrouter_contracts/__init__.py +1 -1
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/kimpton_evalrouter/__init__.py +1 -1
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/kimpton_evalrouter/_account.py +27 -12
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/kimpton_evalrouter/_comparison.py +662 -28
- evalrouter-0.3.9/src/kimpton_evalrouter/_comparison_html.py +690 -0
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/kimpton_evalrouter/_guided.py +728 -116
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/kimpton_evalrouter/_listing.py +153 -11
- evalrouter-0.3.9/src/kimpton_evalrouter/_progress.py +190 -0
- evalrouter-0.3.9/src/kimpton_evalrouter/_report_pareto.py +870 -0
- evalrouter-0.3.9/src/kimpton_evalrouter/_report_theme.py +249 -0
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/kimpton_evalrouter/_resources.py +12 -0
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/kimpton_evalrouter/cli.py +272 -63
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/kimpton_evalrouter/render/__init__.py +3 -1
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/kimpton_evalrouter/render/live.py +214 -99
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/kimpton_evalrouter/render/picker.py +187 -2
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/kimpton_evalrouter/render/screens.py +385 -125
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/kimpton_evalrouter/render/tables.py +16 -3
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/kimpton_evalrouter/types.py +132 -3
- evalrouter-0.3.8/src/kimpton_evalrouter/_comparison_html.py +0 -233
- {evalrouter-0.3.8 → evalrouter-0.3.9}/LICENSE +0 -0
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/evalrouter_contracts/bundle.py +0 -0
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/evalrouter_contracts/components.py +0 -0
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/evalrouter_contracts/models.py +0 -0
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/evalrouter_contracts/protocol.py +0 -0
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/evalrouter_contracts/py.typed +0 -0
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/evalrouter_contracts/templates.py +0 -0
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/evalrouter_contracts/validation.py +0 -0
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/kimpton_evalrouter/__main__.py +0 -0
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/kimpton_evalrouter/_artifacts.py +0 -0
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/kimpton_evalrouter/_boundary.py +0 -0
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/kimpton_evalrouter/_helpers.py +0 -0
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/kimpton_evalrouter/_read_cache.py +0 -0
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/kimpton_evalrouter/_transport.py +0 -0
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/kimpton_evalrouter/langsmith.py +0 -0
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/kimpton_evalrouter/py.typed +0 -0
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/kimpton_evalrouter/render/_console.py +0 -0
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/kimpton_evalrouter/render/_theme.py +0 -0
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/kimpton_evalrouter/render/_widgets.py +0 -0
- {evalrouter-0.3.8 → evalrouter-0.3.9}/src/kimpton_evalrouter/tracing.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: evalrouter
|
|
3
|
-
Version: 0.3.
|
|
3
|
+
Version: 0.3.9
|
|
4
4
|
Summary: Typed Kimpton evaluation client and command-line interface
|
|
5
5
|
License-Expression: LicenseRef-Kimpton-EvalRouter-SDK
|
|
6
6
|
License-File: LICENSE
|
|
@@ -110,11 +110,15 @@ The idempotency key of each accepted quote is saved locally before the run is
|
|
|
110
110
|
submitted (`~/.local/state/evalrouter`, or `EVALROUTER_STATE_DIR`; identifiers
|
|
111
111
|
only, never credentials). Repeating the same command after a dropped connection
|
|
112
112
|
resumes that run instead of starting another; `--new` starts a separate one.
|
|
113
|
-
Afterwards, `results`, `export --format html,json
|
|
114
|
-
|
|
113
|
+
Afterwards, `results RUN`, `export RUN --format html,json` and `wait RUN`
|
|
114
|
+
take the run's ID or a unique prefix of it. `results --diff` also compares
|
|
115
115
|
with the previous run of the same benchmark and model; that takes a few more
|
|
116
|
-
requests, so plain `results` does not.
|
|
117
|
-
|
|
116
|
+
requests, so plain `results` does not. `run --from RUN` runs an earlier
|
|
117
|
+
evaluation again as a new run with the same setup; other `run` options override
|
|
118
|
+
it. Watching a run survives brief API
|
|
119
|
+
outages such as a 503 during a deployment. If the API stays unreachable for
|
|
120
|
+
90 seconds (`--disconnect-timeout SECONDS`), the CLI stops watching, says so and
|
|
121
|
+
prints the `evalrouter wait` command that reattaches; the run continues.
|
|
118
122
|
|
|
119
123
|
## Resume a stopped run
|
|
120
124
|
|
|
@@ -147,15 +151,31 @@ running is watched; a finished one is quoted and asked about again, even with
|
|
|
147
151
|
Tasks stopped by cancellation or the time limit are rerun only with
|
|
148
152
|
`--include-cancelled`.
|
|
149
153
|
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
154
|
+
Refused tasks and cancellations omitted without `--include-cancelled` remain
|
|
155
|
+
excluded from this and every later resume. The quote asks you to acknowledge
|
|
156
|
+
those permanent exclusions; scripts need `--accept-left-out`.
|
|
157
|
+
|
|
158
|
+
New quotes show unresolved effects separately as **Pending**. Safe tasks can
|
|
159
|
+
continue while those cells retain their original provenance. A later resume
|
|
160
|
+
rechecks the original outcome and can run it only when it is genuinely safe;
|
|
161
|
+
a waived charge with an unknown provider outcome does not qualify. Nothing
|
|
162
|
+
retries automatically. Older quotes without pending provenance keep their
|
|
163
|
+
original permanent exclusions, except that an unknown provider outcome can be
|
|
164
|
+
offered for one explicit new attempt (below).
|
|
165
|
+
|
|
166
|
+
A task whose provider call failed is decided from that call's record, never
|
|
167
|
+
from its error name. If its original answer was stored, the resume grades that
|
|
168
|
+
stored answer at no charge, with no new request (`saved_response_cells`). If the
|
|
169
|
+
call is still unresolved, the quote says when reconciliation settles it (up to
|
|
170
|
+
24 hours after it started). If the outcome is uncertain (the provider may have
|
|
171
|
+
processed the request; your charge for it was waived) or the provider did not
|
|
172
|
+
bill a transient failure, nothing retries it on its own: `--retry-unknown`
|
|
173
|
+
consents to pay for **one** new attempt of each such task, once ever, within
|
|
174
|
+
the same cap. The original outcome and charge stay unchanged, and a late
|
|
175
|
+
original answer never adds a charge. `--retry-unknown-max N` refuses (never
|
|
176
|
+
trims) a quote with more such tasks. With your own provider connection, that
|
|
177
|
+
provider may bill both requests, so `--accept-duplicate-provider-charges` is
|
|
178
|
+
also required. The JSON quote reports these as `continuation.unknown_retry`.
|
|
159
179
|
|
|
160
180
|
Resume supports one model, one benchmark and one attempt per task on the
|
|
161
181
|
reviewed native benchmark families (Inspect, SOB text and lm-eval) without a
|
|
@@ -166,7 +186,7 @@ rerun. Graded tasks from runs that finished before resume evidence was recorded,
|
|
|
166
186
|
including existing runs, cannot gain that evidence later, and results are
|
|
167
187
|
never reused across EvalRouter deployments: after a deployment, those tasks are
|
|
168
188
|
refused rather than reused or rerun. Tasks whose earlier charge or provider
|
|
169
|
-
outcome is unresolved are
|
|
189
|
+
outcome is unresolved are never called until a fresh quote proves eligibility. A server without resume
|
|
170
190
|
says so, and nothing is quoted or charged.
|
|
171
191
|
|
|
172
192
|
## Lists
|
|
@@ -174,7 +194,8 @@ says so, and nothing is quoted or charged.
|
|
|
174
194
|
`catalog`, `catalog --models`, `status`, `connections list` and `workspace list`
|
|
175
195
|
print a compact table sized to your terminal with one suggested next command;
|
|
176
196
|
`catalog` hides benchmarks in review or unavailable unless you pass `--all`, and
|
|
177
|
-
`catalog -i` browses them interactively
|
|
197
|
+
`catalog -i` browses them interactively; `status -i` keeps your run list live and
|
|
198
|
+
opens a run with Enter. Every list accepts `--json`,
|
|
178
199
|
`--jq '.data[].id'` (a small jq subset), `-w/--wide`, `--columns a,b`,
|
|
179
200
|
`--sort COL` (`--sort=-COL` descending), `--filter KEY=VALUE` and `--limit N`.
|
|
180
201
|
Piped output stays JSON. Colour follows `NO_COLOR`, `CI` and `TERM=dumb`.
|
|
@@ -264,8 +285,12 @@ evalrouter compare RUN_ID RUN_ID --format html --output my-comparison
|
|
|
264
285
|
task population, task selection and output format in one workspace. Each run
|
|
265
286
|
must be a managed or connected model run; comparison, agent and environment
|
|
266
287
|
runs are refused, and so is a run whose export does not record one of these
|
|
267
|
-
identities. It
|
|
268
|
-
|
|
288
|
+
identities. It reads each run's summary export (`export?format=summary`:
|
|
289
|
+
identities, frozen native summary, coverage, billing snapshot and export
|
|
290
|
+
policy, with no sample rows) and saves `comparison.json` and
|
|
291
|
+
`sources/<run>.summary.json` in a new private directory. `--evidence`
|
|
292
|
+
downloads each run's full JSON export instead (`sources/<run>.json`) and also
|
|
293
|
+
compares grader versions and graded task sets; the scores are the same.
|
|
269
294
|
`comparison.json` holds each run's model identity (route, revision, protocol,
|
|
270
295
|
recorded limits, generation and routing settings), coverage, errors, its
|
|
271
296
|
frozen native summary with the headline's own denominator, and its settled
|
|
@@ -273,13 +298,27 @@ EvalRouter charge. A run that did not complete, or graded fewer tasks than
|
|
|
273
298
|
planned, is marked partial in `comparison.json` and in its own row of the
|
|
274
299
|
terminal table.
|
|
275
300
|
|
|
276
|
-
|
|
277
|
-
|
|
301
|
+
For SOB Text runs that were continued (`evalrouter resume`), add
|
|
302
|
+
`--include-resumed` (`--chain` is the same flag): each ID then names one
|
|
303
|
+
chain, meaning the original run and its resumes, and the chain becomes one
|
|
304
|
+
series. The service decides every task from the one run that graded it,
|
|
305
|
+
re-derives the SOB native summary with the benchmark authors' code, and keeps
|
|
306
|
+
ungraded tasks as errors with their codes. Each score is shown with its runs
|
|
307
|
+
("original + 1 resume") and its graded-of-planned count. If a resume replayed
|
|
308
|
+
a reused answer and got a different score (`reuse_score_mismatch`), the
|
|
309
|
+
report warns and the chain is not complete. `evalrouter export RUN
|
|
310
|
+
--include-resumed` saves that chain result by itself. The command follows
|
|
311
|
+
each run to its newest resume at the time you run it, so a later resume makes
|
|
312
|
+
it return a longer chain; the saved chain documents keep the exact version.
|
|
313
|
+
|
|
314
|
+
`sources/` keeps each export byte for byte, with its SHA-256 recorded. With
|
|
315
|
+
`--evidence`, every graded sample must carry its scored answer by default: the final completion
|
|
278
316
|
text for SOB, plus the per-sample metadata the export supplies (for SOB, the
|
|
279
317
|
response's token counts and finish reason). Exports do not contain complete
|
|
280
318
|
transcripts, reasoning, timings or per-attempt usage. Keep these files
|
|
281
|
-
private. Use `--without-raw` to archive runs
|
|
282
|
-
are withheld by the export policy.
|
|
319
|
+
private. Use `--without-raw` (which implies `--evidence`) to archive runs
|
|
320
|
+
whose answers have expired or are withheld by the export policy. A chain
|
|
321
|
+
summary report downloads member exports only with `--evidence`. Different transports, limits or generation
|
|
283
322
|
settings are listed as warnings. Nothing is regraded, and no deltas,
|
|
284
323
|
intervals or winner are computed. `--output NAME.json` puts the sources in
|
|
285
324
|
`NAME-sources/`.
|
|
@@ -305,11 +344,21 @@ an interactive terminal, with a percentage when validated processed and planned
|
|
|
305
344
|
counts are available. Use `--progress plain` for structured progress or
|
|
306
345
|
`--progress off` to suppress it. Redirected stderr and `--json` retain structured
|
|
307
346
|
progress. A progress percentage counts processed samples; it is not a score.
|
|
347
|
+
`--progress json` writes `evalrouter.progress.v1` records on stderr, on every
|
|
348
|
+
change and every 30 seconds: phase, processed and planned counts, errors,
|
|
349
|
+
spend and elapsed time. `evalrouter events RUN --follow` prints the run's
|
|
350
|
+
event log as JSON lines until it ends; `--type`, `--tail N` and `--after N`
|
|
351
|
+
filter, start from the end and resume.
|
|
352
|
+
`evalrouter open RUN` opens the run's live report page, also when an agent
|
|
353
|
+
runs it with `--json`; `run --open` opens it as soon as the run starts. No
|
|
354
|
+
browser opens in CI, over SSH, without a display, with `--no-browser` or with
|
|
355
|
+
`EVALROUTER_NO_BROWSER=1`; the address is printed instead.
|
|
308
356
|
|
|
309
357
|
Use `--config -` for JSON on stdin. `--json` writes one result on stdout and
|
|
310
358
|
progress on stderr. Exit codes: 0 success; 1 API/transport or failed run;
|
|
311
359
|
2 invalid input or rejected request (including a refused unattended `run`);
|
|
312
|
-
4 partial/cancelled waited run; 5 confirmation declined, nothing started
|
|
360
|
+
4 partial/cancelled waited run; 5 confirmation declined, nothing started;
|
|
361
|
+
6 stopped watching because the API stayed unreachable. Interrupting
|
|
313
362
|
a local wait does not cancel server work. Use `evalrouter cancel RUN_ID`
|
|
314
363
|
explicitly when cancellation is intended.
|
|
315
364
|
|
|
@@ -90,11 +90,15 @@ The idempotency key of each accepted quote is saved locally before the run is
|
|
|
90
90
|
submitted (`~/.local/state/evalrouter`, or `EVALROUTER_STATE_DIR`; identifiers
|
|
91
91
|
only, never credentials). Repeating the same command after a dropped connection
|
|
92
92
|
resumes that run instead of starting another; `--new` starts a separate one.
|
|
93
|
-
Afterwards, `results`, `export --format html,json
|
|
94
|
-
|
|
93
|
+
Afterwards, `results RUN`, `export RUN --format html,json` and `wait RUN`
|
|
94
|
+
take the run's ID or a unique prefix of it. `results --diff` also compares
|
|
95
95
|
with the previous run of the same benchmark and model; that takes a few more
|
|
96
|
-
requests, so plain `results` does not.
|
|
97
|
-
|
|
96
|
+
requests, so plain `results` does not. `run --from RUN` runs an earlier
|
|
97
|
+
evaluation again as a new run with the same setup; other `run` options override
|
|
98
|
+
it. Watching a run survives brief API
|
|
99
|
+
outages such as a 503 during a deployment. If the API stays unreachable for
|
|
100
|
+
90 seconds (`--disconnect-timeout SECONDS`), the CLI stops watching, says so and
|
|
101
|
+
prints the `evalrouter wait` command that reattaches; the run continues.
|
|
98
102
|
|
|
99
103
|
## Resume a stopped run
|
|
100
104
|
|
|
@@ -127,15 +131,31 @@ running is watched; a finished one is quoted and asked about again, even with
|
|
|
127
131
|
Tasks stopped by cancellation or the time limit are rerun only with
|
|
128
132
|
`--include-cancelled`.
|
|
129
133
|
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
134
|
+
Refused tasks and cancellations omitted without `--include-cancelled` remain
|
|
135
|
+
excluded from this and every later resume. The quote asks you to acknowledge
|
|
136
|
+
those permanent exclusions; scripts need `--accept-left-out`.
|
|
137
|
+
|
|
138
|
+
New quotes show unresolved effects separately as **Pending**. Safe tasks can
|
|
139
|
+
continue while those cells retain their original provenance. A later resume
|
|
140
|
+
rechecks the original outcome and can run it only when it is genuinely safe;
|
|
141
|
+
a waived charge with an unknown provider outcome does not qualify. Nothing
|
|
142
|
+
retries automatically. Older quotes without pending provenance keep their
|
|
143
|
+
original permanent exclusions, except that an unknown provider outcome can be
|
|
144
|
+
offered for one explicit new attempt (below).
|
|
145
|
+
|
|
146
|
+
A task whose provider call failed is decided from that call's record, never
|
|
147
|
+
from its error name. If its original answer was stored, the resume grades that
|
|
148
|
+
stored answer at no charge, with no new request (`saved_response_cells`). If the
|
|
149
|
+
call is still unresolved, the quote says when reconciliation settles it (up to
|
|
150
|
+
24 hours after it started). If the outcome is uncertain (the provider may have
|
|
151
|
+
processed the request; your charge for it was waived) or the provider did not
|
|
152
|
+
bill a transient failure, nothing retries it on its own: `--retry-unknown`
|
|
153
|
+
consents to pay for **one** new attempt of each such task, once ever, within
|
|
154
|
+
the same cap. The original outcome and charge stay unchanged, and a late
|
|
155
|
+
original answer never adds a charge. `--retry-unknown-max N` refuses (never
|
|
156
|
+
trims) a quote with more such tasks. With your own provider connection, that
|
|
157
|
+
provider may bill both requests, so `--accept-duplicate-provider-charges` is
|
|
158
|
+
also required. The JSON quote reports these as `continuation.unknown_retry`.
|
|
139
159
|
|
|
140
160
|
Resume supports one model, one benchmark and one attempt per task on the
|
|
141
161
|
reviewed native benchmark families (Inspect, SOB text and lm-eval) without a
|
|
@@ -146,7 +166,7 @@ rerun. Graded tasks from runs that finished before resume evidence was recorded,
|
|
|
146
166
|
including existing runs, cannot gain that evidence later, and results are
|
|
147
167
|
never reused across EvalRouter deployments: after a deployment, those tasks are
|
|
148
168
|
refused rather than reused or rerun. Tasks whose earlier charge or provider
|
|
149
|
-
outcome is unresolved are
|
|
169
|
+
outcome is unresolved are never called until a fresh quote proves eligibility. A server without resume
|
|
150
170
|
says so, and nothing is quoted or charged.
|
|
151
171
|
|
|
152
172
|
## Lists
|
|
@@ -154,7 +174,8 @@ says so, and nothing is quoted or charged.
|
|
|
154
174
|
`catalog`, `catalog --models`, `status`, `connections list` and `workspace list`
|
|
155
175
|
print a compact table sized to your terminal with one suggested next command;
|
|
156
176
|
`catalog` hides benchmarks in review or unavailable unless you pass `--all`, and
|
|
157
|
-
`catalog -i` browses them interactively
|
|
177
|
+
`catalog -i` browses them interactively; `status -i` keeps your run list live and
|
|
178
|
+
opens a run with Enter. Every list accepts `--json`,
|
|
158
179
|
`--jq '.data[].id'` (a small jq subset), `-w/--wide`, `--columns a,b`,
|
|
159
180
|
`--sort COL` (`--sort=-COL` descending), `--filter KEY=VALUE` and `--limit N`.
|
|
160
181
|
Piped output stays JSON. Colour follows `NO_COLOR`, `CI` and `TERM=dumb`.
|
|
@@ -244,8 +265,12 @@ evalrouter compare RUN_ID RUN_ID --format html --output my-comparison
|
|
|
244
265
|
task population, task selection and output format in one workspace. Each run
|
|
245
266
|
must be a managed or connected model run; comparison, agent and environment
|
|
246
267
|
runs are refused, and so is a run whose export does not record one of these
|
|
247
|
-
identities. It
|
|
248
|
-
|
|
268
|
+
identities. It reads each run's summary export (`export?format=summary`:
|
|
269
|
+
identities, frozen native summary, coverage, billing snapshot and export
|
|
270
|
+
policy, with no sample rows) and saves `comparison.json` and
|
|
271
|
+
`sources/<run>.summary.json` in a new private directory. `--evidence`
|
|
272
|
+
downloads each run's full JSON export instead (`sources/<run>.json`) and also
|
|
273
|
+
compares grader versions and graded task sets; the scores are the same.
|
|
249
274
|
`comparison.json` holds each run's model identity (route, revision, protocol,
|
|
250
275
|
recorded limits, generation and routing settings), coverage, errors, its
|
|
251
276
|
frozen native summary with the headline's own denominator, and its settled
|
|
@@ -253,13 +278,27 @@ EvalRouter charge. A run that did not complete, or graded fewer tasks than
|
|
|
253
278
|
planned, is marked partial in `comparison.json` and in its own row of the
|
|
254
279
|
terminal table.
|
|
255
280
|
|
|
256
|
-
|
|
257
|
-
|
|
281
|
+
For SOB Text runs that were continued (`evalrouter resume`), add
|
|
282
|
+
`--include-resumed` (`--chain` is the same flag): each ID then names one
|
|
283
|
+
chain, meaning the original run and its resumes, and the chain becomes one
|
|
284
|
+
series. The service decides every task from the one run that graded it,
|
|
285
|
+
re-derives the SOB native summary with the benchmark authors' code, and keeps
|
|
286
|
+
ungraded tasks as errors with their codes. Each score is shown with its runs
|
|
287
|
+
("original + 1 resume") and its graded-of-planned count. If a resume replayed
|
|
288
|
+
a reused answer and got a different score (`reuse_score_mismatch`), the
|
|
289
|
+
report warns and the chain is not complete. `evalrouter export RUN
|
|
290
|
+
--include-resumed` saves that chain result by itself. The command follows
|
|
291
|
+
each run to its newest resume at the time you run it, so a later resume makes
|
|
292
|
+
it return a longer chain; the saved chain documents keep the exact version.
|
|
293
|
+
|
|
294
|
+
`sources/` keeps each export byte for byte, with its SHA-256 recorded. With
|
|
295
|
+
`--evidence`, every graded sample must carry its scored answer by default: the final completion
|
|
258
296
|
text for SOB, plus the per-sample metadata the export supplies (for SOB, the
|
|
259
297
|
response's token counts and finish reason). Exports do not contain complete
|
|
260
298
|
transcripts, reasoning, timings or per-attempt usage. Keep these files
|
|
261
|
-
private. Use `--without-raw` to archive runs
|
|
262
|
-
are withheld by the export policy.
|
|
299
|
+
private. Use `--without-raw` (which implies `--evidence`) to archive runs
|
|
300
|
+
whose answers have expired or are withheld by the export policy. A chain
|
|
301
|
+
summary report downloads member exports only with `--evidence`. Different transports, limits or generation
|
|
263
302
|
settings are listed as warnings. Nothing is regraded, and no deltas,
|
|
264
303
|
intervals or winner are computed. `--output NAME.json` puts the sources in
|
|
265
304
|
`NAME-sources/`.
|
|
@@ -285,11 +324,21 @@ an interactive terminal, with a percentage when validated processed and planned
|
|
|
285
324
|
counts are available. Use `--progress plain` for structured progress or
|
|
286
325
|
`--progress off` to suppress it. Redirected stderr and `--json` retain structured
|
|
287
326
|
progress. A progress percentage counts processed samples; it is not a score.
|
|
327
|
+
`--progress json` writes `evalrouter.progress.v1` records on stderr, on every
|
|
328
|
+
change and every 30 seconds: phase, processed and planned counts, errors,
|
|
329
|
+
spend and elapsed time. `evalrouter events RUN --follow` prints the run's
|
|
330
|
+
event log as JSON lines until it ends; `--type`, `--tail N` and `--after N`
|
|
331
|
+
filter, start from the end and resume.
|
|
332
|
+
`evalrouter open RUN` opens the run's live report page, also when an agent
|
|
333
|
+
runs it with `--json`; `run --open` opens it as soon as the run starts. No
|
|
334
|
+
browser opens in CI, over SSH, without a display, with `--no-browser` or with
|
|
335
|
+
`EVALROUTER_NO_BROWSER=1`; the address is printed instead.
|
|
288
336
|
|
|
289
337
|
Use `--config -` for JSON on stdin. `--json` writes one result on stdout and
|
|
290
338
|
progress on stderr. Exit codes: 0 success; 1 API/transport or failed run;
|
|
291
339
|
2 invalid input or rejected request (including a refused unattended `run`);
|
|
292
|
-
4 partial/cancelled waited run; 5 confirmation declined, nothing started
|
|
340
|
+
4 partial/cancelled waited run; 5 confirmation declined, nothing started;
|
|
341
|
+
6 stopped watching because the API stayed unreachable. Interrupting
|
|
293
342
|
a local wait does not cancel server work. Use `evalrouter cancel RUN_ID`
|
|
294
343
|
explicitly when cancellation is intended.
|
|
295
344
|
|
|
@@ -55,9 +55,11 @@ FILE_STORE_NAME = "credentials.json"
|
|
|
55
55
|
REFRESH_MARGIN_SECONDS = 60
|
|
56
56
|
MAX_POLL_INTERVAL = 60
|
|
57
57
|
DEFAULT_API_ORIGIN = "https://api.evalrouter.ai"
|
|
58
|
+
#: API host -> the website for that environment. Dev's API is served only at its
|
|
59
|
+
#: Modal address; the name api.dev.evalrouter.ai is the Dev Auth0 audience (an
|
|
60
|
+
#: identifier in tokens), not a host, so it is not listed.
|
|
58
61
|
CONNECT_WEBSITES = {
|
|
59
62
|
"api.evalrouter.ai": "https://evalrouter.ai",
|
|
60
|
-
"api.dev.evalrouter.ai": "https://dev.evalrouter.ai",
|
|
61
63
|
"kimpton-evalrouter-dev--evalrouter-service-api.us-east.modal.direct": "https://dev.evalrouter.ai",
|
|
62
64
|
}
|
|
63
65
|
LOGIN_HINT = "Run `evalrouter login` or set EVALROUTER_API_KEY."
|
|
@@ -1452,11 +1454,7 @@ def _onboarding_workspaces(
|
|
|
1452
1454
|
except APIError as error:
|
|
1453
1455
|
if error.code not in {"account_not_found", "email_unverified"}:
|
|
1454
1456
|
raise
|
|
1455
|
-
website =
|
|
1456
|
-
"api.evalrouter.ai": "https://evalrouter.ai",
|
|
1457
|
-
"api.dev.evalrouter.ai": "https://dev.evalrouter.ai",
|
|
1458
|
-
"kimpton-evalrouter-dev--evalrouter-service-api.us-east.modal.direct": "https://dev.evalrouter.ai",
|
|
1459
|
-
}.get(urlsplit(base).netloc)
|
|
1457
|
+
website = CONNECT_WEBSITES.get(urlsplit(base).netloc)
|
|
1460
1458
|
if website is None:
|
|
1461
1459
|
raise
|
|
1462
1460
|
target = website + "/login?next=%2Fsettings%2Faccount"
|
|
@@ -1924,7 +1922,9 @@ def workspaces(args, *, client_factory, store: CredentialStore | None = None):
|
|
|
1924
1922
|
base = _require_base(args)
|
|
1925
1923
|
access = session_token(store, base)
|
|
1926
1924
|
if not access:
|
|
1927
|
-
raise ClientError(
|
|
1925
|
+
raise ClientError(
|
|
1926
|
+
"authentication_required", "You are not signed in. Run `evalrouter login`."
|
|
1927
|
+
)
|
|
1928
1928
|
entry = store.server(base)
|
|
1929
1929
|
local = entry.get("devices") or {}
|
|
1930
1930
|
rows = [
|
|
@@ -1954,7 +1954,9 @@ def switch(args, *, client_factory, store: CredentialStore | None = None):
|
|
|
1954
1954
|
)
|
|
1955
1955
|
access = session_token(store, base)
|
|
1956
1956
|
if not access:
|
|
1957
|
-
raise ClientError(
|
|
1957
|
+
raise ClientError(
|
|
1958
|
+
"authentication_required", "You are not signed in. Run `evalrouter login`."
|
|
1959
|
+
)
|
|
1958
1960
|
chosen = _pick_workspace(_list_workspaces(client_factory, access), entry.get("active"))
|
|
1959
1961
|
if chosen is False:
|
|
1960
1962
|
raise ClientError(
|
|
@@ -1974,7 +1976,9 @@ def switch(args, *, client_factory, store: CredentialStore | None = None):
|
|
|
1974
1976
|
return {"active": {"id": matches[0], "name": name}, "registered": False}
|
|
1975
1977
|
access = session_token(store, base)
|
|
1976
1978
|
if not access:
|
|
1977
|
-
raise ClientError(
|
|
1979
|
+
raise ClientError(
|
|
1980
|
+
"authentication_required", "You are not signed in. Run `evalrouter login`."
|
|
1981
|
+
)
|
|
1978
1982
|
workspace = _select_workspace(_list_workspaces(client_factory, access), wanted)
|
|
1979
1983
|
device = _register(client_factory, store, base, access, workspace)
|
|
1980
1984
|
return {"active": {"id": device["id"], "name": device["workspace_name"]}, "registered": True}
|
|
@@ -2101,18 +2105,29 @@ def _micro(value: object) -> int | None:
|
|
|
2101
2105
|
return None
|
|
2102
2106
|
|
|
2103
2107
|
|
|
2104
|
-
def
|
|
2105
|
-
"""
|
|
2106
|
-
|
|
2108
|
+
def credits_rows(value: dict) -> list[tuple[str, str, str]]:
|
|
2109
|
+
"""(label, amount, note) for the wallet's balance, held and available amounts."""
|
|
2110
|
+
return [
|
|
2107
2111
|
("Balance", signed_money(value.get("balance_microusd")), ""),
|
|
2108
2112
|
("Held", signed_money(value.get("reserved_microusd")), "reserved for running evaluations"),
|
|
2109
2113
|
("Available", signed_money(value.get("available_microusd")), "for new evaluations"),
|
|
2110
2114
|
]
|
|
2115
|
+
|
|
2116
|
+
|
|
2117
|
+
def credits_lines(value: dict, base: str | None) -> list[str]:
|
|
2118
|
+
"""Terminal projection of the wallet; `--json` prints the document unchanged."""
|
|
2119
|
+
rows = credits_rows(value)
|
|
2111
2120
|
width = max(len(label) for label, _, _ in rows) + 1
|
|
2112
2121
|
amount = max(len(text) for _, text, _ in rows)
|
|
2113
2122
|
lines = ["Workspace credits"]
|
|
2114
2123
|
for label, text, note in rows:
|
|
2115
2124
|
lines.append(f" {label + ':':<{width}} {text:>{amount}}" + (f" {note}" if note else ""))
|
|
2125
|
+
return lines + credits_notes(value, base)
|
|
2126
|
+
|
|
2127
|
+
|
|
2128
|
+
def credits_notes(value: dict, base: str | None) -> list[str]:
|
|
2129
|
+
"""What the amounts mean for new evaluations, and where to add credit."""
|
|
2130
|
+
lines = []
|
|
2116
2131
|
balance, available = (
|
|
2117
2132
|
_micro(value.get(key)) for key in ("balance_microusd", "available_microusd")
|
|
2118
2133
|
)
|