@oneharness/sdk 0.6.10 → 0.6.11
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/dist/generated/contracts.d.ts +14 -7
- package/dist/generated/history-line.d.ts +22 -15
- package/dist/generated/history-records.d.ts +20 -13
- package/dist/generated/history-stream-envelope.d.ts +21 -14
- package/dist/generated/history.d.ts +20 -13
- package/dist/generated/run-stream-envelope.d.ts +14 -7
- package/dist/generated/schemas.json +228 -39
- package/dist/generated/zod.js +144 -40
- package/package.json +2 -2
|
@@ -13,6 +13,12 @@ export type ControlEvent = {
|
|
|
13
13
|
*/
|
|
14
14
|
at: string;
|
|
15
15
|
outcome: "served";
|
|
16
|
+
/**
|
|
17
|
+
* Whether a redirection was committed with the abort. Omitted when it
|
|
18
|
+
* was a plain stop, so an older consumer reads the same record it
|
|
19
|
+
* always did.
|
|
20
|
+
*/
|
|
21
|
+
redirected?: boolean | undefined;
|
|
16
22
|
/**
|
|
17
23
|
* The verb requested.
|
|
18
24
|
*/
|
|
@@ -50,13 +56,14 @@ export type TimingSource = "provider_measured" | "stdout_observed";
|
|
|
50
56
|
* The normalized, closed set of failure reasons oneharness can classify from a
|
|
51
57
|
* harness's output. It is the single source for the `failure_kind` contract
|
|
52
58
|
* value: serialized as the snake_case token a consumer reads in the report
|
|
53
|
-
* (`auth`, `rate_limit`, `model_not_found`, `quota`, `
|
|
54
|
-
* wire shape is unchanged — modeling it as an enum
|
|
55
|
-
* invalid kind unrepresentable and gives every
|
|
56
|
-
* `is_failure`, the fallback fall-through rule,
|
|
57
|
-
* definition to share instead of scattered string
|
|
59
|
+
* (`auth`, `rate_limit`, `model_not_found`, `quota`, `session_not_found`,
|
|
60
|
+
* `tool_deferred`), so the wire shape is unchanged — modeling it as an enum
|
|
61
|
+
* keeps a misspelled or invalid kind unrepresentable and gives every
|
|
62
|
+
* producer/consumer (classifier, `is_failure`, the fallback fall-through rule,
|
|
63
|
+
* the report, history) one definition to share instead of scattered string
|
|
64
|
+
* literals.
|
|
58
65
|
*/
|
|
59
|
-
export type FailureKind = "auth" | "rate_limit" | "model_not_found" | "quota" | "tool_deferred";
|
|
66
|
+
export type FailureKind = "auth" | "rate_limit" | "model_not_found" | "quota" | "session_not_found" | "tool_deferred";
|
|
60
67
|
/**
|
|
61
68
|
* How a harness emits its result, which decides how `text` is extracted.
|
|
62
69
|
*
|
|
@@ -344,7 +351,7 @@ export interface RunResult {
|
|
|
344
351
|
* Best-effort failure reason; `null` when unclassified. Distinct from
|
|
345
352
|
* `status`, which records oneharness's relationship to the process. Two
|
|
346
353
|
* families: coarse reasons for a non-zero run (`auth`, `rate_limit`,
|
|
347
|
-
* `model_not_found`, `quota`), and `tool_deferred` — a run that exited
|
|
354
|
+
* `model_not_found`, `quota`, `session_not_found`), and `tool_deferred` — a run that exited
|
|
348
355
|
* *cleanly* but only deferred a builtin tool call instead of executing it
|
|
349
356
|
* (Claude Code bridge/managed deployments), so it did no useful work. The
|
|
350
357
|
* deferred case is the only `failure_kind` that can appear on a `status: ok`
|
|
@@ -6,7 +6,7 @@ export type HistoryLine = ({
|
|
|
6
6
|
harness: string;
|
|
7
7
|
harness_id?: string | null | undefined;
|
|
8
8
|
run_id: string;
|
|
9
|
-
schema_version: "1.2" | "1.3" | "1.4";
|
|
9
|
+
schema_version: "1.2" | "1.3" | "1.4" | "1.5";
|
|
10
10
|
type: "event";
|
|
11
11
|
variant?: string | null | undefined;
|
|
12
12
|
[k: string]: unknown;
|
|
@@ -27,7 +27,7 @@ export type HistoryLine = ({
|
|
|
27
27
|
[k: string]: unknown;
|
|
28
28
|
} | ({
|
|
29
29
|
error: string;
|
|
30
|
-
schema_version?: "1.3" | "1.4" | undefined;
|
|
30
|
+
schema_version?: "1.3" | "1.4" | "1.5" | undefined;
|
|
31
31
|
[k: string]: unknown;
|
|
32
32
|
} & ({
|
|
33
33
|
status?: "nonzero" | "timeout" | "cancelled" | "spawn-error" | "skipped" | undefined;
|
|
@@ -39,7 +39,13 @@ export type HistoryLine = ({
|
|
|
39
39
|
status?: "ok" | "nonzero" | "timeout" | "spawn-error" | "skipped" | "planned" | undefined;
|
|
40
40
|
[k: string]: unknown;
|
|
41
41
|
} | {
|
|
42
|
-
schema_version?: "1.4" | undefined;
|
|
42
|
+
schema_version?: "1.4" | "1.5" | undefined;
|
|
43
|
+
[k: string]: unknown;
|
|
44
|
+
}) & ({
|
|
45
|
+
failure_kind?: "auth" | "rate_limit" | "model_not_found" | "quota" | "tool_deferred" | null | undefined;
|
|
46
|
+
[k: string]: unknown;
|
|
47
|
+
} | {
|
|
48
|
+
schema_version?: "1.5" | undefined;
|
|
43
49
|
[k: string]: unknown;
|
|
44
50
|
}) & ({
|
|
45
51
|
duration_ms: number;
|
|
@@ -62,7 +68,7 @@ export type HistoryLine = ({
|
|
|
62
68
|
permission_mode: PermissionMode;
|
|
63
69
|
project: string;
|
|
64
70
|
prompt: string;
|
|
65
|
-
schema_version: "1.0" | "1.1" | "1.2" | "1.3" | "1.4";
|
|
71
|
+
schema_version: "1.0" | "1.1" | "1.2" | "1.3" | "1.4" | "1.5";
|
|
66
72
|
session: string;
|
|
67
73
|
session_id: string | null;
|
|
68
74
|
started_at: string;
|
|
@@ -97,7 +103,7 @@ export type HistoryLine = ({
|
|
|
97
103
|
permission_mode: PermissionMode;
|
|
98
104
|
project: string;
|
|
99
105
|
prompt: string;
|
|
100
|
-
schema_version: "1.0" | "1.1" | "1.2" | "1.3" | "1.4";
|
|
106
|
+
schema_version: "1.0" | "1.1" | "1.2" | "1.3" | "1.4" | "1.5";
|
|
101
107
|
session: string;
|
|
102
108
|
session_id: string | null;
|
|
103
109
|
started_at: string;
|
|
@@ -132,7 +138,7 @@ export type HistoryLine = ({
|
|
|
132
138
|
permission_mode: PermissionMode;
|
|
133
139
|
project: string;
|
|
134
140
|
prompt: string;
|
|
135
|
-
schema_version: "1.2" | "1.3" | "1.4";
|
|
141
|
+
schema_version: "1.2" | "1.3" | "1.4" | "1.5";
|
|
136
142
|
session: string;
|
|
137
143
|
session_id: string | null;
|
|
138
144
|
started_at?: never | undefined;
|
|
@@ -167,7 +173,7 @@ export type HistoryLine = ({
|
|
|
167
173
|
permission_mode: PermissionMode;
|
|
168
174
|
project: string;
|
|
169
175
|
prompt: string;
|
|
170
|
-
schema_version: "1.0" | "1.1" | "1.2" | "1.3" | "1.4";
|
|
176
|
+
schema_version: "1.0" | "1.1" | "1.2" | "1.3" | "1.4" | "1.5";
|
|
171
177
|
session: string;
|
|
172
178
|
session_id: string | null;
|
|
173
179
|
started_at?: never | undefined;
|
|
@@ -202,7 +208,7 @@ export type HistoryLine = ({
|
|
|
202
208
|
permission_mode: PermissionMode;
|
|
203
209
|
project: string;
|
|
204
210
|
prompt: string;
|
|
205
|
-
schema_version: "1.3" | "1.4";
|
|
211
|
+
schema_version: "1.3" | "1.4" | "1.5";
|
|
206
212
|
session: string;
|
|
207
213
|
session_id: string | null;
|
|
208
214
|
started_at: string;
|
|
@@ -237,7 +243,7 @@ export type HistoryLine = ({
|
|
|
237
243
|
permission_mode: PermissionMode;
|
|
238
244
|
project: string;
|
|
239
245
|
prompt: string;
|
|
240
|
-
schema_version: "1.0" | "1.1" | "1.2" | "1.3" | "1.4";
|
|
246
|
+
schema_version: "1.0" | "1.1" | "1.2" | "1.3" | "1.4" | "1.5";
|
|
241
247
|
session: string;
|
|
242
248
|
session_id: string | null;
|
|
243
249
|
started_at?: never | undefined;
|
|
@@ -261,13 +267,14 @@ export type TimingSource = "provider_measured" | "stdout_observed";
|
|
|
261
267
|
* The normalized, closed set of failure reasons oneharness can classify from a
|
|
262
268
|
* harness's output. It is the single source for the `failure_kind` contract
|
|
263
269
|
* value: serialized as the snake_case token a consumer reads in the report
|
|
264
|
-
* (`auth`, `rate_limit`, `model_not_found`, `quota`, `
|
|
265
|
-
* wire shape is unchanged — modeling it as an enum
|
|
266
|
-
* invalid kind unrepresentable and gives every
|
|
267
|
-
* `is_failure`, the fallback fall-through rule,
|
|
268
|
-
* definition to share instead of scattered string
|
|
270
|
+
* (`auth`, `rate_limit`, `model_not_found`, `quota`, `session_not_found`,
|
|
271
|
+
* `tool_deferred`), so the wire shape is unchanged — modeling it as an enum
|
|
272
|
+
* keeps a misspelled or invalid kind unrepresentable and gives every
|
|
273
|
+
* producer/consumer (classifier, `is_failure`, the fallback fall-through rule,
|
|
274
|
+
* the report, history) one definition to share instead of scattered string
|
|
275
|
+
* literals.
|
|
269
276
|
*/
|
|
270
|
-
export type FailureKind = "auth" | "rate_limit" | "model_not_found" | "quota" | "tool_deferred";
|
|
277
|
+
export type FailureKind = "auth" | "rate_limit" | "model_not_found" | "quota" | "session_not_found" | "tool_deferred";
|
|
271
278
|
/**
|
|
272
279
|
* The unified approval mode, from least to most autonomy. A harness may not
|
|
273
280
|
* support every value (see [`crate::domain::harness::HarnessSpec::mode`]); the
|
|
@@ -93,7 +93,7 @@ export type HistoryRecord = {
|
|
|
93
93
|
* run's single prompt).
|
|
94
94
|
*/
|
|
95
95
|
prompt: string;
|
|
96
|
-
schema_version: "1.2" | "1.3" | "1.4";
|
|
96
|
+
schema_version: "1.2" | "1.3" | "1.4" | "1.5";
|
|
97
97
|
/**
|
|
98
98
|
* The oneharness session id this run belongs to (the history file's stem).
|
|
99
99
|
*/
|
|
@@ -323,7 +323,7 @@ export type HistoryRecord = {
|
|
|
323
323
|
* run's single prompt).
|
|
324
324
|
*/
|
|
325
325
|
prompt: string;
|
|
326
|
-
schema_version: "1.2" | "1.3" | "1.4";
|
|
326
|
+
schema_version: "1.2" | "1.3" | "1.4" | "1.5";
|
|
327
327
|
/**
|
|
328
328
|
* The oneharness session id this run belongs to (the history file's stem).
|
|
329
329
|
*/
|
|
@@ -415,7 +415,7 @@ export type HistoryRecord = {
|
|
|
415
415
|
* run's single prompt).
|
|
416
416
|
*/
|
|
417
417
|
prompt: string;
|
|
418
|
-
schema_version: "1.2" | "1.3" | "1.4";
|
|
418
|
+
schema_version: "1.2" | "1.3" | "1.4" | "1.5";
|
|
419
419
|
/**
|
|
420
420
|
* The oneharness session id this run belongs to (the history file's stem).
|
|
421
421
|
*/
|
|
@@ -507,7 +507,7 @@ export type HistoryRecord = {
|
|
|
507
507
|
* run's single prompt).
|
|
508
508
|
*/
|
|
509
509
|
prompt: string;
|
|
510
|
-
schema_version: "1.2" | "1.3" | "1.4";
|
|
510
|
+
schema_version: "1.2" | "1.3" | "1.4" | "1.5";
|
|
511
511
|
/**
|
|
512
512
|
* The oneharness session id this run belongs to (the history file's stem).
|
|
513
513
|
*/
|
|
@@ -599,7 +599,7 @@ export type HistoryRecord = {
|
|
|
599
599
|
* run's single prompt).
|
|
600
600
|
*/
|
|
601
601
|
prompt: string;
|
|
602
|
-
schema_version: "1.3" | "1.4";
|
|
602
|
+
schema_version: "1.3" | "1.4" | "1.5";
|
|
603
603
|
/**
|
|
604
604
|
* The oneharness session id this run belongs to (the history file's stem).
|
|
605
605
|
*/
|
|
@@ -944,13 +944,14 @@ export type TimingSource = "provider_measured" | "stdout_observed";
|
|
|
944
944
|
* The normalized, closed set of failure reasons oneharness can classify from a
|
|
945
945
|
* harness's output. It is the single source for the `failure_kind` contract
|
|
946
946
|
* value: serialized as the snake_case token a consumer reads in the report
|
|
947
|
-
* (`auth`, `rate_limit`, `model_not_found`, `quota`, `
|
|
948
|
-
* wire shape is unchanged — modeling it as an enum
|
|
949
|
-
* invalid kind unrepresentable and gives every
|
|
950
|
-
* `is_failure`, the fallback fall-through rule,
|
|
951
|
-
* definition to share instead of scattered string
|
|
947
|
+
* (`auth`, `rate_limit`, `model_not_found`, `quota`, `session_not_found`,
|
|
948
|
+
* `tool_deferred`), so the wire shape is unchanged — modeling it as an enum
|
|
949
|
+
* keeps a misspelled or invalid kind unrepresentable and gives every
|
|
950
|
+
* producer/consumer (classifier, `is_failure`, the fallback fall-through rule,
|
|
951
|
+
* the report, history) one definition to share instead of scattered string
|
|
952
|
+
* literals.
|
|
952
953
|
*/
|
|
953
|
-
export type FailureKind = "auth" | "rate_limit" | "model_not_found" | "quota" | "tool_deferred";
|
|
954
|
+
export type FailureKind = "auth" | "rate_limit" | "model_not_found" | "quota" | "session_not_found" | "tool_deferred";
|
|
954
955
|
/**
|
|
955
956
|
* The outcome of attempting to run one harness.
|
|
956
957
|
*/
|
|
@@ -960,7 +961,7 @@ export type HistoryRecords = (({
|
|
|
960
961
|
[k: string]: unknown;
|
|
961
962
|
} | ({
|
|
962
963
|
error: string;
|
|
963
|
-
schema_version?: "1.3" | "1.4" | undefined;
|
|
964
|
+
schema_version?: "1.3" | "1.4" | "1.5" | undefined;
|
|
964
965
|
[k: string]: unknown;
|
|
965
966
|
} & ({
|
|
966
967
|
status?: "nonzero" | "timeout" | "cancelled" | "spawn-error" | "skipped" | undefined;
|
|
@@ -972,7 +973,13 @@ export type HistoryRecords = (({
|
|
|
972
973
|
status?: "ok" | "nonzero" | "timeout" | "spawn-error" | "skipped" | "planned" | undefined;
|
|
973
974
|
[k: string]: unknown;
|
|
974
975
|
} | {
|
|
975
|
-
schema_version?: "1.4" | undefined;
|
|
976
|
+
schema_version?: "1.4" | "1.5" | undefined;
|
|
977
|
+
[k: string]: unknown;
|
|
978
|
+
}) & ({
|
|
979
|
+
failure_kind?: "auth" | "rate_limit" | "model_not_found" | "quota" | "tool_deferred" | null | undefined;
|
|
980
|
+
[k: string]: unknown;
|
|
981
|
+
} | {
|
|
982
|
+
schema_version?: "1.5" | undefined;
|
|
976
983
|
[k: string]: unknown;
|
|
977
984
|
}) & HistoryRecord)[];
|
|
978
985
|
/**
|
|
@@ -14,7 +14,7 @@ export type HistoryStreamEnvelope = {
|
|
|
14
14
|
[k: string]: unknown;
|
|
15
15
|
} | ({
|
|
16
16
|
error: string;
|
|
17
|
-
schema_version?: "1.3" | "1.4" | undefined;
|
|
17
|
+
schema_version?: "1.3" | "1.4" | "1.5" | undefined;
|
|
18
18
|
[k: string]: unknown;
|
|
19
19
|
} & ({
|
|
20
20
|
status?: "nonzero" | "timeout" | "cancelled" | "spawn-error" | "skipped" | undefined;
|
|
@@ -26,7 +26,13 @@ export type HistoryStreamEnvelope = {
|
|
|
26
26
|
status?: "ok" | "nonzero" | "timeout" | "spawn-error" | "skipped" | "planned" | undefined;
|
|
27
27
|
[k: string]: unknown;
|
|
28
28
|
} | {
|
|
29
|
-
schema_version?: "1.4" | undefined;
|
|
29
|
+
schema_version?: "1.4" | "1.5" | undefined;
|
|
30
|
+
[k: string]: unknown;
|
|
31
|
+
}) & ({
|
|
32
|
+
failure_kind?: "auth" | "rate_limit" | "model_not_found" | "quota" | "tool_deferred" | null | undefined;
|
|
33
|
+
[k: string]: unknown;
|
|
34
|
+
} | {
|
|
35
|
+
schema_version?: "1.5" | undefined;
|
|
30
36
|
[k: string]: unknown;
|
|
31
37
|
}) & HistoryRecord;
|
|
32
38
|
type: "record";
|
|
@@ -131,7 +137,7 @@ export type HistoryRecord = {
|
|
|
131
137
|
* run's single prompt).
|
|
132
138
|
*/
|
|
133
139
|
prompt: string;
|
|
134
|
-
schema_version: "1.2" | "1.3" | "1.4";
|
|
140
|
+
schema_version: "1.2" | "1.3" | "1.4" | "1.5";
|
|
135
141
|
/**
|
|
136
142
|
* The oneharness session id this run belongs to (the history file's stem).
|
|
137
143
|
*/
|
|
@@ -361,7 +367,7 @@ export type HistoryRecord = {
|
|
|
361
367
|
* run's single prompt).
|
|
362
368
|
*/
|
|
363
369
|
prompt: string;
|
|
364
|
-
schema_version: "1.2" | "1.3" | "1.4";
|
|
370
|
+
schema_version: "1.2" | "1.3" | "1.4" | "1.5";
|
|
365
371
|
/**
|
|
366
372
|
* The oneharness session id this run belongs to (the history file's stem).
|
|
367
373
|
*/
|
|
@@ -453,7 +459,7 @@ export type HistoryRecord = {
|
|
|
453
459
|
* run's single prompt).
|
|
454
460
|
*/
|
|
455
461
|
prompt: string;
|
|
456
|
-
schema_version: "1.2" | "1.3" | "1.4";
|
|
462
|
+
schema_version: "1.2" | "1.3" | "1.4" | "1.5";
|
|
457
463
|
/**
|
|
458
464
|
* The oneharness session id this run belongs to (the history file's stem).
|
|
459
465
|
*/
|
|
@@ -545,7 +551,7 @@ export type HistoryRecord = {
|
|
|
545
551
|
* run's single prompt).
|
|
546
552
|
*/
|
|
547
553
|
prompt: string;
|
|
548
|
-
schema_version: "1.2" | "1.3" | "1.4";
|
|
554
|
+
schema_version: "1.2" | "1.3" | "1.4" | "1.5";
|
|
549
555
|
/**
|
|
550
556
|
* The oneharness session id this run belongs to (the history file's stem).
|
|
551
557
|
*/
|
|
@@ -637,7 +643,7 @@ export type HistoryRecord = {
|
|
|
637
643
|
* run's single prompt).
|
|
638
644
|
*/
|
|
639
645
|
prompt: string;
|
|
640
|
-
schema_version: "1.3" | "1.4";
|
|
646
|
+
schema_version: "1.3" | "1.4" | "1.5";
|
|
641
647
|
/**
|
|
642
648
|
* The oneharness session id this run belongs to (the history file's stem).
|
|
643
649
|
*/
|
|
@@ -982,13 +988,14 @@ export type TimingSource = "provider_measured" | "stdout_observed";
|
|
|
982
988
|
* The normalized, closed set of failure reasons oneharness can classify from a
|
|
983
989
|
* harness's output. It is the single source for the `failure_kind` contract
|
|
984
990
|
* value: serialized as the snake_case token a consumer reads in the report
|
|
985
|
-
* (`auth`, `rate_limit`, `model_not_found`, `quota`, `
|
|
986
|
-
* wire shape is unchanged — modeling it as an enum
|
|
987
|
-
* invalid kind unrepresentable and gives every
|
|
988
|
-
* `is_failure`, the fallback fall-through rule,
|
|
989
|
-
* definition to share instead of scattered string
|
|
991
|
+
* (`auth`, `rate_limit`, `model_not_found`, `quota`, `session_not_found`,
|
|
992
|
+
* `tool_deferred`), so the wire shape is unchanged — modeling it as an enum
|
|
993
|
+
* keeps a misspelled or invalid kind unrepresentable and gives every
|
|
994
|
+
* producer/consumer (classifier, `is_failure`, the fallback fall-through rule,
|
|
995
|
+
* the report, history) one definition to share instead of scattered string
|
|
996
|
+
* literals.
|
|
990
997
|
*/
|
|
991
|
-
export type FailureKind = "auth" | "rate_limit" | "model_not_found" | "quota" | "tool_deferred";
|
|
998
|
+
export type FailureKind = "auth" | "rate_limit" | "model_not_found" | "quota" | "session_not_found" | "tool_deferred";
|
|
992
999
|
/**
|
|
993
1000
|
* The outcome of attempting to run one harness.
|
|
994
1001
|
*/
|
|
@@ -998,7 +1005,7 @@ export type HistoryEventLine = {
|
|
|
998
1005
|
harness: string;
|
|
999
1006
|
harness_id?: string | null | undefined;
|
|
1000
1007
|
run_id: string;
|
|
1001
|
-
schema_version: "1.2" | "1.3" | "1.4";
|
|
1008
|
+
schema_version: "1.2" | "1.3" | "1.4" | "1.5";
|
|
1002
1009
|
variant?: string | null | undefined;
|
|
1003
1010
|
[k: string]: unknown;
|
|
1004
1011
|
} | {
|
|
@@ -8,7 +8,7 @@ export type HistoryRecord = ({
|
|
|
8
8
|
[k: string]: unknown;
|
|
9
9
|
} | ({
|
|
10
10
|
error: string;
|
|
11
|
-
schema_version?: "1.3" | "1.4" | undefined;
|
|
11
|
+
schema_version?: "1.3" | "1.4" | "1.5" | undefined;
|
|
12
12
|
[k: string]: unknown;
|
|
13
13
|
} & ({
|
|
14
14
|
status?: "nonzero" | "timeout" | "cancelled" | "spawn-error" | "skipped" | undefined;
|
|
@@ -20,7 +20,13 @@ export type HistoryRecord = ({
|
|
|
20
20
|
status?: "ok" | "nonzero" | "timeout" | "spawn-error" | "skipped" | "planned" | undefined;
|
|
21
21
|
[k: string]: unknown;
|
|
22
22
|
} | {
|
|
23
|
-
schema_version?: "1.4" | undefined;
|
|
23
|
+
schema_version?: "1.4" | "1.5" | undefined;
|
|
24
|
+
[k: string]: unknown;
|
|
25
|
+
}) & ({
|
|
26
|
+
failure_kind?: "auth" | "rate_limit" | "model_not_found" | "quota" | "tool_deferred" | null | undefined;
|
|
27
|
+
[k: string]: unknown;
|
|
28
|
+
} | {
|
|
29
|
+
schema_version?: "1.5" | undefined;
|
|
24
30
|
[k: string]: unknown;
|
|
25
31
|
}) & ({
|
|
26
32
|
duration_ms: number;
|
|
@@ -117,7 +123,7 @@ export type HistoryRecord = ({
|
|
|
117
123
|
* run's single prompt).
|
|
118
124
|
*/
|
|
119
125
|
prompt: string;
|
|
120
|
-
schema_version: "1.2" | "1.3" | "1.4";
|
|
126
|
+
schema_version: "1.2" | "1.3" | "1.4" | "1.5";
|
|
121
127
|
/**
|
|
122
128
|
* The oneharness session id this run belongs to (the history file's stem).
|
|
123
129
|
*/
|
|
@@ -347,7 +353,7 @@ export type HistoryRecord = ({
|
|
|
347
353
|
* run's single prompt).
|
|
348
354
|
*/
|
|
349
355
|
prompt: string;
|
|
350
|
-
schema_version: "1.2" | "1.3" | "1.4";
|
|
356
|
+
schema_version: "1.2" | "1.3" | "1.4" | "1.5";
|
|
351
357
|
/**
|
|
352
358
|
* The oneharness session id this run belongs to (the history file's stem).
|
|
353
359
|
*/
|
|
@@ -439,7 +445,7 @@ export type HistoryRecord = ({
|
|
|
439
445
|
* run's single prompt).
|
|
440
446
|
*/
|
|
441
447
|
prompt: string;
|
|
442
|
-
schema_version: "1.2" | "1.3" | "1.4";
|
|
448
|
+
schema_version: "1.2" | "1.3" | "1.4" | "1.5";
|
|
443
449
|
/**
|
|
444
450
|
* The oneharness session id this run belongs to (the history file's stem).
|
|
445
451
|
*/
|
|
@@ -531,7 +537,7 @@ export type HistoryRecord = ({
|
|
|
531
537
|
* run's single prompt).
|
|
532
538
|
*/
|
|
533
539
|
prompt: string;
|
|
534
|
-
schema_version: "1.2" | "1.3" | "1.4";
|
|
540
|
+
schema_version: "1.2" | "1.3" | "1.4" | "1.5";
|
|
535
541
|
/**
|
|
536
542
|
* The oneharness session id this run belongs to (the history file's stem).
|
|
537
543
|
*/
|
|
@@ -623,7 +629,7 @@ export type HistoryRecord = ({
|
|
|
623
629
|
* run's single prompt).
|
|
624
630
|
*/
|
|
625
631
|
prompt: string;
|
|
626
|
-
schema_version: "1.3" | "1.4";
|
|
632
|
+
schema_version: "1.3" | "1.4" | "1.5";
|
|
627
633
|
/**
|
|
628
634
|
* The oneharness session id this run belongs to (the history file's stem).
|
|
629
635
|
*/
|
|
@@ -968,13 +974,14 @@ export type TimingSource = "provider_measured" | "stdout_observed";
|
|
|
968
974
|
* The normalized, closed set of failure reasons oneharness can classify from a
|
|
969
975
|
* harness's output. It is the single source for the `failure_kind` contract
|
|
970
976
|
* value: serialized as the snake_case token a consumer reads in the report
|
|
971
|
-
* (`auth`, `rate_limit`, `model_not_found`, `quota`, `
|
|
972
|
-
* wire shape is unchanged — modeling it as an enum
|
|
973
|
-
* invalid kind unrepresentable and gives every
|
|
974
|
-
* `is_failure`, the fallback fall-through rule,
|
|
975
|
-
* definition to share instead of scattered string
|
|
977
|
+
* (`auth`, `rate_limit`, `model_not_found`, `quota`, `session_not_found`,
|
|
978
|
+
* `tool_deferred`), so the wire shape is unchanged — modeling it as an enum
|
|
979
|
+
* keeps a misspelled or invalid kind unrepresentable and gives every
|
|
980
|
+
* producer/consumer (classifier, `is_failure`, the fallback fall-through rule,
|
|
981
|
+
* the report, history) one definition to share instead of scattered string
|
|
982
|
+
* literals.
|
|
976
983
|
*/
|
|
977
|
-
export type FailureKind = "auth" | "rate_limit" | "model_not_found" | "quota" | "tool_deferred";
|
|
984
|
+
export type FailureKind = "auth" | "rate_limit" | "model_not_found" | "quota" | "session_not_found" | "tool_deferred";
|
|
978
985
|
/**
|
|
979
986
|
* The outcome of attempting to run one harness.
|
|
980
987
|
*/
|
|
@@ -35,6 +35,12 @@ export type ControlEvent = {
|
|
|
35
35
|
*/
|
|
36
36
|
at: string;
|
|
37
37
|
outcome: "served";
|
|
38
|
+
/**
|
|
39
|
+
* Whether a redirection was committed with the abort. Omitted when it
|
|
40
|
+
* was a plain stop, so an older consumer reads the same record it
|
|
41
|
+
* always did.
|
|
42
|
+
*/
|
|
43
|
+
redirected?: boolean | undefined;
|
|
38
44
|
/**
|
|
39
45
|
* The verb requested.
|
|
40
46
|
*/
|
|
@@ -67,13 +73,14 @@ export type ControlVerb = "interrupt";
|
|
|
67
73
|
* The normalized, closed set of failure reasons oneharness can classify from a
|
|
68
74
|
* harness's output. It is the single source for the `failure_kind` contract
|
|
69
75
|
* value: serialized as the snake_case token a consumer reads in the report
|
|
70
|
-
* (`auth`, `rate_limit`, `model_not_found`, `quota`, `
|
|
71
|
-
* wire shape is unchanged — modeling it as an enum
|
|
72
|
-
* invalid kind unrepresentable and gives every
|
|
73
|
-
* `is_failure`, the fallback fall-through rule,
|
|
74
|
-
* definition to share instead of scattered string
|
|
76
|
+
* (`auth`, `rate_limit`, `model_not_found`, `quota`, `session_not_found`,
|
|
77
|
+
* `tool_deferred`), so the wire shape is unchanged — modeling it as an enum
|
|
78
|
+
* keeps a misspelled or invalid kind unrepresentable and gives every
|
|
79
|
+
* producer/consumer (classifier, `is_failure`, the fallback fall-through rule,
|
|
80
|
+
* the report, history) one definition to share instead of scattered string
|
|
81
|
+
* literals.
|
|
75
82
|
*/
|
|
76
|
-
export type FailureKind = "auth" | "rate_limit" | "model_not_found" | "quota" | "tool_deferred";
|
|
83
|
+
export type FailureKind = "auth" | "rate_limit" | "model_not_found" | "quota" | "session_not_found" | "tool_deferred";
|
|
77
84
|
/**
|
|
78
85
|
* How a harness emits its result, which decides how `text` is extracted.
|
|
79
86
|
*
|
|
@@ -418,7 +425,7 @@ export interface RunResult {
|
|
|
418
425
|
* Best-effort failure reason; `null` when unclassified. Distinct from
|
|
419
426
|
* `status`, which records oneharness's relationship to the process. Two
|
|
420
427
|
* families: coarse reasons for a non-zero run (`auth`, `rate_limit`,
|
|
421
|
-
* `model_not_found`, `quota`), and `tool_deferred` — a run that exited
|
|
428
|
+
* `model_not_found`, `quota`, `session_not_found`), and `tool_deferred` — a run that exited
|
|
422
429
|
* *cleanly* but only deferred a builtin tool call instead of executing it
|
|
423
430
|
* (Claude Code bridge/managed deployments), so it did no useful work. The
|
|
424
431
|
* deferred case is the only `failure_kind` that can appear on a `status: ok`
|