evalsuite-python 0.8.5__tar.gz → 1.1.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.
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/CHANGELOG.md +50 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/PKG-INFO +18 -2
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/README.md +5 -1
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/pyproject.toml +12 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/rust/Cargo.lock +57 -4
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/rust/Cargo.toml +1 -1
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/rust/evalsuite-core/src/surface.rs +20 -21
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/rust/evalsuite-core/src/text.rs +105 -14
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/__init__.py +11 -0
- evalsuite_python-1.1.0/src/evalsuite/_evalci.py +251 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/api.py +37 -5
- evalsuite_python-1.1.0/src/evalsuite/cards.py +427 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/cli/main.py +49 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/core/result.py +84 -12
- evalsuite_python-1.1.0/src/evalsuite/harness.py +470 -0
- evalsuite_python-1.1.0/src/evalsuite/integrations.py +231 -0
- evalsuite_python-1.1.0/src/evalsuite/monitor.py +197 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/stats/compare.py +2 -1
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/version.py +1 -1
- evalsuite_python-1.1.0/tests/test_cards.py +85 -0
- evalsuite_python-1.1.0/tests/test_harness.py +117 -0
- evalsuite_python-1.1.0/tests/test_integrations.py +101 -0
- evalsuite_python-1.1.0/tests/test_monitor.py +57 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/unit/test_core.py +23 -1
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/CONTRIBUTING.md +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/LICENSE +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/LICENSE-APACHE +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/rust/evalsuite-core/Cargo.toml +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/rust/evalsuite-core/README.md +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/rust/evalsuite-core/src/agreement.rs +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/rust/evalsuite-core/src/coco.rs +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/rust/evalsuite-core/src/curve.rs +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/rust/evalsuite-core/src/groups.rs +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/rust/evalsuite-core/src/hash.rs +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/rust/evalsuite-core/src/lib.rs +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/rust/evalsuite-core/src/meteor.rs +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/rust/evalsuite-core/src/permutation.rs +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/rust/evalsuite-core/src/qa.rs +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/rust/evalsuite-core/src/ranks.rs +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/rust/evalsuite-core/src/resample.rs +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/rust/evalsuite-core/src/ter.rs +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/rust/evalsuite-py/Cargo.toml +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/rust/evalsuite-py/src/lib.rs +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/__main__.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/_bench_metrics.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/_lazy.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/_native.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/benchmarks.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/calibration.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/classification/__init__.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/classification/_common.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/classification/metrics.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/cli/__init__.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/clinical/__init__.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/clinical/metrics.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/clinical/report.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/core/__init__.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/core/context.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/core/exceptions.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/core/export.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/core/registry.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/core/types.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/core/validation.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/llmsys/__init__.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/llmsys/_common.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/llmsys/agents.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/llmsys/code.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/llmsys/efficiency.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/llmsys/longcontext.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/llmsys/multilingual.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/llmsys/robustness.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/llmsys/safety.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/llmsys/uncertainty.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/plot.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/py.typed +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/regression/__init__.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/regression/metrics.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/reporting.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/stats/__init__.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/stats/_resolve.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/stats/effect.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/stats/hypothesis.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/stats/intervals.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/stats/paired.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/stats/results.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/text/__init__.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/text/_common.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/text/factuality.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/text/generation.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/text/judge.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/text/qa.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/text/rag.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/text/reasoning.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/text/report.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/text/retrieval.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/text/semantic.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/text/spice.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/text/structured.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/vision/__init__.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/vision/detection.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/src/evalsuite/vision/segmentation.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/__init__.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/classification/__init__.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/classification/test_against_sklearn.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/clinical/__init__.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/clinical/test_outputs.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/clinical/test_v020.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/conftest.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/integration/__init__.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/integration/test_qa.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/integration/test_readme_examples.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/integration/test_repo_hygiene.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/llmsys/__init__.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/llmsys/test_code_longcontext_efficiency.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/llmsys/test_edges.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/llmsys/test_fast_text.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/llmsys/test_hardening.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/llmsys/test_safety_robustness.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/llmsys/test_uncertainty_agents_multilingual.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/output/__init__.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/output/test_benchmarks.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/output/test_cli.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/output/test_plot.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/output/test_reporting.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/regression/__init__.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/regression/test_against_sklearn.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/stats/__init__.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/stats/test_branches.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/stats/test_compare.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/stats/test_fast_paths.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/stats/test_reference.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/test_native.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/text/__init__.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/text/test_against_references.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/text/test_text_edges.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/text/test_v040.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/unit/__init__.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/unit/test_edges.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/vision/__init__.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/vision/test_detection.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/vision/test_edges.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/vision/test_outputs.py +0 -0
- {evalsuite_python-0.8.5 → evalsuite_python-1.1.0}/tests/vision/test_segmentation.py +0 -0
|
@@ -6,6 +6,56 @@ All notable changes to this project are documented here. The format follows
|
|
|
6
6
|
|
|
7
7
|
## [Unreleased]
|
|
8
8
|
|
|
9
|
+
## [1.1.0] - 2026-11-26
|
|
10
|
+
|
|
11
|
+
### Added
|
|
12
|
+
- **The engine everywhere**: npm, C, R and Julia now cover clinical metrics (sensitivity, PPV, NPV, likelihood
|
|
13
|
+
ratios, diagnostic odds ratio, Youden's J, net benefit), calibration (slope, intercept, ECE, MCE,
|
|
14
|
+
Hosmer–Lemeshow), retrieval (NDCG, MRR, MAP, precision / recall / hit rate at k) and segmentation (Dice, IoU),
|
|
15
|
+
in addition to the 1.0 set.
|
|
16
|
+
- **Confidence intervals in every language**: `ci: "analytic"` (Wilson for proportions, DeLong for ROC AUC,
|
|
17
|
+
bootstrap otherwise) or `ci: "bootstrap"` (seeded BCa) returns `ci_low` / `ci_high` alongside the value.
|
|
18
|
+
- **Leaderboard in the engine** (`leaderboard`): Wilson intervals, McNemar tests with Holm adjustment and
|
|
19
|
+
significance-aware ranks, available from JavaScript, C, R and Julia.
|
|
20
|
+
- **R package distribution**: a self-contained source package (Rust sources vendored, offline build, Windows
|
|
21
|
+
support) checked with `R CMD check`, attached to each release and published to the `r-package` branch for
|
|
22
|
+
R-universe. **Julia**: a BinaryBuilder recipe for `EvalSuite_jll`.
|
|
23
|
+
- **Example notebooks** (Colab): classification quickstart, clinical TRIPOD+AI, LLM leaderboard, monitoring,
|
|
24
|
+
vision.
|
|
25
|
+
|
|
26
|
+
### Changed
|
|
27
|
+
- BLEU 1.3× and HD95 1.6× faster than the Python reference path (memoised 13a tokenization, byte-level
|
|
28
|
+
tokenizer, per-segment vocabularies, packed n-gram matching; row-parallel surface scan, allocation-free label
|
|
29
|
+
checks). Results unchanged.
|
|
30
|
+
|
|
31
|
+
## [1.0.0] - 2026-11-25
|
|
32
|
+
|
|
33
|
+
EvalSuite 1.0: answers with uncertainty by default, and one engine in every language.
|
|
34
|
+
|
|
35
|
+
### Added
|
|
36
|
+
- **Confidence intervals by default in `evaluate()`** (`ci="analytic"`: Wilson for proportions, DeLong for
|
|
37
|
+
ROC AUC, t-intervals for error metrics; `ci="bootstrap"` or `ci=False`) and **baseline tests**
|
|
38
|
+
(`baseline_pred=` / `baseline_prob=`: paired difference with interval and p-value, Holm-adjusted). Summaries,
|
|
39
|
+
Markdown, LaTeX and DataFrame exports show the interval and the comparison.
|
|
40
|
+
- **LLM leaderboard harness** (`es.leaderboard`, `evalsuite leaderboard`): scorers (exact match, GSM8K, boxed,
|
|
41
|
+
choice, numeric, ...), Wilson / bootstrap intervals, McNemar or paired-bootstrap tests with Holm adjustment,
|
|
42
|
+
significance-aware ranks, per-category tables, extraction-failure, contamination (n-gram overlap) and
|
|
43
|
+
judge position-consistency checks; Markdown, LaTeX, HTML, CSV and JSON output.
|
|
44
|
+
- **Integrations** (`evalsuite.integrations`): scikit-learn scorers, Hugging Face `compute_metrics`, Keras and
|
|
45
|
+
PyTorch Lightning callbacks, MLflow and Weights & Biases logging (optional extras).
|
|
46
|
+
- **Monitoring** (`es.Monitor`, `evalsuite::monitor`): sliding-window metrics, PSI and Kolmogorov–Smirnov drift
|
|
47
|
+
against reference scores, threshold alerts with callbacks, `snapshot()` with intervals.
|
|
48
|
+
- **Report cards** (`es.report_card`): the TRIPOD+AI performance section (sample, discrimination, calibration,
|
|
49
|
+
Brier, threshold measures, net benefit, subgroups) with intervals, a results paragraph and the checklist; model
|
|
50
|
+
cards from `context`; Markdown, LaTeX, HTML, JSON, CSV and Word (`[docx]` extra).
|
|
51
|
+
- **One engine, every language**: `evalsuite::bridge` (JSON in, JSON out); the `evalsuite` npm package
|
|
52
|
+
(WebAssembly, Node and browser); a C API (`evalsuite-capi`, `evalsuite.h`); R (`bindings/r`) and Julia
|
|
53
|
+
(`bindings/julia`) packages. CI checks that every language gives the engine's value.
|
|
54
|
+
|
|
55
|
+
### Changed
|
|
56
|
+
- Faster Rust text metrics: an allocation-free 13a tokenizer and parallel sentence statistics (TER 1.9×,
|
|
57
|
+
chrF 1.6×, BLEU 1.2× versus 0.8.5); HD95 percentiles by selection instead of sorting.
|
|
58
|
+
|
|
9
59
|
## [0.8.5] - 2026-11-25
|
|
10
60
|
|
|
11
61
|
The Rust edition is complete, gains a command-line tool, and the Python retrieval metrics run on it.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: evalsuite-python
|
|
3
|
-
Version:
|
|
3
|
+
Version: 1.1.0
|
|
4
4
|
Classifier: Development Status :: 5 - Production/Stable
|
|
5
5
|
Classifier: Intended Audience :: Science/Research
|
|
6
6
|
Classifier: Intended Audience :: Healthcare Industry
|
|
@@ -50,14 +50,26 @@ Requires-Dist: pandas-stubs ; extra == 'dev'
|
|
|
50
50
|
Requires-Dist: build ; extra == 'dev'
|
|
51
51
|
Requires-Dist: twine ; extra == 'dev'
|
|
52
52
|
Requires-Dist: pip-audit ; extra == 'dev'
|
|
53
|
+
Requires-Dist: python-docx>=1.0 ; extra == 'docx'
|
|
54
|
+
Requires-Dist: keras>=3 ; extra == 'keras'
|
|
55
|
+
Requires-Dist: lightning>=2 ; extra == 'lightning'
|
|
53
56
|
Requires-Dist: nltk>=3.8 ; extra == 'llm'
|
|
57
|
+
Requires-Dist: mlflow>=2 ; extra == 'mlflow'
|
|
54
58
|
Requires-Dist: matplotlib>=3.5 ; extra == 'plot'
|
|
59
|
+
Requires-Dist: scikit-learn>=1.2 ; extra == 'sklearn'
|
|
55
60
|
Requires-Dist: pillow>=9 ; extra == 'vision'
|
|
61
|
+
Requires-Dist: wandb>=0.16 ; extra == 'wandb'
|
|
56
62
|
Provides-Extra: all
|
|
57
63
|
Provides-Extra: dev
|
|
64
|
+
Provides-Extra: docx
|
|
65
|
+
Provides-Extra: keras
|
|
66
|
+
Provides-Extra: lightning
|
|
58
67
|
Provides-Extra: llm
|
|
68
|
+
Provides-Extra: mlflow
|
|
59
69
|
Provides-Extra: plot
|
|
70
|
+
Provides-Extra: sklearn
|
|
60
71
|
Provides-Extra: vision
|
|
72
|
+
Provides-Extra: wandb
|
|
61
73
|
License-File: LICENSE
|
|
62
74
|
License-File: LICENSE-APACHE
|
|
63
75
|
Summary: A unified Python framework for machine-learning, clinical, statistical, segmentation, object-detection, uncertainty, and model evaluation.
|
|
@@ -85,7 +97,11 @@ Project-URL: Source, https://github.com/mkcs28/evalsuite-python
|
|
|
85
97
|
EvalSuite brings classification, regression, clinical, statistical, segmentation and object-detection
|
|
86
98
|
evaluation into one consistent, validated, documented framework.
|
|
87
99
|
|
|
88
|
-
> **Status: stable (
|
|
100
|
+
> **Status: stable (1.1.0).** Try it in Colab: [example notebooks](notebooks/README.md). **1.0** makes `evaluate()` report confidence intervals by default and test
|
|
101
|
+
> against a baseline, and adds an LLM leaderboard harness, framework integrations (scikit-learn, Hugging Face,
|
|
102
|
+
> Keras, Lightning, MLflow, W&B), monitoring with drift alerts, TRIPOD+AI / model-card report cards, and the same
|
|
103
|
+
> engine for JavaScript (npm, WebAssembly), C, R and Julia.
|
|
104
|
+
> Every item on the 0.1.0–0.5.0 roadmaps is implemented and verified, including SPICE.
|
|
89
105
|
> **0.6 adds a compiled Rust core**: same API and identical results, with text metrics, COCO evaluation and
|
|
90
106
|
> bootstrap resampling several times faster and multithreaded (prebuilt wheels for Linux, macOS and Windows).
|
|
91
107
|
> **0.7.0** moves ROC AUC / average precision (and so `evaluate()`), the LLM-systems consistency metrics,
|
|
@@ -10,7 +10,11 @@
|
|
|
10
10
|
EvalSuite brings classification, regression, clinical, statistical, segmentation and object-detection
|
|
11
11
|
evaluation into one consistent, validated, documented framework.
|
|
12
12
|
|
|
13
|
-
> **Status: stable (
|
|
13
|
+
> **Status: stable (1.1.0).** Try it in Colab: [example notebooks](notebooks/README.md). **1.0** makes `evaluate()` report confidence intervals by default and test
|
|
14
|
+
> against a baseline, and adds an LLM leaderboard harness, framework integrations (scikit-learn, Hugging Face,
|
|
15
|
+
> Keras, Lightning, MLflow, W&B), monitoring with drift alerts, TRIPOD+AI / model-card report cards, and the same
|
|
16
|
+
> engine for JavaScript (npm, WebAssembly), C, R and Julia.
|
|
17
|
+
> Every item on the 0.1.0–0.5.0 roadmaps is implemented and verified, including SPICE.
|
|
14
18
|
> **0.6 adds a compiled Rust core**: same API and identical results, with text metrics, COCO evaluation and
|
|
15
19
|
> bootstrap resampling several times faster and multithreaded (prebuilt wheels for Linux, macOS and Windows).
|
|
16
20
|
> **0.7.0** moves ROC AUC / average precision (and so `evaluate()`), the LLM-systems consistency metrics,
|
|
@@ -42,6 +42,12 @@ dependencies = ["numpy>=1.22", "scipy>=1.8", "pandas>=1.4"]
|
|
|
42
42
|
plot = ["matplotlib>=3.5"]
|
|
43
43
|
vision = ["pillow>=9"]
|
|
44
44
|
llm = ["nltk>=3.8"]
|
|
45
|
+
sklearn = ["scikit-learn>=1.2"]
|
|
46
|
+
keras = ["keras>=3"]
|
|
47
|
+
lightning = ["lightning>=2"]
|
|
48
|
+
mlflow = ["mlflow>=2"]
|
|
49
|
+
docx = ["python-docx>=1.0"]
|
|
50
|
+
wandb = ["wandb>=0.16"]
|
|
45
51
|
all = ["matplotlib>=3.5", "pillow>=9", "nltk>=3.8"]
|
|
46
52
|
dev = [
|
|
47
53
|
"pytest>=7",
|
|
@@ -123,6 +129,8 @@ ignore = ["N803", "N806", "RUF022", "UP007", "UP045", "RUF001", "RUF002", "RUF00
|
|
|
123
129
|
"src/evalsuite/*/metrics.py" = ["E501"]
|
|
124
130
|
# Developer script recording parity fixtures for the Rust crate: each case's lambda runs immediately.
|
|
125
131
|
"scripts/rust_fixtures.py" = ["B007", "B023", "E501", "E731", "E741", "RUF005"]
|
|
132
|
+
"scripts/make_notebooks.py" = ["E501", "S102"]
|
|
133
|
+
"notebooks/*.ipynb" = ["E501", "I001", "S311"]
|
|
126
134
|
|
|
127
135
|
[tool.mypy]
|
|
128
136
|
python_version = "3.10"
|
|
@@ -143,3 +151,7 @@ follow_untyped_imports = false
|
|
|
143
151
|
testpaths = ["tests"]
|
|
144
152
|
addopts = "-q --strict-markers"
|
|
145
153
|
filterwarnings = ["error::RuntimeWarning"]
|
|
154
|
+
|
|
155
|
+
[tool.ruff.format]
|
|
156
|
+
# Generated by scripts/make_notebooks.py.
|
|
157
|
+
exclude = ["notebooks/*.ipynb"]
|
|
@@ -319,7 +319,7 @@ checksum = "00d174d5400e5e8fd687ad1049e2f578285fa914201b1af7e8b112a4546bd826"
|
|
|
319
319
|
|
|
320
320
|
[[package]]
|
|
321
321
|
name = "evalsuite"
|
|
322
|
-
version = "
|
|
322
|
+
version = "1.1.0"
|
|
323
323
|
dependencies = [
|
|
324
324
|
"criterion",
|
|
325
325
|
"evalsuite-core",
|
|
@@ -332,9 +332,16 @@ dependencies = [
|
|
|
332
332
|
"serde_json",
|
|
333
333
|
]
|
|
334
334
|
|
|
335
|
+
[[package]]
|
|
336
|
+
name = "evalsuite-capi"
|
|
337
|
+
version = "1.1.0"
|
|
338
|
+
dependencies = [
|
|
339
|
+
"evalsuite",
|
|
340
|
+
]
|
|
341
|
+
|
|
335
342
|
[[package]]
|
|
336
343
|
name = "evalsuite-cli"
|
|
337
|
-
version = "
|
|
344
|
+
version = "1.1.0"
|
|
338
345
|
dependencies = [
|
|
339
346
|
"clap",
|
|
340
347
|
"csv",
|
|
@@ -344,20 +351,29 @@ dependencies = [
|
|
|
344
351
|
|
|
345
352
|
[[package]]
|
|
346
353
|
name = "evalsuite-core"
|
|
347
|
-
version = "
|
|
354
|
+
version = "1.1.0"
|
|
348
355
|
dependencies = [
|
|
349
356
|
"rayon",
|
|
350
357
|
]
|
|
351
358
|
|
|
352
359
|
[[package]]
|
|
353
360
|
name = "evalsuite-py"
|
|
354
|
-
version = "
|
|
361
|
+
version = "1.1.0"
|
|
355
362
|
dependencies = [
|
|
356
363
|
"evalsuite-core",
|
|
357
364
|
"pyo3",
|
|
358
365
|
"rayon",
|
|
359
366
|
]
|
|
360
367
|
|
|
368
|
+
[[package]]
|
|
369
|
+
name = "evalsuite-wasm"
|
|
370
|
+
version = "1.1.0"
|
|
371
|
+
dependencies = [
|
|
372
|
+
"evalsuite",
|
|
373
|
+
"js-sys",
|
|
374
|
+
"wasm-bindgen",
|
|
375
|
+
]
|
|
376
|
+
|
|
361
377
|
[[package]]
|
|
362
378
|
name = "fancy-regex"
|
|
363
379
|
version = "0.14.0"
|
|
@@ -375,6 +391,30 @@ version = "0.2.0"
|
|
|
375
391
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
376
392
|
checksum = "77ce24cb58228fbb8aa041425bb1050850ac19177686ea6e0f41a70416f56fdb"
|
|
377
393
|
|
|
394
|
+
[[package]]
|
|
395
|
+
name = "futures-core"
|
|
396
|
+
version = "0.3.34"
|
|
397
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
398
|
+
checksum = "92d699e522242e69e3003b94ecc1f960f3a5e015aa7c5d7486e65ad01dd94f5e"
|
|
399
|
+
|
|
400
|
+
[[package]]
|
|
401
|
+
name = "futures-task"
|
|
402
|
+
version = "0.3.34"
|
|
403
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
404
|
+
checksum = "cd417de3d1d015fc3bfd2b1ea46dfc7bab72ef86f1cc7cc9c78e728b34a6d1fd"
|
|
405
|
+
|
|
406
|
+
[[package]]
|
|
407
|
+
name = "futures-util"
|
|
408
|
+
version = "0.3.34"
|
|
409
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
410
|
+
checksum = "0d50a92467f8ba5dd6e3ee5d4bd04d73ab2e4e1c44474a0674821dfce14b79bc"
|
|
411
|
+
dependencies = [
|
|
412
|
+
"futures-core",
|
|
413
|
+
"futures-task",
|
|
414
|
+
"pin-project-lite",
|
|
415
|
+
"slab",
|
|
416
|
+
]
|
|
417
|
+
|
|
378
418
|
[[package]]
|
|
379
419
|
name = "getopts"
|
|
380
420
|
version = "0.2.24"
|
|
@@ -516,6 +556,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
|
516
556
|
checksum = "8dc09d2154098bbf4ef54eab6b117a3c24cbbffe94046b16ee6d6d4510584d3a"
|
|
517
557
|
dependencies = [
|
|
518
558
|
"cfg-if",
|
|
559
|
+
"futures-util",
|
|
519
560
|
"wasm-bindgen",
|
|
520
561
|
]
|
|
521
562
|
|
|
@@ -687,6 +728,12 @@ dependencies = [
|
|
|
687
728
|
"siphasher",
|
|
688
729
|
]
|
|
689
730
|
|
|
731
|
+
[[package]]
|
|
732
|
+
name = "pin-project-lite"
|
|
733
|
+
version = "0.2.18"
|
|
734
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
735
|
+
checksum = "c938015719552d665fd0553b90d96cd7ff58e83e4c061ca99e6bb78865a72752"
|
|
736
|
+
|
|
690
737
|
[[package]]
|
|
691
738
|
name = "portable-atomic"
|
|
692
739
|
version = "1.15.0"
|
|
@@ -1003,6 +1050,12 @@ version = "1.0.4"
|
|
|
1003
1050
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
1004
1051
|
checksum = "33f4fe9184a62d842c9ef383018f3306d8ba224fd9d836f56d7288308847c256"
|
|
1005
1052
|
|
|
1053
|
+
[[package]]
|
|
1054
|
+
name = "slab"
|
|
1055
|
+
version = "0.4.12"
|
|
1056
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
1057
|
+
checksum = "0c790de23124f9ab44544d7ac05d60440adc586479ce501c1d6d7da3cd8c9cf5"
|
|
1058
|
+
|
|
1006
1059
|
[[package]]
|
|
1007
1060
|
name = "static_assertions"
|
|
1008
1061
|
version = "1.1.0"
|
|
@@ -13,29 +13,28 @@ pub fn surface_points(mask: &[bool], dims: &[usize]) -> Vec<[i64; 3]> {
|
|
|
13
13
|
d3[3 - nd..].copy_from_slice(dims);
|
|
14
14
|
let (n0, n1, n2) = (d3[0], d3[1], d3[2]);
|
|
15
15
|
let strides = [n1 * n2, n2, 1];
|
|
16
|
-
|
|
16
|
+
// Parallel over rows (slab × row), not only slabs, so 2-D images use every core; rows are collected in
|
|
17
|
+
// order, so the points come out in the same (C) order as a serial scan.
|
|
18
|
+
let per_slab: Vec<Vec<[i64; 3]>> = (0..n0 * n1)
|
|
17
19
|
.into_par_iter()
|
|
18
|
-
.
|
|
20
|
+
.with_min_len(16)
|
|
21
|
+
.map(|r| {
|
|
22
|
+
let (i, j) = (r / n1, r % n1);
|
|
19
23
|
let mut out = Vec::new();
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
let
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|| !mask[f + strides[ax]]
|
|
35
|
-
});
|
|
36
|
-
if border {
|
|
37
|
-
out.push([i as i64, j as i64, k as i64]);
|
|
38
|
-
}
|
|
24
|
+
let row = r * n2;
|
|
25
|
+
for k in 0..n2 {
|
|
26
|
+
let f = row + k;
|
|
27
|
+
if !mask[f] {
|
|
28
|
+
continue;
|
|
29
|
+
}
|
|
30
|
+
let idx = [i, j, k];
|
|
31
|
+
// Surface: on the image border along a real axis, or a face neighbour is background.
|
|
32
|
+
let border = (3 - nd..3).any(|ax| {
|
|
33
|
+
let p = idx[ax];
|
|
34
|
+
p == 0 || p + 1 == d3[ax] || !mask[f - strides[ax]] || !mask[f + strides[ax]]
|
|
35
|
+
});
|
|
36
|
+
if border {
|
|
37
|
+
out.push([i as i64, j as i64, k as i64]);
|
|
39
38
|
}
|
|
40
39
|
}
|
|
41
40
|
out
|
|
@@ -19,27 +19,118 @@ pub fn bleu_stats(hyp: &[u32], refs: &[&[u32]], order: usize) -> Vec<i64> {
|
|
|
19
19
|
let mut out = vec![0i64; 2 + 2 * order];
|
|
20
20
|
out[0] = hyp_len;
|
|
21
21
|
out[1] = if refs.is_empty() { 0 } else { closest };
|
|
22
|
+
// Short segments (the usual case): sorted n-gram runs merged against each reference, which avoids hash
|
|
23
|
+
// maps and their allocations; long ones: hash counting. Counts are integers, so both give the same result.
|
|
24
|
+
let short = hyp.len() <= 256 && refs.iter().all(|r| r.len() <= 256);
|
|
22
25
|
for n in 1..=order {
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
26
|
+
let correct = if short {
|
|
27
|
+
clipped_sorted(hyp, refs, n)
|
|
28
|
+
} else {
|
|
29
|
+
clipped_hashed(hyp, refs, n)
|
|
30
|
+
};
|
|
31
|
+
out[1 + n] = correct;
|
|
32
|
+
out[1 + order + n] = (hyp_len - n as i64 + 1).max(0);
|
|
33
|
+
}
|
|
34
|
+
out
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
/// Runs of equal n-grams in sorted order: (n-gram, count).
|
|
38
|
+
fn sorted_runs(seq: &[u32], n: usize) -> Vec<(&[u32], u32)> {
|
|
39
|
+
if n == 0 || seq.len() < n {
|
|
40
|
+
return Vec::new();
|
|
41
|
+
}
|
|
42
|
+
let mut w: Vec<&[u32]> = seq.windows(n).collect();
|
|
43
|
+
w.sort_unstable();
|
|
44
|
+
let mut runs: Vec<(&[u32], u32)> = Vec::with_capacity(w.len());
|
|
45
|
+
for g in w {
|
|
46
|
+
match runs.last_mut() {
|
|
47
|
+
Some((last, c)) if *last == g => *c += 1,
|
|
48
|
+
_ => runs.push((g, 1)),
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
runs
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
fn clipped_sorted(hyp: &[u32], refs: &[&[u32]], n: usize) -> i64 {
|
|
55
|
+
// n-grams packed into one integer when the ids fit (16 bits each, n ≤ 4): sorting integers is much
|
|
56
|
+
// cheaper than sorting slices; otherwise slices.
|
|
57
|
+
let fits = n <= 4
|
|
58
|
+
&& hyp
|
|
59
|
+
.iter()
|
|
60
|
+
.chain(refs.iter().flat_map(|r| r.iter()))
|
|
61
|
+
.all(|&t| t < 1 << 16);
|
|
62
|
+
if fits {
|
|
63
|
+
let pack = |s: &[u32]| -> Vec<u64> {
|
|
64
|
+
let mut v: Vec<u64> = if s.len() < n {
|
|
65
|
+
Vec::new()
|
|
66
|
+
} else {
|
|
67
|
+
s.windows(n)
|
|
68
|
+
.map(|w| w.iter().fold(0u64, |k, &t| (k << 16) | u64::from(t)))
|
|
69
|
+
.collect()
|
|
70
|
+
};
|
|
71
|
+
v.sort_unstable();
|
|
72
|
+
v
|
|
73
|
+
};
|
|
74
|
+
return clipped_merge(&runs_of(&pack(hyp)), refs.iter().map(|r| runs_of(&pack(r))));
|
|
75
|
+
}
|
|
76
|
+
let h = sorted_runs(hyp, n);
|
|
77
|
+
clipped_merge(&h, refs.iter().map(|r| sorted_runs(r, n)))
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
fn runs_of(sorted: &[u64]) -> Vec<(u64, u32)> {
|
|
81
|
+
let mut runs: Vec<(u64, u32)> = Vec::with_capacity(sorted.len());
|
|
82
|
+
for &g in sorted {
|
|
83
|
+
match runs.last_mut() {
|
|
84
|
+
Some((last, c)) if *last == g => *c += 1,
|
|
85
|
+
_ => runs.push((g, 1)),
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
runs
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
fn clipped_merge<K: Ord>(h: &[(K, u32)], refs: impl Iterator<Item = Vec<(K, u32)>>) -> i64 {
|
|
92
|
+
if h.is_empty() {
|
|
93
|
+
return 0;
|
|
94
|
+
}
|
|
95
|
+
let mut max_ref = vec![0u32; h.len()];
|
|
96
|
+
for rr in refs {
|
|
97
|
+
let (mut i, mut j) = (0, 0);
|
|
98
|
+
while i < h.len() && j < rr.len() {
|
|
99
|
+
match h[i].0.cmp(&rr[j].0) {
|
|
100
|
+
std::cmp::Ordering::Less => i += 1,
|
|
101
|
+
std::cmp::Ordering::Greater => j += 1,
|
|
102
|
+
std::cmp::Ordering::Equal => {
|
|
103
|
+
max_ref[i] = max_ref[i].max(rr[j].1);
|
|
104
|
+
i += 1;
|
|
105
|
+
j += 1;
|
|
30
106
|
}
|
|
31
107
|
}
|
|
32
108
|
}
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
109
|
+
}
|
|
110
|
+
h.iter()
|
|
111
|
+
.zip(&max_ref)
|
|
112
|
+
.map(|((_, c), m)| i64::from((*c).min(*m)))
|
|
113
|
+
.sum()
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
fn clipped_hashed(hyp: &[u32], refs: &[&[u32]], n: usize) -> i64 {
|
|
117
|
+
// Max count of each n-gram over the references, then matches clipped by it.
|
|
118
|
+
let mut ref_max: FxMap<&[u32], u32> = FxMap::default();
|
|
119
|
+
for r in refs {
|
|
120
|
+
for (g, c) in ngram_counts(r, n) {
|
|
121
|
+
let e = ref_max.entry(g).or_insert(0);
|
|
122
|
+
if c > *e {
|
|
123
|
+
*e = c;
|
|
37
124
|
}
|
|
38
125
|
}
|
|
39
|
-
out[1 + n] = correct;
|
|
40
|
-
out[1 + order + n] = (hyp_len - n as i64 + 1).max(0);
|
|
41
126
|
}
|
|
42
|
-
|
|
127
|
+
let mut correct = 0i64;
|
|
128
|
+
for (g, c) in ngram_counts(hyp, n) {
|
|
129
|
+
if let Some(&m) = ref_max.get(g) {
|
|
130
|
+
correct += i64::from(c.min(m));
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
correct
|
|
43
134
|
}
|
|
44
135
|
|
|
45
136
|
/// Clipped n-gram overlap between a reference `t` and a prediction `p` (ROUGE-N numerator).
|
|
@@ -15,6 +15,7 @@ from .calibration import (
|
|
|
15
15
|
hosmer_lemeshow,
|
|
16
16
|
maximum_calibration_error,
|
|
17
17
|
)
|
|
18
|
+
from .cards import ReportCard, report_card
|
|
18
19
|
from .classification import (
|
|
19
20
|
accuracy,
|
|
20
21
|
average_precision,
|
|
@@ -63,8 +64,10 @@ from .core.exceptions import (
|
|
|
63
64
|
)
|
|
64
65
|
from .core.registry import MetricInfo, list_metrics, metric_info
|
|
65
66
|
from .core.result import EvaluationResult, MetricResult
|
|
67
|
+
from .harness import Leaderboard, leaderboard
|
|
66
68
|
from .llmsys import * # noqa: F403 (v0.5.0 LLM-systems functions, listed in llmsys.__all__)
|
|
67
69
|
from .llmsys import __all__ as _llmsys_all
|
|
70
|
+
from .monitor import Alert, Monitor, ks_drift, population_stability_index
|
|
68
71
|
from .regression import (
|
|
69
72
|
adjusted_r2,
|
|
70
73
|
explained_variance,
|
|
@@ -196,6 +199,8 @@ __all__ = [
|
|
|
196
199
|
"ClassificationReport",
|
|
197
200
|
"stats",
|
|
198
201
|
"roc_auc_ci",
|
|
202
|
+
"report_card",
|
|
203
|
+
"ReportCard",
|
|
199
204
|
"proportion_ci",
|
|
200
205
|
"paired_bootstrap_test",
|
|
201
206
|
"mcnemar_test",
|
|
@@ -230,6 +235,12 @@ __all__ = [
|
|
|
230
235
|
"cohen_kappa",
|
|
231
236
|
"confusion_matrix",
|
|
232
237
|
"evaluate",
|
|
238
|
+
"leaderboard",
|
|
239
|
+
"Monitor",
|
|
240
|
+
"Alert",
|
|
241
|
+
"population_stability_index",
|
|
242
|
+
"ks_drift",
|
|
243
|
+
"Leaderboard",
|
|
233
244
|
"explained_variance",
|
|
234
245
|
"f1",
|
|
235
246
|
"fbeta",
|