@vitest-agent/sdk 2.5.0 → 3.0.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.
package/index.d.ts CHANGED
@@ -9,19 +9,19 @@ import { ChildProcessSpawner } from "effect/unstable/process";
9
9
  * Aggregate coverage percentages across four istanbul metrics.
10
10
  * @public
11
11
  */
12
- declare const CoverageTotals: Schema.Struct<{
12
+ export declare const CoverageTotals: Schema.Struct<{
13
13
  readonly statements: Schema.Number;
14
14
  readonly branches: Schema.Number;
15
15
  readonly functions: Schema.Number;
16
16
  readonly lines: Schema.Number;
17
17
  }>;
18
18
  /** @public */
19
- type CoverageTotals = typeof CoverageTotals.Type;
19
+ export type CoverageTotals = typeof CoverageTotals.Type;
20
20
  /**
21
21
  * Per-file coverage data including uncovered line ranges.
22
22
  * @public
23
23
  */
24
- declare const FileCoverageReport: Schema.Struct<{
24
+ export declare const FileCoverageReport: Schema.Struct<{
25
25
  readonly file: Schema.String;
26
26
  readonly summary: Schema.Struct<{
27
27
  readonly statements: Schema.Number;
@@ -32,12 +32,12 @@ declare const FileCoverageReport: Schema.Struct<{
32
32
  readonly uncoveredLines: Schema.String;
33
33
  }>;
34
34
  /** @public */
35
- type FileCoverageReport = typeof FileCoverageReport.Type;
35
+ export type FileCoverageReport = typeof FileCoverageReport.Type;
36
36
  /**
37
37
  * Complete coverage report attached to an AgentReport.
38
38
  * @public
39
39
  */
40
- declare const CoverageReport: Schema.Struct<{
40
+ export declare const CoverageReport: Schema.Struct<{
41
41
  readonly totals: Schema.Struct<{
42
42
  readonly statements: Schema.Number;
43
43
  readonly branches: Schema.Number;
@@ -56,6 +56,12 @@ declare const CoverageReport: Schema.Struct<{
56
56
  readonly functions: Schema.optional<Schema.Number>;
57
57
  readonly branches: Schema.optional<Schema.Number>;
58
58
  readonly statements: Schema.optional<Schema.Number>;
59
+ readonly perFile: Schema.optionalKey<Schema.Union<readonly [Schema.Boolean, Schema.Struct<{
60
+ readonly lines: Schema.optional<Schema.Number>;
61
+ readonly functions: Schema.optional<Schema.Number>;
62
+ readonly branches: Schema.optional<Schema.Number>;
63
+ readonly statements: Schema.optional<Schema.Number>;
64
+ }>]>>;
59
65
  }>]>>, never>;
60
66
  }>;
61
67
  readonly targets: Schema.optional<Schema.Struct<{
@@ -70,6 +76,12 @@ declare const CoverageReport: Schema.Struct<{
70
76
  readonly functions: Schema.optional<Schema.Number>;
71
77
  readonly branches: Schema.optional<Schema.Number>;
72
78
  readonly statements: Schema.optional<Schema.Number>;
79
+ readonly perFile: Schema.optionalKey<Schema.Union<readonly [Schema.Boolean, Schema.Struct<{
80
+ readonly lines: Schema.optional<Schema.Number>;
81
+ readonly functions: Schema.optional<Schema.Number>;
82
+ readonly branches: Schema.optional<Schema.Number>;
83
+ readonly statements: Schema.optional<Schema.Number>;
84
+ }>]>>;
73
85
  }>]>>, never>;
74
86
  }>>;
75
87
  readonly baselines: Schema.optional<Schema.Struct<{
@@ -84,6 +96,12 @@ declare const CoverageReport: Schema.Struct<{
84
96
  readonly functions: Schema.optional<Schema.Number>;
85
97
  readonly branches: Schema.optional<Schema.Number>;
86
98
  readonly statements: Schema.optional<Schema.Number>;
99
+ readonly perFile: Schema.optionalKey<Schema.Union<readonly [Schema.Boolean, Schema.Struct<{
100
+ readonly lines: Schema.optional<Schema.Number>;
101
+ readonly functions: Schema.optional<Schema.Number>;
102
+ readonly branches: Schema.optional<Schema.Number>;
103
+ readonly statements: Schema.optional<Schema.Number>;
104
+ }>]>>;
87
105
  }>]>>, never>;
88
106
  }>>;
89
107
  readonly scoped: Schema.withDecodingDefaultKey<Schema.Boolean, never>;
@@ -113,14 +131,14 @@ declare const CoverageReport: Schema.Struct<{
113
131
  readonly belowTargetFiles: Schema.optional<Schema.$Array<Schema.String>>;
114
132
  }>;
115
133
  /** @public */
116
- type CoverageReport = typeof CoverageReport.Type;
134
+ export type CoverageReport = typeof CoverageReport.Type;
117
135
  //#endregion
118
136
  //#region src/schemas/RenderState.d.ts
119
137
  /**
120
138
  * Per-test record accumulated as `TestStarted` / `TestFinished` events arrive.
121
139
  * @public
122
140
  */
123
- declare const TestRecord: Schema.Struct<{
141
+ export declare const TestRecord: Schema.Struct<{
124
142
  readonly testName: Schema.String;
125
143
  readonly suitePath: Schema.$Array<Schema.String>;
126
144
  readonly status: Schema.Union<readonly [Schema.Literals<readonly ["passed", "failed", "skipped", "pending"]>, Schema.Literals<readonly ["running", "timed-out"]>]>;
@@ -134,13 +152,13 @@ declare const TestRecord: Schema.Struct<{
134
152
  }>>;
135
153
  }>;
136
154
  /** @public */
137
- type TestRecord = typeof TestRecord.Type;
155
+ export type TestRecord = typeof TestRecord.Type;
138
156
  /**
139
157
  * Per-module aggregation. The reducer keeps modules keyed on
140
158
  * `modulePath` so out-of-order events can update the right slot.
141
159
  * @public
142
160
  */
143
- declare const ModuleRecord: Schema.Struct<{
161
+ export declare const ModuleRecord: Schema.Struct<{
144
162
  readonly modulePath: Schema.String;
145
163
  readonly status: Schema.Literals<readonly ["queued", "running", "finished"]>;
146
164
  readonly passCount: Schema.Number;
@@ -177,14 +195,14 @@ declare const ModuleRecord: Schema.Struct<{
177
195
  readonly tagCounts: Schema.optional<Schema.$Record<Schema.String, Schema.Number>>;
178
196
  }>;
179
197
  /** @public */
180
- type ModuleRecord = typeof ModuleRecord.Type;
198
+ export type ModuleRecord = typeof ModuleRecord.Type;
181
199
  /**
182
200
  * One row in the failure list. A failure can exist before its
183
201
  * classification arrives (`FailureClassified` is emitted from a
184
202
  * separate pipeline), so `classification` is nullable.
185
203
  * @public
186
204
  */
187
- declare const FailureRecord: Schema.Struct<{
205
+ export declare const FailureRecord: Schema.Struct<{
188
206
  readonly modulePath: Schema.String;
189
207
  readonly testName: Schema.String;
190
208
  readonly suitePath: Schema.$Array<Schema.String>;
@@ -199,13 +217,13 @@ declare const FailureRecord: Schema.Struct<{
199
217
  readonly classification: Schema.NullOr<Schema.Literals<readonly ["stable", "new-failure", "persistent", "flaky", "recovered"]>>;
200
218
  }>;
201
219
  /** @public */
202
- type FailureRecord = typeof FailureRecord.Type;
220
+ export type FailureRecord = typeof FailureRecord.Type;
203
221
  /**
204
222
  * Coverage block, populated only after `CoverageReady`. Threshold
205
223
  * violations are accumulated separately as they arrive.
206
224
  * @public
207
225
  */
208
- declare const CoverageRenderState: Schema.Struct<{
226
+ export declare const CoverageRenderState: Schema.Struct<{
209
227
  readonly metrics: Schema.Struct<{
210
228
  readonly statements: Schema.Number;
211
229
  readonly branches: Schema.Number;
@@ -238,25 +256,25 @@ declare const CoverageRenderState: Schema.Struct<{
238
256
  readonly totalFiles: Schema.optional<Schema.Number>;
239
257
  }>;
240
258
  /** @public */
241
- type CoverageRenderState = typeof CoverageRenderState.Type;
259
+ export type CoverageRenderState = typeof CoverageRenderState.Type;
242
260
  /**
243
261
  * A `SuggestedAction` event, denormalized into the queue the renderer reads.
244
262
  * @public
245
263
  */
246
- declare const SuggestedActionRecord: Schema.Struct<{
264
+ export declare const SuggestedActionRecord: Schema.Struct<{
247
265
  readonly severity: Schema.Literals<readonly ["info", "warn", "blocker"]>;
248
266
  readonly title: Schema.String;
249
267
  readonly detail: Schema.String;
250
268
  readonly targetTool: Schema.optional<Schema.String>;
251
269
  }>;
252
270
  /** @public */
253
- type SuggestedActionRecord = typeof SuggestedActionRecord.Type;
271
+ export type SuggestedActionRecord = typeof SuggestedActionRecord.Type;
254
272
  /**
255
273
  * Per-run totals, recomputed on every `ModuleFinished` and reconciled
256
274
  * against `RunFinished` (which carries the runner's own count).
257
275
  * @public
258
276
  */
259
- declare const RenderTotals: Schema.Struct<{
277
+ export declare const RenderTotals: Schema.Struct<{
260
278
  readonly passCount: Schema.Number;
261
279
  readonly failCount: Schema.Number;
262
280
  readonly skipCount: Schema.Number;
@@ -264,7 +282,7 @@ declare const RenderTotals: Schema.Struct<{
264
282
  readonly durationMs: Schema.Number;
265
283
  }>;
266
284
  /** @public */
267
- type RenderTotals = typeof RenderTotals.Type;
285
+ export type RenderTotals = typeof RenderTotals.Type;
268
286
  /**
269
287
  * The renderer state. Both the human (Ink) and agent (string)
270
288
  * renderers read this shape; the reducer is the only producer.
@@ -276,7 +294,7 @@ type RenderTotals = typeof RenderTotals.Type;
276
294
  * rather than the suite completing.
277
295
  * @public
278
296
  */
279
- declare const RenderState: Schema.Struct<{
297
+ export declare const RenderState: Schema.Struct<{
280
298
  readonly phase: Schema.Literals<readonly ["idle", "running", "finished", "timed-out"]>;
281
299
  readonly runId: Schema.NullOr<Schema.String>;
282
300
  readonly configHash: Schema.NullOr<Schema.String>;
@@ -407,14 +425,14 @@ declare const RenderState: Schema.Struct<{
407
425
  }>>;
408
426
  }>;
409
427
  /** @public */
410
- type RenderState = typeof RenderState.Type;
428
+ export type RenderState = typeof RenderState.Type;
411
429
  /**
412
430
  * Initial state — what the reducer returns when no events have been
413
431
  * applied yet. Exported so tests and the renderers' bootstrapping
414
432
  * code share one definition.
415
433
  * @public
416
434
  */
417
- declare const initialRenderState: RenderState;
435
+ export declare const initialRenderState: RenderState;
418
436
  //#endregion
419
437
  //#region src/contracts/dispatcher.d.ts
420
438
  /**
@@ -430,7 +448,7 @@ declare const initialRenderState: RenderState;
430
448
  * - `workspace` — more than one project.
431
449
  * @public
432
450
  */
433
- type RunShape = "single-test" | "single-file" | "single-project" | "workspace";
451
+ export type RunShape = "single-test" | "single-file" | "single-project" | "workspace";
434
452
  /**
435
453
  * The three outcome classes the dispatcher distinguishes.
436
454
  *
@@ -439,7 +457,7 @@ type RunShape = "single-test" | "single-file" | "single-project" | "workspace";
439
457
  * - `threshold-violation` — `totals.failed === 0` and at least one coverage violation.
440
458
  * @public
441
459
  */
442
- type RunOutcome = "all-pass" | "some-fail" | "threshold-violation";
460
+ export type RunOutcome = "all-pass" | "some-fail" | "threshold-violation";
443
461
  /**
444
462
  * Compact per-project aggregate carried into workspace cells.
445
463
  *
@@ -448,7 +466,7 @@ type RunOutcome = "all-pass" | "some-fail" | "threshold-violation";
448
466
  * optional — workspace cells render the columns only when present.
449
467
  * @public
450
468
  */
451
- interface ProjectSummary {
469
+ export interface ProjectSummary {
452
470
  readonly name: string;
453
471
  readonly passCount: number;
454
472
  readonly failCount: number;
@@ -468,7 +486,7 @@ interface ProjectSummary {
468
486
  * `ReporterRenderInput.trendSummary` before invoking `dispatch`.
469
487
  * @public
470
488
  */
471
- interface TrendSummary {
489
+ export interface TrendSummary {
472
490
  readonly direction: "improving" | "regressing" | "stable";
473
491
  readonly runCount: number;
474
492
  readonly firstMetric?: {
@@ -487,7 +505,7 @@ interface TrendSummary {
487
505
  * helpers the plugin computes once before dispatch so cells stay pure.
488
506
  * @public
489
507
  */
490
- interface DispatchInputs {
508
+ export interface DispatchInputs {
491
509
  readonly state: RenderState;
492
510
  readonly shape: RunShape;
493
511
  readonly outcome: RunOutcome;
@@ -525,7 +543,7 @@ interface DispatchInputs {
525
543
  * `dispatch(inputs, opts)`. Cells destructure only what they consume.
526
544
  * @public
527
545
  */
528
- interface CellOptions {
546
+ export interface CellOptions {
529
547
  /**
530
548
  * Resolved value of the `NO_COLOR` env var. Cells gate ANSI escape
531
549
  * sequences and OSC-8 hyperlinks on this.
@@ -544,7 +562,7 @@ interface CellOptions {
544
562
  * Aggregate test run statistics.
545
563
  * @public
546
564
  */
547
- declare const ReportSummary: Schema.Struct<{
565
+ export declare const ReportSummary: Schema.Struct<{
548
566
  readonly total: Schema.Number;
549
567
  readonly passed: Schema.Number;
550
568
  readonly failed: Schema.Number;
@@ -560,12 +578,12 @@ declare const ReportSummary: Schema.Struct<{
560
578
  readonly modules: Schema.optional<Schema.Number>;
561
579
  }>;
562
580
  /** @public */
563
- type ReportSummary = typeof ReportSummary.Type;
581
+ export type ReportSummary = typeof ReportSummary.Type;
564
582
  /**
565
583
  * An individual test case result.
566
584
  * @public
567
585
  */
568
- declare const TestReport: Schema.Struct<{
586
+ export declare const TestReport: Schema.Struct<{
569
587
  readonly name: Schema.String;
570
588
  readonly fullName: Schema.String;
571
589
  readonly state: Schema.Literals<readonly ["passed", "failed", "skipped", "pending"]>;
@@ -582,12 +600,12 @@ declare const TestReport: Schema.Struct<{
582
600
  readonly classification: Schema.optional<Schema.Literals<readonly ["stable", "new-failure", "persistent", "flaky", "recovered"]>>;
583
601
  }>;
584
602
  /** @public */
585
- type TestReport = typeof TestReport.Type;
603
+ export type TestReport = typeof TestReport.Type;
586
604
  /**
587
605
  * A test module (file) and its contained test cases.
588
606
  * @public
589
607
  */
590
- declare const ModuleReport: Schema.Struct<{
608
+ export declare const ModuleReport: Schema.Struct<{
591
609
  readonly file: Schema.String;
592
610
  readonly state: Schema.Literals<readonly ["passed", "failed", "skipped", "pending"]>;
593
611
  readonly duration: Schema.optional<Schema.Number>;
@@ -616,23 +634,23 @@ declare const ModuleReport: Schema.Struct<{
616
634
  }>>;
617
635
  }>;
618
636
  /** @public */
619
- type ModuleReport = typeof ModuleReport.Type;
637
+ export type ModuleReport = typeof ModuleReport.Type;
620
638
  /**
621
639
  * Per-tag pass/fail/skip aggregates for a single project run.
622
640
  * @public
623
641
  */
624
- declare const TagCountEntry: Schema.Struct<{
642
+ export declare const TagCountEntry: Schema.Struct<{
625
643
  readonly passed: Schema.optional<Schema.Number>;
626
644
  readonly failed: Schema.optional<Schema.Number>;
627
645
  readonly skipped: Schema.optional<Schema.Number>;
628
646
  }>;
629
647
  /** @public */
630
- type TagCountEntry = typeof TagCountEntry.Type;
648
+ export type TagCountEntry = typeof TagCountEntry.Type;
631
649
  /**
632
650
  * Complete per-project test report written to disk as JSON.
633
651
  * @public
634
652
  */
635
- declare const AgentReport: Schema.Struct<{
653
+ export declare const AgentReport: Schema.Struct<{
636
654
  readonly timestamp: Schema.String;
637
655
  readonly project: Schema.optional<Schema.String>;
638
656
  readonly reason: Schema.Literals<readonly ["passed", "failed", "interrupted"]>;
@@ -706,6 +724,12 @@ declare const AgentReport: Schema.Struct<{
706
724
  readonly functions: Schema.optional<Schema.Number>;
707
725
  readonly branches: Schema.optional<Schema.Number>;
708
726
  readonly statements: Schema.optional<Schema.Number>;
727
+ readonly perFile: Schema.optionalKey<Schema.Union<readonly [Schema.Boolean, Schema.Struct<{
728
+ readonly lines: Schema.optional<Schema.Number>;
729
+ readonly functions: Schema.optional<Schema.Number>;
730
+ readonly branches: Schema.optional<Schema.Number>;
731
+ readonly statements: Schema.optional<Schema.Number>;
732
+ }>]>>;
709
733
  }>]>>, never>;
710
734
  }>;
711
735
  readonly targets: Schema.optional<Schema.Struct<{
@@ -720,6 +744,12 @@ declare const AgentReport: Schema.Struct<{
720
744
  readonly functions: Schema.optional<Schema.Number>;
721
745
  readonly branches: Schema.optional<Schema.Number>;
722
746
  readonly statements: Schema.optional<Schema.Number>;
747
+ readonly perFile: Schema.optionalKey<Schema.Union<readonly [Schema.Boolean, Schema.Struct<{
748
+ readonly lines: Schema.optional<Schema.Number>;
749
+ readonly functions: Schema.optional<Schema.Number>;
750
+ readonly branches: Schema.optional<Schema.Number>;
751
+ readonly statements: Schema.optional<Schema.Number>;
752
+ }>]>>;
723
753
  }>]>>, never>;
724
754
  }>>;
725
755
  readonly baselines: Schema.optional<Schema.Struct<{
@@ -734,6 +764,12 @@ declare const AgentReport: Schema.Struct<{
734
764
  readonly functions: Schema.optional<Schema.Number>;
735
765
  readonly branches: Schema.optional<Schema.Number>;
736
766
  readonly statements: Schema.optional<Schema.Number>;
767
+ readonly perFile: Schema.optionalKey<Schema.Union<readonly [Schema.Boolean, Schema.Struct<{
768
+ readonly lines: Schema.optional<Schema.Number>;
769
+ readonly functions: Schema.optional<Schema.Number>;
770
+ readonly branches: Schema.optional<Schema.Number>;
771
+ readonly statements: Schema.optional<Schema.Number>;
772
+ }>]>>;
737
773
  }>]>>, never>;
738
774
  }>>;
739
775
  readonly scoped: Schema.withDecodingDefaultKey<Schema.Boolean, never>;
@@ -784,37 +820,37 @@ declare const AgentReport: Schema.Struct<{
784
820
  }>>;
785
821
  }>;
786
822
  /** @public */
787
- type AgentReport = typeof AgentReport.Type;
823
+ export type AgentReport = typeof AgentReport.Type;
788
824
  //#endregion
789
825
  //#region src/schemas/Common.d.ts
790
826
  /**
791
827
  * Possible states for an individual test case.
792
828
  * @public
793
829
  */
794
- declare const TestState: Schema.Literals<readonly ["passed", "failed", "skipped", "pending"]>;
830
+ export declare const TestState: Schema.Literals<readonly ["passed", "failed", "skipped", "pending"]>;
795
831
  /** @public */
796
- type TestState = typeof TestState.Type;
832
+ export type TestState = typeof TestState.Type;
797
833
  /**
798
834
  * Overall outcome of a test run.
799
835
  * @public
800
836
  */
801
- declare const TestRunReason: Schema.Literals<readonly ["passed", "failed", "interrupted"]>;
837
+ export declare const TestRunReason: Schema.Literals<readonly ["passed", "failed", "interrupted"]>;
802
838
  /** @public */
803
- type TestRunReason = typeof TestRunReason.Type;
839
+ export type TestRunReason = typeof TestRunReason.Type;
804
840
  /**
805
841
  * Classification of a test's failure history across runs.
806
842
  * @public
807
843
  */
808
- declare const TestClassification: Schema.Literals<readonly ["stable", "new-failure", "persistent", "flaky", "recovered"]>;
844
+ export declare const TestClassification: Schema.Literals<readonly ["stable", "new-failure", "persistent", "flaky", "recovered"]>;
809
845
  /** @public */
810
- type TestClassification = typeof TestClassification.Type;
846
+ export type TestClassification = typeof TestClassification.Type;
811
847
  /**
812
848
  * Console output verbosity mode for AgentReporter.
813
849
  * @public
814
850
  */
815
- declare const ConsoleOutputMode: Schema.Literals<readonly ["failures", "full", "silent"]>;
851
+ export declare const ConsoleOutputMode: Schema.Literals<readonly ["failures", "full", "silent"]>;
816
852
  /** @public */
817
- type ConsoleOutputMode = typeof ConsoleOutputMode.Type;
853
+ export type ConsoleOutputMode = typeof ConsoleOutputMode.Type;
818
854
  /**
819
855
  * Console output choices per executor type.
820
856
  *
@@ -833,60 +869,60 @@ type ConsoleOutputMode = typeof ConsoleOutputMode.Type;
833
869
  * so the default for `ci` is `passthrough` until it lands.
834
870
  * @public
835
871
  */
836
- declare const HumanConsoleMode: Schema.Literals<readonly ["passthrough", "silent", "stream", "agent"]>;
872
+ export declare const HumanConsoleMode: Schema.Literals<readonly ["passthrough", "silent", "stream", "agent"]>;
837
873
  /** @public */
838
- type HumanConsoleMode = typeof HumanConsoleMode.Type;
874
+ export type HumanConsoleMode = typeof HumanConsoleMode.Type;
839
875
  /** @public */
840
- declare const AgentConsoleMode: Schema.Literals<readonly ["passthrough", "silent", "agent"]>;
876
+ export declare const AgentConsoleMode: Schema.Literals<readonly ["passthrough", "silent", "agent"]>;
841
877
  /** @public */
842
- type AgentConsoleMode = typeof AgentConsoleMode.Type;
878
+ export type AgentConsoleMode = typeof AgentConsoleMode.Type;
843
879
  /** @public */
844
- declare const CiConsoleMode: Schema.Literals<readonly ["passthrough", "silent", "ci-annotations"]>;
880
+ export declare const CiConsoleMode: Schema.Literals<readonly ["passthrough", "silent", "ci-annotations"]>;
845
881
  /** @public */
846
- type CiConsoleMode = typeof CiConsoleMode.Type;
882
+ export type CiConsoleMode = typeof CiConsoleMode.Type;
847
883
  /**
848
884
  * Union of every legal console-output value across the three executor slots.
849
885
  * Useful for type-narrowing in renderers that take the resolved value.
850
886
  * @public
851
887
  */
852
- declare const ConsoleMode: Schema.Union<readonly [Schema.Literals<readonly ["passthrough", "silent", "stream", "agent"]>, Schema.Literals<readonly ["passthrough", "silent", "agent"]>, Schema.Literals<readonly ["passthrough", "silent", "ci-annotations"]>]>;
888
+ export declare const ConsoleMode: Schema.Union<readonly [Schema.Literals<readonly ["passthrough", "silent", "stream", "agent"]>, Schema.Literals<readonly ["passthrough", "silent", "agent"]>, Schema.Literals<readonly ["passthrough", "silent", "ci-annotations"]>]>;
853
889
  /** @public */
854
- type ConsoleMode = typeof ConsoleMode.Type;
890
+ export type ConsoleMode = typeof ConsoleMode.Type;
855
891
  /**
856
892
  * Supported package managers for run command generation.
857
893
  * @public
858
894
  */
859
- declare const PackageManager: Schema.Literals<readonly ["pnpm", "npm", "yarn", "bun"]>;
895
+ export declare const PackageManager: Schema.Literals<readonly ["pnpm", "npm", "yarn", "bun"]>;
860
896
  /** @public */
861
- type PackageManager = typeof PackageManager.Type;
897
+ export type PackageManager = typeof PackageManager.Type;
862
898
  /**
863
899
  * Runtime environment where tests are being executed.
864
900
  * @public
865
901
  */
866
- declare const Environment: Schema.Literals<readonly ["agent-shell", "terminal", "ci-github", "ci-generic"]>;
902
+ export declare const Environment: Schema.Literals<readonly ["agent-shell", "terminal", "ci-github", "ci-generic"]>;
867
903
  /** @public */
868
- type Environment = typeof Environment.Type;
904
+ export type Environment = typeof Environment.Type;
869
905
  /**
870
906
  * Who or what is executing the test run.
871
907
  * @public
872
908
  */
873
- declare const Executor: Schema.Literals<readonly ["human", "agent", "ci"]>;
909
+ export declare const Executor: Schema.Literals<readonly ["human", "agent", "ci"]>;
874
910
  /** @public */
875
- type Executor = typeof Executor.Type;
911
+ export type Executor = typeof Executor.Type;
876
912
  /**
877
913
  * Output format for the reporter pipeline.
878
914
  * @public
879
915
  */
880
- declare const OutputFormat: Schema.Literals<readonly ["terminal", "markdown", "json", "vitest-bypass", "silent", "ci-annotations"]>;
916
+ export declare const OutputFormat: Schema.Literals<readonly ["terminal", "markdown", "json", "vitest-bypass", "silent", "ci-annotations"]>;
881
917
  /** @public */
882
- type OutputFormat = typeof OutputFormat.Type;
918
+ export type OutputFormat = typeof OutputFormat.Type;
883
919
  /**
884
920
  * Level of detail in reporter output.
885
921
  * @public
886
922
  */
887
- declare const DetailLevel: Schema.Literals<readonly ["minimal", "neutral", "standard", "verbose"]>;
923
+ export declare const DetailLevel: Schema.Literals<readonly ["minimal", "neutral", "standard", "verbose"]>;
888
924
  /** @public */
889
- type DetailLevel = typeof DetailLevel.Type;
925
+ export type DetailLevel = typeof DetailLevel.Type;
890
926
  /**
891
927
  * A single test or module error with optional stack trace, diff, and
892
928
  * structured assertion values.
@@ -899,7 +935,7 @@ type DetailLevel = typeof DetailLevel.Type;
899
935
  * the schema boundary.
900
936
  * @public
901
937
  */
902
- declare const ReportError: Schema.Struct<{
938
+ export declare const ReportError: Schema.Struct<{
903
939
  readonly message: Schema.String;
904
940
  readonly stack: Schema.optional<Schema.String>;
905
941
  readonly diff: Schema.optional<Schema.String>;
@@ -907,17 +943,34 @@ declare const ReportError: Schema.Struct<{
907
943
  readonly received: Schema.optional<Schema.String>;
908
944
  }>;
909
945
  /** @public */
910
- type ReportError = typeof ReportError.Type;
946
+ export type ReportError = typeof ReportError.Type;
911
947
  //#endregion
912
948
  //#region src/formatters/types.d.ts
913
- /** @public */
914
- interface RenderedOutput {
949
+ /**
950
+ * One unit of rendered reporter output, tagged by where it goes.
951
+ *
952
+ * `stdout` writes to the process stdout stream, `github-summary`
953
+ * appends to the GitHub Actions step-summary file, and `file` is
954
+ * reserved for reporters that embed their own destination path.
955
+ *
956
+ * `report` writes `filename` into `.vitest/<scope>/` through Vitest 5's
957
+ * `createReport`. The plugin drops these when reporting is disabled,
958
+ * exactly as it drops `github-summary` outside GitHub Actions.
959
+ *
960
+ * @public
961
+ */
962
+ export type RenderedOutput = {
915
963
  readonly target: "stdout" | "file" | "github-summary";
916
964
  readonly content: string;
917
965
  readonly contentType: string;
918
- }
966
+ } | {
967
+ readonly target: "report";
968
+ readonly filename: string;
969
+ readonly content: string;
970
+ readonly contentType: string;
971
+ };
919
972
  /** @public */
920
- interface FormatterContext {
973
+ export interface FormatterContext {
921
974
  readonly detail: DetailLevel;
922
975
  readonly noColor: boolean;
923
976
  readonly coverageConsoleLimit: number;
@@ -936,7 +989,7 @@ interface FormatterContext {
936
989
  readonly mcp?: boolean;
937
990
  }
938
991
  /** @public */
939
- interface Formatter {
992
+ export interface Formatter {
940
993
  readonly format: string;
941
994
  readonly render: (reports: ReadonlyArray<AgentReport>, context: FormatterContext) => ReadonlyArray<RenderedOutput>;
942
995
  }
@@ -946,43 +999,43 @@ interface Formatter {
946
999
  * Coverage metric whose threshold can be violated independently.
947
1000
  * @public
948
1001
  */
949
- declare const CoverageMetric: Schema.Literals<readonly ["lines", "branches", "functions", "statements"]>;
1002
+ export declare const CoverageMetric: Schema.Literals<readonly ["lines", "branches", "functions", "statements"]>;
950
1003
  /** @public */
951
- type CoverageMetric = typeof CoverageMetric.Type;
1004
+ export type CoverageMetric = typeof CoverageMetric.Type;
952
1005
  /**
953
1006
  * Severity tier for a suggested action emitted during a run.
954
1007
  * @public
955
1008
  */
956
- declare const ActionSeverity: Schema.Literals<readonly ["info", "warn", "blocker"]>;
1009
+ export declare const ActionSeverity: Schema.Literals<readonly ["info", "warn", "blocker"]>;
957
1010
  /** @public */
958
- type ActionSeverity = typeof ActionSeverity.Type;
1011
+ export type ActionSeverity = typeof ActionSeverity.Type;
959
1012
  /**
960
1013
  * Lifecycle scope of a Vitest setup/teardown hook.
961
1014
  * @public
962
1015
  */
963
- declare const HookType: Schema.Literals<readonly ["beforeAll", "afterAll", "beforeEach", "afterEach"]>;
1016
+ export declare const HookType: Schema.Literals<readonly ["beforeAll", "afterAll", "beforeEach", "afterEach"]>;
964
1017
  /** @public */
965
- type HookType = typeof HookType.Type;
1018
+ export type HookType = typeof HookType.Type;
966
1019
  /**
967
1020
  * Terminal status of a Vitest hook run.
968
1021
  * @public
969
1022
  */
970
- declare const HookStatus: Schema.Literals<readonly ["passed", "failed"]>;
1023
+ export declare const HookStatus: Schema.Literals<readonly ["passed", "failed"]>;
971
1024
  /** @public */
972
- type HookStatus = typeof HookStatus.Type;
1025
+ export type HookStatus = typeof HookStatus.Type;
973
1026
  /**
974
1027
  * Output stream a captured user `console.log` was written to.
975
1028
  * @public
976
1029
  */
977
- declare const ConsoleLogLevel: Schema.Literals<readonly ["stdout", "stderr"]>;
1030
+ export declare const ConsoleLogLevel: Schema.Literals<readonly ["stdout", "stderr"]>;
978
1031
  /** @public */
979
- type ConsoleLogLevel = typeof ConsoleLogLevel.Type;
1032
+ export type ConsoleLogLevel = typeof ConsoleLogLevel.Type;
980
1033
  /**
981
1034
  * A coverage gap surfaced to the renderer — a per-file shortfall that
982
1035
  * a renderer may want to call out individually.
983
1036
  * @public
984
1037
  */
985
- declare const CoverageGap: Schema.Struct<{
1038
+ export declare const CoverageGap: Schema.Struct<{
986
1039
  readonly file: Schema.String;
987
1040
  readonly missing: Schema.Struct<{
988
1041
  readonly statements: Schema.Number;
@@ -993,7 +1046,7 @@ declare const CoverageGap: Schema.Struct<{
993
1046
  readonly uncoveredLines: Schema.optional<Schema.String>;
994
1047
  }>;
995
1048
  /** @public */
996
- type CoverageGap = typeof CoverageGap.Type;
1049
+ export type CoverageGap = typeof CoverageGap.Type;
997
1050
  /**
998
1051
  * The reducer projects this union into `RenderState`. Renderers
999
1052
  * never read the raw event stream — they read the projected state.
@@ -1004,7 +1057,7 @@ type CoverageGap = typeof CoverageGap.Type;
1004
1057
  * been updated to consume the new state shape.
1005
1058
  * @public
1006
1059
  */
1007
- declare const RunEvent: Schema.Union<readonly [Schema.TaggedStruct<"RunStarted", {
1060
+ export declare const RunEvent: Schema.Union<readonly [Schema.TaggedStruct<"RunStarted", {
1008
1061
  readonly runId: Schema.String;
1009
1062
  readonly startedAt: Schema.String;
1010
1063
  readonly configHash: Schema.String;
@@ -1087,11 +1140,36 @@ declare const RunEvent: Schema.Union<readonly [Schema.TaggedStruct<"RunStarted",
1087
1140
  readonly testName: Schema.String;
1088
1141
  readonly suitePath: Schema.$Array<Schema.String>;
1089
1142
  readonly annotation: Schema.String;
1143
+ readonly annotationType: Schema.String;
1144
+ readonly location: Schema.optional<Schema.Struct<{
1145
+ readonly file: Schema.String;
1146
+ readonly line: Schema.Number;
1147
+ readonly column: Schema.Number;
1148
+ }>>;
1149
+ readonly attachments: Schema.$Array<Schema.Struct<{
1150
+ readonly contentType: Schema.optional<Schema.String>;
1151
+ readonly path: Schema.optional<Schema.String>;
1152
+ readonly body: Schema.optional<Schema.String>;
1153
+ readonly bodyEncoding: Schema.optional<Schema.Literals<readonly ["base64", "utf-8"]>>;
1154
+ readonly byteSize: Schema.Number;
1155
+ }>>;
1090
1156
  }>, Schema.TaggedStruct<"TestArtifactRecorded", {
1091
1157
  readonly modulePath: Schema.String;
1092
1158
  readonly testName: Schema.String;
1093
1159
  readonly suitePath: Schema.$Array<Schema.String>;
1094
1160
  readonly artifact: Schema.String;
1161
+ readonly location: Schema.optional<Schema.Struct<{
1162
+ readonly file: Schema.String;
1163
+ readonly line: Schema.Number;
1164
+ readonly column: Schema.Number;
1165
+ }>>;
1166
+ readonly attachments: Schema.$Array<Schema.Struct<{
1167
+ readonly contentType: Schema.optional<Schema.String>;
1168
+ readonly path: Schema.optional<Schema.String>;
1169
+ readonly body: Schema.optional<Schema.String>;
1170
+ readonly bodyEncoding: Schema.optional<Schema.Literals<readonly ["base64", "utf-8"]>>;
1171
+ readonly byteSize: Schema.Number;
1172
+ }>>;
1095
1173
  }>, Schema.TaggedStruct<"WatcherReady", {}>, Schema.TaggedStruct<"WatcherRerun", {
1096
1174
  readonly triggerFiles: Schema.$Array<Schema.String>;
1097
1175
  readonly reason: Schema.optional<Schema.String>;
@@ -1168,7 +1246,7 @@ declare const RunEvent: Schema.Union<readonly [Schema.TaggedStruct<"RunStarted",
1168
1246
  }>>>;
1169
1247
  }>]>;
1170
1248
  /** @public */
1171
- type RunEvent = typeof RunEvent.Type;
1249
+ export type RunEvent = typeof RunEvent.Type;
1172
1250
  /**
1173
1251
  * Convenience: discriminator-keyed map of the individual variants.
1174
1252
  *
@@ -1176,54 +1254,108 @@ type RunEvent = typeof RunEvent.Type;
1176
1254
  * pulling the whole union shape into scope.
1177
1255
  * @public
1178
1256
  */
1179
- type RunEventByTag = { [E in RunEvent as E["_tag"]]: E; };
1257
+ export type RunEventByTag = { [E in RunEvent as E["_tag"]]: E; };
1180
1258
  //#endregion
1181
1259
  //#region src/schemas/Thresholds.d.ts
1182
1260
  /**
1183
1261
  * Per-metric threshold values. All optional -- only set metrics are enforced.
1184
1262
  * @public
1185
1263
  */
1186
- declare const MetricThresholds: Schema.Struct<{
1264
+ export declare const MetricThresholds: Schema.Struct<{
1187
1265
  readonly lines: Schema.optional<Schema.Number>;
1188
1266
  readonly functions: Schema.optional<Schema.Number>;
1189
1267
  readonly branches: Schema.optional<Schema.Number>;
1190
1268
  readonly statements: Schema.optional<Schema.Number>;
1191
1269
  }>;
1192
1270
  /** @public */
1193
- type MetricThresholds = typeof MetricThresholds.Type;
1271
+ export type MetricThresholds = typeof MetricThresholds.Type;
1272
+ /**
1273
+ * A `perFile` setting. Vitest 5 allows either a plain boolean or a
1274
+ * per-metric object that overrides the metric numbers used for the
1275
+ * per-file check.
1276
+ *
1277
+ * An object constrains exactly the metrics it names, so `{}` enforces
1278
+ * nothing at all. Write `true` to check every metric.
1279
+ * @public
1280
+ */
1281
+ export declare const PerFileThresholds: Schema.Union<readonly [Schema.Boolean, Schema.Struct<{
1282
+ readonly lines: Schema.optional<Schema.Number>;
1283
+ readonly functions: Schema.optional<Schema.Number>;
1284
+ readonly branches: Schema.optional<Schema.Number>;
1285
+ readonly statements: Schema.optional<Schema.Number>;
1286
+ }>]>;
1287
+ /** @public */
1288
+ export type PerFileThresholds = typeof PerFileThresholds.Type;
1289
+ /**
1290
+ * The metric values carried by a glob-pattern entry. Under Vitest 5 a
1291
+ * glob entry no longer inherits the top-level `perFile`, so it carries
1292
+ * its own optional setting.
1293
+ * @public
1294
+ */
1295
+ export declare const PatternMetricThresholds: Schema.Struct<{
1296
+ readonly lines: Schema.optional<Schema.Number>;
1297
+ readonly functions: Schema.optional<Schema.Number>;
1298
+ readonly branches: Schema.optional<Schema.Number>;
1299
+ readonly statements: Schema.optional<Schema.Number>;
1300
+ readonly perFile: Schema.optionalKey<Schema.Union<readonly [Schema.Boolean, Schema.Struct<{
1301
+ readonly lines: Schema.optional<Schema.Number>;
1302
+ readonly functions: Schema.optional<Schema.Number>;
1303
+ readonly branches: Schema.optional<Schema.Number>;
1304
+ readonly statements: Schema.optional<Schema.Number>;
1305
+ }>]>>;
1306
+ }>;
1307
+ /** @public */
1308
+ export type PatternMetricThresholds = typeof PatternMetricThresholds.Type;
1194
1309
  /**
1195
1310
  * A glob pattern paired with its metric thresholds.
1196
1311
  * @public
1197
1312
  */
1198
- declare const PatternThresholds: Schema.Tuple<readonly [Schema.String, Schema.Struct<{
1313
+ export declare const PatternThresholds: Schema.Tuple<readonly [Schema.String, Schema.Struct<{
1199
1314
  readonly lines: Schema.optional<Schema.Number>;
1200
1315
  readonly functions: Schema.optional<Schema.Number>;
1201
1316
  readonly branches: Schema.optional<Schema.Number>;
1202
1317
  readonly statements: Schema.optional<Schema.Number>;
1318
+ readonly perFile: Schema.optionalKey<Schema.Union<readonly [Schema.Boolean, Schema.Struct<{
1319
+ readonly lines: Schema.optional<Schema.Number>;
1320
+ readonly functions: Schema.optional<Schema.Number>;
1321
+ readonly branches: Schema.optional<Schema.Number>;
1322
+ readonly statements: Schema.optional<Schema.Number>;
1323
+ }>]>>;
1203
1324
  }>]>;
1204
1325
  /** @public */
1205
- type PatternThresholds = typeof PatternThresholds.Type;
1326
+ export type PatternThresholds = typeof PatternThresholds.Type;
1206
1327
  /**
1207
1328
  * Fully resolved thresholds ready for evaluation.
1208
1329
  * @public
1209
1330
  */
1210
- declare const ResolvedThresholds: Schema.Struct<{
1331
+ export declare const ResolvedThresholds: Schema.Struct<{
1211
1332
  readonly global: Schema.Struct<{
1212
1333
  readonly lines: Schema.optional<Schema.Number>;
1213
1334
  readonly functions: Schema.optional<Schema.Number>;
1214
1335
  readonly branches: Schema.optional<Schema.Number>;
1215
1336
  readonly statements: Schema.optional<Schema.Number>;
1216
1337
  }>;
1217
- readonly perFile: Schema.withDecodingDefaultKey<Schema.Boolean, never>;
1338
+ readonly perFile: Schema.withDecodingDefaultKey<Schema.Union<readonly [Schema.Boolean, Schema.Struct<{
1339
+ readonly lines: Schema.optional<Schema.Number>;
1340
+ readonly functions: Schema.optional<Schema.Number>;
1341
+ readonly branches: Schema.optional<Schema.Number>;
1342
+ readonly statements: Schema.optional<Schema.Number>;
1343
+ }>]>, never>;
1218
1344
  readonly patterns: Schema.withDecodingDefaultKey<Schema.$Array<Schema.Tuple<readonly [Schema.String, Schema.Struct<{
1219
1345
  readonly lines: Schema.optional<Schema.Number>;
1220
1346
  readonly functions: Schema.optional<Schema.Number>;
1221
1347
  readonly branches: Schema.optional<Schema.Number>;
1222
1348
  readonly statements: Schema.optional<Schema.Number>;
1349
+ readonly perFile: Schema.optionalKey<Schema.Union<readonly [Schema.Boolean, Schema.Struct<{
1350
+ readonly lines: Schema.optional<Schema.Number>;
1351
+ readonly functions: Schema.optional<Schema.Number>;
1352
+ readonly branches: Schema.optional<Schema.Number>;
1353
+ readonly statements: Schema.optional<Schema.Number>;
1354
+ }>]>>;
1223
1355
  }>]>>, never>;
1224
1356
  }>;
1225
1357
  /** @public */
1226
- type ResolvedThresholds = typeof ResolvedThresholds.Type;
1358
+ export type ResolvedThresholds = typeof ResolvedThresholds.Type;
1227
1359
  //#endregion
1228
1360
  //#region src/schemas/Transport.d.ts
1229
1361
  /**
@@ -1235,11 +1367,11 @@ type ResolvedThresholds = typeof ResolvedThresholds.Type;
1235
1367
  * diff and no breaking API change at the call site.
1236
1368
  * @public
1237
1369
  */
1238
- declare const Transport: Schema.Union<readonly [Schema.Struct<{
1370
+ export declare const Transport: Schema.Union<readonly [Schema.Struct<{
1239
1371
  readonly kind: Schema.Literal<"local">;
1240
1372
  }>]>;
1241
1373
  /** @public */
1242
- type Transport = typeof Transport.Type;
1374
+ export type Transport = typeof Transport.Type;
1243
1375
  //#endregion
1244
1376
  //#region src/contracts/reporter.d.ts
1245
1377
  /**
@@ -1257,7 +1389,7 @@ type Transport = typeof Transport.Type;
1257
1389
  * var; reporters use it to gate ANSI escapes and OSC-8 hyperlinks.
1258
1390
  * @public
1259
1391
  */
1260
- interface ResolvedReporterConfig {
1392
+ export interface ResolvedReporterConfig {
1261
1393
  readonly dbPath?: string;
1262
1394
  readonly projectFilter?: string;
1263
1395
  /**
@@ -1333,7 +1465,7 @@ interface ResolvedReporterConfig {
1333
1465
  * named-field object. Reporters destructure only what they consume.
1334
1466
  * @public
1335
1467
  */
1336
- interface ReporterKit {
1468
+ export interface ReporterKit {
1337
1469
  readonly config: ResolvedReporterConfig;
1338
1470
  readonly stdEnv: Environment;
1339
1471
  /**
@@ -1369,7 +1501,7 @@ interface ReporterKit {
1369
1501
  * where coverage trends were computed.
1370
1502
  * @public
1371
1503
  */
1372
- interface ReporterRenderInput {
1504
+ export interface ReporterRenderInput {
1373
1505
  readonly reports: ReadonlyArray<AgentReport>;
1374
1506
  readonly classifications: ReadonlyMap<string, TestClassification>;
1375
1507
  readonly trendSummary?: {
@@ -1403,7 +1535,7 @@ interface ReporterRenderInput {
1403
1535
  * no console output at all.
1404
1536
  * @public
1405
1537
  */
1406
- interface VitestAgentReporter {
1538
+ export interface VitestAgentReporter {
1407
1539
  readonly render: (input: ReporterRenderInput, kit: ReporterKit) => ReadonlyArray<RenderedOutput>;
1408
1540
  }
1409
1541
  /**
@@ -1425,7 +1557,7 @@ interface VitestAgentReporter {
1425
1557
  * the plugin own the kit assembly.
1426
1558
  * @public
1427
1559
  */
1428
- type VitestAgentReporterFactory = (kit: ReporterKit) => VitestAgentReporter | ReadonlyArray<VitestAgentReporter>;
1560
+ export type VitestAgentReporterFactory = (kit: ReporterKit) => VitestAgentReporter | ReadonlyArray<VitestAgentReporter>;
1429
1561
  //#endregion
1430
1562
  //#region src/schemas/Identity.d.ts
1431
1563
  /**
@@ -1434,18 +1566,18 @@ type VitestAgentReporterFactory = (kit: ReporterKit) => VitestAgentReporter | Re
1434
1566
  * agent's lifetime.
1435
1567
  * @public
1436
1568
  */
1437
- declare const AgentId: Schema.brand<Schema.String, "AgentId">;
1569
+ export declare const AgentId: Schema.brand<Schema.String, "AgentId">;
1438
1570
  /** @public */
1439
- type AgentId = Schema.Schema.Type<typeof AgentId>;
1571
+ export type AgentId = Schema.Schema.Type<typeof AgentId>;
1440
1572
  /**
1441
1573
  * The unit "all work on this feature" rolls up to. Survives
1442
1574
  * `claude --resume` and parallel windows; lives in the host's
1443
1575
  * transcript filename for Claude Code.
1444
1576
  * @public
1445
1577
  */
1446
- declare const ConversationId: Schema.brand<Schema.String, "ConversationId">;
1578
+ export declare const ConversationId: Schema.brand<Schema.String, "ConversationId">;
1447
1579
  /** @public */
1448
- type ConversationId = Schema.Schema.Type<typeof ConversationId>;
1580
+ export type ConversationId = Schema.Schema.Type<typeof ConversationId>;
1449
1581
  /**
1450
1582
  * The agent host process's chat id (Claude Code's per-process chat
1451
1583
  * UUID, etc.). Shorter-lived than a conversation; one conversation can
@@ -1453,17 +1585,17 @@ type ConversationId = Schema.Schema.Type<typeof ConversationId>;
1453
1585
  * `sessions.id` (the SQLite agent-run PK).
1454
1586
  * @public
1455
1587
  */
1456
- declare const ChatId: Schema.brand<Schema.String, "ChatId">;
1588
+ export declare const ChatId: Schema.brand<Schema.String, "ChatId">;
1457
1589
  /** @public */
1458
- type ChatId = Schema.Schema.Type<typeof ChatId>;
1590
+ export type ChatId = Schema.Schema.Type<typeof ChatId>;
1459
1591
  /**
1460
1592
  * One TDD orchestration task. Replaces the legacy `tdd_session_id`
1461
1593
  * vocabulary so "session" is unambiguous in the codebase.
1462
1594
  * @public
1463
1595
  */
1464
- declare const TddTaskId: Schema.brand<Schema.String, "TddTaskId">;
1596
+ export declare const TddTaskId: Schema.brand<Schema.String, "TddTaskId">;
1465
1597
  /** @public */
1466
- type TddTaskId = Schema.Schema.Type<typeof TddTaskId>;
1598
+ export type TddTaskId = Schema.Schema.Type<typeof TddTaskId>;
1467
1599
  /**
1468
1600
  * Filesystem-safe key for the per-project data store directory under
1469
1601
  * `$XDG_DATA_HOME/vitest-agent/<projectKey>/`. Resolved by the
@@ -1472,9 +1604,9 @@ type TddTaskId = Schema.Schema.Type<typeof TddTaskId>;
1472
1604
  * value is `ProjectIdentityNotResolvableError`, not an empty string).
1473
1605
  * @public
1474
1606
  */
1475
- declare const ProjectKey: Schema.brand<Schema.String, "ProjectKey">;
1607
+ export declare const ProjectKey: Schema.brand<Schema.String, "ProjectKey">;
1476
1608
  /** @public */
1477
- type ProjectKey = Schema.Schema.Type<typeof ProjectKey>;
1609
+ export type ProjectKey = Schema.Schema.Type<typeof ProjectKey>;
1478
1610
  /**
1479
1611
  * Who initiated the action (test run, hypothesis, note, TDD phase, …).
1480
1612
  * Recorded on every action row alongside `agent_id`.
@@ -1484,9 +1616,9 @@ type ProjectKey = Schema.Schema.Type<typeof ProjectKey>;
1484
1616
  * - `system` — a CI run, scheduler, or other non-human/non-agent actor
1485
1617
  * @public
1486
1618
  */
1487
- declare const ActorType: Schema.Literals<readonly ["agent", "user", "system"]>;
1619
+ export declare const ActorType: Schema.Literals<readonly ["agent", "user", "system"]>;
1488
1620
  /** @public */
1489
- type ActorType = typeof ActorType.Type;
1621
+ export type ActorType = typeof ActorType.Type;
1490
1622
  /**
1491
1623
  * Recommended canonical host identifiers. Open enum at the SDK level so
1492
1624
  * a new client doesn't require an SDK release; the MCP server defaults
@@ -1497,9 +1629,9 @@ type ActorType = typeof ActorType.Type;
1497
1629
  * match a known pattern — preferred over guessing.
1498
1630
  * @public
1499
1631
  */
1500
- declare const HostKind: Schema.Literals<readonly ["claude-code", "claude-desktop", "cursor", "goose", "chatgpt", "mcp-inspector", "unknown"]>;
1632
+ export declare const HostKind: Schema.Literals<readonly ["claude-code", "claude-desktop", "cursor", "goose", "chatgpt", "mcp-inspector", "unknown"]>;
1501
1633
  /** @public */
1502
- type HostKind = typeof HostKind.Type;
1634
+ export type HostKind = typeof HostKind.Type;
1503
1635
  //#endregion
1504
1636
  //#region src/errors/AgentErrors.d.ts
1505
1637
  declare const AgentNotFoundError_base: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => import("effect/Cause").YieldableError & {
@@ -1511,7 +1643,7 @@ declare const AgentNotFoundError_base: new <A extends Record<string, any> = {}>(
1511
1643
  * this agent first.
1512
1644
  * @public
1513
1645
  */
1514
- declare class AgentNotFoundError extends AgentNotFoundError_base<{
1646
+ export declare class AgentNotFoundError extends AgentNotFoundError_base<{
1515
1647
  readonly agentId: AgentId;
1516
1648
  readonly chatId?: ChatId;
1517
1649
  }> {}
@@ -1523,7 +1655,7 @@ declare const SessionNotFoundError_base: new <A extends Record<string, any> = {}
1523
1655
  * probably hasn't fired the SessionStart equivalent for this chat yet.
1524
1656
  * @public
1525
1657
  */
1526
- declare class SessionNotFoundError extends SessionNotFoundError_base<{
1658
+ export declare class SessionNotFoundError extends SessionNotFoundError_base<{
1527
1659
  readonly chatId: ChatId;
1528
1660
  }> {}
1529
1661
  declare const ConversationNotFoundError_base: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => import("effect/Cause").YieldableError & {
@@ -1534,7 +1666,7 @@ declare const ConversationNotFoundError_base: new <A extends Record<string, any>
1534
1666
  * require a conversation row.
1535
1667
  * @public
1536
1668
  */
1537
- declare class ConversationNotFoundError extends ConversationNotFoundError_base<{
1669
+ export declare class ConversationNotFoundError extends ConversationNotFoundError_base<{
1538
1670
  readonly conversationId: ConversationId;
1539
1671
  }> {}
1540
1672
  declare const RegistrationConflictError_base: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => import("effect/Cause").YieldableError & {
@@ -1546,7 +1678,7 @@ declare const RegistrationConflictError_base: new <A extends Record<string, any>
1546
1678
  * caller named. Distinct from `IdempotencyHit`, which is a success.
1547
1679
  * @public
1548
1680
  */
1549
- declare class RegistrationConflictError extends RegistrationConflictError_base<{
1681
+ export declare class RegistrationConflictError extends RegistrationConflictError_base<{
1550
1682
  readonly reason: string;
1551
1683
  }> {
1552
1684
  constructor(args: {
@@ -1562,7 +1694,7 @@ declare const HostMetadataParseError_base: new <A extends Record<string, any> =
1562
1694
  * paths that explicitly carry through `Schema.parseJson` errors.
1563
1695
  * @public
1564
1696
  */
1565
- declare class HostMetadataParseError extends HostMetadataParseError_base<{
1697
+ export declare class HostMetadataParseError extends HostMetadataParseError_base<{
1566
1698
  readonly raw: string;
1567
1699
  readonly reason: string;
1568
1700
  }> {}
@@ -1574,7 +1706,7 @@ declare const SidecarTimeoutError_base: new <A extends Record<string, any> = {}>
1574
1706
  * `Effect.timeout`; the top-level wrapper maps it to exit code 2.
1575
1707
  * @public
1576
1708
  */
1577
- declare class SidecarTimeoutError extends SidecarTimeoutError_base<{
1709
+ export declare class SidecarTimeoutError extends SidecarTimeoutError_base<{
1578
1710
  readonly operation: string;
1579
1711
  readonly timeoutMs: number;
1580
1712
  }> {
@@ -1592,7 +1724,7 @@ declare const DataStoreError_base: new <A extends Record<string, any> = {}>(args
1592
1724
  * Error raised when a SQLite operation fails at read, write, or migration time.
1593
1725
  * @public
1594
1726
  */
1595
- declare class DataStoreError extends DataStoreError_base<{
1727
+ export declare class DataStoreError extends DataStoreError_base<{
1596
1728
  readonly operation: "read" | "write" | "migrate";
1597
1729
  readonly table: string;
1598
1730
  readonly reason: string;
@@ -1615,7 +1747,7 @@ declare class DataStoreError extends DataStoreError_base<{
1615
1747
  * circular `cause` references.
1616
1748
  * @public
1617
1749
  */
1618
- declare const extractSqlReason: (e: unknown) => string;
1750
+ export declare const extractSqlReason: (e: unknown) => string;
1619
1751
  //#endregion
1620
1752
  //#region src/errors/DiscoveryError.d.ts
1621
1753
  declare const DiscoveryError_base: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => import("effect/Cause").YieldableError & {
@@ -1625,7 +1757,7 @@ declare const DiscoveryError_base: new <A extends Record<string, any> = {}>(args
1625
1757
  * Error raised when project discovery (glob, file read, or stat) fails.
1626
1758
  * @public
1627
1759
  */
1628
- declare class DiscoveryError extends DiscoveryError_base<{
1760
+ export declare class DiscoveryError extends DiscoveryError_base<{
1629
1761
  readonly operation: "glob" | "read" | "stat";
1630
1762
  readonly path: string;
1631
1763
  readonly reason: string;
@@ -1651,7 +1783,7 @@ declare const PathResolutionError_base: new <A extends Record<string, any> = {}>
1651
1783
  * write to.
1652
1784
  * @public
1653
1785
  */
1654
- declare class PathResolutionError extends PathResolutionError_base<{
1786
+ export declare class PathResolutionError extends PathResolutionError_base<{
1655
1787
  readonly reason: string;
1656
1788
  }> {
1657
1789
  constructor(args: {
@@ -1670,7 +1802,7 @@ declare class PathResolutionError extends PathResolutionError_base<{
1670
1802
  * "URL canonicalization rejected the value").
1671
1803
  * @public
1672
1804
  */
1673
- interface ProjectIdentityCandidate {
1805
+ export interface ProjectIdentityCandidate {
1674
1806
  readonly source: string;
1675
1807
  readonly reason: string;
1676
1808
  }
@@ -1688,7 +1820,7 @@ declare const ProjectIdentityNotResolvableError_base: new <A extends Record<stri
1688
1820
  * went through the new resolver.
1689
1821
  * @public
1690
1822
  */
1691
- declare class ProjectIdentityNotResolvableError extends ProjectIdentityNotResolvableError_base<{
1823
+ export declare class ProjectIdentityNotResolvableError extends ProjectIdentityNotResolvableError_base<{
1692
1824
  readonly tried: ReadonlyArray<ProjectIdentityCandidate>;
1693
1825
  }> {
1694
1826
  constructor(args: {
@@ -1709,7 +1841,7 @@ declare const GitCommandError_base: new <A extends Record<string, any> = {}>(arg
1709
1841
  * meaningfully recover from.
1710
1842
  * @public
1711
1843
  */
1712
- declare class GitCommandError extends GitCommandError_base<{
1844
+ export declare class GitCommandError extends GitCommandError_base<{
1713
1845
  readonly command: string;
1714
1846
  readonly reason: string;
1715
1847
  }> {
@@ -1729,7 +1861,7 @@ declare const ProbeMissError_base: new <A extends Record<string, any> = {}>(args
1729
1861
  * probes).
1730
1862
  * @internal
1731
1863
  */
1732
- declare class ProbeMissError extends ProbeMissError_base<{
1864
+ export declare class ProbeMissError extends ProbeMissError_base<{
1733
1865
  readonly probe: string;
1734
1866
  }> {}
1735
1867
  //#endregion
@@ -1738,7 +1870,7 @@ declare const GoalNotFoundError_base: new <A extends Record<string, any> = {}>(a
1738
1870
  readonly _tag: "GoalNotFoundError";
1739
1871
  } & Readonly<A>;
1740
1872
  /** @public */
1741
- declare class GoalNotFoundError extends GoalNotFoundError_base<{
1873
+ export declare class GoalNotFoundError extends GoalNotFoundError_base<{
1742
1874
  readonly id: number;
1743
1875
  readonly reason: string;
1744
1876
  }> {
@@ -1751,7 +1883,7 @@ declare const BehaviorNotFoundError_base: new <A extends Record<string, any> = {
1751
1883
  readonly _tag: "BehaviorNotFoundError";
1752
1884
  } & Readonly<A>;
1753
1885
  /** @public */
1754
- declare class BehaviorNotFoundError extends BehaviorNotFoundError_base<{
1886
+ export declare class BehaviorNotFoundError extends BehaviorNotFoundError_base<{
1755
1887
  readonly id: number;
1756
1888
  readonly reason: string;
1757
1889
  }> {
@@ -1764,7 +1896,7 @@ declare const TddTaskNotFoundError_base: new <A extends Record<string, any> = {}
1764
1896
  readonly _tag: "TddTaskNotFoundError";
1765
1897
  } & Readonly<A>;
1766
1898
  /** @public */
1767
- declare class TddTaskNotFoundError extends TddTaskNotFoundError_base<{
1899
+ export declare class TddTaskNotFoundError extends TddTaskNotFoundError_base<{
1768
1900
  readonly id: number;
1769
1901
  readonly reason: string;
1770
1902
  }> {
@@ -1774,12 +1906,12 @@ declare class TddTaskNotFoundError extends TddTaskNotFoundError_base<{
1774
1906
  });
1775
1907
  }
1776
1908
  /** @public */
1777
- type TddTaskEndOutcome = "succeeded" | "blocked" | "abandoned";
1909
+ export type TddTaskEndOutcome = "succeeded" | "blocked" | "abandoned";
1778
1910
  declare const TddTaskAlreadyEndedError_base: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => import("effect/Cause").YieldableError & {
1779
1911
  readonly _tag: "TddTaskAlreadyEndedError";
1780
1912
  } & Readonly<A>;
1781
1913
  /** @public */
1782
- declare class TddTaskAlreadyEndedError extends TddTaskAlreadyEndedError_base<{
1914
+ export declare class TddTaskAlreadyEndedError extends TddTaskAlreadyEndedError_base<{
1783
1915
  readonly id: number;
1784
1916
  readonly endedAt: string;
1785
1917
  readonly outcome: TddTaskEndOutcome;
@@ -1791,12 +1923,12 @@ declare class TddTaskAlreadyEndedError extends TddTaskAlreadyEndedError_base<{
1791
1923
  });
1792
1924
  }
1793
1925
  /** @public */
1794
- type IllegalStatusTransitionEntity = "goal" | "behavior" | "task";
1926
+ export type IllegalStatusTransitionEntity = "goal" | "behavior" | "task";
1795
1927
  declare const IllegalStatusTransitionError_base: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => import("effect/Cause").YieldableError & {
1796
1928
  readonly _tag: "IllegalStatusTransitionError";
1797
1929
  } & Readonly<A>;
1798
1930
  /** @public */
1799
- declare class IllegalStatusTransitionError extends IllegalStatusTransitionError_base<{
1931
+ export declare class IllegalStatusTransitionError extends IllegalStatusTransitionError_base<{
1800
1932
  readonly entity: IllegalStatusTransitionEntity;
1801
1933
  readonly id: number;
1802
1934
  readonly from: string;
@@ -1814,15 +1946,15 @@ declare class IllegalStatusTransitionError extends IllegalStatusTransitionError_
1814
1946
  //#endregion
1815
1947
  //#region src/formatters/ci-annotations.d.ts
1816
1948
  /** @public */
1817
- declare const ciAnnotationsFormatter: Formatter;
1949
+ export declare const ciAnnotationsFormatter: Formatter;
1818
1950
  //#endregion
1819
1951
  //#region src/formatters/gfm.d.ts
1820
1952
  /** @public */
1821
- declare const GfmFormatter: Formatter;
1953
+ export declare const GfmFormatter: Formatter;
1822
1954
  //#endregion
1823
1955
  //#region src/formatters/json.d.ts
1824
1956
  /** @public */
1825
- declare const JsonFormatter: Formatter;
1957
+ export declare const JsonFormatter: Formatter;
1826
1958
  //#endregion
1827
1959
  //#region src/formatters/markdown.d.ts
1828
1960
  /**
@@ -1836,15 +1968,15 @@ declare const JsonFormatter: Formatter;
1836
1968
  * Markdown-aware sink.
1837
1969
  * @public
1838
1970
  */
1839
- declare const MarkdownFormatter: Formatter;
1971
+ export declare const MarkdownFormatter: Formatter;
1840
1972
  //#endregion
1841
1973
  //#region src/formatters/silent.d.ts
1842
1974
  /** @public */
1843
- declare const SilentFormatter: Formatter;
1975
+ export declare const SilentFormatter: Formatter;
1844
1976
  //#endregion
1845
1977
  //#region src/formatters/terminal.d.ts
1846
1978
  /** @public */
1847
- declare const TerminalFormatter: Formatter;
1979
+ export declare const TerminalFormatter: Formatter;
1848
1980
  //#endregion
1849
1981
  //#region src/schemas/Config.d.ts
1850
1982
  declare const VitestAgentConfig_base: Schema.Class<VitestAgentConfig, Schema.Struct<{
@@ -1869,7 +2001,7 @@ declare const VitestAgentConfig_base: Schema.Class<VitestAgentConfig, Schema.Str
1869
2001
  * keying), or when you want a stable key independent of `name` changes.
1870
2002
  * @public
1871
2003
  */
1872
- declare class VitestAgentConfig extends VitestAgentConfig_base {}
2004
+ export declare class VitestAgentConfig extends VitestAgentConfig_base {}
1873
2005
  //#endregion
1874
2006
  //#region src/services/Config.d.ts
1875
2007
  /**
@@ -1878,7 +2010,7 @@ declare class VitestAgentConfig extends VitestAgentConfig_base {}
1878
2010
  * type without referencing the `ConfigFileShape<A>` generic directly.
1879
2011
  * @public
1880
2012
  */
1881
- type VitestAgentConfigFileService = ConfigFileShape<VitestAgentConfig>;
2013
+ export type VitestAgentConfigFileService = ConfigFileShape<VitestAgentConfig>;
1882
2014
  declare const VitestAgentConfigFile_base: import("effect/Context").ServiceClass<VitestAgentConfigFile, "vitest-agent/Config", ConfigFileShape<VitestAgentConfig>>;
1883
2015
  /**
1884
2016
  * Typed service class (Context tag) for the vitest-agent config file service.
@@ -1888,7 +2020,7 @@ declare const VitestAgentConfigFile_base: import("effect/Context").ServiceClass<
1888
2020
  * `ConfigLive(projectDir)`.
1889
2021
  * @public
1890
2022
  */
1891
- declare class VitestAgentConfigFile extends VitestAgentConfigFile_base {}
2023
+ export declare class VitestAgentConfigFile extends VitestAgentConfigFile_base {}
1892
2024
  //#endregion
1893
2025
  //#region src/layers/ConfigLive.d.ts
1894
2026
  /**
@@ -1909,14 +2041,14 @@ declare class VitestAgentConfigFile extends VitestAgentConfigFile_base {}
1909
2041
  * sees the right config even when invoked from elsewhere.
1910
2042
  * @public
1911
2043
  */
1912
- declare const ConfigLive: (projectDir: string) => Layer.Layer<VitestAgentConfigFile, never, FileSystem.FileSystem | Path.Path>;
2044
+ export declare const ConfigLive: (projectDir: string) => Layer.Layer<VitestAgentConfigFile, never, FileSystem.FileSystem | Path.Path>;
1913
2045
  //#endregion
1914
2046
  //#region src/schemas/Baselines.d.ts
1915
2047
  /**
1916
2048
  * Coverage baselines -- the auto-ratcheting high-water mark.
1917
2049
  * @public
1918
2050
  */
1919
- declare const CoverageBaselines: Schema.Struct<{
2051
+ export declare const CoverageBaselines: Schema.Struct<{
1920
2052
  readonly updatedAt: Schema.String;
1921
2053
  readonly global: Schema.Struct<{
1922
2054
  readonly lines: Schema.optional<Schema.Number>;
@@ -1929,17 +2061,23 @@ declare const CoverageBaselines: Schema.Struct<{
1929
2061
  readonly functions: Schema.optional<Schema.Number>;
1930
2062
  readonly branches: Schema.optional<Schema.Number>;
1931
2063
  readonly statements: Schema.optional<Schema.Number>;
2064
+ readonly perFile: Schema.optionalKey<Schema.Union<readonly [Schema.Boolean, Schema.Struct<{
2065
+ readonly lines: Schema.optional<Schema.Number>;
2066
+ readonly functions: Schema.optional<Schema.Number>;
2067
+ readonly branches: Schema.optional<Schema.Number>;
2068
+ readonly statements: Schema.optional<Schema.Number>;
2069
+ }>]>>;
1932
2070
  }>]>>, never>;
1933
2071
  }>;
1934
2072
  /** @public */
1935
- type CoverageBaselines = typeof CoverageBaselines.Type;
2073
+ export type CoverageBaselines = typeof CoverageBaselines.Type;
1936
2074
  //#endregion
1937
2075
  //#region src/schemas/CacheManifest.d.ts
1938
2076
  /**
1939
2077
  * A single project entry in the cache manifest.
1940
2078
  * @public
1941
2079
  */
1942
- declare const CacheManifestEntry: Schema.Struct<{
2080
+ export declare const CacheManifestEntry: Schema.Struct<{
1943
2081
  readonly project: Schema.String;
1944
2082
  readonly reportFile: Schema.String;
1945
2083
  readonly historyFile: Schema.optional<Schema.String>;
@@ -1947,12 +2085,12 @@ declare const CacheManifestEntry: Schema.Struct<{
1947
2085
  readonly lastResult: Schema.NullOr<Schema.Literals<readonly ["passed", "failed", "interrupted"]>>;
1948
2086
  }>;
1949
2087
  /** @public */
1950
- type CacheManifestEntry = typeof CacheManifestEntry.Type;
2088
+ export type CacheManifestEntry = typeof CacheManifestEntry.Type;
1951
2089
  /**
1952
2090
  * Root manifest file that indexes all project reports.
1953
2091
  * @public
1954
2092
  */
1955
- declare const CacheManifest: Schema.Struct<{
2093
+ export declare const CacheManifest: Schema.Struct<{
1956
2094
  readonly updatedAt: Schema.String;
1957
2095
  readonly cacheDir: Schema.String;
1958
2096
  readonly projects: Schema.$Array<Schema.Struct<{
@@ -1964,24 +2102,24 @@ declare const CacheManifest: Schema.Struct<{
1964
2102
  }>>;
1965
2103
  }>;
1966
2104
  /** @public */
1967
- type CacheManifest = typeof CacheManifest.Type;
2105
+ export type CacheManifest = typeof CacheManifest.Type;
1968
2106
  //#endregion
1969
2107
  //#region src/schemas/History.d.ts
1970
2108
  /**
1971
2109
  * A single test run outcome (pass or fail only).
1972
2110
  * @public
1973
2111
  */
1974
- declare const TestRun: Schema.Struct<{
2112
+ export declare const TestRun: Schema.Struct<{
1975
2113
  readonly timestamp: Schema.String;
1976
2114
  readonly state: Schema.Literals<readonly ["passed", "failed"]>;
1977
2115
  }>;
1978
2116
  /** @public */
1979
- type TestRun = typeof TestRun.Type;
2117
+ export type TestRun = typeof TestRun.Type;
1980
2118
  /**
1981
2119
  * History for a single test across multiple runs.
1982
2120
  * @public
1983
2121
  */
1984
- declare const TestHistory: Schema.Struct<{
2122
+ export declare const TestHistory: Schema.Struct<{
1985
2123
  readonly modulePath: Schema.String;
1986
2124
  readonly fullName: Schema.String;
1987
2125
  readonly runs: Schema.$Array<Schema.Struct<{
@@ -1990,12 +2128,12 @@ declare const TestHistory: Schema.Struct<{
1990
2128
  }>>;
1991
2129
  }>;
1992
2130
  /** @public */
1993
- type TestHistory = typeof TestHistory.Type;
2131
+ export type TestHistory = typeof TestHistory.Type;
1994
2132
  /**
1995
2133
  * Per-project history record containing all tracked tests.
1996
2134
  * @public
1997
2135
  */
1998
- declare const HistoryRecord: Schema.Struct<{
2136
+ export declare const HistoryRecord: Schema.Struct<{
1999
2137
  readonly project: Schema.String;
2000
2138
  readonly updatedAt: Schema.String;
2001
2139
  readonly tests: Schema.$Array<Schema.Struct<{
@@ -2008,19 +2146,19 @@ declare const HistoryRecord: Schema.Struct<{
2008
2146
  }>>;
2009
2147
  }>;
2010
2148
  /** @public */
2011
- type HistoryRecord = typeof HistoryRecord.Type;
2149
+ export type HistoryRecord = typeof HistoryRecord.Type;
2012
2150
  //#endregion
2013
2151
  //#region src/schemas/Tdd.d.ts
2014
2152
  /** @public */
2015
- declare const GoalStatus: Schema.Literals<readonly ["pending", "in_progress", "done", "abandoned"]>;
2153
+ export declare const GoalStatus: Schema.Literals<readonly ["pending", "in_progress", "done", "abandoned"]>;
2016
2154
  /** @public */
2017
- type GoalStatus = typeof GoalStatus.Type;
2155
+ export type GoalStatus = typeof GoalStatus.Type;
2018
2156
  /** @public */
2019
- declare const BehaviorStatus: Schema.Literals<readonly ["pending", "in_progress", "done", "abandoned"]>;
2157
+ export declare const BehaviorStatus: Schema.Literals<readonly ["pending", "in_progress", "done", "abandoned"]>;
2020
2158
  /** @public */
2021
- type BehaviorStatus = typeof BehaviorStatus.Type;
2159
+ export type BehaviorStatus = typeof BehaviorStatus.Type;
2022
2160
  /** @public */
2023
- declare const GoalRow: Schema.Struct<{
2161
+ export declare const GoalRow: Schema.Struct<{
2024
2162
  readonly id: Schema.Number;
2025
2163
  readonly sessionId: Schema.Number;
2026
2164
  readonly ordinal: Schema.Number;
@@ -2029,9 +2167,9 @@ declare const GoalRow: Schema.Struct<{
2029
2167
  readonly createdAt: Schema.String;
2030
2168
  }>;
2031
2169
  /** @public */
2032
- type GoalRow = typeof GoalRow.Type;
2170
+ export type GoalRow = typeof GoalRow.Type;
2033
2171
  /** @public */
2034
- declare const BehaviorRow: Schema.Struct<{
2172
+ export declare const BehaviorRow: Schema.Struct<{
2035
2173
  readonly id: Schema.Number;
2036
2174
  readonly goalId: Schema.Number;
2037
2175
  readonly ordinal: Schema.Number;
@@ -2041,9 +2179,9 @@ declare const BehaviorRow: Schema.Struct<{
2041
2179
  readonly createdAt: Schema.String;
2042
2180
  }>;
2043
2181
  /** @public */
2044
- type BehaviorRow = typeof BehaviorRow.Type;
2182
+ export type BehaviorRow = typeof BehaviorRow.Type;
2045
2183
  /** @public */
2046
- declare const GoalDetail: Schema.Struct<{
2184
+ export declare const GoalDetail: Schema.Struct<{
2047
2185
  readonly id: Schema.Number;
2048
2186
  readonly sessionId: Schema.Number;
2049
2187
  readonly ordinal: Schema.Number;
@@ -2061,9 +2199,9 @@ declare const GoalDetail: Schema.Struct<{
2061
2199
  }>>;
2062
2200
  }>;
2063
2201
  /** @public */
2064
- type GoalDetail = typeof GoalDetail.Type;
2202
+ export type GoalDetail = typeof GoalDetail.Type;
2065
2203
  /** @public */
2066
- declare const BehaviorDetail: Schema.Struct<{
2204
+ export declare const BehaviorDetail: Schema.Struct<{
2067
2205
  readonly id: Schema.Number;
2068
2206
  readonly goalId: Schema.Number;
2069
2207
  readonly ordinal: Schema.Number;
@@ -2087,14 +2225,14 @@ declare const BehaviorDetail: Schema.Struct<{
2087
2225
  }>>;
2088
2226
  }>;
2089
2227
  /** @public */
2090
- type BehaviorDetail = typeof BehaviorDetail.Type;
2228
+ export type BehaviorDetail = typeof BehaviorDetail.Type;
2091
2229
  //#endregion
2092
2230
  //#region src/schemas/Trends.d.ts
2093
2231
  /**
2094
2232
  * A single coverage trend data point recorded on a full test run.
2095
2233
  * @public
2096
2234
  */
2097
- declare const TrendEntry: Schema.Struct<{
2235
+ export declare const TrendEntry: Schema.Struct<{
2098
2236
  readonly timestamp: Schema.String;
2099
2237
  readonly coverage: Schema.Struct<{
2100
2238
  readonly statements: Schema.Number;
@@ -2112,12 +2250,12 @@ declare const TrendEntry: Schema.Struct<{
2112
2250
  readonly targetsHash: Schema.optional<Schema.String>;
2113
2251
  }>;
2114
2252
  /** @public */
2115
- type TrendEntry = typeof TrendEntry.Type;
2253
+ export type TrendEntry = typeof TrendEntry.Type;
2116
2254
  /**
2117
2255
  * Per-project trend record with sliding window of entries.
2118
2256
  * @public
2119
2257
  */
2120
- declare const TrendRecord: Schema.Struct<{
2258
+ export declare const TrendRecord: Schema.Struct<{
2121
2259
  readonly entries: Schema.$Array<Schema.Struct<{
2122
2260
  readonly timestamp: Schema.String;
2123
2261
  readonly coverage: Schema.Struct<{
@@ -2137,13 +2275,13 @@ declare const TrendRecord: Schema.Struct<{
2137
2275
  }>>;
2138
2276
  }>;
2139
2277
  /** @public */
2140
- type TrendRecord = typeof TrendRecord.Type;
2278
+ export type TrendRecord = typeof TrendRecord.Type;
2141
2279
  //#endregion
2142
2280
  //#region src/utils/validate-phase-transition.d.ts
2143
2281
  /** @public */
2144
- type Phase = "spike" | "red" | "red.triangulate" | "green" | "green.fake-it" | "refactor" | "extended-red" | "green-without-red";
2282
+ export type Phase = "spike" | "red" | "red.triangulate" | "green" | "green.fake-it" | "refactor" | "extended-red" | "green-without-red";
2145
2283
  /** @public */
2146
- type ArtifactKind = "test_written" | "test_failed_run" | "code_written" | "test_passed_run" | "refactor" | "test_weakened";
2284
+ export type ArtifactKind = "test_written" | "test_failed_run" | "code_written" | "test_passed_run" | "refactor" | "test_weakened";
2147
2285
  /**
2148
2286
  * Explicit test-runner marker on a `tdd_artifacts` row (issue #363). `vitest`
2149
2287
  * artifacts always carry a `test_case_id` when they anchor a specific test;
@@ -2152,9 +2290,9 @@ type ArtifactKind = "test_written" | "test_failed_run" | "code_written" | "test_
2152
2290
  * run-level artifact without weakening the vitest guard.
2153
2291
  * @public
2154
2292
  */
2155
- type ArtifactSuite = "vitest" | "bats";
2293
+ export type ArtifactSuite = "vitest" | "bats";
2156
2294
  /** @public */
2157
- interface CitedArtifact {
2295
+ export interface CitedArtifact {
2158
2296
  readonly id: number;
2159
2297
  /**
2160
2298
  * `tdd_phases.id` of the phase this artifact was actually recorded in — the
@@ -2181,7 +2319,7 @@ interface CitedArtifact {
2181
2319
  readonly suite?: ArtifactSuite;
2182
2320
  }
2183
2321
  /** @public */
2184
- interface PhaseTransitionContext {
2322
+ export interface PhaseTransitionContext {
2185
2323
  readonly tdd_task_id: number;
2186
2324
  readonly current_phase: Phase;
2187
2325
  /**
@@ -2198,15 +2336,15 @@ interface PhaseTransitionContext {
2198
2336
  readonly requested_behavior_id: number | null;
2199
2337
  }
2200
2338
  /** @public */
2201
- type DenialReason = "missing_artifact_evidence" | "wrong_artifact_kind" | "wrong_source_phase" | "unknown_tdd_task" | "tdd_task_already_ended" | "goal_not_started" | "goal_not_found" | "goal_not_in_progress" | "goal_not_in_tdd_task" | "behavior_not_found" | "behavior_not_in_goal" | "refactor_without_passing_run" | "evidence_not_in_phase_window" | "evidence_not_for_behavior" | "evidence_test_was_already_failing";
2339
+ export type DenialReason = "missing_artifact_evidence" | "wrong_artifact_kind" | "wrong_source_phase" | "unknown_tdd_task" | "tdd_task_already_ended" | "goal_not_started" | "goal_not_found" | "goal_not_in_progress" | "goal_not_in_tdd_task" | "behavior_not_found" | "behavior_not_in_goal" | "refactor_without_passing_run" | "evidence_not_in_phase_window" | "evidence_not_for_behavior" | "evidence_test_was_already_failing";
2202
2340
  /** @public */
2203
- interface Remediation {
2341
+ export interface Remediation {
2204
2342
  readonly suggestedTool: string;
2205
2343
  readonly suggestedArgs: Record<string, unknown>;
2206
2344
  readonly humanHint: string;
2207
2345
  }
2208
2346
  /** @public */
2209
- type PhaseTransitionResult = {
2347
+ export type PhaseTransitionResult = {
2210
2348
  readonly accepted: true;
2211
2349
  readonly phase: Phase;
2212
2350
  } | {
@@ -2225,7 +2363,7 @@ type PhaseTransitionResult = {
2225
2363
  * required artifact (`spike→red`, `*→red`, etc.) return `null`.
2226
2364
  * @public
2227
2365
  */
2228
- declare const requiredArtifactForTransition: (from: Phase, to: Phase) => {
2366
+ export declare const requiredArtifactForTransition: (from: Phase, to: Phase) => {
2229
2367
  kind: ArtifactKind;
2230
2368
  humanHint: string;
2231
2369
  } | null;
@@ -2243,9 +2381,9 @@ declare const requiredArtifactForTransition: (from: Phase, to: Phase) => {
2243
2381
  * keeping the two in lockstep (issue #115).
2244
2382
  * @public
2245
2383
  */
2246
- declare const transitionEnforcesBehaviorMatch: (from: Phase, to: Phase) => boolean;
2384
+ export declare const transitionEnforcesBehaviorMatch: (from: Phase, to: Phase) => boolean;
2247
2385
  /** @public */
2248
- declare const validatePhaseTransition: (ctx: PhaseTransitionContext) => PhaseTransitionResult;
2386
+ export declare const validatePhaseTransition: (ctx: PhaseTransitionContext) => PhaseTransitionResult;
2249
2387
  //#endregion
2250
2388
  //#region src/schemas/Agent.d.ts
2251
2389
  declare const Agent_base: Schema.Class<Agent, Schema.TaggedStruct<"Agent", {
@@ -2271,7 +2409,7 @@ declare const Agent_base: Schema.Class<Agent, Schema.TaggedStruct<"Agent", {
2271
2409
  * two reveals a mid-session branch switch, which is itself signal.
2272
2410
  * @public
2273
2411
  */
2274
- declare class Agent extends Agent_base {}
2412
+ export declare class Agent extends Agent_base {}
2275
2413
  declare const IdempotencyHit_base: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P]; }>) => Readonly<A> & {
2276
2414
  readonly _tag: "IdempotencyHit";
2277
2415
  } & import("effect/Pipeable").Pipeable;
@@ -2286,46 +2424,46 @@ declare const IdempotencyHit_base: new <A extends Record<string, any> = {}>(args
2286
2424
  * downstream code uses `Match.tag` to branch.
2287
2425
  * @public
2288
2426
  */
2289
- declare class IdempotencyHit extends IdempotencyHit_base<{
2427
+ export declare class IdempotencyHit extends IdempotencyHit_base<{
2290
2428
  readonly existingAgentId: typeof AgentId.Type;
2291
2429
  }> {}
2292
2430
  /**
2293
2431
  * Sum type of the two possible outcomes of `registerAgent`.
2294
2432
  * @public
2295
2433
  */
2296
- type RegisterAgentResult = Agent | IdempotencyHit;
2434
+ export type RegisterAgentResult = Agent | IdempotencyHit;
2297
2435
  /**
2298
2436
  * Agent tree — root agent with all descendants nested under
2299
2437
  * `children`. Returned by `DataStore.getAgentTree` for forensics and
2300
2438
  * the `vitest-agent agent list` CLI subcommand.
2301
2439
  * @public
2302
2440
  */
2303
- interface AgentTreeNode {
2441
+ export interface AgentTreeNode {
2304
2442
  readonly agent: Agent;
2305
2443
  readonly children: ReadonlyArray<AgentTreeNode>;
2306
2444
  }
2307
2445
  //#endregion
2308
2446
  //#region src/services/DataStore.d.ts
2309
2447
  /** @public */
2310
- interface CreateGoalInput {
2448
+ export interface CreateGoalInput {
2311
2449
  readonly tddTaskId: number;
2312
2450
  readonly goal: string;
2313
2451
  }
2314
2452
  /** @public */
2315
- interface UpdateGoalInput {
2453
+ export interface UpdateGoalInput {
2316
2454
  readonly id: number;
2317
2455
  readonly goal?: string;
2318
2456
  readonly status?: GoalStatus;
2319
2457
  }
2320
2458
  /** @public */
2321
- interface CreateBehaviorInput {
2459
+ export interface CreateBehaviorInput {
2322
2460
  readonly goalId: number;
2323
2461
  readonly behavior: string;
2324
2462
  readonly suggestedTestName?: string;
2325
2463
  readonly dependsOnBehaviorIds?: ReadonlyArray<number>;
2326
2464
  }
2327
2465
  /** @public */
2328
- interface UpdateBehaviorInput {
2466
+ export interface UpdateBehaviorInput {
2329
2467
  readonly id: number;
2330
2468
  readonly behavior?: string;
2331
2469
  readonly suggestedTestName?: string | null;
@@ -2333,7 +2471,7 @@ interface UpdateBehaviorInput {
2333
2471
  readonly dependsOnBehaviorIds?: ReadonlyArray<number>;
2334
2472
  }
2335
2473
  /** @public */
2336
- interface SettingsInput {
2474
+ export interface SettingsInput {
2337
2475
  readonly vitestVersion: string;
2338
2476
  readonly pool?: string;
2339
2477
  readonly environment?: string;
@@ -2350,7 +2488,7 @@ interface SettingsInput {
2350
2488
  readonly coverageProvider?: string;
2351
2489
  }
2352
2490
  /** @public */
2353
- interface TestRunInput {
2491
+ export interface TestRunInput {
2354
2492
  readonly invocationId: string;
2355
2493
  readonly project: string;
2356
2494
  readonly settingsHash: string;
@@ -2402,7 +2540,7 @@ interface TestRunInput {
2402
2540
  readonly hostMetadata?: Record<string, unknown> | null;
2403
2541
  }
2404
2542
  /** @public */
2405
- interface ModuleInput {
2543
+ export interface ModuleInput {
2406
2544
  readonly fileId: number;
2407
2545
  readonly relativeModuleId: string;
2408
2546
  readonly state: string;
@@ -2414,7 +2552,7 @@ interface ModuleInput {
2414
2552
  readonly heap?: number;
2415
2553
  }
2416
2554
  /** @public */
2417
- interface TestCaseInput {
2555
+ export interface TestCaseInput {
2418
2556
  readonly suiteId?: number;
2419
2557
  readonly vitestId?: string;
2420
2558
  readonly name: string;
@@ -2446,7 +2584,7 @@ interface TestCaseInput {
2446
2584
  readonly createdTurnId?: number;
2447
2585
  }
2448
2586
  /** @public */
2449
- interface StackFrameInput {
2587
+ export interface StackFrameInput {
2450
2588
  readonly ordinal: number;
2451
2589
  readonly method: string | null;
2452
2590
  readonly filePath: string;
@@ -2456,7 +2594,7 @@ interface StackFrameInput {
2456
2594
  readonly functionBoundaryLine?: number;
2457
2595
  }
2458
2596
  /** @public */
2459
- interface TestErrorInput {
2597
+ export interface TestErrorInput {
2460
2598
  readonly testCaseId?: number;
2461
2599
  readonly testSuiteId?: number;
2462
2600
  readonly moduleId?: number;
@@ -2472,8 +2610,50 @@ interface TestErrorInput {
2472
2610
  readonly frames?: ReadonlyArray<StackFrameInput>;
2473
2611
  readonly ordinal?: number;
2474
2612
  }
2613
+ /**
2614
+ * Ceiling on an inline attachment body. Vitest has already copied file
2615
+ * attachments into `.vitest/attachments/`, so a large body is referenced
2616
+ * by `path` rather than duplicated into `data.db`.
2617
+ * @public
2618
+ */
2619
+ export declare const INLINE_ATTACHMENT_BODY_CAP_BYTES: number;
2620
+ /** @public */
2621
+ export interface TestAttachmentInput {
2622
+ readonly contentType?: string;
2623
+ /** Post-resolution path under `.vitest/attachments/`, or an http(s) URL. */
2624
+ readonly path?: string;
2625
+ /** Inline body; persisted only when `byteSize` is under the 64 KiB cap. */
2626
+ readonly body?: string;
2627
+ /** How to read `body`. Vitest treats a string body as base64 unless `"utf-8"`. */
2628
+ readonly bodyEncoding?: "base64" | "utf-8";
2629
+ readonly byteSize: number;
2630
+ }
2631
+ /** @public */
2632
+ export interface TestAnnotationInput {
2633
+ readonly testCaseId: number;
2634
+ /** Arbitrary Vitest annotation type -- not an enum. */
2635
+ readonly type: string;
2636
+ readonly message: string;
2637
+ readonly locationFile?: string;
2638
+ readonly locationLine?: number;
2639
+ readonly locationColumn?: number;
2640
+ readonly attachments?: ReadonlyArray<TestAttachmentInput>;
2641
+ }
2642
+ /** @public */
2643
+ export interface TestArtifactInput {
2644
+ readonly testCaseId: number;
2645
+ /** `pkg:name`; `internal:` types are Vitest's own and are never written. */
2646
+ readonly type: string;
2647
+ readonly message?: string;
2648
+ /** JSON of the artifact's custom fields, minus attachments and location. */
2649
+ readonly data?: string;
2650
+ readonly locationFile?: string;
2651
+ readonly locationLine?: number;
2652
+ readonly locationColumn?: number;
2653
+ readonly attachments?: ReadonlyArray<TestAttachmentInput>;
2654
+ }
2475
2655
  /** @public */
2476
- interface FileCoverageInput {
2656
+ export interface FileCoverageInput {
2477
2657
  readonly fileId: number;
2478
2658
  readonly statements: number;
2479
2659
  readonly branches: number;
@@ -2493,7 +2673,7 @@ interface FileCoverageInput {
2493
2673
  readonly tier?: "below_threshold" | "below_target";
2494
2674
  }
2495
2675
  /** @public */
2496
- interface SuiteInput {
2676
+ export interface SuiteInput {
2497
2677
  readonly parentSuiteId?: number;
2498
2678
  readonly name: string;
2499
2679
  readonly fullName: string;
@@ -2507,7 +2687,7 @@ interface SuiteInput {
2507
2687
  readonly locationColumn?: number;
2508
2688
  }
2509
2689
  /** @public */
2510
- interface NoteInput {
2690
+ export interface NoteInput {
2511
2691
  readonly title: string;
2512
2692
  readonly content: string;
2513
2693
  readonly scope: "global" | "project" | "module" | "suite" | "test" | "note";
@@ -2520,7 +2700,7 @@ interface NoteInput {
2520
2700
  readonly pinned?: boolean;
2521
2701
  }
2522
2702
  /** @public */
2523
- interface SessionInput {
2703
+ export interface SessionInput {
2524
2704
  readonly chatId: string;
2525
2705
  readonly project: string;
2526
2706
  readonly cwd: string;
@@ -2538,7 +2718,7 @@ interface SessionInput {
2538
2718
  readonly conversationId?: string;
2539
2719
  }
2540
2720
  /** @public */
2541
- interface TurnInput {
2721
+ export interface TurnInput {
2542
2722
  readonly sessionId: number;
2543
2723
  /** When omitted, writeTurn computes MAX(turnNo) + 1 for the session. */
2544
2724
  readonly turnNo?: number;
@@ -2547,13 +2727,13 @@ interface TurnInput {
2547
2727
  readonly occurredAt: string;
2548
2728
  }
2549
2729
  /** @public */
2550
- interface FailureSignatureWriteInput {
2730
+ export interface FailureSignatureWriteInput {
2551
2731
  readonly signatureHash: string;
2552
2732
  readonly runId: number;
2553
2733
  readonly seenAt: string;
2554
2734
  }
2555
2735
  /** @public */
2556
- interface HypothesisInput {
2736
+ export interface HypothesisInput {
2557
2737
  readonly sessionId: number;
2558
2738
  readonly content: string;
2559
2739
  readonly createdTurnId?: number;
@@ -2561,21 +2741,21 @@ interface HypothesisInput {
2561
2741
  readonly citedStackFrameId?: number;
2562
2742
  }
2563
2743
  /** @public */
2564
- interface ValidateHypothesisInput {
2744
+ export interface ValidateHypothesisInput {
2565
2745
  readonly id: number;
2566
2746
  readonly outcome: "confirmed" | "refuted" | "abandoned";
2567
2747
  readonly validatedTurnId?: number;
2568
2748
  readonly validatedAt: string;
2569
2749
  }
2570
2750
  /** @public */
2571
- interface IdempotentResponseInput {
2751
+ export interface IdempotentResponseInput {
2572
2752
  readonly procedurePath: string;
2573
2753
  readonly key: string;
2574
2754
  readonly resultJson: string;
2575
2755
  readonly createdAt: string;
2576
2756
  }
2577
2757
  /** @public */
2578
- interface TddTaskInput {
2758
+ export interface TddTaskInput {
2579
2759
  readonly sessionId: number;
2580
2760
  readonly goal: string;
2581
2761
  readonly startedAt: string;
@@ -2583,14 +2763,14 @@ interface TddTaskInput {
2583
2763
  readonly runId?: string;
2584
2764
  }
2585
2765
  /** @public */
2586
- interface EndTddTaskInput {
2766
+ export interface EndTddTaskInput {
2587
2767
  readonly id: number;
2588
2768
  readonly endedAt: string;
2589
2769
  readonly outcome: "succeeded" | "blocked" | "abandoned";
2590
2770
  readonly summaryNoteId?: number;
2591
2771
  }
2592
2772
  /** @public */
2593
- interface WriteTddPhaseInput {
2773
+ export interface WriteTddPhaseInput {
2594
2774
  readonly tddTaskId: number;
2595
2775
  readonly behaviorId?: number;
2596
2776
  readonly phase: Phase;
@@ -2599,12 +2779,12 @@ interface WriteTddPhaseInput {
2599
2779
  readonly parentPhaseId?: number;
2600
2780
  }
2601
2781
  /** @public */
2602
- interface WriteTddPhaseOutput {
2782
+ export interface WriteTddPhaseOutput {
2603
2783
  readonly id: number;
2604
2784
  readonly previousPhaseId: number | null;
2605
2785
  }
2606
2786
  /** @public */
2607
- interface WriteTddArtifactInput {
2787
+ export interface WriteTddArtifactInput {
2608
2788
  readonly phaseId: number;
2609
2789
  readonly artifactKind: ArtifactKind;
2610
2790
  readonly fileId?: number;
@@ -2617,7 +2797,7 @@ interface WriteTddArtifactInput {
2617
2797
  readonly suite?: ArtifactSuite;
2618
2798
  }
2619
2799
  /** @public */
2620
- interface WriteCommitInput {
2800
+ export interface WriteCommitInput {
2621
2801
  readonly sha: string;
2622
2802
  readonly parentSha?: string;
2623
2803
  readonly message?: string;
@@ -2626,20 +2806,20 @@ interface WriteCommitInput {
2626
2806
  readonly branch?: string;
2627
2807
  }
2628
2808
  /** @public */
2629
- type ChangeKind = "added" | "modified" | "deleted" | "renamed" | "untracked-modified";
2809
+ export type ChangeKind = "added" | "modified" | "deleted" | "renamed" | "untracked-modified";
2630
2810
  /** @public */
2631
- interface RunChangedFile {
2811
+ export interface RunChangedFile {
2632
2812
  readonly filePath: string;
2633
2813
  readonly changeKind: ChangeKind;
2634
2814
  readonly commitSha?: string;
2635
2815
  }
2636
2816
  /** @public */
2637
- interface WriteRunChangedFilesInput {
2817
+ export interface WriteRunChangedFilesInput {
2638
2818
  readonly runId: number;
2639
2819
  readonly files: ReadonlyArray<RunChangedFile>;
2640
2820
  }
2641
2821
  /** @public */
2642
- type RunInvocationMethod = "bash" | "mcp" | "cli";
2822
+ export type RunInvocationMethod = "bash" | "mcp" | "cli";
2643
2823
  /**
2644
2824
  * Input to `DataStore.registerAgent`.
2645
2825
  *
@@ -2653,7 +2833,7 @@ type RunInvocationMethod = "bash" | "mcp" | "cli";
2653
2833
  * same row.
2654
2834
  * @public
2655
2835
  */
2656
- interface RegisterAgentInput {
2836
+ export interface RegisterAgentInput {
2657
2837
  readonly sessionId: number;
2658
2838
  readonly agentType: string;
2659
2839
  readonly parentAgentId: string | null;
@@ -2675,7 +2855,7 @@ interface RegisterAgentInput {
2675
2855
  readonly agentId?: string;
2676
2856
  }
2677
2857
  /** @public */
2678
- interface AssociateRunSessionInput {
2858
+ export interface AssociateRunSessionInput {
2679
2859
  readonly chatId: string;
2680
2860
  readonly invocationMethod: RunInvocationMethod;
2681
2861
  }
@@ -2686,6 +2866,17 @@ declare const DataStore_base: Context.ServiceClass<DataStore, "vitest-agent/Data
2686
2866
  readonly writeSuites: (moduleId: number, suites: ReadonlyArray<SuiteInput>) => Effect.Effect<ReadonlyArray<number>, DataStoreError>;
2687
2867
  readonly writeTestCases: (moduleId: number, tests: ReadonlyArray<TestCaseInput>) => Effect.Effect<ReadonlyArray<number>, DataStoreError>;
2688
2868
  readonly writeErrors: (runId: number, errors: ReadonlyArray<TestErrorInput>) => Effect.Effect<void, DataStoreError>;
2869
+ /**
2870
+ * Persist `context.annotate` notes and their attachment descriptors.
2871
+ * `runId` is carried for log correlation only -- `test_annotations`
2872
+ * rows are reachable through `test_cases`.
2873
+ */
2874
+ readonly writeAnnotations: (runId: number, annotations: ReadonlyArray<TestAnnotationInput>) => Effect.Effect<void, DataStoreError>;
2875
+ /**
2876
+ * Persist `recordArtifact` payloads and their attachment
2877
+ * descriptors. `runId` is carried for log correlation only.
2878
+ */
2879
+ readonly writeArtifacts: (runId: number, artifacts: ReadonlyArray<TestArtifactInput>) => Effect.Effect<void, DataStoreError>;
2689
2880
  readonly writeCoverage: (runId: number, coverage: ReadonlyArray<FileCoverageInput>) => Effect.Effect<void, DataStoreError>;
2690
2881
  readonly writeHistory: (project: string, fullName: string, modulePath: string, runId: number, timestamp: string, state: string, duration: number | null, flaky: boolean, retryCount: number, errorMessage: string | null) => Effect.Effect<void, DataStoreError>;
2691
2882
  readonly writeBaselines: (baselines: CoverageBaselines) => Effect.Effect<void, DataStoreError>;
@@ -2783,11 +2974,11 @@ declare const DataStore_base: Context.ServiceClass<DataStore, "vitest-agent/Data
2783
2974
  readonly endAgent: (agentId: string, endedAt: number) => Effect.Effect<void, AgentNotFoundError | DataStoreError>;
2784
2975
  }>;
2785
2976
  /** @public */
2786
- declare class DataStore extends DataStore_base {}
2977
+ export declare class DataStore extends DataStore_base {}
2787
2978
  //#endregion
2788
2979
  //#region src/services/DataReader.d.ts
2789
2980
  /** @public */
2790
- interface ProjectRunSummary {
2981
+ export interface ProjectRunSummary {
2791
2982
  readonly project: string;
2792
2983
  readonly lastRun: string | null;
2793
2984
  readonly lastResult: "passed" | "failed" | "interrupted" | null;
@@ -2797,7 +2988,7 @@ interface ProjectRunSummary {
2797
2988
  readonly skipped: number;
2798
2989
  }
2799
2990
  /** @public */
2800
- interface FlakyTest {
2991
+ export interface FlakyTest {
2801
2992
  readonly fullName: string;
2802
2993
  readonly modulePath: string;
2803
2994
  readonly project: string;
@@ -2807,7 +2998,7 @@ interface FlakyTest {
2807
2998
  readonly lastTimestamp: string;
2808
2999
  }
2809
3000
  /** @public */
2810
- interface PersistentFailure {
3001
+ export interface PersistentFailure {
2811
3002
  readonly fullName: string;
2812
3003
  readonly modulePath: string;
2813
3004
  readonly project: string;
@@ -2817,7 +3008,7 @@ interface PersistentFailure {
2817
3008
  readonly lastErrorMessage: string | null;
2818
3009
  }
2819
3010
  /** @public */
2820
- interface TestError {
3011
+ export interface TestError {
2821
3012
  /** `test_errors.id` — required by `hypothesis (action: record).citedTestErrorId`. */
2822
3013
  readonly id: number;
2823
3014
  /**
@@ -2837,7 +3028,7 @@ interface TestError {
2837
3028
  readonly moduleFile: string | null;
2838
3029
  }
2839
3030
  /** @public */
2840
- interface NoteRow {
3031
+ export interface NoteRow {
2841
3032
  readonly id: number;
2842
3033
  readonly title: string;
2843
3034
  readonly content: string;
@@ -2853,7 +3044,7 @@ interface NoteRow {
2853
3044
  readonly updatedAt: string;
2854
3045
  }
2855
3046
  /** @public */
2856
- interface SettingsRow {
3047
+ export interface SettingsRow {
2857
3048
  readonly hash: string;
2858
3049
  readonly reporters: string | null;
2859
3050
  readonly coverageEnabled: boolean;
@@ -2868,7 +3059,7 @@ interface SettingsRow {
2868
3059
  readonly capturedAt: string;
2869
3060
  }
2870
3061
  /** @public */
2871
- interface TestListEntry {
3062
+ export interface TestListEntry {
2872
3063
  readonly id: number;
2873
3064
  readonly fullName: string;
2874
3065
  readonly state: string;
@@ -2877,7 +3068,7 @@ interface TestListEntry {
2877
3068
  readonly classification: string | null;
2878
3069
  }
2879
3070
  /** @public */
2880
- interface ModuleListEntry {
3071
+ export interface ModuleListEntry {
2881
3072
  readonly id: number;
2882
3073
  readonly file: string;
2883
3074
  readonly state: string;
@@ -2885,7 +3076,7 @@ interface ModuleListEntry {
2885
3076
  readonly duration: number | null;
2886
3077
  }
2887
3078
  /** @public */
2888
- interface SuiteListEntry {
3079
+ export interface SuiteListEntry {
2889
3080
  readonly id: number;
2890
3081
  readonly name: string;
2891
3082
  readonly module: string;
@@ -2893,12 +3084,12 @@ interface SuiteListEntry {
2893
3084
  readonly testCount: number;
2894
3085
  }
2895
3086
  /** @public */
2896
- interface SettingsListEntry {
3087
+ export interface SettingsListEntry {
2897
3088
  readonly hash: string;
2898
3089
  readonly capturedAt: string;
2899
3090
  }
2900
3091
  /** @public */
2901
- interface SessionDetail {
3092
+ export interface SessionDetail {
2902
3093
  readonly id: number;
2903
3094
  readonly chatId: string;
2904
3095
  readonly project: string;
@@ -2914,7 +3105,7 @@ interface SessionDetail {
2914
3105
  readonly conversationId: string | null;
2915
3106
  }
2916
3107
  /** @public */
2917
- interface TurnSummary {
3108
+ export interface TurnSummary {
2918
3109
  readonly id: number;
2919
3110
  readonly sessionId: number;
2920
3111
  readonly turnNo: number;
@@ -2923,7 +3114,7 @@ interface TurnSummary {
2923
3114
  readonly occurredAt: string;
2924
3115
  }
2925
3116
  /** @public */
2926
- interface HistoryQueryOptions {
3117
+ export interface HistoryQueryOptions {
2927
3118
  /** Exact `full_name` match — narrows to a single test's history. */
2928
3119
  readonly testName?: string;
2929
3120
  /** Exact `module_path` match — narrows to tests in one file. */
@@ -2941,7 +3132,7 @@ interface HistoryQueryOptions {
2941
3132
  *
2942
3133
  * @public
2943
3134
  */
2944
- interface ClassificationQueryOptions {
3135
+ export interface ClassificationQueryOptions {
2945
3136
  /** Exact `full_name` match — narrows to a single test's classification. */
2946
3137
  readonly testName?: string;
2947
3138
  /** Exact `module_path` match — narrows to tests in one file. */
@@ -2954,19 +3145,19 @@ interface ClassificationQueryOptions {
2954
3145
  *
2955
3146
  * @public
2956
3147
  */
2957
- interface TestLookupOptions {
3148
+ export interface TestLookupOptions {
2958
3149
  /** Exact `module_path` match — picks one variant of an ambiguous `full_name`. */
2959
3150
  readonly modulePath?: string;
2960
3151
  }
2961
3152
  /** @public */
2962
- interface TurnSearchOptions {
3153
+ export interface TurnSearchOptions {
2963
3154
  readonly sessionId?: number;
2964
3155
  readonly type?: string;
2965
3156
  readonly since?: string;
2966
3157
  readonly limit?: number;
2967
3158
  }
2968
3159
  /** @public */
2969
- interface AcceptanceMetrics {
3160
+ export interface AcceptanceMetrics {
2970
3161
  readonly phaseEvidenceIntegrity: {
2971
3162
  total: number;
2972
3163
  compliant: number;
@@ -2989,7 +3180,7 @@ interface AcceptanceMetrics {
2989
3180
  };
2990
3181
  }
2991
3182
  /** @public */
2992
- interface FailureSignatureDetail {
3183
+ export interface FailureSignatureDetail {
2993
3184
  readonly signatureHash: string;
2994
3185
  readonly firstSeenRunId: number | null;
2995
3186
  readonly firstSeenAt: string;
@@ -3002,7 +3193,7 @@ interface FailureSignatureDetail {
3002
3193
  }>;
3003
3194
  }
3004
3195
  /** @public */
3005
- interface TddPhaseDetail {
3196
+ export interface TddPhaseDetail {
3006
3197
  readonly id: number;
3007
3198
  readonly behaviorId: number | null;
3008
3199
  readonly phase: string;
@@ -3011,7 +3202,7 @@ interface TddPhaseDetail {
3011
3202
  readonly transitionReason: string | null;
3012
3203
  }
3013
3204
  /** @public */
3014
- interface TddArtifactDetail {
3205
+ export interface TddArtifactDetail {
3015
3206
  readonly id: number;
3016
3207
  readonly phaseId: number;
3017
3208
  readonly artifactKind: string;
@@ -3020,7 +3211,7 @@ interface TddArtifactDetail {
3020
3211
  readonly recordedAt: string;
3021
3212
  }
3022
3213
  /** @public */
3023
- interface TddTaskDetail {
3214
+ export interface TddTaskDetail {
3024
3215
  readonly id: number;
3025
3216
  readonly sessionId: number;
3026
3217
  readonly goal: string;
@@ -3033,18 +3224,18 @@ interface TddTaskDetail {
3033
3224
  readonly artifacts: ReadonlyArray<TddArtifactDetail>;
3034
3225
  }
3035
3226
  /** @public */
3036
- interface CurrentTddPhase {
3227
+ export interface CurrentTddPhase {
3037
3228
  readonly id: number;
3038
3229
  readonly phase: Phase;
3039
3230
  readonly startedAt: string;
3040
3231
  readonly behaviorId: number | null;
3041
3232
  }
3042
3233
  /** @public */
3043
- interface CitedArtifactRow extends CitedArtifact {
3234
+ export interface CitedArtifactRow extends CitedArtifact {
3044
3235
  readonly phase_id: number;
3045
3236
  }
3046
3237
  /** @public */
3047
- interface CommitChangesEntry {
3238
+ export interface CommitChangesEntry {
3048
3239
  readonly sha: string;
3049
3240
  readonly parentSha: string | null;
3050
3241
  readonly message: string | null;
@@ -3057,7 +3248,7 @@ interface CommitChangesEntry {
3057
3248
  }>;
3058
3249
  }
3059
3250
  /** @public */
3060
- interface HypothesisDetail {
3251
+ export interface HypothesisDetail {
3061
3252
  readonly id: number;
3062
3253
  readonly sessionId: number;
3063
3254
  readonly content: string;
@@ -3067,7 +3258,7 @@ interface HypothesisDetail {
3067
3258
  readonly validatedAt: string | null;
3068
3259
  }
3069
3260
  /** @public */
3070
- interface TddTaskSummary {
3261
+ export interface TddTaskSummary {
3071
3262
  readonly id: number;
3072
3263
  readonly sessionId: number;
3073
3264
  readonly goal: string;
@@ -3082,7 +3273,7 @@ interface TddTaskSummary {
3082
3273
  *
3083
3274
  * @public
3084
3275
  */
3085
- interface TddArtifactRow {
3276
+ export interface TddArtifactRow {
3086
3277
  readonly id: number;
3087
3278
  readonly tddTaskId: number;
3088
3279
  readonly phaseId: number;
@@ -3096,7 +3287,7 @@ interface TddArtifactRow {
3096
3287
  readonly suite: ArtifactSuite;
3097
3288
  }
3098
3289
  /** @public */
3099
- interface TagInventoryRow {
3290
+ export interface TagInventoryRow {
3100
3291
  /** The tag name (e.g. `"int"`, `"e2e"`, `"unit"`). */
3101
3292
  readonly tag: string;
3102
3293
  /** The Vitest project this tag was observed in. */
@@ -3111,6 +3302,45 @@ interface TagInventoryRow {
3111
3302
  */
3112
3303
  readonly testCount: number;
3113
3304
  }
3305
+ /** @public */
3306
+ export interface TestArtifactQueryOptions {
3307
+ /** Disambiguates a fullName that exists in more than one module. */
3308
+ readonly modulePath?: string;
3309
+ }
3310
+ /** @public */
3311
+ export interface PersistedAttachment {
3312
+ readonly contentType?: string;
3313
+ readonly path?: string;
3314
+ readonly body?: string;
3315
+ /** How to read `body`. Absent when nothing was stored inline. */
3316
+ readonly bodyEncoding?: "base64" | "utf-8";
3317
+ readonly byteSize: number | null;
3318
+ }
3319
+ /** @public */
3320
+ export interface TestAnnotationRow {
3321
+ readonly id: number;
3322
+ readonly type: string;
3323
+ readonly message: string;
3324
+ readonly location?: {
3325
+ readonly file: string;
3326
+ readonly line: number;
3327
+ readonly column: number;
3328
+ };
3329
+ readonly attachments: ReadonlyArray<PersistedAttachment>;
3330
+ }
3331
+ /** @public */
3332
+ export interface TestArtifactRow {
3333
+ readonly id: number;
3334
+ readonly type: string;
3335
+ readonly message: string | null;
3336
+ readonly data: string | null;
3337
+ readonly location?: {
3338
+ readonly file: string;
3339
+ readonly line: number;
3340
+ readonly column: number;
3341
+ };
3342
+ readonly attachments: ReadonlyArray<PersistedAttachment>;
3343
+ }
3114
3344
  declare const DataReader_base: Context.ServiceClass<DataReader, "vitest-agent/DataReader", {
3115
3345
  readonly getLatestRun: (project: string) => Effect.Effect<Option.Option<AgentReport>, DataStoreError>;
3116
3346
  readonly getRunsByProject: () => Effect.Effect<ReadonlyArray<ProjectRunSummary>, DataStoreError>;
@@ -3123,6 +3353,10 @@ declare const DataReader_base: Context.ServiceClass<DataReader, "vitest-agent/Da
3123
3353
  readonly getCoverage: (project: string) => Effect.Effect<Option.Option<CoverageReport>, DataStoreError>;
3124
3354
  readonly getTestsForFile: (filePath: string) => Effect.Effect<ReadonlyArray<string>, DataStoreError>;
3125
3355
  readonly getErrors: (project: string, errorName?: string) => Effect.Effect<ReadonlyArray<TestError>, DataStoreError>;
3356
+ /** Annotations recorded for a test in the project's latest run. */
3357
+ readonly getAnnotationsForTest: (project: string, fullName: string, options?: TestArtifactQueryOptions) => Effect.Effect<ReadonlyArray<TestAnnotationRow>, DataStoreError>;
3358
+ /** Artifacts recorded for a test in the project's latest run. */
3359
+ readonly getArtifactsForTest: (project: string, fullName: string, options?: TestArtifactQueryOptions) => Effect.Effect<ReadonlyArray<TestArtifactRow>, DataStoreError>;
3126
3360
  readonly getNotes: (scope?: string, project?: string, testFullName?: string) => Effect.Effect<ReadonlyArray<NoteRow>, DataStoreError>;
3127
3361
  readonly getNoteById: (id: number) => Effect.Effect<Option.Option<NoteRow>, DataStoreError>;
3128
3362
  readonly searchNotes: (query: string) => Effect.Effect<ReadonlyArray<NoteRow>, DataStoreError>;
@@ -3271,19 +3505,19 @@ declare const DataReader_base: Context.ServiceClass<DataReader, "vitest-agent/Da
3271
3505
  }) => Effect.Effect<ReadonlyArray<TestListEntry>, DataStoreError>;
3272
3506
  }>;
3273
3507
  /** @public */
3274
- declare class DataReader extends DataReader_base {}
3508
+ export declare class DataReader extends DataReader_base {}
3275
3509
  //#endregion
3276
3510
  //#region src/layers/DataReaderLive.d.ts
3277
3511
  /** @public */
3278
- declare const DataReaderLive: Layer.Layer<DataReader, never, SqlClient>;
3512
+ export declare const DataReaderLive: Layer.Layer<DataReader, never, SqlClient>;
3279
3513
  //#endregion
3280
3514
  //#region src/layers/DataStoreLive.d.ts
3281
3515
  /** @public */
3282
- declare const DataStoreLive: Layer.Layer<DataStore, never, SqlClient>;
3516
+ export declare const DataStoreLive: Layer.Layer<DataStore, never, SqlClient>;
3283
3517
  //#endregion
3284
3518
  //#region src/services/DetailResolver.d.ts
3285
3519
  /** @public */
3286
- interface RunHealth {
3520
+ export interface RunHealth {
3287
3521
  readonly hasFailures: boolean;
3288
3522
  readonly belowTargets: boolean;
3289
3523
  readonly hasTargets?: boolean;
@@ -3292,11 +3526,11 @@ declare const DetailResolver_base: Context.ServiceClass<DetailResolver, "vitest-
3292
3526
  readonly resolve: (executor: Executor, health: RunHealth, explicit?: DetailLevel) => Effect.Effect<DetailLevel>;
3293
3527
  }>;
3294
3528
  /** @public */
3295
- declare class DetailResolver extends DetailResolver_base {}
3529
+ export declare class DetailResolver extends DetailResolver_base {}
3296
3530
  //#endregion
3297
3531
  //#region src/layers/DetailResolverLive.d.ts
3298
3532
  /** @public */
3299
- declare const DetailResolverLive: Layer.Layer<DetailResolver, never, never>;
3533
+ export declare const DetailResolverLive: Layer.Layer<DetailResolver, never, never>;
3300
3534
  //#endregion
3301
3535
  //#region src/services/DiscoveryRegistry.d.ts
3302
3536
  /**
@@ -3304,7 +3538,7 @@ declare const DetailResolverLive: Layer.Layer<DetailResolver, never, never>;
3304
3538
  *
3305
3539
  * @public
3306
3540
  */
3307
- interface KnownProjectInput {
3541
+ export interface KnownProjectInput {
3308
3542
  readonly projectKey: string;
3309
3543
  readonly canonicalForm: string;
3310
3544
  readonly dataDbPath: string;
@@ -3316,7 +3550,7 @@ interface KnownProjectInput {
3316
3550
  *
3317
3551
  * @public
3318
3552
  */
3319
- interface KnownProject {
3553
+ export interface KnownProject {
3320
3554
  readonly projectKey: string;
3321
3555
  readonly canonicalForm: string;
3322
3556
  readonly dataDbPath: string;
@@ -3345,11 +3579,11 @@ declare const DiscoveryRegistry_base: Context.ServiceClass<DiscoveryRegistry, "v
3345
3579
  readonly prune: (maxAgeDays: number) => Effect.Effect<number, DataStoreError>;
3346
3580
  }>;
3347
3581
  /** @public */
3348
- declare class DiscoveryRegistry extends DiscoveryRegistry_base {}
3582
+ export declare class DiscoveryRegistry extends DiscoveryRegistry_base {}
3349
3583
  //#endregion
3350
3584
  //#region src/layers/DiscoveryRegistryLive.d.ts
3351
3585
  /** @public */
3352
- declare const DiscoveryRegistryLive: Layer.Layer<DiscoveryRegistry, never, SqlClient>;
3586
+ export declare const DiscoveryRegistryLive: Layer.Layer<DiscoveryRegistry, never, SqlClient>;
3353
3587
  //#endregion
3354
3588
  //#region src/services/EnvironmentDetector.d.ts
3355
3589
  declare const EnvironmentDetector_base: Context.ServiceClass<EnvironmentDetector, "vitest-agent/EnvironmentDetector", {
@@ -3358,15 +3592,15 @@ declare const EnvironmentDetector_base: Context.ServiceClass<EnvironmentDetector
3358
3592
  readonly agentName: Effect.Effect<string | undefined>;
3359
3593
  }>;
3360
3594
  /** @public */
3361
- declare class EnvironmentDetector extends EnvironmentDetector_base {}
3595
+ export declare class EnvironmentDetector extends EnvironmentDetector_base {}
3362
3596
  //#endregion
3363
3597
  //#region src/layers/EnvironmentDetectorLive.d.ts
3364
3598
  /** @public */
3365
- declare const EnvironmentDetectorLive: Layer.Layer<EnvironmentDetector>;
3599
+ export declare const EnvironmentDetectorLive: Layer.Layer<EnvironmentDetector>;
3366
3600
  //#endregion
3367
3601
  //#region src/layers/EnvironmentDetectorTest.d.ts
3368
3602
  /** @public */
3369
- declare const EnvironmentDetectorTest: {
3603
+ export declare const EnvironmentDetectorTest: {
3370
3604
  layer: (env?: Environment) => Layer.Layer<EnvironmentDetector, never, never>;
3371
3605
  };
3372
3606
  //#endregion
@@ -3375,18 +3609,18 @@ declare const ExecutorResolver_base: Context.ServiceClass<ExecutorResolver, "vit
3375
3609
  readonly resolve: (env: Environment) => Effect.Effect<Executor>;
3376
3610
  }>;
3377
3611
  /** @public */
3378
- declare class ExecutorResolver extends ExecutorResolver_base {}
3612
+ export declare class ExecutorResolver extends ExecutorResolver_base {}
3379
3613
  //#endregion
3380
3614
  //#region src/layers/ExecutorResolverLive.d.ts
3381
3615
  /** @public */
3382
- declare const ExecutorResolverLive: Layer.Layer<ExecutorResolver, never, never>;
3616
+ export declare const ExecutorResolverLive: Layer.Layer<ExecutorResolver, never, never>;
3383
3617
  //#endregion
3384
3618
  //#region src/services/FormatSelector.d.ts
3385
3619
  declare const FormatSelector_base: Context.ServiceClass<FormatSelector, "vitest-agent/FormatSelector", {
3386
3620
  readonly select: (executor: Executor, explicitFormat?: OutputFormat, environment?: Environment) => Effect.Effect<OutputFormat>;
3387
3621
  }>;
3388
3622
  /** @public */
3389
- declare class FormatSelector extends FormatSelector_base {}
3623
+ export declare class FormatSelector extends FormatSelector_base {}
3390
3624
  //#endregion
3391
3625
  //#region src/layers/FormatSelectorLive.d.ts
3392
3626
  /**
@@ -3401,14 +3635,14 @@ declare class FormatSelector extends FormatSelector_base {}
3401
3635
  * for surfaces that *do* render it (MCP tools, GitHub step summary).
3402
3636
  * @public
3403
3637
  */
3404
- declare const FormatSelectorLive: Layer.Layer<FormatSelector, never, never>;
3638
+ export declare const FormatSelectorLive: Layer.Layer<FormatSelector, never, never>;
3405
3639
  //#endregion
3406
3640
  //#region src/services/HistoryTracker.d.ts
3407
3641
  /**
3408
3642
  * Lightweight test outcome for history classification.
3409
3643
  * @public
3410
3644
  */
3411
- interface TestOutcome {
3645
+ export interface TestOutcome {
3412
3646
  readonly modulePath: string;
3413
3647
  readonly fullName: string;
3414
3648
  readonly state: "passed" | "failed";
@@ -3424,7 +3658,7 @@ interface TestOutcome {
3424
3658
  * key exists to prevent.
3425
3659
  * @public
3426
3660
  */
3427
- declare const historyKey: (modulePath: string, fullName: string) => string;
3661
+ export declare const historyKey: (modulePath: string, fullName: string) => string;
3428
3662
  declare const HistoryTracker_base: Context.ServiceClass<HistoryTracker, "vitest-agent/HistoryTracker", {
3429
3663
  readonly classify: (project: string, testOutcomes: ReadonlyArray<TestOutcome>, timestamp: string) => Effect.Effect<{
3430
3664
  history: HistoryRecord;
@@ -3432,22 +3666,22 @@ declare const HistoryTracker_base: Context.ServiceClass<HistoryTracker, "vitest-
3432
3666
  }, DataStoreError>;
3433
3667
  }>;
3434
3668
  /** @public */
3435
- declare class HistoryTracker extends HistoryTracker_base {}
3669
+ export declare class HistoryTracker extends HistoryTracker_base {}
3436
3670
  //#endregion
3437
3671
  //#region src/layers/HistoryTrackerLive.d.ts
3438
3672
  /** @public */
3439
- declare const HistoryTrackerLive: Layer.Layer<HistoryTracker, never, DataReader>;
3673
+ export declare const HistoryTrackerLive: Layer.Layer<HistoryTracker, never, DataReader>;
3440
3674
  //#endregion
3441
3675
  //#region src/layers/HistoryTrackerTest.d.ts
3442
3676
  /** @public */
3443
- interface HistoryTrackerTestState {
3677
+ export interface HistoryTrackerTestState {
3444
3678
  readonly classifyCalls: Array<{
3445
3679
  project: string;
3446
3680
  timestamp: string;
3447
3681
  }>;
3448
3682
  }
3449
3683
  /** @public */
3450
- declare const HistoryTrackerTest: {
3684
+ export declare const HistoryTrackerTest: {
3451
3685
  readonly empty: () => HistoryTrackerTestState;
3452
3686
  readonly layer: (state: HistoryTrackerTestState, cannedResult?: {
3453
3687
  history: HistoryRecord;
@@ -3465,29 +3699,29 @@ declare const HistoryTrackerTest: {
3465
3699
  * output.
3466
3700
  * @public
3467
3701
  */
3468
- declare const LoggerLive: (level?: LogLevel.LogLevel, logFile?: string) => Layer.Layer<never>;
3702
+ export declare const LoggerLive: (level?: LogLevel.LogLevel, logFile?: string) => Layer.Layer<never>;
3469
3703
  /** @public */
3470
- declare function resolveLogLevel(option?: string): LogLevel.LogLevel | undefined;
3704
+ export declare function resolveLogLevel(option?: string): LogLevel.LogLevel | undefined;
3471
3705
  /**
3472
3706
  * Resolve log file from option or environment variable.
3473
3707
  * @public
3474
3708
  */
3475
- declare function resolveLogFile(option?: string): string | undefined;
3709
+ export declare function resolveLogFile(option?: string): string | undefined;
3476
3710
  //#endregion
3477
3711
  //#region src/layers/OutputPipelineLive.d.ts
3478
3712
  /** @public */
3479
- declare const OutputPipelineLive: Layer.Layer<DetailResolver | EnvironmentDetector | ExecutorResolver | FormatSelector | OutputRenderer, never, never>;
3713
+ export declare const OutputPipelineLive: Layer.Layer<DetailResolver | EnvironmentDetector | ExecutorResolver | FormatSelector | OutputRenderer, never, never>;
3480
3714
  //#endregion
3481
3715
  //#region src/services/OutputRenderer.d.ts
3482
3716
  declare const OutputRenderer_base: Context.ServiceClass<OutputRenderer, "vitest-agent/OutputRenderer", {
3483
3717
  readonly render: (reports: ReadonlyArray<AgentReport>, format: OutputFormat, context: FormatterContext) => Effect.Effect<ReadonlyArray<RenderedOutput>>;
3484
3718
  }>;
3485
3719
  /** @public */
3486
- declare class OutputRenderer extends OutputRenderer_base {}
3720
+ export declare class OutputRenderer extends OutputRenderer_base {}
3487
3721
  //#endregion
3488
3722
  //#region src/layers/OutputRendererLive.d.ts
3489
3723
  /** @public */
3490
- declare const OutputRendererLive: Layer.Layer<OutputRenderer, never, never>;
3724
+ export declare const OutputRendererLive: Layer.Layer<OutputRenderer, never, never>;
3491
3725
  //#endregion
3492
3726
  //#region src/layers/PathResolutionLive.d.ts
3493
3727
  /**
@@ -3510,23 +3744,23 @@ declare const OutputRendererLive: Layer.Layer<OutputRenderer, never, never>;
3510
3744
  * anchor the config file resolvers and workspace discovery.
3511
3745
  * @public
3512
3746
  */
3513
- declare const PathResolutionLive: (projectDir: string) => Layer.Layer<AppDirs | VitestAgentConfigFile | WorkspaceDiscovery, import("@effected/xdg").XdgEnvError, import("effect/FileSystem").FileSystem | import("effect/Path").Path>;
3747
+ export declare const PathResolutionLive: (projectDir: string) => Layer.Layer<AppDirs | VitestAgentConfigFile | WorkspaceDiscovery, import("@effected/xdg").XdgEnvError, import("effect/FileSystem").FileSystem | import("effect/Path").Path>;
3514
3748
  //#endregion
3515
3749
  //#region src/services/PerClientSessionMap.d.ts
3516
3750
  /** @public */
3517
- interface MapSessionInput {
3751
+ export interface MapSessionInput {
3518
3752
  readonly hostSessionId: string;
3519
3753
  readonly conversationId: string;
3520
3754
  readonly projectKey: string;
3521
3755
  readonly projectDir: string;
3522
3756
  }
3523
3757
  /** @public */
3524
- interface MapSessionOutput {
3758
+ export interface MapSessionOutput {
3525
3759
  readonly mainAgentId: string;
3526
3760
  readonly conversationId: string;
3527
3761
  }
3528
3762
  /** @public */
3529
- interface SessionContextRow {
3763
+ export interface SessionContextRow {
3530
3764
  readonly hostSessionId: string;
3531
3765
  readonly conversationId: string;
3532
3766
  readonly projectKey: string;
@@ -3558,7 +3792,7 @@ declare const PerClientSessionMapReader_base: Context.ServiceClass<PerClientSess
3558
3792
  * methods would be a type error.
3559
3793
  * @public
3560
3794
  */
3561
- declare class PerClientSessionMapReader extends PerClientSessionMapReader_base {}
3795
+ export declare class PerClientSessionMapReader extends PerClientSessionMapReader_base {}
3562
3796
  declare const PerClientSessionMapWriter_base: Context.ServiceClass<PerClientSessionMapWriter, "vitest-agent/PerClientSessionMapWriter", {
3563
3797
  /**
3564
3798
  * Upsert a conversation row. Returns the canonical conversation_id
@@ -3595,7 +3829,7 @@ declare const PerClientSessionMapWriter_base: Context.ServiceClass<PerClientSess
3595
3829
  * one resolve.
3596
3830
  * @public
3597
3831
  */
3598
- declare class PerClientSessionMapWriter extends PerClientSessionMapWriter_base {}
3832
+ export declare class PerClientSessionMapWriter extends PerClientSessionMapWriter_base {}
3599
3833
  //#endregion
3600
3834
  //#region src/layers/PerClientSessionMapLive.d.ts
3601
3835
  /**
@@ -3604,18 +3838,18 @@ declare class PerClientSessionMapWriter extends PerClientSessionMapWriter_base {
3604
3838
  * methods and never declares write methods.
3605
3839
  * @public
3606
3840
  */
3607
- declare const PerClientSessionMapReaderLive: Layer.Layer<PerClientSessionMapReader, never, SqlClient>;
3841
+ export declare const PerClientSessionMapReaderLive: Layer.Layer<PerClientSessionMapReader, never, SqlClient>;
3608
3842
  /**
3609
3843
  * Read-write layer. Provides both write methods and the Reader's read
3610
3844
  * methods so the same layer instance satisfies callers of either
3611
3845
  * tag.
3612
3846
  * @public
3613
3847
  */
3614
- declare const PerClientSessionMapWriterLive: Layer.Layer<PerClientSessionMapWriter | PerClientSessionMapReader, never, SqlClient>;
3848
+ export declare const PerClientSessionMapWriterLive: Layer.Layer<PerClientSessionMapWriter | PerClientSessionMapReader, never, SqlClient>;
3615
3849
  //#endregion
3616
3850
  //#region src/services/ProjectDiscovery.d.ts
3617
3851
  /** @public */
3618
- interface TestFileEntry {
3852
+ export interface TestFileEntry {
3619
3853
  readonly testFile: string;
3620
3854
  readonly sourceFiles: ReadonlyArray<string>;
3621
3855
  }
@@ -3624,15 +3858,15 @@ declare const ProjectDiscovery_base: Context.ServiceClass<ProjectDiscovery, "vit
3624
3858
  readonly mapTestToSource: (testFile: string) => Effect.Effect<ReadonlyArray<string>, DiscoveryError>;
3625
3859
  }>;
3626
3860
  /** @public */
3627
- declare class ProjectDiscovery extends ProjectDiscovery_base {}
3861
+ export declare class ProjectDiscovery extends ProjectDiscovery_base {}
3628
3862
  //#endregion
3629
3863
  //#region src/layers/ProjectDiscoveryLive.d.ts
3630
3864
  /** @public */
3631
- declare const ProjectDiscoveryLive: Layer.Layer<ProjectDiscovery, never, FileSystem.FileSystem>;
3865
+ export declare const ProjectDiscoveryLive: Layer.Layer<ProjectDiscovery, never, FileSystem.FileSystem>;
3632
3866
  //#endregion
3633
3867
  //#region src/layers/ProjectDiscoveryTest.d.ts
3634
3868
  /** @public */
3635
- declare const ProjectDiscoveryTest: {
3869
+ export declare const ProjectDiscoveryTest: {
3636
3870
  readonly layer: (entries: ReadonlyArray<TestFileEntry>) => Layer.Layer<ProjectDiscovery>;
3637
3871
  };
3638
3872
  //#endregion
@@ -3649,13 +3883,13 @@ declare const ProjectDiscoveryTest: {
3649
3883
  * `vitest-agent doctor`-style commands.
3650
3884
  * @public
3651
3885
  */
3652
- interface ResolvedIdentity {
3886
+ export interface ResolvedIdentity {
3653
3887
  readonly projectKey: string;
3654
3888
  readonly canonicalForm: string;
3655
3889
  readonly source: ProjectIdentitySource;
3656
3890
  }
3657
3891
  /** @public */
3658
- type ProjectIdentitySource = "explicit" | "toml" | "git-remote" | "package-repository" | "package-name";
3892
+ export type ProjectIdentitySource = "explicit" | "toml" | "git-remote" | "package-repository" | "package-name";
3659
3893
  /**
3660
3894
  * Per-source candidate values. Each is optional — an absent or empty
3661
3895
  * value causes the resolver to fall through to the next source.
@@ -3664,7 +3898,7 @@ type ProjectIdentitySource = "explicit" | "toml" | "git-remote" | "package-repos
3664
3898
  * subprocess, `package.json` read). Tests pass a literal object.
3665
3899
  * @public
3666
3900
  */
3667
- interface ProjectIdentityCandidates {
3901
+ export interface ProjectIdentityCandidates {
3668
3902
  readonly explicit?: string;
3669
3903
  readonly toml?: string;
3670
3904
  readonly gitRemote?: string;
@@ -3678,7 +3912,7 @@ interface ProjectIdentityCandidates {
3678
3912
  * configured `AgentPlugin({ projectId: "..." })` in `vitest.config.ts`.
3679
3913
  * @public
3680
3914
  */
3681
- interface ResolveProjectIdentityOptions {
3915
+ export interface ResolveProjectIdentityOptions {
3682
3916
  readonly projectId?: string;
3683
3917
  }
3684
3918
  /**
@@ -3692,7 +3926,7 @@ interface ResolveProjectIdentityOptions {
3692
3926
  * shape from `canonicalizeGitUrl`.
3693
3927
  * @public
3694
3928
  */
3695
- declare const resolveProjectIdentityFromCandidates: (candidates: ProjectIdentityCandidates) => ResolvedIdentity | null;
3929
+ export declare const resolveProjectIdentityFromCandidates: (candidates: ProjectIdentityCandidates) => ResolvedIdentity | null;
3696
3930
  declare const ProjectIdentity_base: Context.ServiceClass<ProjectIdentity, "vitest-agent/ProjectIdentity", {
3697
3931
  readonly resolve: (workspaceRoot: string, options?: ResolveProjectIdentityOptions) => Effect.Effect<ResolvedIdentity, ProjectIdentityNotResolvableError>;
3698
3932
  }>;
@@ -3702,7 +3936,7 @@ declare const ProjectIdentity_base: Context.ServiceClass<ProjectIdentity, "vites
3702
3936
  * pre-built `ResolvedIdentity`.
3703
3937
  * @public
3704
3938
  */
3705
- declare class ProjectIdentity extends ProjectIdentity_base {}
3939
+ export declare class ProjectIdentity extends ProjectIdentity_base {}
3706
3940
  //#endregion
3707
3941
  //#region src/layers/ProjectIdentityLive.d.ts
3708
3942
  /**
@@ -3715,7 +3949,7 @@ declare class ProjectIdentity extends ProjectIdentity_base {}
3715
3949
  *
3716
3950
  * @public
3717
3951
  */
3718
- type CandidateContext = FileSystem.FileSystem | WorkspaceDiscovery | VitestAgentConfigFile | ChildProcessSpawner.ChildProcessSpawner;
3952
+ export type CandidateContext = FileSystem.FileSystem | WorkspaceDiscovery | VitestAgentConfigFile | ChildProcessSpawner.ChildProcessSpawner;
3719
3953
  /**
3720
3954
  * Live layer that wires the resolver into real I/O. Requires
3721
3955
  * `FileSystem`, `CommandExecutor`, `WorkspaceDiscovery`, and
@@ -3723,7 +3957,7 @@ type CandidateContext = FileSystem.FileSystem | WorkspaceDiscovery | VitestAgent
3723
3957
  * `NodeServices.layer` at the entry point.
3724
3958
  * @public
3725
3959
  */
3726
- declare const ProjectIdentityLive: Layer.Layer<ProjectIdentity, never, CandidateContext>;
3960
+ export declare const ProjectIdentityLive: Layer.Layer<ProjectIdentity, never, CandidateContext>;
3727
3961
  /**
3728
3962
  * Build a Test layer that returns a fixed `ResolvedIdentity` (or
3729
3963
  * fails with `ProjectIdentityNotResolvableError`). Use in unit tests
@@ -3731,7 +3965,7 @@ declare const ProjectIdentityLive: Layer.Layer<ProjectIdentity, never, Candidate
3731
3965
  * services.
3732
3966
  * @public
3733
3967
  */
3734
- declare const ProjectIdentityTest: (result: ResolvedIdentity | ProjectIdentityNotResolvableError) => Layer.Layer<ProjectIdentity, never, never>;
3968
+ export declare const ProjectIdentityTest: (result: ResolvedIdentity | ProjectIdentityNotResolvableError) => Layer.Layer<ProjectIdentity, never, never>;
3735
3969
  //#endregion
3736
3970
  //#region src/services/RunContext.d.ts
3737
3971
  declare const RunContext_base: Schema.Class<RunContext, Schema.Struct<{
@@ -3755,7 +3989,7 @@ declare const RunContext_base: Schema.Class<RunContext, Schema.Struct<{
3755
3989
  * and `Schema.encode(...)` for the SQLite row mapping.
3756
3990
  * @public
3757
3991
  */
3758
- declare class RunContext extends RunContext_base {}
3992
+ export declare class RunContext extends RunContext_base {}
3759
3993
  declare const AgentContext_base: Schema.Class<AgentContext, Schema.Struct<{
3760
3994
  readonly startGitBranch: Schema.NullOr<Schema.String>;
3761
3995
  readonly startGitCommitSha: Schema.NullOr<Schema.String>;
@@ -3767,7 +4001,7 @@ declare const AgentContext_base: Schema.Class<AgentContext, Schema.Struct<{
3767
4001
  * dirty-tree state and upstream tracking are per-run concerns.
3768
4002
  * @public
3769
4003
  */
3770
- declare class AgentContext extends AgentContext_base {}
4004
+ export declare class AgentContext extends AgentContext_base {}
3771
4005
  declare const RunContext$_base: Context.ServiceClass<RunContext$, "vitest-agent/RunContextService", {
3772
4006
  readonly captureRunContext: (cwd: string) => Effect.Effect<RunContext>;
3773
4007
  readonly captureAgentContext: (cwd: string) => Effect.Effect<AgentContext>;
@@ -3777,7 +4011,7 @@ declare const RunContext$_base: Context.ServiceClass<RunContext$, "vitest-agent/
3777
4011
  * returns whatever the test fixture passes.
3778
4012
  * @public
3779
4013
  */
3780
- declare class RunContext$ extends RunContext$_base {}
4014
+ export declare class RunContext$ extends RunContext$_base {}
3781
4015
  /**
3782
4016
  * Re-export the service tag under a less-collision-prone name. The
3783
4017
  * `RunContext` Schema.Class above shares its symbol-name with the
@@ -3786,9 +4020,9 @@ declare class RunContext$ extends RunContext$_base {}
3786
4020
  *
3787
4021
  * @public
3788
4022
  */
3789
- declare const RunContextService: typeof RunContext$;
4023
+ export declare const RunContextService: typeof RunContext$;
3790
4024
  /** @public */
3791
- type RunContextService = RunContext$;
4025
+ export type RunContextService = RunContext$;
3792
4026
  //#endregion
3793
4027
  //#region src/layers/RunContextLive.d.ts
3794
4028
  /**
@@ -3799,13 +4033,13 @@ type RunContextService = RunContext$;
3799
4033
  * constructs.
3800
4034
  * @public
3801
4035
  */
3802
- declare const RunContextLive: Layer.Layer<RunContextService, never, ChildProcessSpawner.ChildProcessSpawner>;
4036
+ export declare const RunContextLive: Layer.Layer<RunContextService, never, ChildProcessSpawner.ChildProcessSpawner>;
3803
4037
  /**
3804
4038
  * Build a Test layer that returns fixed `RunContext` and
3805
4039
  * `AgentContext` values regardless of `cwd`.
3806
4040
  * @public
3807
4041
  */
3808
- declare const RunContextTest: (fixture: {
4042
+ export declare const RunContextTest: (fixture: {
3809
4043
  readonly runContext: RunContext;
3810
4044
  readonly agentContext: AgentContext;
3811
4045
  }) => Layer.Layer<RunContextService, never, never>;
@@ -3825,7 +4059,7 @@ interface FormatTriageOptions {
3825
4059
  * replaced with empty defaults so the caller is guaranteed a string.
3826
4060
  * @public
3827
4061
  */
3828
- declare const formatTriageEffect: (options?: FormatTriageOptions) => Effect.Effect<string, never, DataReader>;
4062
+ export declare const formatTriageEffect: (options?: FormatTriageOptions) => Effect.Effect<string, never, DataReader>;
3829
4063
  //#endregion
3830
4064
  //#region src/lib/format-wrapup.d.ts
3831
4065
  /** @public */
@@ -3838,12 +4072,37 @@ interface FormatWrapupOptions {
3838
4072
  readonly userPromptHint?: string;
3839
4073
  }
3840
4074
  /** @public */
3841
- declare const formatWrapupEffect: (options: FormatWrapupOptions) => Effect.Effect<string, never, DataReader>;
4075
+ export declare const formatWrapupEffect: (options: FormatWrapupOptions) => Effect.Effect<string, never, DataReader>;
3842
4076
  //#endregion
3843
4077
  //#region src/migrations/0001_initial.d.ts
3844
4078
  /** @internal */
3845
4079
  declare const migration: Effect.Effect<void, import("effect/unstable/sql/SqlError").SqlError, SqlClient>;
3846
4080
  //#endregion
4081
+ //#region src/migrations/0002_test_artifacts.d.ts
4082
+ /** @internal */
4083
+ declare const migration$1: Effect.Effect<void, import("effect/unstable/sql/SqlError").SqlError, SqlClient>;
4084
+ //#endregion
4085
+ //#region src/migrations/index.d.ts
4086
+ /**
4087
+ * Every migration that must run against a per-project `data.db`, keyed by
4088
+ * migration id in application order.
4089
+ *
4090
+ * This is the single source of truth for the project database's migration
4091
+ * set: `ensureMigrated`, the sdk testing layer, `ReporterLive`, `McpLive`,
4092
+ * `CliLive` and `SidecarLive` all pass it straight to
4093
+ * `SqliteMigrator.fromRecord`, so adding a migration file and registering it
4094
+ * here is enough to reach every process that opens a project database.
4095
+ *
4096
+ * The session-map and discovery-registry databases are separate schemas with
4097
+ * their own migrations and are deliberately not listed here.
4098
+ *
4099
+ * @public
4100
+ */
4101
+ export declare const PROJECT_MIGRATIONS: {
4102
+ readonly "0001_initial": import("effect/Effect").Effect<void, import("effect/unstable/sql/SqlError").SqlError, import("effect/unstable/sql/SqlClient").SqlClient>;
4103
+ readonly "0002_test_artifacts": import("effect/Effect").Effect<void, import("effect/unstable/sql/SqlError").SqlError, import("effect/unstable/sql/SqlClient").SqlClient>;
4104
+ };
4105
+ //#endregion
3847
4106
  //#region src/migrations/registry_0001_initial.d.ts
3848
4107
  /**
3849
4108
  * Migration for the global discovery registry SQLite at
@@ -3859,19 +4118,19 @@ declare const migration: Effect.Effect<void, import("effect/unstable/sql/SqlErro
3859
4118
  * the `ON CONFLICT(project_key) DO UPDATE` upsert.
3860
4119
  * @public
3861
4120
  */
3862
- declare const migration$1: Effect.Effect<void, import("effect/unstable/sql/SqlError").SqlError, SqlClient>;
4121
+ declare const migration$2: Effect.Effect<void, import("effect/unstable/sql/SqlError").SqlError, SqlClient>;
3863
4122
  //#endregion
3864
4123
  //#region src/migrations/session_map_0001_initial.d.ts
3865
4124
  /** @internal */
3866
- declare const migration$2: Effect.Effect<void, import("effect/unstable/sql/SqlError").SqlError, SqlClient>;
4125
+ declare const migration$3: Effect.Effect<void, import("effect/unstable/sql/SqlError").SqlError, SqlClient>;
3867
4126
  //#endregion
3868
4127
  //#region src/schemas/ChannelEvent.d.ts
3869
4128
  /** @public */
3870
- declare const SessionOutcome: Schema.Literals<readonly ["succeeded", "blocked", "abandoned"]>;
4129
+ export declare const SessionOutcome: Schema.Literals<readonly ["succeeded", "blocked", "abandoned"]>;
3871
4130
  /** @public */
3872
- type SessionOutcome = typeof SessionOutcome.Type;
4131
+ export type SessionOutcome = typeof SessionOutcome.Type;
3873
4132
  /** @public */
3874
- declare const GoalsReadyEvent: Schema.Struct<{
4133
+ export declare const GoalsReadyEvent: Schema.Struct<{
3875
4134
  readonly type: Schema.Literal<"goals_ready">;
3876
4135
  readonly sessionId: Schema.Number;
3877
4136
  readonly goals: Schema.$Array<Schema.Struct<{
@@ -3881,9 +4140,9 @@ declare const GoalsReadyEvent: Schema.Struct<{
3881
4140
  }>>;
3882
4141
  }>;
3883
4142
  /** @public */
3884
- type GoalsReadyEvent = typeof GoalsReadyEvent.Type;
4143
+ export type GoalsReadyEvent = typeof GoalsReadyEvent.Type;
3885
4144
  /** @public */
3886
- declare const GoalAddedEvent: Schema.Struct<{
4145
+ export declare const GoalAddedEvent: Schema.Struct<{
3887
4146
  readonly type: Schema.Literal<"goal_added">;
3888
4147
  readonly sessionId: Schema.Number;
3889
4148
  readonly goal: Schema.Struct<{
@@ -3893,35 +4152,35 @@ declare const GoalAddedEvent: Schema.Struct<{
3893
4152
  }>;
3894
4153
  }>;
3895
4154
  /** @public */
3896
- type GoalAddedEvent = typeof GoalAddedEvent.Type;
4155
+ export type GoalAddedEvent = typeof GoalAddedEvent.Type;
3897
4156
  /** @public */
3898
- declare const GoalStartedEvent: Schema.Struct<{
4157
+ export declare const GoalStartedEvent: Schema.Struct<{
3899
4158
  readonly type: Schema.Literal<"goal_started">;
3900
4159
  readonly sessionId: Schema.Number;
3901
4160
  readonly goalId: Schema.Number;
3902
4161
  }>;
3903
4162
  /** @public */
3904
- type GoalStartedEvent = typeof GoalStartedEvent.Type;
4163
+ export type GoalStartedEvent = typeof GoalStartedEvent.Type;
3905
4164
  /** @public */
3906
- declare const GoalCompletedEvent: Schema.Struct<{
4165
+ export declare const GoalCompletedEvent: Schema.Struct<{
3907
4166
  readonly type: Schema.Literal<"goal_completed">;
3908
4167
  readonly sessionId: Schema.Number;
3909
4168
  readonly goalId: Schema.Number;
3910
4169
  readonly behaviorIds: Schema.$Array<Schema.Number>;
3911
4170
  }>;
3912
4171
  /** @public */
3913
- type GoalCompletedEvent = typeof GoalCompletedEvent.Type;
4172
+ export type GoalCompletedEvent = typeof GoalCompletedEvent.Type;
3914
4173
  /** @public */
3915
- declare const GoalAbandonedEvent: Schema.Struct<{
4174
+ export declare const GoalAbandonedEvent: Schema.Struct<{
3916
4175
  readonly type: Schema.Literal<"goal_abandoned">;
3917
4176
  readonly sessionId: Schema.Number;
3918
4177
  readonly goalId: Schema.Number;
3919
4178
  readonly reason: Schema.String;
3920
4179
  }>;
3921
4180
  /** @public */
3922
- type GoalAbandonedEvent = typeof GoalAbandonedEvent.Type;
4181
+ export type GoalAbandonedEvent = typeof GoalAbandonedEvent.Type;
3923
4182
  /** @public */
3924
- declare const BehaviorsReadyEvent: Schema.Struct<{
4183
+ export declare const BehaviorsReadyEvent: Schema.Struct<{
3925
4184
  readonly type: Schema.Literal<"behaviors_ready">;
3926
4185
  readonly sessionId: Schema.Number;
3927
4186
  readonly goalId: Schema.Number;
@@ -3932,9 +4191,9 @@ declare const BehaviorsReadyEvent: Schema.Struct<{
3932
4191
  }>>;
3933
4192
  }>;
3934
4193
  /** @public */
3935
- type BehaviorsReadyEvent = typeof BehaviorsReadyEvent.Type;
4194
+ export type BehaviorsReadyEvent = typeof BehaviorsReadyEvent.Type;
3936
4195
  /** @public */
3937
- declare const BehaviorAddedEvent: Schema.Struct<{
4196
+ export declare const BehaviorAddedEvent: Schema.Struct<{
3938
4197
  readonly type: Schema.Literal<"behavior_added">;
3939
4198
  readonly sessionId: Schema.Number;
3940
4199
  readonly goalId: Schema.Number;
@@ -3945,18 +4204,18 @@ declare const BehaviorAddedEvent: Schema.Struct<{
3945
4204
  }>;
3946
4205
  }>;
3947
4206
  /** @public */
3948
- type BehaviorAddedEvent = typeof BehaviorAddedEvent.Type;
4207
+ export type BehaviorAddedEvent = typeof BehaviorAddedEvent.Type;
3949
4208
  /** @public */
3950
- declare const BehaviorStartedEvent: Schema.Struct<{
4209
+ export declare const BehaviorStartedEvent: Schema.Struct<{
3951
4210
  readonly type: Schema.Literal<"behavior_started">;
3952
4211
  readonly sessionId: Schema.Number;
3953
4212
  readonly goalId: Schema.Number;
3954
4213
  readonly behaviorId: Schema.Number;
3955
4214
  }>;
3956
4215
  /** @public */
3957
- type BehaviorStartedEvent = typeof BehaviorStartedEvent.Type;
4216
+ export type BehaviorStartedEvent = typeof BehaviorStartedEvent.Type;
3958
4217
  /** @public */
3959
- declare const PhaseTransitionEvent: Schema.Struct<{
4218
+ export declare const PhaseTransitionEvent: Schema.Struct<{
3960
4219
  readonly type: Schema.Literal<"phase_transition">;
3961
4220
  readonly sessionId: Schema.Number;
3962
4221
  readonly goalId: Schema.Number;
@@ -3965,18 +4224,18 @@ declare const PhaseTransitionEvent: Schema.Struct<{
3965
4224
  readonly to: Schema.Literals<readonly ["spike", "red", "red.triangulate", "green", "green.fake-it", "refactor", "extended-red", "green-without-red"]>;
3966
4225
  }>;
3967
4226
  /** @public */
3968
- type PhaseTransitionEvent = typeof PhaseTransitionEvent.Type;
4227
+ export type PhaseTransitionEvent = typeof PhaseTransitionEvent.Type;
3969
4228
  /** @public */
3970
- declare const BehaviorCompletedEvent: Schema.Struct<{
4229
+ export declare const BehaviorCompletedEvent: Schema.Struct<{
3971
4230
  readonly type: Schema.Literal<"behavior_completed">;
3972
4231
  readonly sessionId: Schema.Number;
3973
4232
  readonly goalId: Schema.Number;
3974
4233
  readonly behaviorId: Schema.Number;
3975
4234
  }>;
3976
4235
  /** @public */
3977
- type BehaviorCompletedEvent = typeof BehaviorCompletedEvent.Type;
4236
+ export type BehaviorCompletedEvent = typeof BehaviorCompletedEvent.Type;
3978
4237
  /** @public */
3979
- declare const BehaviorAbandonedEvent: Schema.Struct<{
4238
+ export declare const BehaviorAbandonedEvent: Schema.Struct<{
3980
4239
  readonly type: Schema.Literal<"behavior_abandoned">;
3981
4240
  readonly sessionId: Schema.Number;
3982
4241
  readonly goalId: Schema.Number;
@@ -3984,9 +4243,9 @@ declare const BehaviorAbandonedEvent: Schema.Struct<{
3984
4243
  readonly reason: Schema.String;
3985
4244
  }>;
3986
4245
  /** @public */
3987
- type BehaviorAbandonedEvent = typeof BehaviorAbandonedEvent.Type;
4246
+ export type BehaviorAbandonedEvent = typeof BehaviorAbandonedEvent.Type;
3988
4247
  /** @public */
3989
- declare const BlockedEvent: Schema.Struct<{
4248
+ export declare const BlockedEvent: Schema.Struct<{
3990
4249
  readonly type: Schema.Literal<"blocked">;
3991
4250
  readonly sessionId: Schema.Number;
3992
4251
  readonly goalId: Schema.Number;
@@ -3995,18 +4254,18 @@ declare const BlockedEvent: Schema.Struct<{
3995
4254
  readonly failureSignatureHash: Schema.optional<Schema.String>;
3996
4255
  }>;
3997
4256
  /** @public */
3998
- type BlockedEvent = typeof BlockedEvent.Type;
4257
+ export type BlockedEvent = typeof BlockedEvent.Type;
3999
4258
  /** @public */
4000
- declare const SessionCompleteEvent: Schema.Struct<{
4259
+ export declare const SessionCompleteEvent: Schema.Struct<{
4001
4260
  readonly type: Schema.Literal<"session_complete">;
4002
4261
  readonly sessionId: Schema.Number;
4003
4262
  readonly goalIds: Schema.$Array<Schema.Number>;
4004
4263
  readonly outcome: Schema.Literals<readonly ["succeeded", "blocked", "abandoned"]>;
4005
4264
  }>;
4006
4265
  /** @public */
4007
- type SessionCompleteEvent = typeof SessionCompleteEvent.Type;
4266
+ export type SessionCompleteEvent = typeof SessionCompleteEvent.Type;
4008
4267
  /** @public */
4009
- declare const ChannelEvent: Schema.Union<readonly [Schema.Struct<{
4268
+ export declare const ChannelEvent: Schema.Union<readonly [Schema.Struct<{
4010
4269
  readonly type: Schema.Literal<"goals_ready">;
4011
4270
  readonly sessionId: Schema.Number;
4012
4271
  readonly goals: Schema.$Array<Schema.Struct<{
@@ -4091,7 +4350,7 @@ declare const ChannelEvent: Schema.Union<readonly [Schema.Struct<{
4091
4350
  readonly outcome: Schema.Literals<readonly ["succeeded", "blocked", "abandoned"]>;
4092
4351
  }>]>;
4093
4352
  /** @public */
4094
- type ChannelEvent = typeof ChannelEvent.Type;
4353
+ export type ChannelEvent = typeof ChannelEvent.Type;
4095
4354
  /**
4096
4355
  * Event types whose `goalId` and `sessionId` should be resolved
4097
4356
  * server-side from `behaviorId` (per spec: "not trusting the
@@ -4099,9 +4358,9 @@ type ChannelEvent = typeof ChannelEvent.Type;
4099
4358
  * which subset to enrich vs pass through.
4100
4359
  * @public
4101
4360
  */
4102
- declare const BehaviorScopedEventTypes: readonly ["behavior_started", "phase_transition", "behavior_completed", "behavior_abandoned", "blocked"];
4361
+ export declare const BehaviorScopedEventTypes: readonly ["behavior_started", "phase_transition", "behavior_completed", "behavior_abandoned", "blocked"];
4103
4362
  /** @public */
4104
- type BehaviorScopedEventType = (typeof BehaviorScopedEventTypes)[number];
4363
+ export type BehaviorScopedEventType = (typeof BehaviorScopedEventTypes)[number];
4105
4364
  //#endregion
4106
4365
  //#region src/schemas/ConsoleLeaks.d.ts
4107
4366
  /**
@@ -4109,7 +4368,7 @@ type BehaviorScopedEventType = (typeof BehaviorScopedEventTypes)[number];
4109
4368
  * (one `console.*` call), not lines.
4110
4369
  * @public
4111
4370
  */
4112
- declare const ConsoleLeakFile: Schema.Struct<{
4371
+ export declare const ConsoleLeakFile: Schema.Struct<{
4113
4372
  readonly file: Schema.String;
4114
4373
  readonly stdout: Schema.Number;
4115
4374
  readonly stderr: Schema.Number;
@@ -4117,7 +4376,7 @@ declare const ConsoleLeakFile: Schema.Struct<{
4117
4376
  readonly sample: Schema.optional<Schema.String>;
4118
4377
  }>;
4119
4378
  /** @public */
4120
- type ConsoleLeakFile = typeof ConsoleLeakFile.Type;
4379
+ export type ConsoleLeakFile = typeof ConsoleLeakFile.Type;
4121
4380
  /**
4122
4381
  * Summary of console output logged inside tests that did NOT pass. Kept
4123
4382
  * separate from `total`/`byFile` so it can never be mistaken for a leak in a
@@ -4126,12 +4385,12 @@ type ConsoleLeakFile = typeof ConsoleLeakFile.Type;
4126
4385
  * genuine leaks on every red run.
4127
4386
  * @public
4128
4387
  */
4129
- declare const ConsoleLeaksFromFailingTests: Schema.Struct<{
4388
+ export declare const ConsoleLeaksFromFailingTests: Schema.Struct<{
4130
4389
  readonly total: Schema.Number;
4131
4390
  readonly files: Schema.Number;
4132
4391
  }>;
4133
4392
  /** @public */
4134
- type ConsoleLeaksFromFailingTests = typeof ConsoleLeaksFromFailingTests.Type;
4393
+ export type ConsoleLeaksFromFailingTests = typeof ConsoleLeaksFromFailingTests.Type;
4135
4394
  /**
4136
4395
  * Aggregate stray-console-output signal for a single test run. Omitted from
4137
4396
  * a report entirely when the run produced no user console output at all
@@ -4141,7 +4400,7 @@ type ConsoleLeaksFromFailingTests = typeof ConsoleLeaksFromFailingTests.Type;
4141
4400
  * visible without polluting the actionable leak signal (issue #263).
4142
4401
  * @public
4143
4402
  */
4144
- declare const ConsoleLeaks: Schema.Struct<{
4403
+ export declare const ConsoleLeaks: Schema.Struct<{
4145
4404
  readonly total: Schema.Number;
4146
4405
  readonly byFile: Schema.$Array<Schema.Struct<{
4147
4406
  readonly file: Schema.String;
@@ -4157,7 +4416,7 @@ declare const ConsoleLeaks: Schema.Struct<{
4157
4416
  }>>;
4158
4417
  }>;
4159
4418
  /** @public */
4160
- type ConsoleLeaks = typeof ConsoleLeaks.Type;
4419
+ export type ConsoleLeaks = typeof ConsoleLeaks.Type;
4161
4420
  //#endregion
4162
4421
  //#region src/schemas/CoverageLevel.d.ts
4163
4422
  declare const CoverageLevel_base: Schema.Class<CoverageLevel, Schema.Struct<{
@@ -4172,7 +4431,7 @@ declare const CoverageLevel_base: Schema.Class<CoverageLevel, Schema.Struct<{
4172
4431
  * perFile flag. Extend this class to define custom named presets.
4173
4432
  * @public
4174
4433
  */
4175
- declare class CoverageLevel extends CoverageLevel_base {
4434
+ export declare class CoverageLevel extends CoverageLevel_base {
4176
4435
  /** No enforcement — all metrics at 0%. */
4177
4436
  static readonly none: CoverageLevel;
4178
4437
  /** Minimal coverage bar — all metrics at 50%. */
@@ -4203,48 +4462,57 @@ declare class CoverageLevel extends CoverageLevel_base {
4203
4462
  }
4204
4463
  /** The named preset identifiers. * @public
4205
4464
  */
4206
- type CoverageLevelName = "none" | "basic" | "standard" | "strict" | "full";
4465
+ export type CoverageLevelName = "none" | "basic" | "standard" | "strict" | "full";
4207
4466
  /** Accepted input forms: a preset name string or a CoverageLevel instance. * @public
4208
4467
  */
4209
- type CoverageInput = CoverageLevelName | CoverageLevel;
4468
+ export type CoverageInput = CoverageLevelName | CoverageLevel;
4210
4469
  /**
4211
4470
  * Resolves a CoverageInput (preset name or CoverageLevel instance) to a
4212
4471
  * CoverageLevel. When input is undefined, returns the named fallback preset.
4213
4472
  * Throws if a string is provided that does not match a known preset name.
4214
4473
  * @public
4215
4474
  */
4216
- declare function resolveCoverageInput(input: CoverageInput | undefined, fallback: CoverageLevelName): CoverageLevel;
4475
+ export declare function resolveCoverageInput(input: CoverageInput | undefined, fallback: CoverageLevelName): CoverageLevel;
4217
4476
  /**
4218
4477
  * Validates that coverageTargets are not below coverageThresholds for any
4219
4478
  * metric, and that both agree on perFile. Throws a descriptive Error on
4220
4479
  * any violation.
4221
4480
  * @public
4222
4481
  */
4223
- declare function validateCoverageConfig(thresholds: CoverageLevel, targets: CoverageLevel): void;
4482
+ export declare function validateCoverageConfig(thresholds: CoverageLevel, targets: CoverageLevel): void;
4224
4483
  //#endregion
4225
4484
  //#region src/schemas/CoverageTargets.d.ts
4226
4485
  /**
4227
4486
  * Per-metric leaf shape for coverageTargets entries. Allows optional
4228
- * numeric targets per metric and the `100: true` shortcut.
4487
+ * numeric targets per metric, the `100: true` shortcut, and — mirroring
4488
+ * Vitest 5 — a per-glob `perFile` setting.
4229
4489
  * @public
4230
4490
  */
4231
- declare const CoverageTargetsMetrics: Schema.Struct<{
4491
+ export declare const CoverageTargetsMetrics: Schema.Struct<{
4232
4492
  readonly lines: Schema.optional<Schema.Number>;
4233
4493
  readonly functions: Schema.optional<Schema.Number>;
4234
4494
  readonly branches: Schema.optional<Schema.Number>;
4235
4495
  readonly statements: Schema.optional<Schema.Number>;
4236
4496
  readonly 100: Schema.optional<Schema.Literal<true>>;
4497
+ readonly perFile: Schema.optional<Schema.Union<readonly [Schema.Boolean, Schema.Struct<{
4498
+ readonly lines: Schema.optional<Schema.Number>;
4499
+ readonly functions: Schema.optional<Schema.Number>;
4500
+ readonly branches: Schema.optional<Schema.Number>;
4501
+ readonly statements: Schema.optional<Schema.Number>;
4502
+ }>]>>;
4237
4503
  }>;
4238
4504
  /** @public */
4239
- type CoverageTargetsMetrics = typeof CoverageTargetsMetrics.Type;
4505
+ export type CoverageTargetsMetrics = typeof CoverageTargetsMetrics.Type;
4240
4506
  /**
4241
4507
  * Typed schema for the coverageTargets option.
4242
4508
  *
4243
4509
  * Mirrors Vitest's coverage.thresholds shape — per-metric positive numbers,
4244
4510
  * the `100: true` shortcut (only valid at key `"100"`), and glob-pattern
4245
4511
  * entries with metric objects. Positive numbers only; negatives and zeros
4246
- * are rejected. `perFile` is not allowed here — inherit it from
4247
- * `coverage.thresholds.perFile`.
4512
+ * are rejected. A top-level `perFile` is not allowed here — set it on
4513
+ * `coverage.thresholds.perFile`. A `perFile` inside a glob-pattern entry
4514
+ * IS allowed, mirroring Vitest 5, where a glob entry no longer inherits
4515
+ * the top-level setting.
4248
4516
  *
4249
4517
  * A decode-time refinement rejects `true` at any key other than `"100"`
4250
4518
  * so `{ statements: true }` fails parse rather than silently flowing
@@ -4252,15 +4520,21 @@ type CoverageTargetsMetrics = typeof CoverageTargetsMetrics.Type;
4252
4520
  * at key `"100"`.
4253
4521
  * @public
4254
4522
  */
4255
- declare const CoverageTargets: Schema.$Record<Schema.String, Schema.Union<readonly [Schema.Number, Schema.Literal<true>, Schema.Struct<{
4523
+ export declare const CoverageTargets: Schema.$Record<Schema.String, Schema.Union<readonly [Schema.Number, Schema.Literal<true>, Schema.Struct<{
4256
4524
  readonly lines: Schema.optional<Schema.Number>;
4257
4525
  readonly functions: Schema.optional<Schema.Number>;
4258
4526
  readonly branches: Schema.optional<Schema.Number>;
4259
4527
  readonly statements: Schema.optional<Schema.Number>;
4260
4528
  readonly 100: Schema.optional<Schema.Literal<true>>;
4529
+ readonly perFile: Schema.optional<Schema.Union<readonly [Schema.Boolean, Schema.Struct<{
4530
+ readonly lines: Schema.optional<Schema.Number>;
4531
+ readonly functions: Schema.optional<Schema.Number>;
4532
+ readonly branches: Schema.optional<Schema.Number>;
4533
+ readonly statements: Schema.optional<Schema.Number>;
4534
+ }>]>>;
4261
4535
  }>]>>;
4262
4536
  /** @public */
4263
- type CoverageTargets = typeof CoverageTargets.Type;
4537
+ export type CoverageTargets = typeof CoverageTargets.Type;
4264
4538
  //#endregion
4265
4539
  //#region src/schemas/Options.d.ts
4266
4540
  /**
@@ -4278,23 +4552,46 @@ type CoverageTargets = typeof CoverageTargets.Type;
4278
4552
  * annotations writer ships.
4279
4553
  * @public
4280
4554
  */
4281
- declare const ConsoleOutputs: Schema.Struct<{
4555
+ export declare const ConsoleOutputs: Schema.Struct<{
4282
4556
  readonly human: Schema.optional<Schema.Literals<readonly ["passthrough", "silent", "stream", "agent"]>>;
4283
4557
  readonly agent: Schema.optional<Schema.Literals<readonly ["passthrough", "silent", "agent"]>>;
4284
4558
  readonly ci: Schema.optional<Schema.Literals<readonly ["passthrough", "silent", "ci-annotations"]>>;
4285
4559
  }>;
4286
4560
  /** @public */
4287
- type ConsoleOutputs = typeof ConsoleOutputs.Type;
4561
+ export type ConsoleOutputs = typeof ConsoleOutputs.Type;
4562
+ /**
4563
+ * Report-file settings. An object overrides the scope directory name
4564
+ * used under `.vitest/`; the default scope is `vitest-agent`.
4565
+ *
4566
+ * @public
4567
+ */
4568
+ export declare const ReportSettings: Schema.Struct<{
4569
+ readonly scope: Schema.optional<Schema.String>;
4570
+ }>;
4571
+ /** @public */
4572
+ export type ReportSettings = typeof ReportSettings.Type;
4573
+ /**
4574
+ * Report-file settings. `false` disables `.vitest/<scope>/` writes
4575
+ * entirely; an object overrides the scope directory name.
4576
+ *
4577
+ * Default: on for the `agent` and `ci` executors, off for `human`.
4578
+ * @public
4579
+ */
4580
+ export declare const ReportOption: Schema.Union<readonly [Schema.Literal<false>, Schema.Struct<{
4581
+ readonly scope: Schema.optional<Schema.String>;
4582
+ }>]>;
4583
+ /** @public */
4584
+ export type ReportOption = typeof ReportOption.Type;
4288
4585
  /**
4289
4586
  * The 2.0 user-facing options for `AgentPlugin`.
4290
4587
  *
4291
- * Five fields total. Two are function-typed (`reporter`, `onRunEvent`)
4588
+ * Six fields total. Two are function-typed (`reporter`, `onRunEvent`)
4292
4589
  * and live on the `AgentPluginConstructorOptions` companion interface in
4293
4590
  * `@vitest-agent/plugin` — Effect Schema cannot encode functions cleanly,
4294
- * so the schema-decodable struct carries the three data-shaped fields.
4591
+ * so the schema-decodable struct carries the four data-shaped fields.
4295
4592
  * @public
4296
4593
  */
4297
- declare const AgentPluginOptions: Schema.Struct<{
4594
+ export declare const AgentPluginOptions: Schema.Struct<{
4298
4595
  readonly console: Schema.optional<Schema.Struct<{
4299
4596
  readonly human: Schema.optional<Schema.Literals<readonly ["passthrough", "silent", "stream", "agent"]>>;
4300
4597
  readonly agent: Schema.optional<Schema.Literals<readonly ["passthrough", "silent", "agent"]>>;
@@ -4306,13 +4603,22 @@ declare const AgentPluginOptions: Schema.Struct<{
4306
4603
  readonly branches: Schema.optional<Schema.Number>;
4307
4604
  readonly statements: Schema.optional<Schema.Number>;
4308
4605
  readonly 100: Schema.optional<Schema.Literal<true>>;
4606
+ readonly perFile: Schema.optional<Schema.Union<readonly [Schema.Boolean, Schema.Struct<{
4607
+ readonly lines: Schema.optional<Schema.Number>;
4608
+ readonly functions: Schema.optional<Schema.Number>;
4609
+ readonly branches: Schema.optional<Schema.Number>;
4610
+ readonly statements: Schema.optional<Schema.Number>;
4611
+ }>]>>;
4309
4612
  }>]>>>;
4310
4613
  readonly transport: Schema.optional<Schema.Union<readonly [Schema.Struct<{
4311
4614
  readonly kind: Schema.Literal<"local">;
4312
4615
  }>]>>;
4616
+ readonly report: Schema.optional<Schema.Union<readonly [Schema.Literal<false>, Schema.Struct<{
4617
+ readonly scope: Schema.optional<Schema.String>;
4618
+ }>]>>;
4313
4619
  }>;
4314
4620
  /** @public */
4315
- type AgentPluginOptions = typeof AgentPluginOptions.Type;
4621
+ export type AgentPluginOptions = typeof AgentPluginOptions.Type;
4316
4622
  /**
4317
4623
  * Reporter-implementation options.
4318
4624
  *
@@ -4324,16 +4630,292 @@ type AgentPluginOptions = typeof AgentPluginOptions.Type;
4324
4630
  * (currently only `projectFilter` for per-project scoping).
4325
4631
  * @public
4326
4632
  */
4327
- declare const AgentReporterOptions: Schema.Struct<{
4633
+ export declare const AgentReporterOptions: Schema.Struct<{
4328
4634
  /** Set by the plugin per-project. Filters reports to one project. */
4329
4635
  readonly projectFilter: Schema.optional<Schema.String>;
4330
4636
  }>;
4331
4637
  /** @public */
4332
- type AgentReporterOptions = typeof AgentReporterOptions.Type;
4638
+ export type AgentReporterOptions = typeof AgentReporterOptions.Type;
4639
+ //#endregion
4640
+ //#region src/schemas/RunReportFile.d.ts
4641
+ /**
4642
+ * Canonical `$schema` URL for `RunReportFile` version 1.
4643
+ *
4644
+ * Written as the first key of `run.json` so an editor or a JSON Schema
4645
+ * validator can resolve the contract without knowing about vitest-agent.
4646
+ *
4647
+ * @public
4648
+ */
4649
+ export declare const RUN_REPORT_FILE_SCHEMA_URL = "https://vitest-agent.dev/schemas/run-report-file-1.0.0.json";
4650
+ /**
4651
+ * Envelope for the `run.json` report file.
4652
+ *
4653
+ * @public
4654
+ */
4655
+ export declare const RunReportFile: Schema.Struct<{
4656
+ readonly $schema: Schema.optionalKey<Schema.String>;
4657
+ readonly schemaVersion: Schema.Literal<1>;
4658
+ readonly generatedAt: Schema.String;
4659
+ readonly reports: Schema.$Array<Schema.Struct<{
4660
+ readonly timestamp: Schema.String;
4661
+ readonly project: Schema.optional<Schema.String>;
4662
+ readonly reason: Schema.Literals<readonly ["passed", "failed", "interrupted"]>;
4663
+ readonly summary: Schema.Struct<{
4664
+ readonly total: Schema.Number;
4665
+ readonly passed: Schema.Number;
4666
+ readonly failed: Schema.Number;
4667
+ readonly skipped: Schema.Number;
4668
+ readonly duration: Schema.Number;
4669
+ readonly modules: Schema.optional<Schema.Number>;
4670
+ }>;
4671
+ readonly failed: Schema.$Array<Schema.Struct<{
4672
+ readonly file: Schema.String;
4673
+ readonly state: Schema.Literals<readonly ["passed", "failed", "skipped", "pending"]>;
4674
+ readonly duration: Schema.optional<Schema.Number>;
4675
+ readonly errors: Schema.optional<Schema.$Array<Schema.Struct<{
4676
+ readonly message: Schema.String;
4677
+ readonly stack: Schema.optional<Schema.String>;
4678
+ readonly diff: Schema.optional<Schema.String>;
4679
+ readonly expected: Schema.optional<Schema.String>;
4680
+ readonly received: Schema.optional<Schema.String>;
4681
+ }>>>;
4682
+ readonly tests: Schema.$Array<Schema.Struct<{
4683
+ readonly name: Schema.String;
4684
+ readonly fullName: Schema.String;
4685
+ readonly state: Schema.Literals<readonly ["passed", "failed", "skipped", "pending"]>;
4686
+ readonly duration: Schema.optional<Schema.Number>;
4687
+ readonly flaky: Schema.optional<Schema.Boolean>;
4688
+ readonly slow: Schema.optional<Schema.Boolean>;
4689
+ readonly errors: Schema.optional<Schema.$Array<Schema.Struct<{
4690
+ readonly message: Schema.String;
4691
+ readonly stack: Schema.optional<Schema.String>;
4692
+ readonly diff: Schema.optional<Schema.String>;
4693
+ readonly expected: Schema.optional<Schema.String>;
4694
+ readonly received: Schema.optional<Schema.String>;
4695
+ }>>>;
4696
+ readonly classification: Schema.optional<Schema.Literals<readonly ["stable", "new-failure", "persistent", "flaky", "recovered"]>>;
4697
+ }>>;
4698
+ }>>;
4699
+ readonly unhandledErrors: Schema.$Array<Schema.Struct<{
4700
+ readonly message: Schema.String;
4701
+ readonly stack: Schema.optional<Schema.String>;
4702
+ readonly diff: Schema.optional<Schema.String>;
4703
+ readonly expected: Schema.optional<Schema.String>;
4704
+ readonly received: Schema.optional<Schema.String>;
4705
+ }>>;
4706
+ readonly failedFiles: Schema.$Array<Schema.String>;
4707
+ readonly coverage: Schema.optional<Schema.Struct<{
4708
+ readonly totals: Schema.Struct<{
4709
+ readonly statements: Schema.Number;
4710
+ readonly branches: Schema.Number;
4711
+ readonly functions: Schema.Number;
4712
+ readonly lines: Schema.Number;
4713
+ }>;
4714
+ readonly thresholds: Schema.Struct<{
4715
+ readonly global: Schema.Struct<{
4716
+ readonly lines: Schema.optional<Schema.Number>;
4717
+ readonly functions: Schema.optional<Schema.Number>;
4718
+ readonly branches: Schema.optional<Schema.Number>;
4719
+ readonly statements: Schema.optional<Schema.Number>;
4720
+ }>;
4721
+ readonly patterns: Schema.withDecodingDefaultKey<Schema.$Array<Schema.Tuple<readonly [Schema.String, Schema.Struct<{
4722
+ readonly lines: Schema.optional<Schema.Number>;
4723
+ readonly functions: Schema.optional<Schema.Number>;
4724
+ readonly branches: Schema.optional<Schema.Number>;
4725
+ readonly statements: Schema.optional<Schema.Number>;
4726
+ readonly perFile: Schema.optionalKey<Schema.Union<readonly [Schema.Boolean, Schema.Struct<{
4727
+ readonly lines: Schema.optional<Schema.Number>;
4728
+ readonly functions: Schema.optional<Schema.Number>;
4729
+ readonly branches: Schema.optional<Schema.Number>;
4730
+ readonly statements: Schema.optional<Schema.Number>;
4731
+ }>]>>;
4732
+ }>]>>, never>;
4733
+ }>;
4734
+ readonly targets: Schema.optional<Schema.Struct<{
4735
+ readonly global: Schema.Struct<{
4736
+ readonly lines: Schema.optional<Schema.Number>;
4737
+ readonly functions: Schema.optional<Schema.Number>;
4738
+ readonly branches: Schema.optional<Schema.Number>;
4739
+ readonly statements: Schema.optional<Schema.Number>;
4740
+ }>;
4741
+ readonly patterns: Schema.withDecodingDefaultKey<Schema.$Array<Schema.Tuple<readonly [Schema.String, Schema.Struct<{
4742
+ readonly lines: Schema.optional<Schema.Number>;
4743
+ readonly functions: Schema.optional<Schema.Number>;
4744
+ readonly branches: Schema.optional<Schema.Number>;
4745
+ readonly statements: Schema.optional<Schema.Number>;
4746
+ readonly perFile: Schema.optionalKey<Schema.Union<readonly [Schema.Boolean, Schema.Struct<{
4747
+ readonly lines: Schema.optional<Schema.Number>;
4748
+ readonly functions: Schema.optional<Schema.Number>;
4749
+ readonly branches: Schema.optional<Schema.Number>;
4750
+ readonly statements: Schema.optional<Schema.Number>;
4751
+ }>]>>;
4752
+ }>]>>, never>;
4753
+ }>>;
4754
+ readonly baselines: Schema.optional<Schema.Struct<{
4755
+ readonly global: Schema.Struct<{
4756
+ readonly lines: Schema.optional<Schema.Number>;
4757
+ readonly functions: Schema.optional<Schema.Number>;
4758
+ readonly branches: Schema.optional<Schema.Number>;
4759
+ readonly statements: Schema.optional<Schema.Number>;
4760
+ }>;
4761
+ readonly patterns: Schema.withDecodingDefaultKey<Schema.$Array<Schema.Tuple<readonly [Schema.String, Schema.Struct<{
4762
+ readonly lines: Schema.optional<Schema.Number>;
4763
+ readonly functions: Schema.optional<Schema.Number>;
4764
+ readonly branches: Schema.optional<Schema.Number>;
4765
+ readonly statements: Schema.optional<Schema.Number>;
4766
+ readonly perFile: Schema.optionalKey<Schema.Union<readonly [Schema.Boolean, Schema.Struct<{
4767
+ readonly lines: Schema.optional<Schema.Number>;
4768
+ readonly functions: Schema.optional<Schema.Number>;
4769
+ readonly branches: Schema.optional<Schema.Number>;
4770
+ readonly statements: Schema.optional<Schema.Number>;
4771
+ }>]>>;
4772
+ }>]>>, never>;
4773
+ }>>;
4774
+ readonly scoped: Schema.withDecodingDefaultKey<Schema.Boolean, never>;
4775
+ readonly scopedFiles: Schema.optional<Schema.$Array<Schema.String>>;
4776
+ readonly totalFiles: Schema.optional<Schema.Number>;
4777
+ readonly lowCoverage: Schema.$Array<Schema.Struct<{
4778
+ readonly file: Schema.String;
4779
+ readonly summary: Schema.Struct<{
4780
+ readonly statements: Schema.Number;
4781
+ readonly branches: Schema.Number;
4782
+ readonly functions: Schema.Number;
4783
+ readonly lines: Schema.Number;
4784
+ }>;
4785
+ readonly uncoveredLines: Schema.String;
4786
+ }>>;
4787
+ readonly lowCoverageFiles: Schema.$Array<Schema.String>;
4788
+ readonly belowTarget: Schema.optional<Schema.$Array<Schema.Struct<{
4789
+ readonly file: Schema.String;
4790
+ readonly summary: Schema.Struct<{
4791
+ readonly statements: Schema.Number;
4792
+ readonly branches: Schema.Number;
4793
+ readonly functions: Schema.Number;
4794
+ readonly lines: Schema.Number;
4795
+ }>;
4796
+ readonly uncoveredLines: Schema.String;
4797
+ }>>>;
4798
+ readonly belowTargetFiles: Schema.optional<Schema.$Array<Schema.String>>;
4799
+ }>>;
4800
+ readonly tagCounts: Schema.optional<Schema.$Record<Schema.String, Schema.Struct<{
4801
+ readonly passed: Schema.optional<Schema.Number>;
4802
+ readonly failed: Schema.optional<Schema.Number>;
4803
+ readonly skipped: Schema.optional<Schema.Number>;
4804
+ }>>>;
4805
+ readonly consoleLeaks: Schema.optional<Schema.Struct<{
4806
+ readonly total: Schema.Number;
4807
+ readonly byFile: Schema.$Array<Schema.Struct<{
4808
+ readonly file: Schema.String;
4809
+ readonly stdout: Schema.Number;
4810
+ readonly stderr: Schema.Number;
4811
+ readonly tests: Schema.optional<Schema.$Array<Schema.String>>;
4812
+ readonly sample: Schema.optional<Schema.String>;
4813
+ }>>;
4814
+ readonly truncated: Schema.optional<Schema.Boolean>;
4815
+ readonly fromFailingTests: Schema.optional<Schema.Struct<{
4816
+ readonly total: Schema.Number;
4817
+ readonly files: Schema.Number;
4818
+ }>>;
4819
+ }>>;
4820
+ }>>;
4821
+ }>;
4822
+ /** @public */
4823
+ export type RunReportFile = typeof RunReportFile.Type;
4824
+ //#endregion
4825
+ //#region src/schemas/TestArtifacts.d.ts
4826
+ /**
4827
+ * Source position a test annotation or test artifact points at.
4828
+ * @public
4829
+ */
4830
+ export declare const TestArtifactLocation: Schema.Struct<{
4831
+ readonly file: Schema.String;
4832
+ readonly line: Schema.Number;
4833
+ readonly column: Schema.Number;
4834
+ }>;
4835
+ /** @public */
4836
+ export type TestArtifactLocation = typeof TestArtifactLocation.Type;
4837
+ /**
4838
+ * One attachment descriptor.
4839
+ *
4840
+ * `path` is the location Vitest already rewrote the attachment to
4841
+ * (usually under `.vitest/attachments/`) or an external `http(s)` URL —
4842
+ * vitest-agent never copies the file itself. `byteSize` is always
4843
+ * recorded so a dangling path stays describable. Vitest treats a string
4844
+ * `body` as base64 unless `bodyEncoding` is `"utf-8"`.
4845
+ *
4846
+ * `body` and `bodyEncoding` are populated only on the persistence path,
4847
+ * for inline attachments under the 64 KiB cap. Attachments carried by
4848
+ * `TestAnnotated` and `TestArtifactRecorded` run events are descriptors
4849
+ * only — never assume an event attachment has a body; read the stored
4850
+ * row when the bytes are needed.
4851
+ * @public
4852
+ */
4853
+ export declare const TestAttachment: Schema.Struct<{
4854
+ readonly contentType: Schema.optional<Schema.String>;
4855
+ readonly path: Schema.optional<Schema.String>;
4856
+ readonly body: Schema.optional<Schema.String>;
4857
+ readonly bodyEncoding: Schema.optional<Schema.Literals<readonly ["base64", "utf-8"]>>;
4858
+ readonly byteSize: Schema.Number;
4859
+ }>;
4860
+ /** @public */
4861
+ export type TestAttachment = typeof TestAttachment.Type;
4862
+ /**
4863
+ * A test annotation as recorded by `context.annotate`.
4864
+ *
4865
+ * `type` is an arbitrary string — Vitest applies no enum
4866
+ * (`.repos/vitest/packages/vitest/src/runtime/runner/types.ts`).
4867
+ * @public
4868
+ */
4869
+ export declare const TestAnnotation: Schema.Struct<{
4870
+ readonly type: Schema.String;
4871
+ readonly message: Schema.String;
4872
+ readonly location: Schema.optional<Schema.Struct<{
4873
+ readonly file: Schema.String;
4874
+ readonly line: Schema.Number;
4875
+ readonly column: Schema.Number;
4876
+ }>>;
4877
+ readonly attachments: Schema.$Array<Schema.Struct<{
4878
+ readonly contentType: Schema.optional<Schema.String>;
4879
+ readonly path: Schema.optional<Schema.String>;
4880
+ readonly body: Schema.optional<Schema.String>;
4881
+ readonly bodyEncoding: Schema.optional<Schema.Literals<readonly ["base64", "utf-8"]>>;
4882
+ readonly byteSize: Schema.Number;
4883
+ }>>;
4884
+ }>;
4885
+ /** @public */
4886
+ export type TestAnnotation = typeof TestAnnotation.Type;
4887
+ /**
4888
+ * A test artifact as recorded by `recordArtifact`.
4889
+ *
4890
+ * `data` is the JSON encoding of the artifact's custom fields, minus
4891
+ * `attachments` and `location` (both modelled separately). Artifacts
4892
+ * whose `type` starts with `internal:` are Vitest's own and are not
4893
+ * persisted.
4894
+ * @public
4895
+ */
4896
+ export declare const TestArtifact: Schema.Struct<{
4897
+ readonly type: Schema.String;
4898
+ readonly message: Schema.optional<Schema.String>;
4899
+ readonly data: Schema.optional<Schema.String>;
4900
+ readonly location: Schema.optional<Schema.Struct<{
4901
+ readonly file: Schema.String;
4902
+ readonly line: Schema.Number;
4903
+ readonly column: Schema.Number;
4904
+ }>>;
4905
+ readonly attachments: Schema.$Array<Schema.Struct<{
4906
+ readonly contentType: Schema.optional<Schema.String>;
4907
+ readonly path: Schema.optional<Schema.String>;
4908
+ readonly body: Schema.optional<Schema.String>;
4909
+ readonly bodyEncoding: Schema.optional<Schema.Literals<readonly ["base64", "utf-8"]>>;
4910
+ readonly byteSize: Schema.Number;
4911
+ }>>;
4912
+ }>;
4913
+ /** @public */
4914
+ export type TestArtifact = typeof TestArtifact.Type;
4333
4915
  //#endregion
4334
4916
  //#region src/schemas/turns/FileEditPayload.d.ts
4335
4917
  /** @public */
4336
- declare const FileEditPayload: Schema.Struct<{
4918
+ export declare const FileEditPayload: Schema.Struct<{
4337
4919
  readonly type: Schema.Literal<"file_edit">;
4338
4920
  readonly file_path: Schema.String;
4339
4921
  readonly edit_kind: Schema.Literals<readonly ["write", "edit", "multi_edit"]>;
@@ -4342,55 +4924,55 @@ declare const FileEditPayload: Schema.Struct<{
4342
4924
  readonly diff: Schema.optional<Schema.String>;
4343
4925
  }>;
4344
4926
  /** @public */
4345
- type FileEditPayload = typeof FileEditPayload.Type;
4927
+ export type FileEditPayload = typeof FileEditPayload.Type;
4346
4928
  //#endregion
4347
4929
  //#region src/schemas/turns/HookFirePayload.d.ts
4348
4930
  /** @public */
4349
- declare const HookFirePayload: Schema.Struct<{
4931
+ export declare const HookFirePayload: Schema.Struct<{
4350
4932
  readonly type: Schema.Literal<"hook_fire">;
4351
4933
  readonly hook_kind: Schema.Literals<readonly ["SessionStart", "SessionEnd", "Stop", "StopFailure", "SubagentStart", "SubagentStop", "PreCompact", "PostCompact", "PreToolUse", "PostToolUse", "PostToolUseFailure", "UserPromptSubmit", "FileChanged"]>;
4352
4934
  readonly chat_id: Schema.optional<Schema.String>;
4353
4935
  readonly previous_record_failures: Schema.optional<Schema.$Array<Schema.String>>;
4354
4936
  }>;
4355
4937
  /** @public */
4356
- type HookFirePayload = typeof HookFirePayload.Type;
4938
+ export type HookFirePayload = typeof HookFirePayload.Type;
4357
4939
  //#endregion
4358
4940
  //#region src/schemas/turns/HypothesisPayload.d.ts
4359
4941
  /** @public */
4360
- declare const HypothesisPayload: Schema.Struct<{
4942
+ export declare const HypothesisPayload: Schema.Struct<{
4361
4943
  readonly type: Schema.Literal<"hypothesis">;
4362
4944
  readonly content: Schema.String;
4363
4945
  readonly cited_test_error_id: Schema.optional<Schema.Number>;
4364
4946
  readonly cited_stack_frame_id: Schema.optional<Schema.Number>;
4365
4947
  }>;
4366
4948
  /** @public */
4367
- type HypothesisPayload = typeof HypothesisPayload.Type;
4949
+ export type HypothesisPayload = typeof HypothesisPayload.Type;
4368
4950
  //#endregion
4369
4951
  //#region src/schemas/turns/NotePayload.d.ts
4370
4952
  /** @public */
4371
- declare const NotePayload: Schema.Struct<{
4953
+ export declare const NotePayload: Schema.Struct<{
4372
4954
  readonly type: Schema.Literal<"note">;
4373
4955
  readonly scope: Schema.String;
4374
4956
  readonly title: Schema.optional<Schema.String>;
4375
4957
  readonly content: Schema.String;
4376
4958
  }>;
4377
4959
  /** @public */
4378
- type NotePayload = typeof NotePayload.Type;
4960
+ export type NotePayload = typeof NotePayload.Type;
4379
4961
  //#endregion
4380
4962
  //#region src/schemas/turns/ToolCallPayload.d.ts
4381
4963
  /** @public */
4382
- declare const ToolCallPayload: Schema.Struct<{
4964
+ export declare const ToolCallPayload: Schema.Struct<{
4383
4965
  readonly type: Schema.Literal<"tool_call">;
4384
4966
  readonly tool_name: Schema.String;
4385
4967
  readonly tool_input: Schema.Unknown;
4386
4968
  readonly tool_use_id: Schema.optional<Schema.String>;
4387
4969
  }>;
4388
4970
  /** @public */
4389
- type ToolCallPayload = typeof ToolCallPayload.Type;
4971
+ export type ToolCallPayload = typeof ToolCallPayload.Type;
4390
4972
  //#endregion
4391
4973
  //#region src/schemas/turns/ToolResultPayload.d.ts
4392
4974
  /** @public */
4393
- declare const ToolResultPayload: Schema.Struct<{
4975
+ export declare const ToolResultPayload: Schema.Struct<{
4394
4976
  readonly type: Schema.Literal<"tool_result">;
4395
4977
  readonly tool_name: Schema.String;
4396
4978
  readonly tool_use_id: Schema.optional<Schema.String>;
@@ -4399,21 +4981,21 @@ declare const ToolResultPayload: Schema.Struct<{
4399
4981
  readonly duration_ms: Schema.optional<Schema.Number>;
4400
4982
  }>;
4401
4983
  /** @public */
4402
- type ToolResultPayload = typeof ToolResultPayload.Type;
4984
+ export type ToolResultPayload = typeof ToolResultPayload.Type;
4403
4985
  //#endregion
4404
4986
  //#region src/schemas/turns/UserPromptPayload.d.ts
4405
4987
  /** @public */
4406
- declare const UserPromptPayload: Schema.Struct<{
4988
+ export declare const UserPromptPayload: Schema.Struct<{
4407
4989
  readonly type: Schema.Literal<"user_prompt">;
4408
4990
  readonly prompt: Schema.String;
4409
4991
  readonly cc_message_id: Schema.optional<Schema.String>;
4410
4992
  }>;
4411
4993
  /** @public */
4412
- type UserPromptPayload = typeof UserPromptPayload.Type;
4994
+ export type UserPromptPayload = typeof UserPromptPayload.Type;
4413
4995
  //#endregion
4414
4996
  //#region src/schemas/turns/index.d.ts
4415
4997
  /** @public */
4416
- declare const TurnPayload: Schema.Union<readonly [Schema.Struct<{
4998
+ export declare const TurnPayload: Schema.Union<readonly [Schema.Struct<{
4417
4999
  readonly type: Schema.Literal<"user_prompt">;
4418
5000
  readonly prompt: Schema.String;
4419
5001
  readonly cc_message_id: Schema.optional<Schema.String>;
@@ -4453,7 +5035,7 @@ declare const TurnPayload: Schema.Union<readonly [Schema.Struct<{
4453
5035
  readonly cited_stack_frame_id: Schema.optional<Schema.Number>;
4454
5036
  }>]>;
4455
5037
  /** @public */
4456
- type TurnPayload = typeof TurnPayload.Type;
5038
+ export type TurnPayload = typeof TurnPayload.Type;
4457
5039
  //#endregion
4458
5040
  //#region src/services/idempotency.d.ts
4459
5041
  /**
@@ -4462,9 +5044,9 @@ type TurnPayload = typeof TurnPayload.Type;
4462
5044
  * string, both of which could collide with caller-supplied values.
4463
5045
  * @public
4464
5046
  */
4465
- declare const IDEMPOTENCY_ROOT_SENTINEL = "__ROOT__";
5047
+ export declare const IDEMPOTENCY_ROOT_SENTINEL = "__ROOT__";
4466
5048
  /** @public */
4467
- interface IdempotencyInput {
5049
+ export interface IdempotencyInput {
4468
5050
  readonly agentType: string;
4469
5051
  readonly parentAgentId: string | null;
4470
5052
  readonly clientNonce: string;
@@ -4483,14 +5065,14 @@ interface IdempotencyInput {
4483
5065
  * future debugging.
4484
5066
  * @public
4485
5067
  */
4486
- declare const deriveIdempotencyKey: (input: IdempotencyInput) => string;
5068
+ export declare const deriveIdempotencyKey: (input: IdempotencyInput) => string;
4487
5069
  //#endregion
4488
5070
  //#region src/sql/assemblers.d.ts
4489
5071
  /**
4490
5072
  * Minimal shape of a test_runs aggregation row used to build the manifest.
4491
5073
  * @public
4492
5074
  */
4493
- interface ManifestRow {
5075
+ export interface ManifestRow {
4494
5076
  project: string;
4495
5077
  sub_project: string | null;
4496
5078
  timestamp: string;
@@ -4500,7 +5082,7 @@ interface ManifestRow {
4500
5082
  * Minimal shape of a test_history row used to build a history record.
4501
5083
  * @public
4502
5084
  */
4503
- interface HistoryRow {
5085
+ export interface HistoryRow {
4504
5086
  module_path: string;
4505
5087
  full_name: string;
4506
5088
  timestamp: string;
@@ -4516,7 +5098,7 @@ interface HistoryRow {
4516
5098
  * into the `tests` array format.
4517
5099
  * @public
4518
5100
  */
4519
- interface AssembledHistoryRecord {
5101
+ export interface AssembledHistoryRecord {
4520
5102
  [compositeKey: string]: {
4521
5103
  modulePath: string;
4522
5104
  fullName: string;
@@ -4530,7 +5112,7 @@ interface AssembledHistoryRecord {
4530
5112
  * The `dbPath` is stored as `cacheDir` so CLI tools can locate the source.
4531
5113
  * @public
4532
5114
  */
4533
- declare function assembleManifest(rows: ManifestRow[], dbPath: string): CacheManifest;
5115
+ export declare function assembleManifest(rows: ManifestRow[], dbPath: string): CacheManifest;
4534
5116
  /**
4535
5117
  * Groups test_history rows by the composite (module_path, full_name) key
4536
5118
  * into a keyed record.
@@ -4544,7 +5126,7 @@ declare function assembleManifest(rows: ManifestRow[], dbPath: string): CacheMan
4544
5126
  * (matching the `TestRun` schema constraint).
4545
5127
  * @public
4546
5128
  */
4547
- declare function assembleHistoryRecord(rows: HistoryRow[]): AssembledHistoryRecord;
5129
+ export declare function assembleHistoryRecord(rows: HistoryRow[]): AssembledHistoryRecord;
4548
5130
  //#endregion
4549
5131
  //#region src/utils/ansi.d.ts
4550
5132
  /**
@@ -4552,7 +5134,7 @@ declare function assembleHistoryRecord(rows: HistoryRow[]): AssembledHistoryReco
4552
5134
  *
4553
5135
  * @internal
4554
5136
  */
4555
- interface AnsiOptions {
5137
+ export interface AnsiOptions {
4556
5138
  noColor?: boolean;
4557
5139
  }
4558
5140
  /**
@@ -4574,7 +5156,7 @@ interface AnsiOptions {
4574
5156
  * @see {@link https://no-color.org/ | NO_COLOR convention}
4575
5157
  * @internal
4576
5158
  */
4577
- declare function ansi(text: string, color: string, options?: AnsiOptions): string;
5159
+ export declare function ansi(text: string, color: string, options?: AnsiOptions): string;
4578
5160
  /**
4579
5161
  * Strip all ANSI escape codes from a string.
4580
5162
  *
@@ -4583,7 +5165,7 @@ declare function ansi(text: string, color: string, options?: AnsiOptions): strin
4583
5165
  *
4584
5166
  * @internal
4585
5167
  */
4586
- declare function stripAnsi(text: string): string;
5168
+ export declare function stripAnsi(text: string): string;
4587
5169
  //#endregion
4588
5170
  //#region src/utils/build-report.d.ts
4589
5171
  /**
@@ -4595,7 +5177,7 @@ declare function stripAnsi(text: string): string;
4595
5177
  *
4596
5178
  * @public
4597
5179
  */
4598
- interface VitestParsedStack {
5180
+ export interface VitestParsedStack {
4599
5181
  method: string;
4600
5182
  file: string;
4601
5183
  line: number;
@@ -4609,7 +5191,7 @@ interface VitestParsedStack {
4609
5191
  *
4610
5192
  * @public
4611
5193
  */
4612
- interface VitestTestError {
5194
+ export interface VitestTestError {
4613
5195
  message: string;
4614
5196
  diff?: string;
4615
5197
  stacks?: Array<string | VitestParsedStack>;
@@ -4622,7 +5204,7 @@ interface VitestTestError {
4622
5204
  *
4623
5205
  * @public
4624
5206
  */
4625
- interface VitestTestResult {
5207
+ export interface VitestTestResult {
4626
5208
  state: string;
4627
5209
  errors?: ReadonlyArray<VitestTestError>;
4628
5210
  }
@@ -4631,7 +5213,7 @@ interface VitestTestResult {
4631
5213
  *
4632
5214
  * @public
4633
5215
  */
4634
- interface VitestTestDiagnostic {
5216
+ export interface VitestTestDiagnostic {
4635
5217
  duration: number;
4636
5218
  flaky: boolean;
4637
5219
  slow: boolean;
@@ -4646,7 +5228,7 @@ interface VitestTestDiagnostic {
4646
5228
  *
4647
5229
  * @public
4648
5230
  */
4649
- interface VitestTestCase {
5231
+ export interface VitestTestCase {
4650
5232
  type: "test";
4651
5233
  name: string;
4652
5234
  fullName: string;
@@ -4661,7 +5243,7 @@ interface VitestTestCase {
4661
5243
  *
4662
5244
  * @public
4663
5245
  */
4664
- interface VitestModuleDiagnostic {
5246
+ export interface VitestModuleDiagnostic {
4665
5247
  duration: number;
4666
5248
  }
4667
5249
  /**
@@ -4669,7 +5251,7 @@ interface VitestModuleDiagnostic {
4669
5251
  *
4670
5252
  * @public
4671
5253
  */
4672
- interface VitestModuleError {
5254
+ export interface VitestModuleError {
4673
5255
  message: string;
4674
5256
  stacks?: Array<string | VitestParsedStack>;
4675
5257
  }
@@ -4678,7 +5260,7 @@ interface VitestModuleError {
4678
5260
  *
4679
5261
  * @public
4680
5262
  */
4681
- interface VitestTestSuite {
5263
+ export interface VitestTestSuite {
4682
5264
  type: "suite";
4683
5265
  name: string;
4684
5266
  fullName: string;
@@ -4713,7 +5295,7 @@ interface VitestTestSuite {
4713
5295
  *
4714
5296
  * @public
4715
5297
  */
4716
- interface VitestTestModule {
5298
+ export interface VitestTestModule {
4717
5299
  type: "module";
4718
5300
  moduleId: string;
4719
5301
  relativeModuleId: string;
@@ -4746,7 +5328,7 @@ interface VitestTestModule {
4746
5328
  *
4747
5329
  * @public
4748
5330
  */
4749
- declare function buildAgentReport(testModules: ReadonlyArray<VitestTestModule>, unhandledErrors: ReadonlyArray<VitestModuleError>, reason: "passed" | "failed" | "interrupted", options: {
5331
+ export declare function buildAgentReport(testModules: ReadonlyArray<VitestTestModule>, unhandledErrors: ReadonlyArray<VitestModuleError>, reason: "passed" | "failed" | "interrupted", options: {
4750
5332
  readonly omitPassingTests?: boolean;
4751
5333
  }, projectName?: string): AgentReport;
4752
5334
  /**
@@ -4763,7 +5345,7 @@ declare function buildAgentReport(testModules: ReadonlyArray<VitestTestModule>,
4763
5345
  * @returns the number of modules in `report.failed` with no failed test case
4764
5346
  * @public
4765
5347
  */
4766
- declare const countSuiteFailures: (report: Pick<AgentReport, "failed">) => number;
5348
+ export declare const countSuiteFailures: (report: Pick<AgentReport, "failed">) => number;
4767
5349
  //#endregion
4768
5350
  //#region src/utils/canonicalize-git-url.d.ts
4769
5351
  /**
@@ -4786,7 +5368,7 @@ declare const countSuiteFailures: (report: Pick<AgentReport, "failed">) => numbe
4786
5368
  * host like `github.com` is not a project identity.
4787
5369
  * @public
4788
5370
  */
4789
- declare const canonicalizeGitUrl: (raw: string) => string | null;
5371
+ export declare const canonicalizeGitUrl: (raw: string) => string | null;
4790
5372
  /**
4791
5373
  * Convert a (possibly raw) git URL to the filesystem-safe `project_key`
4792
5374
  * form. The canonical `host/path` is mapped 1:1 to `host__path` so it
@@ -4794,7 +5376,7 @@ declare const canonicalizeGitUrl: (raw: string) => string | null;
4794
5376
  * `$XDG_DATA_HOME/vitest-agent/`.
4795
5377
  * @public
4796
5378
  */
4797
- declare const gitUrlToProjectKey: (raw: string) => string | null;
5379
+ export declare const gitUrlToProjectKey: (raw: string) => string | null;
4798
5380
  //#endregion
4799
5381
  //#region src/utils/classify-test.d.ts
4800
5382
  /**
@@ -4805,7 +5387,7 @@ declare const gitUrlToProjectKey: (raw: string) => string | null;
4805
5387
  * @returns The test's classification
4806
5388
  * @public
4807
5389
  */
4808
- declare function classifyTest(current: "passed" | "failed", priorRuns: ReadonlyArray<{
5390
+ export declare function classifyTest(current: "passed" | "failed", priorRuns: ReadonlyArray<{
4809
5391
  state: string;
4810
5392
  }>): TestClassification;
4811
5393
  //#endregion
@@ -4828,7 +5410,7 @@ declare function classifyTest(current: "passed" | "failed", priorRuns: ReadonlyA
4828
5410
  *
4829
5411
  * @public
4830
5412
  */
4831
- declare const coerceErrorText: (value: unknown) => string | undefined;
5413
+ export declare const coerceErrorText: (value: unknown) => string | undefined;
4832
5414
  /**
4833
5415
  * Read a named field off an unknown error-like value and coerce it with
4834
5416
  * {@link coerceErrorText}, guarding the property access itself. A live getter
@@ -4843,7 +5425,7 @@ declare const coerceErrorText: (value: unknown) => string | undefined;
4843
5425
  *
4844
5426
  * @public
4845
5427
  */
4846
- declare const coerceErrorField: (source: unknown, key: string) => string | undefined;
5428
+ export declare const coerceErrorField: (source: unknown, key: string) => string | undefined;
4847
5429
  //#endregion
4848
5430
  //#region src/utils/compress-lines.d.ts
4849
5431
  /**
@@ -4872,7 +5454,7 @@ declare const coerceErrorField: (source: unknown, key: string) => string | undef
4872
5454
  *
4873
5455
  * @public
4874
5456
  */
4875
- declare function compressLines(lines: number[]): string;
5457
+ export declare function compressLines(lines: number[]): string;
4876
5458
  //#endregion
4877
5459
  //#region src/utils/compute-trend.d.ts
4878
5460
  /**
@@ -4883,7 +5465,7 @@ declare function compressLines(lines: number[]): string;
4883
5465
  * is stable for the same logical configuration.
4884
5466
  * @public
4885
5467
  */
4886
- declare function hashTargets(targets: ResolvedThresholds | undefined): string | undefined;
5468
+ export declare function hashTargets(targets: ResolvedThresholds | undefined): string | undefined;
4887
5469
  /**
4888
5470
  * Compute a new trend entry and return the updated trend record.
4889
5471
  *
@@ -4891,12 +5473,12 @@ declare function hashTargets(targets: ResolvedThresholds | undefined): string |
4891
5473
  * cleared and the new entry becomes the first data point.
4892
5474
  * @public
4893
5475
  */
4894
- declare function computeTrend(current: CoverageTotals, existing: TrendRecord | undefined, targets: ResolvedThresholds | undefined): TrendRecord;
5476
+ export declare function computeTrend(current: CoverageTotals, existing: TrendRecord | undefined, targets: ResolvedThresholds | undefined): TrendRecord;
4895
5477
  /**
4896
5478
  * Get the overall direction from recent entries.
4897
5479
  * @public
4898
5480
  */
4899
- declare function getRecentDirection(record: TrendRecord, count?: number): {
5481
+ export declare function getRecentDirection(record: TrendRecord, count?: number): {
4900
5482
  direction: "improving" | "regressing" | "stable";
4901
5483
  runCount: number;
4902
5484
  };
@@ -4907,7 +5489,7 @@ declare function getRecentDirection(record: TrendRecord, count?: number): {
4907
5489
  * when the write happened inside one). Fed to buildConsoleLeaks.
4908
5490
  * @public
4909
5491
  */
4910
- interface ConsoleLeakEntry {
5492
+ export interface ConsoleLeakEntry {
4911
5493
  readonly file: string;
4912
5494
  readonly test?: string;
4913
5495
  readonly type: "stdout" | "stderr";
@@ -4931,7 +5513,7 @@ interface ConsoleLeakEntry {
4931
5513
  * `undefined` only when there is no output at all, non-failing or failing.
4932
5514
  * @public
4933
5515
  */
4934
- declare function buildConsoleLeaks(entries: ReadonlyArray<ConsoleLeakEntry>): ConsoleLeaks | undefined;
5516
+ export declare function buildConsoleLeaks(entries: ReadonlyArray<ConsoleLeakEntry>): ConsoleLeaks | undefined;
4935
5517
  /**
4936
5518
  * Structural subset of a Vitest runner task (File / Suite / Test) carrying
4937
5519
  * captured console output. Modeled locally so this util needs no `vitest`
@@ -4940,7 +5522,7 @@ declare function buildConsoleLeaks(entries: ReadonlyArray<ConsoleLeakEntry>): Co
4940
5522
  * reporter stripping in agent mode.
4941
5523
  * @public
4942
5524
  */
4943
- interface ConsoleLeakTask {
5525
+ export interface ConsoleLeakTask {
4944
5526
  readonly type?: string;
4945
5527
  readonly name?: string;
4946
5528
  readonly fullTestName?: string;
@@ -4967,7 +5549,7 @@ interface ConsoleLeakTask {
4967
5549
  * enclosing file itself failed (e.g. a collection/load error).
4968
5550
  * @public
4969
5551
  */
4970
- declare function collectConsoleLeakEntries(files: ReadonlyArray<ConsoleLeakTask>): ConsoleLeakEntry[];
5552
+ export declare function collectConsoleLeakEntries(files: ReadonlyArray<ConsoleLeakTask>): ConsoleLeakEntry[];
4971
5553
  //#endregion
4972
5554
  //#region src/utils/detect-non-default-discover-strategy.d.ts
4973
5555
  /**
@@ -4984,7 +5566,7 @@ declare function collectConsoleLeakEntries(files: ReadonlyArray<ConsoleLeakTask>
4984
5566
  * false negative would produce a confidently wrong deny.
4985
5567
  * @public
4986
5568
  */
4987
- declare function detectNonDefaultDiscoverStrategy(source: string): boolean;
5569
+ export declare function detectNonDefaultDiscoverStrategy(source: string): boolean;
4988
5570
  //#endregion
4989
5571
  //#region src/utils/detect-pm.d.ts
4990
5572
  /**
@@ -5015,7 +5597,7 @@ declare function detectNonDefaultDiscoverStrategy(source: string): boolean;
5015
5597
  *
5016
5598
  * @internal
5017
5599
  */
5018
- interface FileSystemAdapter {
5600
+ export interface FileSystemAdapter {
5019
5601
  readFile(path: string): Promise<string>;
5020
5602
  exists(path: string): Promise<boolean>;
5021
5603
  }
@@ -5035,7 +5617,7 @@ interface FileSystemAdapter {
5035
5617
  *
5036
5618
  * @internal
5037
5619
  */
5038
- declare function detectPackageManager(root: string, fs: FileSystemAdapter): Promise<PackageManager | null>;
5620
+ export declare function detectPackageManager(root: string, fs: FileSystemAdapter): Promise<PackageManager | null>;
5039
5621
  /**
5040
5622
  * Return the vitest run command for the given package manager.
5041
5623
  *
@@ -5046,7 +5628,7 @@ declare function detectPackageManager(root: string, fs: FileSystemAdapter): Prom
5046
5628
  *
5047
5629
  * @internal
5048
5630
  */
5049
- declare function getRunCommand(pm: PackageManager | null): string;
5631
+ export declare function getRunCommand(pm: PackageManager | null): string;
5050
5632
  //#endregion
5051
5633
  //#region src/utils/detect-timeout.d.ts
5052
5634
  /**
@@ -5055,7 +5637,7 @@ declare function getRunCommand(pm: PackageManager | null): string;
5055
5637
  * "timeout".
5056
5638
  * @public
5057
5639
  */
5058
- declare const isTimeoutError: (error: {
5640
+ export declare const isTimeoutError: (error: {
5059
5641
  message?: string;
5060
5642
  name?: string;
5061
5643
  }) => boolean;
@@ -5068,17 +5650,17 @@ declare const isTimeoutError: (error: {
5068
5650
  * no-ops.
5069
5651
  * @public
5070
5652
  */
5071
- declare function ensureMigrated(dbPath: string, logLevel?: LogLevel.LogLevel, logFile?: string): Promise<void>;
5653
+ export declare function ensureMigrated(dbPath: string, logLevel?: LogLevel.LogLevel, logFile?: string): Promise<void>;
5072
5654
  /**
5073
5655
  * Reset the migration cache. Test-only.
5074
5656
  *
5075
5657
  * @internal
5076
5658
  */
5077
- declare function _resetMigrationCacheForTesting(): void;
5659
+ export declare function _resetMigrationCacheForTesting(): void;
5078
5660
  //#endregion
5079
5661
  //#region src/utils/failure-signature.d.ts
5080
5662
  /** @public */
5081
- interface FailureSignatureInput {
5663
+ export interface FailureSignatureInput {
5082
5664
  readonly error_name: string;
5083
5665
  readonly assertion_message: string;
5084
5666
  readonly top_frame_function_name: string;
@@ -5086,9 +5668,9 @@ interface FailureSignatureInput {
5086
5668
  readonly top_frame_raw_line?: number;
5087
5669
  }
5088
5670
  /** @public */
5089
- declare const normalizeAssertionShape: (message: string) => string | null;
5671
+ export declare const normalizeAssertionShape: (message: string) => string | null;
5090
5672
  /** @public */
5091
- declare const computeFailureSignature: (input: FailureSignatureInput) => string;
5673
+ export declare const computeFailureSignature: (input: FailureSignatureInput) => string;
5092
5674
  //#endregion
5093
5675
  //#region src/utils/format-console.d.ts
5094
5676
  /**
@@ -5096,7 +5678,7 @@ declare const computeFailureSignature: (input: FailureSignatureInput) => string;
5096
5678
  *
5097
5679
  * @internal
5098
5680
  */
5099
- interface ConsoleFormatOptions {
5681
+ export interface ConsoleFormatOptions {
5100
5682
  /** Output verbosity: `"failures"` (default), `"full"`, or `"silent"`. */
5101
5683
  consoleOutput: "failures" | "full" | "silent";
5102
5684
  /** Maximum number of low-coverage files to show in console output. */
@@ -5132,7 +5714,7 @@ interface ConsoleFormatOptions {
5132
5714
  *
5133
5715
  * @internal
5134
5716
  */
5135
- declare function getWorstMetric(f: FileCoverageReport): {
5717
+ export declare function getWorstMetric(f: FileCoverageReport): {
5136
5718
  label: string;
5137
5719
  pct: number;
5138
5720
  };
@@ -5146,7 +5728,7 @@ declare function getWorstMetric(f: FileCoverageReport): {
5146
5728
  *
5147
5729
  * @internal
5148
5730
  */
5149
- declare function relativePath(filePath: string, cwd?: string): string;
5731
+ export declare function relativePath(filePath: string, cwd?: string): string;
5150
5732
  /**
5151
5733
  * Determine the output tier based on test results and coverage state.
5152
5734
  *
@@ -5156,7 +5738,7 @@ declare function relativePath(filePath: string, cwd?: string): string;
5156
5738
  *
5157
5739
  * @internal
5158
5740
  */
5159
- declare function determineTier(report: AgentReport): "green" | "yellow" | "red";
5741
+ export declare function determineTier(report: AgentReport): "green" | "yellow" | "red";
5160
5742
  /**
5161
5743
  * Format an {@link (AgentReport:variable)} as compact, actionable console markdown.
5162
5744
  *
@@ -5179,7 +5761,7 @@ declare function determineTier(report: AgentReport): "green" | "yellow" | "red";
5179
5761
  *
5180
5762
  * @internal
5181
5763
  */
5182
- declare function formatConsoleMarkdown(report: AgentReport, options: ConsoleFormatOptions): string;
5764
+ export declare function formatConsoleMarkdown(report: AgentReport, options: ConsoleFormatOptions): string;
5183
5765
  //#endregion
5184
5766
  //#region src/utils/format-fatal-error.d.ts
5185
5767
  /**
@@ -5193,7 +5775,7 @@ declare function formatConsoleMarkdown(report: AgentReport, options: ConsoleForm
5193
5775
  *
5194
5776
  * @public
5195
5777
  */
5196
- declare function formatFatalError(err: unknown): string;
5778
+ export declare function formatFatalError(err: unknown): string;
5197
5779
  //#endregion
5198
5780
  //#region src/utils/format-gfm.d.ts
5199
5781
  /**
@@ -5218,7 +5800,7 @@ declare function formatFatalError(err: unknown): string;
5218
5800
  *
5219
5801
  * @public
5220
5802
  */
5221
- declare function formatGfm(reports: AgentReport[]): string;
5803
+ export declare function formatGfm(reports: AgentReport[]): string;
5222
5804
  //#endregion
5223
5805
  //#region src/utils/format-scoped-coverage-note.d.ts
5224
5806
  /**
@@ -5239,11 +5821,11 @@ declare function formatGfm(reports: AgentReport[]): string;
5239
5821
  * @returns the note text, e.g. `"Coverage thresholds skipped: partial run (2 of 47 test files)"`
5240
5822
  * @public
5241
5823
  */
5242
- declare function formatScopedCoverageNote(testedFileCount: number, totalFileCount?: number): string;
5824
+ export declare function formatScopedCoverageNote(testedFileCount: number, totalFileCount?: number): string;
5243
5825
  //#endregion
5244
5826
  //#region src/utils/function-boundary.d.ts
5245
5827
  /** @public */
5246
- interface FunctionBoundary {
5828
+ export interface FunctionBoundary {
5247
5829
  readonly line: number;
5248
5830
  readonly name: string;
5249
5831
  }
@@ -5256,15 +5838,15 @@ interface FunctionBoundary {
5256
5838
  * casts are all accepted.
5257
5839
  * @public
5258
5840
  */
5259
- declare const findFunctionBoundary: (source: string, line: number) => FunctionBoundary | null;
5841
+ export declare const findFunctionBoundary: (source: string, line: number) => FunctionBoundary | null;
5260
5842
  //#endregion
5261
5843
  //#region src/utils/hyperlink.d.ts
5262
5844
  /** @public */
5263
- interface Osc8Options {
5845
+ export interface Osc8Options {
5264
5846
  readonly enabled: boolean;
5265
5847
  }
5266
5848
  /** @public */
5267
- declare const osc8: (url: string, label: string, options: Osc8Options) => string;
5849
+ export declare const osc8: (url: string, label: string, options: Osc8Options) => string;
5268
5850
  //#endregion
5269
5851
  //#region src/utils/match-vitest-command.d.ts
5270
5852
  /**
@@ -5274,7 +5856,7 @@ declare const osc8: (url: string, label: string, options: Osc8Options) => string
5274
5856
  * (computed once per project and cached by the sidecar).
5275
5857
  * @public
5276
5858
  */
5277
- declare const isVitestInvocation: (command: string, vitestScripts: ReadonlySet<string>) => boolean;
5859
+ export declare const isVitestInvocation: (command: string, vitestScripts: ReadonlySet<string>) => boolean;
5278
5860
  /**
5279
5861
  * Build the env-var prefix string to prepend to a matched command.
5280
5862
  *
@@ -5286,7 +5868,7 @@ declare const isVitestInvocation: (command: string, vitestScripts: ReadonlySet<s
5286
5868
  * Bash calls, no risk of cross-contamination.
5287
5869
  * @public
5288
5870
  */
5289
- declare const buildEnvPrefix: (input: {
5871
+ export declare const buildEnvPrefix: (input: {
5290
5872
  readonly conversationId: string;
5291
5873
  readonly agentId: string;
5292
5874
  readonly parentAgentId?: string;
@@ -5297,7 +5879,7 @@ declare const buildEnvPrefix: (input: {
5297
5879
  * unchanged. When it matches, prepends the env prefix.
5298
5880
  * @public
5299
5881
  */
5300
- declare const rewriteBashCommand: (input: {
5882
+ export declare const rewriteBashCommand: (input: {
5301
5883
  readonly command: string;
5302
5884
  readonly vitestScripts: ReadonlySet<string>;
5303
5885
  readonly conversationId: string;
@@ -5312,7 +5894,7 @@ declare const rewriteBashCommand: (input: {
5312
5894
  * is a documented limitation.
5313
5895
  * @public
5314
5896
  */
5315
- declare const detectVitestScripts: (scripts: Record<string, string>) => Set<string>;
5897
+ export declare const detectVitestScripts: (scripts: Record<string, string>) => Set<string>;
5316
5898
  //#endregion
5317
5899
  //#region src/utils/normalize-workspace-key.d.ts
5318
5900
  /**
@@ -5342,11 +5924,11 @@ declare const detectVitestScripts: (scripts: Record<string, string>) => Set<stri
5342
5924
  * @returns A filesystem-safe single path segment.
5343
5925
  * @public
5344
5926
  */
5345
- declare function normalizeWorkspaceKey(name: string): string;
5927
+ export declare function normalizeWorkspaceKey(name: string): string;
5346
5928
  //#endregion
5347
5929
  //#region src/utils/probe-host-metadata.d.ts
5348
5930
  /** @public */
5349
- interface HostMetadataResult {
5931
+ export interface HostMetadataResult {
5350
5932
  readonly source: string | null;
5351
5933
  readonly value: string | null;
5352
5934
  readonly metadata: Record<string, unknown> | null;
@@ -5371,19 +5953,19 @@ interface HostMetadataResult {
5371
5953
  * 9. `process.ppid` walk (handled by the Live layer)
5372
5954
  * @public
5373
5955
  */
5374
- declare const probeHostMetadataFromEnv: (env: Record<string, string | undefined>) => HostMetadataResult;
5956
+ export declare const probeHostMetadataFromEnv: (env: Record<string, string | undefined>) => HostMetadataResult;
5375
5957
  //#endregion
5376
5958
  //#region src/utils/resolve-data-path.d.ts
5377
5959
  /**
5378
5960
  * Filename of the SQLite database that stores all reporter data.
5379
5961
  * @public
5380
5962
  */
5381
- declare const DATABASE_FILENAME = "data.db";
5963
+ export declare const DATABASE_FILENAME = "data.db";
5382
5964
  /**
5383
5965
  * Caller-supplied overrides for `resolveDataPath`.
5384
5966
  * @public
5385
5967
  */
5386
- interface ResolveDataPathOptions {
5968
+ export interface ResolveDataPathOptions {
5387
5969
  /**
5388
5970
  * Programmatic override for the entire data directory. Highest precedence.
5389
5971
  *
@@ -5423,7 +6005,7 @@ interface ResolveDataPathOptions {
5423
6005
  * @param options - Optional programmatic overrides.
5424
6006
  * @public
5425
6007
  */
5426
- declare const resolveDataPath: (projectDir: string, options?: ResolveDataPathOptions) => Effect.Effect<any, import("@effected/xdg").AppDirsError | import("effect/PlatformError").PlatformError | import("@effected/config-file").ConfigReadError, AppDirs | FileSystem.FileSystem | VitestAgentConfigFile>;
6008
+ export declare const resolveDataPath: (projectDir: string, options?: ResolveDataPathOptions) => Effect.Effect<any, import("@effected/xdg").AppDirsError | import("effect/PlatformError").PlatformError | import("@effected/config-file").ConfigReadError, AppDirs | FileSystem.FileSystem | VitestAgentConfigFile>;
5427
6009
  //#endregion
5428
6010
  //#region src/utils/resolve-project-key-from-cwd.d.ts
5429
6011
  /**
@@ -5436,7 +6018,7 @@ declare const resolveDataPath: (projectDir: string, options?: ResolveDataPathOpt
5436
6018
  * empty case.
5437
6019
  * @public
5438
6020
  */
5439
- declare const resolveProjectKeyFromCwd: (cwd: string) => string;
6021
+ export declare const resolveProjectKeyFromCwd: (cwd: string) => string;
5440
6022
  //#endregion
5441
6023
  //#region src/utils/resolve-workspace-key.d.ts
5442
6024
  /**
@@ -5464,7 +6046,7 @@ declare const resolveProjectKeyFromCwd: (cwd: string) => string;
5464
6046
  * reporter's resolved `projectDir` (CLAUDE_PROJECT_DIR or process.cwd()).
5465
6047
  * @public
5466
6048
  */
5467
- declare const resolveWorkspaceKey: (projectDir: string) => Effect.Effect<string, WorkspaceRootNotFoundError | WorkspaceDiscoveryFailure, WorkspaceDiscovery>;
6049
+ export declare const resolveWorkspaceKey: (projectDir: string) => Effect.Effect<string, WorkspaceRootNotFoundError | WorkspaceDiscoveryFailure, WorkspaceDiscovery>;
5468
6050
  //#endregion
5469
6051
  //#region src/utils/safe-filename.d.ts
5470
6052
  /**
@@ -5493,17 +6075,17 @@ declare const resolveWorkspaceKey: (projectDir: string) => Effect.Effect<string,
5493
6075
  *
5494
6076
  * @public
5495
6077
  */
5496
- declare function safeFilename(name: string): string;
6078
+ export declare function safeFilename(name: string): string;
5497
6079
  //#endregion
5498
6080
  //#region src/utils/test-location.d.ts
5499
6081
  /** Directory holding source files whose tests may be co-located. @public */
5500
- declare const SRC_DIR = "src";
6082
+ export declare const SRC_DIR = "src";
5501
6083
  /** Canonical test directory name. @public */
5502
- declare const TEST_DIR = "__test__";
6084
+ export declare const TEST_DIR = "__test__";
5503
6085
  /** Support directories under `__test__/` that are never collected. @public */
5504
- declare const TEST_HELPER_DIRS: readonly ["fixtures", "snapshots", "utils"];
6086
+ export declare const TEST_HELPER_DIRS: readonly ["fixtures", "snapshots", "utils"];
5505
6087
  /** Glob suffix matching every discoverable test file. @public */
5506
- declare const TEST_FILE_GLOB_SUFFIX = "*.{test,spec}.{ts,tsx,js,jsx}";
6088
+ export declare const TEST_FILE_GLOB_SUFFIX = "*.{test,spec}.{ts,tsx,js,jsx}";
5507
6089
  /**
5508
6090
  * Directory names discovery never walks into, and therefore never collects
5509
6091
  * tests from. Keep in step with {@link TEST_FILE_GLOB_SUFFIX}'s extension set:
@@ -5516,7 +6098,7 @@ declare const TEST_FILE_GLOB_SUFFIX = "*.{test,spec}.{ts,tsx,js,jsx}";
5516
6098
  * any path that crosses one.
5517
6099
  * @public
5518
6100
  */
5519
- declare const NON_DISCOVERABLE_DIRS: ReadonlySet<string>;
6101
+ export declare const NON_DISCOVERABLE_DIRS: ReadonlySet<string>;
5520
6102
  /**
5521
6103
  * True when `filePathOrName` ends in a discoverable test-file suffix — the
5522
6104
  * extension half of the layout rule, matching {@link TEST_FILE_GLOB_SUFFIX}.
@@ -5526,7 +6108,7 @@ declare const NON_DISCOVERABLE_DIRS: ReadonlySet<string>;
5526
6108
  * when the answer has to account for where the file sits.
5527
6109
  * @public
5528
6110
  */
5529
- declare function isTestFileName(filePathOrName: string): boolean;
6111
+ export declare function isTestFileName(filePathOrName: string): boolean;
5530
6112
  /**
5531
6113
  * Outcome of classifying a path against the test-layout rule.
5532
6114
  *
@@ -5535,15 +6117,15 @@ declare function isTestFileName(filePathOrName: string): boolean;
5535
6117
  * - `invalid` — not a legal test location.
5536
6118
  * @public
5537
6119
  */
5538
- type TestPathVerdict = "valid" | "excluded" | "invalid";
6120
+ export type TestPathVerdict = "valid" | "excluded" | "invalid";
5539
6121
  /** Result of {@link classifyTestPath}. @public */
5540
- interface TestPathClassification {
6122
+ export interface TestPathClassification {
5541
6123
  readonly verdict: TestPathVerdict;
5542
6124
  readonly workspace: string | null;
5543
6125
  readonly suggestedPath: string | null;
5544
6126
  }
5545
6127
  /** Minimal workspace shape {@link classifyTestPath} needs to attribute a path. @public */
5546
- interface WorkspaceLike {
6128
+ export interface WorkspaceLike {
5547
6129
  readonly name: string;
5548
6130
  readonly path: string;
5549
6131
  }
@@ -5557,7 +6139,7 @@ interface WorkspaceLike {
5557
6139
  * agree with {@link classifyTestPath} about which package owns it.
5558
6140
  * @public
5559
6141
  */
5560
- declare function findOwningWorkspace(workspaces: ReadonlyArray<WorkspaceLike>, filePath: string): WorkspaceLike | null;
6142
+ export declare function findOwningWorkspace(workspaces: ReadonlyArray<WorkspaceLike>, filePath: string): WorkspaceLike | null;
5561
6143
  /**
5562
6144
  * Classifies `filePath` against the test-layout rule: a test file is
5563
6145
  * discoverable only at `<workspace>/src/**` or `<workspace>/__test__/**`,
@@ -5575,28 +6157,28 @@ declare function findOwningWorkspace(workspaces: ReadonlyArray<WorkspaceLike>, f
5575
6157
  * when it fires — `@vitest-agent/cli`'s `agent check-test-path` does.
5576
6158
  * @public
5577
6159
  */
5578
- declare function classifyTestPath(workspaces: ReadonlyArray<WorkspaceLike>, filePath: string): TestPathClassification | null;
6160
+ export declare function classifyTestPath(workspaces: ReadonlyArray<WorkspaceLike>, filePath: string): TestPathClassification | null;
5579
6161
  //#endregion
5580
6162
  //#region src/utils/validate-coverage-targets-shape.d.ts
5581
6163
  /** @public */
5582
- interface CoverageTargetsShapeError {
6164
+ export interface CoverageTargetsShapeError {
5583
6165
  readonly code: string;
5584
6166
  readonly path: string;
5585
6167
  readonly message: string;
5586
6168
  }
5587
6169
  /** @public */
5588
- interface CoverageTargetsShapeWarning {
6170
+ export interface CoverageTargetsShapeWarning {
5589
6171
  readonly code: string;
5590
6172
  readonly path: string;
5591
6173
  readonly message: string;
5592
6174
  }
5593
6175
  /** @public */
5594
- interface CoverageTargetsShapeInfo {
6176
+ export interface CoverageTargetsShapeInfo {
5595
6177
  readonly code: string;
5596
6178
  readonly message: string;
5597
6179
  }
5598
6180
  /** @public */
5599
- interface CoverageTargetsShapeResult {
6181
+ export interface CoverageTargetsShapeResult {
5600
6182
  readonly errors: ReadonlyArray<CoverageTargetsShapeError>;
5601
6183
  readonly warnings: ReadonlyArray<CoverageTargetsShapeWarning>;
5602
6184
  readonly info: ReadonlyArray<CoverageTargetsShapeInfo>;
@@ -5610,14 +6192,16 @@ interface CoverageTargetsShapeResult {
5610
6192
  * OR a literal `true` appears at any key other than `"100"`. The
5611
6193
  * offending `path` is included (e.g. `"lines"`, `"src/**.ts.lines"`,
5612
6194
  * or `"statements"` when misused as a boolean shortcut).
5613
- * - `PERFILE_ON_TARGETS` — the `perFile` key appears inside coverageTargets;
5614
- * it should be set on `coverage.thresholds.perFile` instead.
6195
+ * - `PERFILE_ON_TARGETS` — a top-level `perFile` key appears in
6196
+ * coverageTargets; the top-level setting belongs on
6197
+ * `coverage.thresholds.perFile`. A `perFile` inside a glob-pattern entry
6198
+ * is legal and is not reported.
5615
6199
  *
5616
6200
  * @param input - The raw value passed as coverageTargets.
5617
6201
  * @returns A result object with errors, warnings, and info arrays.
5618
6202
  * @public
5619
6203
  */
5620
- declare function validateCoverageTargetsShape(input: unknown): CoverageTargetsShapeResult;
6204
+ export declare function validateCoverageTargetsShape(input: unknown): CoverageTargetsShapeResult;
5621
6205
  //#endregion
5622
6206
  //#region src/index.d.ts
5623
6207
  /**
@@ -5628,7 +6212,7 @@ declare function validateCoverageTargetsShape(input: unknown): CoverageTargetsSh
5628
6212
  * substituted yet. Exported for version introspection by downstream tooling.
5629
6213
  * @public
5630
6214
  */
5631
- declare const CURRENT_SDK_VERSION: string;
6215
+ export declare const CURRENT_SDK_VERSION: string;
5632
6216
  //#endregion
5633
- export { AcceptanceMetrics, ActionSeverity, ActorType, Agent, AgentConsoleMode, AgentContext, AgentId, AgentNotFoundError, AgentPluginOptions, AgentReport, AgentReporterOptions, AgentTreeNode, AnsiOptions, ArtifactKind, ArtifactSuite, AssembledHistoryRecord, AssociateRunSessionInput, BehaviorAbandonedEvent, BehaviorAddedEvent, BehaviorCompletedEvent, BehaviorDetail, BehaviorNotFoundError, BehaviorRow, BehaviorScopedEventType, BehaviorScopedEventTypes, BehaviorStartedEvent, BehaviorStatus, BehaviorsReadyEvent, BlockedEvent, CURRENT_SDK_VERSION, CacheManifest, CacheManifestEntry, CandidateContext, CellOptions, ChangeKind, ChannelEvent, ChatId, CiConsoleMode, CitedArtifact, CitedArtifactRow, ClassificationQueryOptions, CommitChangesEntry, ConfigLive, ConsoleFormatOptions, ConsoleLeakEntry, ConsoleLeakFile, ConsoleLeakTask, ConsoleLeaks, ConsoleLeaksFromFailingTests, ConsoleLogLevel, ConsoleMode, ConsoleOutputMode, ConsoleOutputs, ConversationId, ConversationNotFoundError, CoverageBaselines, FileCoverageReport as CoverageFile, FileCoverageReport, CoverageGap, CoverageInput, CoverageLevel, CoverageLevelName, CoverageMetric, CoverageRenderState, CoverageReport, CoverageTargets, CoverageTargetsMetrics, CoverageTargetsShapeError, CoverageTargetsShapeInfo, CoverageTargetsShapeResult, CoverageTargetsShapeWarning, CoverageTotals, CreateBehaviorInput, CreateGoalInput, CurrentTddPhase, DATABASE_FILENAME, DataReader, DataReaderLive, DataStore, DataStoreError, DataStoreLive, DenialReason, DetailLevel, DetailResolver, DetailResolverLive, DiscoveryError, DiscoveryRegistry, DiscoveryRegistryLive, DispatchInputs, EndTddTaskInput, Environment, EnvironmentDetector, EnvironmentDetectorLive, EnvironmentDetectorTest, Executor, ExecutorResolver, ExecutorResolverLive, FailureRecord, FailureSignatureDetail, FailureSignatureInput, FailureSignatureWriteInput, FileCoverageInput, FileEditPayload, FileSystemAdapter, FlakyTest, FormatSelector, FormatSelectorLive, type FormatTriageOptions, type FormatWrapupOptions, Formatter, FormatterContext, FunctionBoundary, GfmFormatter, GitCommandError, GoalAbandonedEvent, GoalAddedEvent, GoalCompletedEvent, GoalDetail, GoalNotFoundError, GoalRow, GoalStartedEvent, GoalStatus, GoalsReadyEvent, HistoryQueryOptions, HistoryRecord, HistoryRow, HistoryTracker, HistoryTrackerLive, HistoryTrackerTest, HistoryTrackerTestState, HookFirePayload, HookStatus, HookType, HostKind, HostMetadataParseError, HostMetadataResult, HumanConsoleMode, HypothesisDetail, HypothesisInput, HypothesisPayload, IDEMPOTENCY_ROOT_SENTINEL, IdempotencyHit, IdempotencyInput, IdempotentResponseInput, IllegalStatusTransitionEntity, IllegalStatusTransitionError, JsonFormatter, KnownProject, KnownProjectInput, LoggerLive, ManifestRow, MapSessionInput, MapSessionOutput, MarkdownFormatter, MetricThresholds, ModuleInput, ModuleListEntry, ModuleRecord, ModuleReport, NON_DISCOVERABLE_DIRS, NoteInput, NotePayload, NoteRow, Osc8Options, OutputFormat, OutputPipelineLive, OutputRenderer, OutputRendererLive, PackageManager, PathResolutionError, PathResolutionLive, PatternThresholds, PerClientSessionMapReader, PerClientSessionMapReaderLive, PerClientSessionMapWriter, PerClientSessionMapWriterLive, PersistentFailure, Phase, PhaseTransitionContext, PhaseTransitionEvent, PhaseTransitionResult, ProbeMissError, ProjectDiscovery, ProjectDiscoveryLive, ProjectDiscoveryTest, ProjectIdentity, ProjectIdentityCandidate, ProjectIdentityCandidates, ProjectIdentityLive, ProjectIdentityNotResolvableError, ProjectIdentitySource, ProjectIdentityTest, ProjectKey, ProjectRunSummary, ProjectSummary, RegisterAgentInput, RegisterAgentResult, RegistrationConflictError, Remediation, RenderState, RenderTotals, RenderedOutput, ReportError, ReportSummary, ReporterKit, ReporterRenderInput, ResolveDataPathOptions, ResolveProjectIdentityOptions, ResolvedIdentity, ResolvedReporterConfig, ResolvedThresholds, RunChangedFile, RunContext, RunContext$, RunContextLive, RunContextService, RunContextTest, RunEvent, RunEventByTag, RunHealth, RunInvocationMethod, RunOutcome, RunShape, SRC_DIR, SessionCompleteEvent, SessionContextRow, SessionDetail, SessionInput, SessionNotFoundError, SessionOutcome, SettingsInput, SettingsListEntry, SettingsRow, SidecarTimeoutError, SilentFormatter, StackFrameInput, SuggestedActionRecord, SuiteInput, SuiteListEntry, TEST_DIR, TEST_FILE_GLOB_SUFFIX, TEST_HELPER_DIRS, TagCountEntry, TagInventoryRow, TddArtifactDetail, TddArtifactRow, TddPhaseDetail, TddTaskAlreadyEndedError, TddTaskDetail, TddTaskEndOutcome, TddTaskId, TddTaskInput, TddTaskNotFoundError, TddTaskSummary, TerminalFormatter, TestCaseInput, TestClassification, TestError, TestErrorInput, TestFileEntry, TestHistory, TestListEntry, TestLookupOptions, TestOutcome, TestPathClassification, TestPathVerdict, TestRecord, TestReport, TestRun, TestRunInput, TestRunReason, TestState, ToolCallPayload, ToolResultPayload, Transport, TrendEntry, TrendRecord, TrendSummary, TurnInput, TurnPayload, TurnSearchOptions, TurnSummary, UpdateBehaviorInput, UpdateGoalInput, UserPromptPayload, ValidateHypothesisInput, VitestAgentConfig, VitestAgentConfigFile, VitestAgentConfigFileService, VitestAgentReporter, VitestAgentReporterFactory, VitestModuleDiagnostic, VitestModuleError, VitestParsedStack, VitestTestCase, VitestTestDiagnostic, VitestTestError, VitestTestModule, VitestTestResult, VitestTestSuite, WorkspaceLike, type WrapupKind, WriteCommitInput, WriteRunChangedFilesInput, WriteTddArtifactInput, WriteTddPhaseInput, WriteTddPhaseOutput, _resetMigrationCacheForTesting, ansi, assembleHistoryRecord, assembleManifest, buildAgentReport, buildConsoleLeaks, buildEnvPrefix, canonicalizeGitUrl, ciAnnotationsFormatter, classifyTest, classifyTestPath, coerceErrorField, coerceErrorText, collectConsoleLeakEntries, compressLines, computeFailureSignature, computeTrend, countSuiteFailures, deriveIdempotencyKey, detectNonDefaultDiscoverStrategy, detectPackageManager, detectVitestScripts, determineTier, ensureMigrated, extractSqlReason, findFunctionBoundary, findOwningWorkspace, formatConsoleMarkdown, formatFatalError, formatGfm, formatScopedCoverageNote, formatTriageEffect, formatWrapupEffect, getRecentDirection, getRunCommand, getWorstMetric, gitUrlToProjectKey, hashTargets, historyKey, initialRenderState, isTestFileName, isTimeoutError, isVitestInvocation, migration as migration0001, normalizeAssertionShape, normalizeWorkspaceKey, osc8, probeHostMetadataFromEnv, migration$1 as registryMigration0001, relativePath, requiredArtifactForTransition, resolveCoverageInput, resolveDataPath, resolveLogFile, resolveLogLevel, resolveProjectIdentityFromCandidates, resolveProjectKeyFromCwd, resolveWorkspaceKey, rewriteBashCommand, safeFilename, migration$2 as sessionMapMigration0001, stripAnsi, transitionEnforcesBehaviorMatch, validateCoverageConfig, validateCoverageTargetsShape, validatePhaseTransition };
6217
+ export { FileCoverageReport as CoverageFile, type FormatTriageOptions, type FormatWrapupOptions, type WrapupKind, migration as migration0001, migration$1 as migration0002, migration$2 as registryMigration0001, migration$3 as sessionMapMigration0001 };
5634
6218
  //# sourceMappingURL=index.d.ts.map