@ai-sdk-tool/eval 0.1.3 → 0.1.5
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.
- package/README.md +18 -5
- package/dist/index.cjs +422 -375
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +8 -4
- package/dist/index.d.ts +8 -4
- package/dist/index.js +421 -374
- package/dist/index.js.map +1 -1
- package/package.json +4 -1
package/README.md
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
#
|
|
1
|
+
# AI SDK - evaluation tool
|
|
2
|
+
|
|
3
|
+
[](https://www.npmjs.com/package/@ai-sdk-tool/eval)
|
|
4
|
+
[](https://www.npmjs.com/package/@ai-sdk-tool/eval)
|
|
2
5
|
|
|
3
6
|
This package provides a standardized, extensible, and reproducible way to benchmark and evaluate the performance of Language Models (`LanguageModel` instances) within the Vercel AI SDK ecosystem.
|
|
4
7
|
|
|
@@ -18,9 +21,7 @@ It allows developers to:
|
|
|
18
21
|
## Installation
|
|
19
22
|
|
|
20
23
|
```bash
|
|
21
|
-
|
|
22
|
-
# In the future, it would be published to npm:
|
|
23
|
-
# npm install @ai-sdk-tool/eval
|
|
24
|
+
pnpm add @ai-sdk-tool/eval
|
|
24
25
|
```
|
|
25
26
|
|
|
26
27
|
## Quick Start
|
|
@@ -52,6 +53,12 @@ async function runMyEvaluation() {
|
|
|
52
53
|
runMyEvaluation();
|
|
53
54
|
```
|
|
54
55
|
|
|
56
|
+
Run the example from this repo:
|
|
57
|
+
|
|
58
|
+
```bash
|
|
59
|
+
cd examples/eval-core && pnpm dlx tsx src/bfcl-simple.ts
|
|
60
|
+
```
|
|
61
|
+
|
|
55
62
|
## Built-in Benchmarks
|
|
56
63
|
|
|
57
64
|
This package includes several pre-built benchmarks.
|
|
@@ -60,7 +67,13 @@ This package includes several pre-built benchmarks.
|
|
|
60
67
|
- `bfclParallelBenchmark`: Evaluates parallel (multi-tool) function calls.
|
|
61
68
|
- `bfclMultipleBenchmark`: Evaluates multiple calls to the same function.
|
|
62
69
|
- `bfclParallelMultipleBenchmark`: A combination of parallel and multiple function calls.
|
|
63
|
-
- `jsonGenerationBenchmark`: Evaluates the model's ability to generate schema-compliant JSON.
|
|
70
|
+
- `jsonGenerationBenchmark`: Evaluates the model's ability to generate schema-compliant JSON.
|
|
71
|
+
|
|
72
|
+
To try a JSON generation run locally:
|
|
73
|
+
|
|
74
|
+
```bash
|
|
75
|
+
cd examples/eval-core && pnpm dlx tsx src/json-generation.ts
|
|
76
|
+
```
|
|
64
77
|
|
|
65
78
|
## Creating a Custom Benchmark
|
|
66
79
|
|