@agentswf/lab 0.0.0-stage → 0.4.0

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.
Files changed (125) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +15 -2
  3. package/package.json +46 -4
  4. package/schema/lab-check.schema.json +64 -0
  5. package/schema/lab-config.schema.json +187 -0
  6. package/schema/lab-final.schema.json +48 -0
  7. package/schema/lab-good-record.schema.json +70 -0
  8. package/schema/lab-grade.schema.json +49 -0
  9. package/schema/lab-key.schema.json +124 -0
  10. package/schema/lab-label.schema.json +32 -0
  11. package/schema/lab-loop-report.schema.json +221 -0
  12. package/schema/lab-loop.schema.json +141 -0
  13. package/schema/lab-plan.schema.json +128 -0
  14. package/schema/lab-previous.schema.json +70 -0
  15. package/schema/lab-proposal.schema.json +52 -0
  16. package/schema/lab-report.schema.json +1128 -0
  17. package/schema/lab-run.schema.json +253 -0
  18. package/schema/lab-runs.schema.json +132 -0
  19. package/schema/lab-score.schema.json +319 -0
  20. package/schema/lab-spread.schema.json +110 -0
  21. package/schema/lab-trial.schema.json +543 -0
  22. package/schema/lab-try.schema.json +113 -0
  23. package/schema/local.json +155 -0
  24. package/src/cli.ts +9 -0
  25. package/src/env/capture.ts +48 -0
  26. package/src/env/compare.ts +201 -0
  27. package/src/env/facts.ts +51 -0
  28. package/src/env/fetch.ts +57 -0
  29. package/src/env/files.ts +228 -0
  30. package/src/env/grade-case.ts +80 -0
  31. package/src/env/grade-helper.ts +352 -0
  32. package/src/env/grader.ts +131 -0
  33. package/src/env/index.ts +727 -0
  34. package/src/env/mock.ts +374 -0
  35. package/src/env/routes.ts +90 -0
  36. package/src/env/sources.ts +19 -0
  37. package/src/env/state.ts +79 -0
  38. package/src/env/trial.ts +185 -0
  39. package/src/format/key.ts +168 -0
  40. package/src/format/loop.ts +179 -0
  41. package/src/format/output.ts +542 -0
  42. package/src/format/records.ts +443 -0
  43. package/src/format/schema-files.ts +64 -0
  44. package/src/format/settings.ts +559 -0
  45. package/src/format/trial-env.ts +67 -0
  46. package/src/format/trial-file.ts +134 -0
  47. package/src/help/awf-lab.txt +29 -0
  48. package/src/help/case.txt +39 -0
  49. package/src/help/config.txt +14 -0
  50. package/src/help/label.txt +12 -0
  51. package/src/help/loop.txt +44 -0
  52. package/src/help/report.txt +20 -0
  53. package/src/help/run.txt +61 -0
  54. package/src/help/runs.txt +11 -0
  55. package/src/help/score.txt +28 -0
  56. package/src/judge/criteria.workflow.ts +237 -0
  57. package/src/judge/version.ts +6 -0
  58. package/src/lab/answer.ts +47 -0
  59. package/src/lab/blame.ts +204 -0
  60. package/src/lab/box.ts +251 -0
  61. package/src/lab/capture-command.ts +302 -0
  62. package/src/lab/capture.ts +234 -0
  63. package/src/lab/check-command.ts +187 -0
  64. package/src/lab/cli.ts +325 -0
  65. package/src/lab/code-graders.ts +108 -0
  66. package/src/lab/columns.ts +138 -0
  67. package/src/lab/command-context.ts +436 -0
  68. package/src/lab/compare.ts +123 -0
  69. package/src/lab/config-command.ts +283 -0
  70. package/src/lab/criteria.ts +69 -0
  71. package/src/lab/dataset.ts +375 -0
  72. package/src/lab/eval-files.ts +196 -0
  73. package/src/lab/expect.ts +79 -0
  74. package/src/lab/facts.ts +59 -0
  75. package/src/lab/families.ts +32 -0
  76. package/src/lab/folders.ts +172 -0
  77. package/src/lab/git.ts +128 -0
  78. package/src/lab/good.ts +224 -0
  79. package/src/lab/grading-stub.txt +8 -0
  80. package/src/lab/grading.ts +332 -0
  81. package/src/lab/inspect.ts +227 -0
  82. package/src/lab/labels.ts +211 -0
  83. package/src/lab/loop-code.ts +255 -0
  84. package/src/lab/loop-command.ts +774 -0
  85. package/src/lab/loop-records.ts +144 -0
  86. package/src/lab/loop.ts +864 -0
  87. package/src/lab/marker.ts +23 -0
  88. package/src/lab/outcome.ts +196 -0
  89. package/src/lab/pooled.ts +106 -0
  90. package/src/lab/project-env.ts +39 -0
  91. package/src/lab/rates.ts +155 -0
  92. package/src/lab/reach.ts +111 -0
  93. package/src/lab/record-copies.ts +202 -0
  94. package/src/lab/refusal.ts +2 -0
  95. package/src/lab/report-command.ts +157 -0
  96. package/src/lab/report.ts +936 -0
  97. package/src/lab/reuse.ts +134 -0
  98. package/src/lab/run-command.ts +958 -0
  99. package/src/lab/run-logs.ts +89 -0
  100. package/src/lab/run-report.ts +286 -0
  101. package/src/lab/runs-command.ts +171 -0
  102. package/src/lab/runs.ts +172 -0
  103. package/src/lab/scaffold.ts +94 -0
  104. package/src/lab/score-command.ts +197 -0
  105. package/src/lab/score.ts +396 -0
  106. package/src/lab/store.ts +383 -0
  107. package/src/lab/target-stub.txt +18 -0
  108. package/src/lab/text.ts +29 -0
  109. package/src/lab/trial-settings.ts +105 -0
  110. package/src/lab/trial.ts +439 -0
  111. package/src/lab/usage.ts +274 -0
  112. package/src/lab/verdict.ts +161 -0
  113. package/src/lab/workflow-graders.ts +164 -0
  114. package/src/lab/workspace.ts +496 -0
  115. package/src/loop/propose.workflow.ts +84 -0
  116. package/src/shared/allowance.ts +185 -0
  117. package/src/shared/compare/index.ts +3 -0
  118. package/src/shared/compare/paired.ts +397 -0
  119. package/src/shared/compare/stats.ts +139 -0
  120. package/src/shared/compare/types.ts +75 -0
  121. package/src/shared/config.ts +15 -0
  122. package/src/shared/runner.ts +321 -0
  123. package/src/shared/validate.ts +181 -0
  124. package/src/shared/version.ts +41 -0
  125. package/src/write-schemas.ts +10 -0
@@ -0,0 +1,1128 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "title": "awf-lab run, score and report --json",
4
+ "type": "object",
5
+ "required": [
6
+ "kind",
7
+ "labRun",
8
+ "dataset",
9
+ "partial",
10
+ "exit",
11
+ "params",
12
+ "code",
13
+ "sums",
14
+ "reused",
15
+ "rates",
16
+ "tags",
17
+ "cases",
18
+ "numbers",
19
+ "numbersLeftOut",
20
+ "agreement"
21
+ ],
22
+ "properties": {
23
+ "kind": {
24
+ "type": "string",
25
+ "const": "awf.lab-report/1"
26
+ },
27
+ "labRun": {
28
+ "type": "string",
29
+ "pattern": "^[0-9]{8}-[0-9]{6}-[0-9a-f]{4}$"
30
+ },
31
+ "dataset": {
32
+ "type": "string",
33
+ "minLength": 1
34
+ },
35
+ "partial": {
36
+ "type": "boolean"
37
+ },
38
+ "stop": {
39
+ "type": "object",
40
+ "required": ["why", "notRun"],
41
+ "properties": {
42
+ "why": {
43
+ "enum": ["budget", "compare", "precondition", "stage"]
44
+ },
45
+ "notRun": {
46
+ "type": "integer",
47
+ "minimum": 0
48
+ }
49
+ },
50
+ "additionalProperties": false
51
+ },
52
+ "exit": {
53
+ "type": "integer",
54
+ "minimum": 0,
55
+ "maximum": 5
56
+ },
57
+ "params": {
58
+ "type": "object",
59
+ "patternProperties": {
60
+ "^[A-Za-z][A-Za-z0-9_-]*$": {
61
+ "type": "string",
62
+ "minLength": 1
63
+ }
64
+ }
65
+ },
66
+ "code": {
67
+ "type": "object",
68
+ "required": ["path", "branch", "commit", "dirty", "version", "sandbox", "limits"],
69
+ "properties": {
70
+ "path": {
71
+ "type": "string",
72
+ "minLength": 1
73
+ },
74
+ "branch": {
75
+ "anyOf": [
76
+ {
77
+ "type": "string",
78
+ "minLength": 1
79
+ },
80
+ {
81
+ "type": "null"
82
+ }
83
+ ]
84
+ },
85
+ "commit": {
86
+ "anyOf": [
87
+ {
88
+ "type": "string",
89
+ "minLength": 1
90
+ },
91
+ {
92
+ "type": "null"
93
+ }
94
+ ]
95
+ },
96
+ "dirty": {
97
+ "type": "boolean"
98
+ },
99
+ "version": {
100
+ "type": "string",
101
+ "minLength": 1
102
+ },
103
+ "sandbox": {
104
+ "anyOf": [
105
+ {
106
+ "type": "object",
107
+ "required": ["by", "provider", "network"],
108
+ "properties": {
109
+ "by": {
110
+ "type": "string",
111
+ "const": "lab"
112
+ },
113
+ "provider": {
114
+ "type": "string",
115
+ "const": "srt"
116
+ },
117
+ "network": {
118
+ "type": "object",
119
+ "required": ["agents", "code", "webSearch", "sockets"],
120
+ "properties": {
121
+ "agents": {
122
+ "type": "array",
123
+ "items": {
124
+ "type": "string",
125
+ "pattern": "^(\\*\\.)?[A-Za-z0-9-]+(\\.[A-Za-z0-9-]+)*$"
126
+ }
127
+ },
128
+ "code": {
129
+ "type": "array",
130
+ "items": {
131
+ "type": "string",
132
+ "pattern": "^(\\*\\.)?[A-Za-z0-9-]+(\\.[A-Za-z0-9-]+)*$"
133
+ }
134
+ },
135
+ "webSearch": {
136
+ "type": "boolean"
137
+ },
138
+ "sockets": {
139
+ "type": "array",
140
+ "items": {
141
+ "type": "string",
142
+ "minLength": 1
143
+ }
144
+ }
145
+ },
146
+ "additionalProperties": false
147
+ }
148
+ },
149
+ "additionalProperties": false
150
+ },
151
+ {
152
+ "type": "object",
153
+ "required": ["by", "network"],
154
+ "properties": {
155
+ "by": {
156
+ "type": "string",
157
+ "const": "workflow"
158
+ },
159
+ "network": {
160
+ "type": "object",
161
+ "required": ["agents", "code", "webSearch", "sockets"],
162
+ "properties": {
163
+ "agents": {
164
+ "type": "array",
165
+ "items": {
166
+ "type": "string",
167
+ "pattern": "^(\\*\\.)?[A-Za-z0-9-]+(\\.[A-Za-z0-9-]+)*$"
168
+ }
169
+ },
170
+ "code": {
171
+ "type": "array",
172
+ "items": {
173
+ "type": "string",
174
+ "pattern": "^(\\*\\.)?[A-Za-z0-9-]+(\\.[A-Za-z0-9-]+)*$"
175
+ }
176
+ },
177
+ "webSearch": {
178
+ "type": "boolean"
179
+ },
180
+ "sockets": {
181
+ "type": "array",
182
+ "items": {
183
+ "type": "string",
184
+ "minLength": 1
185
+ }
186
+ }
187
+ },
188
+ "additionalProperties": false
189
+ }
190
+ },
191
+ "additionalProperties": false
192
+ }
193
+ ]
194
+ },
195
+ "limits": {
196
+ "type": "object",
197
+ "required": ["setup", "workflow", "after"],
198
+ "properties": {
199
+ "setup": {
200
+ "type": "string",
201
+ "pattern": "^[1-9][0-9]*(ms|s|m|h)$"
202
+ },
203
+ "workflow": {
204
+ "type": "string",
205
+ "pattern": "^[1-9][0-9]*(ms|s|m|h)$"
206
+ },
207
+ "after": {
208
+ "type": "string",
209
+ "pattern": "^[1-9][0-9]*(ms|s|m|h)$"
210
+ }
211
+ },
212
+ "additionalProperties": false
213
+ }
214
+ },
215
+ "additionalProperties": false
216
+ },
217
+ "sums": {
218
+ "type": "object",
219
+ "required": ["estimate", "reusedEstimate", "gradingEstimate", "unpriced"],
220
+ "properties": {
221
+ "msMedian": {
222
+ "type": "number",
223
+ "minimum": 0
224
+ },
225
+ "estimateMedian": {
226
+ "type": "number",
227
+ "minimum": 0
228
+ },
229
+ "estimate": {
230
+ "type": "number",
231
+ "minimum": 0
232
+ },
233
+ "reusedEstimate": {
234
+ "type": "number",
235
+ "minimum": 0
236
+ },
237
+ "gradingEstimate": {
238
+ "type": "number",
239
+ "minimum": 0
240
+ },
241
+ "unpriced": {
242
+ "type": "boolean"
243
+ }
244
+ },
245
+ "additionalProperties": false
246
+ },
247
+ "reused": {
248
+ "type": "integer",
249
+ "minimum": 0
250
+ },
251
+ "rates": {
252
+ "type": "object",
253
+ "required": ["cases", "passed"],
254
+ "properties": {
255
+ "cases": {
256
+ "type": "integer",
257
+ "minimum": 0
258
+ },
259
+ "passed": {
260
+ "type": "integer",
261
+ "minimum": 0
262
+ },
263
+ "interval": {
264
+ "type": "array",
265
+ "additionalItems": false,
266
+ "items": [
267
+ {
268
+ "type": "number"
269
+ },
270
+ {
271
+ "type": "number"
272
+ }
273
+ ],
274
+ "minItems": 2
275
+ },
276
+ "mean": {
277
+ "type": "object",
278
+ "required": ["mean"],
279
+ "properties": {
280
+ "mean": {
281
+ "type": "number"
282
+ },
283
+ "interval": {
284
+ "type": "array",
285
+ "additionalItems": false,
286
+ "items": [
287
+ {
288
+ "type": "number"
289
+ },
290
+ {
291
+ "type": "number"
292
+ }
293
+ ],
294
+ "minItems": 2
295
+ }
296
+ },
297
+ "additionalProperties": false
298
+ },
299
+ "k": {
300
+ "type": "integer",
301
+ "minimum": 2
302
+ },
303
+ "passAll": {
304
+ "type": "integer",
305
+ "minimum": 0
306
+ },
307
+ "passAny": {
308
+ "type": "integer",
309
+ "minimum": 0
310
+ }
311
+ },
312
+ "additionalProperties": false
313
+ },
314
+ "tags": {
315
+ "type": "array",
316
+ "items": {
317
+ "type": "object",
318
+ "required": ["tag", "cases", "passed", "failing"],
319
+ "properties": {
320
+ "tag": {
321
+ "type": "string",
322
+ "minLength": 1
323
+ },
324
+ "cases": {
325
+ "type": "integer",
326
+ "minimum": 0
327
+ },
328
+ "passed": {
329
+ "type": "integer",
330
+ "minimum": 0
331
+ },
332
+ "failing": {
333
+ "type": "array",
334
+ "items": {
335
+ "type": "string",
336
+ "minLength": 1
337
+ }
338
+ }
339
+ },
340
+ "additionalProperties": false
341
+ }
342
+ },
343
+ "cases": {
344
+ "type": "array",
345
+ "items": {
346
+ "type": "object",
347
+ "required": [
348
+ "name",
349
+ "verdict",
350
+ "passed",
351
+ "trials",
352
+ "trialIds",
353
+ "knownFailing",
354
+ "outcomes",
355
+ "notes",
356
+ "history"
357
+ ],
358
+ "properties": {
359
+ "name": {
360
+ "type": "string",
361
+ "minLength": 1
362
+ },
363
+ "verdict": {
364
+ "anyOf": [
365
+ {
366
+ "enum": ["passed", "failed", "flaky", "unclear"]
367
+ },
368
+ {
369
+ "type": "null"
370
+ }
371
+ ]
372
+ },
373
+ "none": {
374
+ "enum": ["not graded", "graded by numbers"]
375
+ },
376
+ "passed": {
377
+ "type": "integer",
378
+ "minimum": 0
379
+ },
380
+ "trials": {
381
+ "type": "integer",
382
+ "minimum": 0
383
+ },
384
+ "trialIds": {
385
+ "type": "array",
386
+ "items": {
387
+ "type": "string",
388
+ "minLength": 1
389
+ }
390
+ },
391
+ "knownFailing": {
392
+ "type": "boolean"
393
+ },
394
+ "outcomes": {
395
+ "type": "array",
396
+ "items": {
397
+ "enum": [
398
+ "leaked",
399
+ "errored",
400
+ "failed",
401
+ "stopped",
402
+ "undecided",
403
+ "passed",
404
+ "graded by numbers",
405
+ "not graded"
406
+ ]
407
+ }
408
+ },
409
+ "why": {
410
+ "type": "string"
411
+ },
412
+ "notes": {
413
+ "type": "array",
414
+ "items": {
415
+ "type": "string"
416
+ }
417
+ },
418
+ "history": {
419
+ "type": "array",
420
+ "items": {
421
+ "enum": ["passed", "failed", "flaky", "unclear"]
422
+ }
423
+ }
424
+ },
425
+ "additionalProperties": false
426
+ }
427
+ },
428
+ "numbers": {
429
+ "type": "object",
430
+ "patternProperties": {
431
+ "^.*$": {
432
+ "type": "object",
433
+ "patternProperties": {
434
+ "^.*$": {
435
+ "anyOf": [
436
+ {
437
+ "type": "object",
438
+ "required": ["count", "of"],
439
+ "properties": {
440
+ "count": {
441
+ "type": "number",
442
+ "minimum": 0
443
+ },
444
+ "of": {
445
+ "type": "number",
446
+ "minimum": 0
447
+ }
448
+ },
449
+ "additionalProperties": false
450
+ },
451
+ {
452
+ "type": "object",
453
+ "required": ["values"],
454
+ "properties": {
455
+ "values": {
456
+ "type": "array",
457
+ "items": {
458
+ "type": "number"
459
+ }
460
+ }
461
+ },
462
+ "additionalProperties": false
463
+ }
464
+ ]
465
+ }
466
+ }
467
+ }
468
+ }
469
+ },
470
+ "numbersLeftOut": {
471
+ "type": "integer",
472
+ "minimum": 0
473
+ },
474
+ "agreement": {
475
+ "type": "array",
476
+ "items": {
477
+ "type": "object",
478
+ "required": ["a", "b", "verdicts", "parts"],
479
+ "properties": {
480
+ "a": {
481
+ "type": "string",
482
+ "minLength": 1
483
+ },
484
+ "b": {
485
+ "type": "string",
486
+ "minLength": 1
487
+ },
488
+ "verdicts": {
489
+ "type": "object",
490
+ "required": ["alike", "of"],
491
+ "properties": {
492
+ "alike": {
493
+ "type": "integer",
494
+ "minimum": 0
495
+ },
496
+ "of": {
497
+ "type": "integer",
498
+ "minimum": 0
499
+ }
500
+ },
501
+ "additionalProperties": false
502
+ },
503
+ "parts": {
504
+ "type": "object",
505
+ "required": ["alike", "of"],
506
+ "properties": {
507
+ "alike": {
508
+ "type": "integer",
509
+ "minimum": 0
510
+ },
511
+ "of": {
512
+ "type": "integer",
513
+ "minimum": 0
514
+ }
515
+ },
516
+ "additionalProperties": false
517
+ }
518
+ },
519
+ "additionalProperties": false
520
+ }
521
+ },
522
+ "labels": {
523
+ "type": "object",
524
+ "required": ["good", "needsWork", "notCompared", "graders", "disagreements"],
525
+ "properties": {
526
+ "good": {
527
+ "type": "object",
528
+ "required": ["labeled", "agreed"],
529
+ "properties": {
530
+ "labeled": {
531
+ "type": "integer",
532
+ "minimum": 0
533
+ },
534
+ "agreed": {
535
+ "type": "integer",
536
+ "minimum": 0
537
+ }
538
+ },
539
+ "additionalProperties": false
540
+ },
541
+ "needsWork": {
542
+ "type": "object",
543
+ "required": ["labeled", "agreed"],
544
+ "properties": {
545
+ "labeled": {
546
+ "type": "integer",
547
+ "minimum": 0
548
+ },
549
+ "agreed": {
550
+ "type": "integer",
551
+ "minimum": 0
552
+ }
553
+ },
554
+ "additionalProperties": false
555
+ },
556
+ "notCompared": {
557
+ "type": "integer",
558
+ "minimum": 0
559
+ },
560
+ "graders": {
561
+ "type": "array",
562
+ "items": {
563
+ "type": "object",
564
+ "required": ["grader", "good", "needsWork", "cost", "deciding"],
565
+ "properties": {
566
+ "grader": {
567
+ "type": "string",
568
+ "minLength": 1
569
+ },
570
+ "good": {
571
+ "type": "object",
572
+ "required": ["labeled", "agreed"],
573
+ "properties": {
574
+ "labeled": {
575
+ "type": "integer",
576
+ "minimum": 0
577
+ },
578
+ "agreed": {
579
+ "type": "integer",
580
+ "minimum": 0
581
+ }
582
+ },
583
+ "additionalProperties": false
584
+ },
585
+ "needsWork": {
586
+ "type": "object",
587
+ "required": ["labeled", "agreed"],
588
+ "properties": {
589
+ "labeled": {
590
+ "type": "integer",
591
+ "minimum": 0
592
+ },
593
+ "agreed": {
594
+ "type": "integer",
595
+ "minimum": 0
596
+ }
597
+ },
598
+ "additionalProperties": false
599
+ },
600
+ "cost": {
601
+ "type": "number",
602
+ "minimum": 0
603
+ },
604
+ "deciding": {
605
+ "type": "boolean"
606
+ }
607
+ },
608
+ "additionalProperties": false
609
+ }
610
+ },
611
+ "disagreements": {
612
+ "type": "array",
613
+ "items": {
614
+ "type": "object",
615
+ "required": ["case", "column", "trial", "mark", "outcome"],
616
+ "properties": {
617
+ "case": {
618
+ "type": "string",
619
+ "minLength": 1
620
+ },
621
+ "column": {
622
+ "type": "integer",
623
+ "minimum": 0
624
+ },
625
+ "trial": {
626
+ "type": "integer",
627
+ "minimum": 1
628
+ },
629
+ "mark": {
630
+ "enum": ["good", "needs-work"]
631
+ },
632
+ "note": {
633
+ "type": "string",
634
+ "minLength": 1
635
+ },
636
+ "outcome": {
637
+ "type": "string",
638
+ "minLength": 1
639
+ }
640
+ },
641
+ "additionalProperties": false
642
+ }
643
+ }
644
+ },
645
+ "additionalProperties": false
646
+ },
647
+ "stale": {
648
+ "anyOf": [
649
+ {
650
+ "type": "integer",
651
+ "minimum": 0
652
+ },
653
+ {
654
+ "type": "object",
655
+ "required": ["unread"],
656
+ "properties": {
657
+ "unread": {
658
+ "type": "string"
659
+ }
660
+ },
661
+ "additionalProperties": false
662
+ }
663
+ ]
664
+ },
665
+ "columns": {
666
+ "type": "array",
667
+ "items": {
668
+ "type": "object",
669
+ "required": [
670
+ "label",
671
+ "rates",
672
+ "path",
673
+ "branch",
674
+ "commit",
675
+ "dirty",
676
+ "version",
677
+ "sandbox",
678
+ "limits",
679
+ "params",
680
+ "sums",
681
+ "numbers",
682
+ "numbersLeftOut",
683
+ "cases"
684
+ ],
685
+ "properties": {
686
+ "label": {
687
+ "type": "string",
688
+ "minLength": 1
689
+ },
690
+ "compare": {
691
+ "anyOf": [
692
+ {
693
+ "type": "object",
694
+ "required": ["decision", "stop", "reason", "metrics"],
695
+ "properties": {
696
+ "decision": {
697
+ "enum": ["better", "worse", "tie", "undecided"]
698
+ },
699
+ "stop": {
700
+ "type": "boolean"
701
+ },
702
+ "reason": {
703
+ "type": "string"
704
+ },
705
+ "metrics": {
706
+ "type": "array",
707
+ "items": {}
708
+ }
709
+ },
710
+ "additionalProperties": false
711
+ },
712
+ {
713
+ "type": "object",
714
+ "required": ["error"],
715
+ "properties": {
716
+ "error": {
717
+ "type": "string"
718
+ }
719
+ },
720
+ "additionalProperties": false
721
+ }
722
+ ]
723
+ },
724
+ "rates": {
725
+ "type": "object",
726
+ "required": ["cases", "passed"],
727
+ "properties": {
728
+ "cases": {
729
+ "type": "integer",
730
+ "minimum": 0
731
+ },
732
+ "passed": {
733
+ "type": "integer",
734
+ "minimum": 0
735
+ },
736
+ "interval": {
737
+ "type": "array",
738
+ "additionalItems": false,
739
+ "items": [
740
+ {
741
+ "type": "number"
742
+ },
743
+ {
744
+ "type": "number"
745
+ }
746
+ ],
747
+ "minItems": 2
748
+ },
749
+ "mean": {
750
+ "type": "object",
751
+ "required": ["mean"],
752
+ "properties": {
753
+ "mean": {
754
+ "type": "number"
755
+ },
756
+ "interval": {
757
+ "type": "array",
758
+ "additionalItems": false,
759
+ "items": [
760
+ {
761
+ "type": "number"
762
+ },
763
+ {
764
+ "type": "number"
765
+ }
766
+ ],
767
+ "minItems": 2
768
+ }
769
+ },
770
+ "additionalProperties": false
771
+ },
772
+ "k": {
773
+ "type": "integer",
774
+ "minimum": 2
775
+ },
776
+ "passAll": {
777
+ "type": "integer",
778
+ "minimum": 0
779
+ },
780
+ "passAny": {
781
+ "type": "integer",
782
+ "minimum": 0
783
+ }
784
+ },
785
+ "additionalProperties": false
786
+ },
787
+ "difference": {
788
+ "type": "object",
789
+ "required": ["cases", "mean", "shown"],
790
+ "properties": {
791
+ "cases": {
792
+ "type": "integer",
793
+ "minimum": 0
794
+ },
795
+ "mean": {
796
+ "type": "number"
797
+ },
798
+ "interval": {
799
+ "type": "array",
800
+ "additionalItems": false,
801
+ "items": [
802
+ {
803
+ "type": "number"
804
+ },
805
+ {
806
+ "type": "number"
807
+ }
808
+ ],
809
+ "minItems": 2
810
+ },
811
+ "shown": {
812
+ "type": "boolean"
813
+ }
814
+ },
815
+ "additionalProperties": false
816
+ },
817
+ "path": {
818
+ "type": "string",
819
+ "minLength": 1
820
+ },
821
+ "branch": {
822
+ "anyOf": [
823
+ {
824
+ "type": "string",
825
+ "minLength": 1
826
+ },
827
+ {
828
+ "type": "null"
829
+ }
830
+ ]
831
+ },
832
+ "commit": {
833
+ "anyOf": [
834
+ {
835
+ "type": "string",
836
+ "minLength": 1
837
+ },
838
+ {
839
+ "type": "null"
840
+ }
841
+ ]
842
+ },
843
+ "dirty": {
844
+ "type": "boolean"
845
+ },
846
+ "version": {
847
+ "type": "string",
848
+ "minLength": 1
849
+ },
850
+ "sandbox": {
851
+ "anyOf": [
852
+ {
853
+ "type": "object",
854
+ "required": ["by", "provider", "network"],
855
+ "properties": {
856
+ "by": {
857
+ "type": "string",
858
+ "const": "lab"
859
+ },
860
+ "provider": {
861
+ "type": "string",
862
+ "const": "srt"
863
+ },
864
+ "network": {
865
+ "type": "object",
866
+ "required": ["agents", "code", "webSearch", "sockets"],
867
+ "properties": {
868
+ "agents": {
869
+ "type": "array",
870
+ "items": {
871
+ "type": "string",
872
+ "pattern": "^(\\*\\.)?[A-Za-z0-9-]+(\\.[A-Za-z0-9-]+)*$"
873
+ }
874
+ },
875
+ "code": {
876
+ "type": "array",
877
+ "items": {
878
+ "type": "string",
879
+ "pattern": "^(\\*\\.)?[A-Za-z0-9-]+(\\.[A-Za-z0-9-]+)*$"
880
+ }
881
+ },
882
+ "webSearch": {
883
+ "type": "boolean"
884
+ },
885
+ "sockets": {
886
+ "type": "array",
887
+ "items": {
888
+ "type": "string",
889
+ "minLength": 1
890
+ }
891
+ }
892
+ },
893
+ "additionalProperties": false
894
+ }
895
+ },
896
+ "additionalProperties": false
897
+ },
898
+ {
899
+ "type": "object",
900
+ "required": ["by", "network"],
901
+ "properties": {
902
+ "by": {
903
+ "type": "string",
904
+ "const": "workflow"
905
+ },
906
+ "network": {
907
+ "type": "object",
908
+ "required": ["agents", "code", "webSearch", "sockets"],
909
+ "properties": {
910
+ "agents": {
911
+ "type": "array",
912
+ "items": {
913
+ "type": "string",
914
+ "pattern": "^(\\*\\.)?[A-Za-z0-9-]+(\\.[A-Za-z0-9-]+)*$"
915
+ }
916
+ },
917
+ "code": {
918
+ "type": "array",
919
+ "items": {
920
+ "type": "string",
921
+ "pattern": "^(\\*\\.)?[A-Za-z0-9-]+(\\.[A-Za-z0-9-]+)*$"
922
+ }
923
+ },
924
+ "webSearch": {
925
+ "type": "boolean"
926
+ },
927
+ "sockets": {
928
+ "type": "array",
929
+ "items": {
930
+ "type": "string",
931
+ "minLength": 1
932
+ }
933
+ }
934
+ },
935
+ "additionalProperties": false
936
+ }
937
+ },
938
+ "additionalProperties": false
939
+ }
940
+ ]
941
+ },
942
+ "limits": {
943
+ "type": "object",
944
+ "required": ["setup", "workflow", "after"],
945
+ "properties": {
946
+ "setup": {
947
+ "type": "string",
948
+ "pattern": "^[1-9][0-9]*(ms|s|m|h)$"
949
+ },
950
+ "workflow": {
951
+ "type": "string",
952
+ "pattern": "^[1-9][0-9]*(ms|s|m|h)$"
953
+ },
954
+ "after": {
955
+ "type": "string",
956
+ "pattern": "^[1-9][0-9]*(ms|s|m|h)$"
957
+ }
958
+ },
959
+ "additionalProperties": false
960
+ },
961
+ "params": {
962
+ "type": "object",
963
+ "patternProperties": {
964
+ "^[A-Za-z][A-Za-z0-9_-]*$": {
965
+ "type": "string",
966
+ "minLength": 1
967
+ }
968
+ }
969
+ },
970
+ "sums": {
971
+ "type": "object",
972
+ "required": ["estimate", "reusedEstimate", "gradingEstimate", "unpriced"],
973
+ "properties": {
974
+ "msMedian": {
975
+ "type": "number",
976
+ "minimum": 0
977
+ },
978
+ "estimateMedian": {
979
+ "type": "number",
980
+ "minimum": 0
981
+ },
982
+ "estimate": {
983
+ "type": "number",
984
+ "minimum": 0
985
+ },
986
+ "reusedEstimate": {
987
+ "type": "number",
988
+ "minimum": 0
989
+ },
990
+ "gradingEstimate": {
991
+ "type": "number",
992
+ "minimum": 0
993
+ },
994
+ "unpriced": {
995
+ "type": "boolean"
996
+ }
997
+ },
998
+ "additionalProperties": false
999
+ },
1000
+ "numbers": {
1001
+ "type": "object",
1002
+ "patternProperties": {
1003
+ "^.*$": {
1004
+ "type": "object",
1005
+ "patternProperties": {
1006
+ "^.*$": {
1007
+ "anyOf": [
1008
+ {
1009
+ "type": "object",
1010
+ "required": ["count", "of"],
1011
+ "properties": {
1012
+ "count": {
1013
+ "type": "number",
1014
+ "minimum": 0
1015
+ },
1016
+ "of": {
1017
+ "type": "number",
1018
+ "minimum": 0
1019
+ }
1020
+ },
1021
+ "additionalProperties": false
1022
+ },
1023
+ {
1024
+ "type": "object",
1025
+ "required": ["values"],
1026
+ "properties": {
1027
+ "values": {
1028
+ "type": "array",
1029
+ "items": {
1030
+ "type": "number"
1031
+ }
1032
+ }
1033
+ },
1034
+ "additionalProperties": false
1035
+ }
1036
+ ]
1037
+ }
1038
+ }
1039
+ }
1040
+ }
1041
+ },
1042
+ "numbersLeftOut": {
1043
+ "type": "integer",
1044
+ "minimum": 0
1045
+ },
1046
+ "cases": {
1047
+ "type": "array",
1048
+ "items": {
1049
+ "type": "object",
1050
+ "required": ["name", "verdict", "passed", "trials", "trialIds"],
1051
+ "properties": {
1052
+ "name": {
1053
+ "type": "string",
1054
+ "minLength": 1
1055
+ },
1056
+ "verdict": {
1057
+ "anyOf": [
1058
+ {
1059
+ "enum": ["passed", "failed", "flaky", "unclear"]
1060
+ },
1061
+ {
1062
+ "type": "null"
1063
+ }
1064
+ ]
1065
+ },
1066
+ "passed": {
1067
+ "type": "integer",
1068
+ "minimum": 0
1069
+ },
1070
+ "trials": {
1071
+ "type": "integer",
1072
+ "minimum": 0
1073
+ },
1074
+ "trialIds": {
1075
+ "type": "array",
1076
+ "items": {
1077
+ "type": "string",
1078
+ "minLength": 1
1079
+ }
1080
+ }
1081
+ },
1082
+ "additionalProperties": false
1083
+ }
1084
+ }
1085
+ },
1086
+ "additionalProperties": false
1087
+ }
1088
+ },
1089
+ "trials": {
1090
+ "type": "array",
1091
+ "items": {}
1092
+ },
1093
+ "scored": {
1094
+ "type": "object",
1095
+ "required": ["graded", "errored", "estimate", "stopped"],
1096
+ "properties": {
1097
+ "graded": {
1098
+ "type": "object",
1099
+ "patternProperties": {
1100
+ "^.*$": {
1101
+ "type": "integer",
1102
+ "minimum": 0
1103
+ }
1104
+ }
1105
+ },
1106
+ "errored": {
1107
+ "type": "object",
1108
+ "patternProperties": {
1109
+ "^.*$": {
1110
+ "type": "integer",
1111
+ "minimum": 0
1112
+ }
1113
+ }
1114
+ },
1115
+ "estimate": {
1116
+ "type": "number",
1117
+ "minimum": 0
1118
+ },
1119
+ "stopped": {
1120
+ "type": "boolean"
1121
+ }
1122
+ },
1123
+ "additionalProperties": false
1124
+ }
1125
+ },
1126
+ "additionalProperties": false,
1127
+ "description": "awf-lab run, score and report --json."
1128
+ }