@mmnto/totem 1.18.2 → 1.19.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.
@@ -63,7 +63,7 @@ export declare const RecurrencePatternSchema: z.ZodObject<{
63
63
  paths: string[];
64
64
  signature: string;
65
65
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif" | "mixed";
66
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
66
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
67
67
  occurrences: number;
68
68
  prs: string[];
69
69
  sampleBodies: string[];
@@ -74,7 +74,7 @@ export declare const RecurrencePatternSchema: z.ZodObject<{
74
74
  paths: string[];
75
75
  signature: string;
76
76
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif" | "mixed";
77
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
77
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
78
78
  occurrences: number;
79
79
  prs: string[];
80
80
  sampleBodies: string[];
@@ -121,7 +121,7 @@ export declare const RecurrenceStatsSchema: z.ZodObject<{
121
121
  paths: string[];
122
122
  signature: string;
123
123
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif" | "mixed";
124
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
124
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
125
125
  occurrences: number;
126
126
  prs: string[];
127
127
  sampleBodies: string[];
@@ -132,7 +132,7 @@ export declare const RecurrenceStatsSchema: z.ZodObject<{
132
132
  paths: string[];
133
133
  signature: string;
134
134
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif" | "mixed";
135
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
135
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
136
136
  occurrences: number;
137
137
  prs: string[];
138
138
  sampleBodies: string[];
@@ -166,7 +166,7 @@ export declare const RecurrenceStatsSchema: z.ZodObject<{
166
166
  paths: string[];
167
167
  signature: string;
168
168
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif" | "mixed";
169
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
169
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
170
170
  occurrences: number;
171
171
  prs: string[];
172
172
  sampleBodies: string[];
@@ -177,7 +177,7 @@ export declare const RecurrenceStatsSchema: z.ZodObject<{
177
177
  paths: string[];
178
178
  signature: string;
179
179
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif" | "mixed";
180
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
180
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
181
181
  occurrences: number;
182
182
  prs: string[];
183
183
  sampleBodies: string[];
@@ -191,7 +191,7 @@ export declare const RecurrenceStatsSchema: z.ZodObject<{
191
191
  paths: string[];
192
192
  signature: string;
193
193
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif" | "mixed";
194
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
194
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
195
195
  occurrences: number;
196
196
  prs: string[];
197
197
  sampleBodies: string[];
@@ -207,7 +207,7 @@ export declare const RecurrenceStatsSchema: z.ZodObject<{
207
207
  paths: string[];
208
208
  signature: string;
209
209
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif" | "mixed";
210
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
210
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
211
211
  occurrences: number;
212
212
  prs: string[];
213
213
  sampleBodies: string[];
@@ -221,7 +221,7 @@ export declare const RecurrenceStatsSchema: z.ZodObject<{
221
221
  paths: string[];
222
222
  signature: string;
223
223
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif" | "mixed";
224
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
224
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
225
225
  occurrences: number;
226
226
  prs: string[];
227
227
  sampleBodies: string[];
@@ -237,7 +237,7 @@ export declare const RecurrenceStatsSchema: z.ZodObject<{
237
237
  paths: string[];
238
238
  signature: string;
239
239
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif" | "mixed";
240
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
240
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
241
241
  occurrences: number;
242
242
  prs: string[];
243
243
  sampleBodies: string[];
@@ -86,7 +86,7 @@ export declare const RetrospectFindingSchema: z.ZodDiscriminatedUnion<"classific
86
86
  file: string;
87
87
  signature: string;
88
88
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
89
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
89
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
90
90
  coveredByRule: boolean;
91
91
  roundNumber: number;
92
92
  bodyExcerpt: string;
@@ -98,7 +98,7 @@ export declare const RetrospectFindingSchema: z.ZodDiscriminatedUnion<"classific
98
98
  file: string;
99
99
  signature: string;
100
100
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
101
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
101
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
102
102
  coveredByRule: boolean;
103
103
  roundNumber: number;
104
104
  bodyExcerpt: string;
@@ -131,7 +131,7 @@ export declare const RetrospectFindingSchema: z.ZodDiscriminatedUnion<"classific
131
131
  file: string;
132
132
  signature: string;
133
133
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
134
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
134
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
135
135
  coveredByRule: boolean;
136
136
  roundNumber: number;
137
137
  bodyExcerpt: string;
@@ -142,7 +142,7 @@ export declare const RetrospectFindingSchema: z.ZodDiscriminatedUnion<"classific
142
142
  file: string;
143
143
  signature: string;
144
144
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
145
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
145
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
146
146
  coveredByRule: boolean;
147
147
  roundNumber: number;
148
148
  bodyExcerpt: string;
@@ -174,7 +174,7 @@ export declare const RetrospectFindingSchema: z.ZodDiscriminatedUnion<"classific
174
174
  file: string;
175
175
  signature: string;
176
176
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
177
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
177
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
178
178
  coveredByRule: boolean;
179
179
  roundNumber: number;
180
180
  bodyExcerpt: string;
@@ -185,7 +185,7 @@ export declare const RetrospectFindingSchema: z.ZodDiscriminatedUnion<"classific
185
185
  file: string;
186
186
  signature: string;
187
187
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
188
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
188
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
189
189
  coveredByRule: boolean;
190
190
  roundNumber: number;
191
191
  bodyExcerpt: string;
@@ -277,7 +277,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
277
277
  file: string;
278
278
  signature: string;
279
279
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
280
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
280
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
281
281
  coveredByRule: boolean;
282
282
  roundNumber: number;
283
283
  bodyExcerpt: string;
@@ -289,7 +289,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
289
289
  file: string;
290
290
  signature: string;
291
291
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
292
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
292
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
293
293
  coveredByRule: boolean;
294
294
  roundNumber: number;
295
295
  bodyExcerpt: string;
@@ -322,7 +322,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
322
322
  file: string;
323
323
  signature: string;
324
324
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
325
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
325
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
326
326
  coveredByRule: boolean;
327
327
  roundNumber: number;
328
328
  bodyExcerpt: string;
@@ -333,7 +333,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
333
333
  file: string;
334
334
  signature: string;
335
335
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
336
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
336
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
337
337
  coveredByRule: boolean;
338
338
  roundNumber: number;
339
339
  bodyExcerpt: string;
@@ -365,7 +365,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
365
365
  file: string;
366
366
  signature: string;
367
367
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
368
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
368
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
369
369
  coveredByRule: boolean;
370
370
  roundNumber: number;
371
371
  bodyExcerpt: string;
@@ -376,7 +376,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
376
376
  file: string;
377
377
  signature: string;
378
378
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
379
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
379
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
380
380
  coveredByRule: boolean;
381
381
  roundNumber: number;
382
382
  bodyExcerpt: string;
@@ -412,7 +412,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
412
412
  file: string;
413
413
  signature: string;
414
414
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
415
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
415
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
416
416
  coveredByRule: boolean;
417
417
  roundNumber: number;
418
418
  bodyExcerpt: string;
@@ -424,7 +424,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
424
424
  file: string;
425
425
  signature: string;
426
426
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
427
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
427
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
428
428
  coveredByRule: boolean;
429
429
  roundNumber: number;
430
430
  bodyExcerpt: string;
@@ -457,7 +457,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
457
457
  file: string;
458
458
  signature: string;
459
459
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
460
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
460
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
461
461
  coveredByRule: boolean;
462
462
  roundNumber: number;
463
463
  bodyExcerpt: string;
@@ -468,7 +468,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
468
468
  file: string;
469
469
  signature: string;
470
470
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
471
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
471
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
472
472
  coveredByRule: boolean;
473
473
  roundNumber: number;
474
474
  bodyExcerpt: string;
@@ -500,7 +500,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
500
500
  file: string;
501
501
  signature: string;
502
502
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
503
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
503
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
504
504
  coveredByRule: boolean;
505
505
  roundNumber: number;
506
506
  bodyExcerpt: string;
@@ -511,7 +511,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
511
511
  file: string;
512
512
  signature: string;
513
513
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
514
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
514
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
515
515
  coveredByRule: boolean;
516
516
  roundNumber: number;
517
517
  bodyExcerpt: string;
@@ -547,7 +547,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
547
547
  file: string;
548
548
  signature: string;
549
549
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
550
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
550
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
551
551
  coveredByRule: boolean;
552
552
  roundNumber: number;
553
553
  bodyExcerpt: string;
@@ -559,7 +559,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
559
559
  file: string;
560
560
  signature: string;
561
561
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
562
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
562
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
563
563
  coveredByRule: boolean;
564
564
  roundNumber: number;
565
565
  bodyExcerpt: string;
@@ -592,7 +592,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
592
592
  file: string;
593
593
  signature: string;
594
594
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
595
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
595
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
596
596
  coveredByRule: boolean;
597
597
  roundNumber: number;
598
598
  bodyExcerpt: string;
@@ -603,7 +603,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
603
603
  file: string;
604
604
  signature: string;
605
605
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
606
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
606
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
607
607
  coveredByRule: boolean;
608
608
  roundNumber: number;
609
609
  bodyExcerpt: string;
@@ -635,7 +635,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
635
635
  file: string;
636
636
  signature: string;
637
637
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
638
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
638
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
639
639
  coveredByRule: boolean;
640
640
  roundNumber: number;
641
641
  bodyExcerpt: string;
@@ -646,7 +646,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
646
646
  file: string;
647
647
  signature: string;
648
648
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
649
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
649
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
650
650
  coveredByRule: boolean;
651
651
  roundNumber: number;
652
652
  bodyExcerpt: string;
@@ -664,7 +664,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
664
664
  file: string;
665
665
  signature: string;
666
666
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
667
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
667
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
668
668
  coveredByRule: boolean;
669
669
  roundNumber: number;
670
670
  bodyExcerpt: string;
@@ -676,7 +676,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
676
676
  file: string;
677
677
  signature: string;
678
678
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
679
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
679
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
680
680
  coveredByRule: boolean;
681
681
  roundNumber: number;
682
682
  bodyExcerpt: string;
@@ -687,7 +687,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
687
687
  file: string;
688
688
  signature: string;
689
689
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
690
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
690
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
691
691
  coveredByRule: boolean;
692
692
  roundNumber: number;
693
693
  bodyExcerpt: string;
@@ -718,7 +718,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
718
718
  file: string;
719
719
  signature: string;
720
720
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
721
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
721
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
722
722
  coveredByRule: boolean;
723
723
  roundNumber: number;
724
724
  bodyExcerpt: string;
@@ -730,7 +730,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
730
730
  file: string;
731
731
  signature: string;
732
732
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
733
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
733
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
734
734
  coveredByRule: boolean;
735
735
  roundNumber: number;
736
736
  bodyExcerpt: string;
@@ -741,7 +741,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
741
741
  file: string;
742
742
  signature: string;
743
743
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
744
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
744
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
745
745
  coveredByRule: boolean;
746
746
  roundNumber: number;
747
747
  bodyExcerpt: string;
@@ -753,7 +753,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
753
753
  file: string;
754
754
  signature: string;
755
755
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
756
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
756
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
757
757
  coveredByRule: boolean;
758
758
  roundNumber: number;
759
759
  bodyExcerpt: string;
@@ -765,7 +765,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
765
765
  file: string;
766
766
  signature: string;
767
767
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
768
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
768
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
769
769
  coveredByRule: boolean;
770
770
  roundNumber: number;
771
771
  bodyExcerpt: string;
@@ -776,7 +776,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
776
776
  file: string;
777
777
  signature: string;
778
778
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
779
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
779
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
780
780
  coveredByRule: boolean;
781
781
  roundNumber: number;
782
782
  bodyExcerpt: string;
@@ -792,7 +792,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
792
792
  file: string;
793
793
  signature: string;
794
794
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
795
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
795
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
796
796
  coveredByRule: boolean;
797
797
  roundNumber: number;
798
798
  bodyExcerpt: string;
@@ -804,7 +804,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
804
804
  file: string;
805
805
  signature: string;
806
806
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
807
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
807
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
808
808
  coveredByRule: boolean;
809
809
  roundNumber: number;
810
810
  bodyExcerpt: string;
@@ -815,7 +815,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
815
815
  file: string;
816
816
  signature: string;
817
817
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
818
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
818
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
819
819
  coveredByRule: boolean;
820
820
  roundNumber: number;
821
821
  bodyExcerpt: string;
@@ -846,7 +846,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
846
846
  file: string;
847
847
  signature: string;
848
848
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
849
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
849
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
850
850
  coveredByRule: boolean;
851
851
  roundNumber: number;
852
852
  bodyExcerpt: string;
@@ -858,7 +858,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
858
858
  file: string;
859
859
  signature: string;
860
860
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
861
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
861
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
862
862
  coveredByRule: boolean;
863
863
  roundNumber: number;
864
864
  bodyExcerpt: string;
@@ -869,7 +869,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
869
869
  file: string;
870
870
  signature: string;
871
871
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
872
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
872
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
873
873
  coveredByRule: boolean;
874
874
  roundNumber: number;
875
875
  bodyExcerpt: string;
@@ -881,7 +881,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
881
881
  file: string;
882
882
  signature: string;
883
883
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
884
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
884
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
885
885
  coveredByRule: boolean;
886
886
  roundNumber: number;
887
887
  bodyExcerpt: string;
@@ -893,7 +893,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
893
893
  file: string;
894
894
  signature: string;
895
895
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
896
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
896
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
897
897
  coveredByRule: boolean;
898
898
  roundNumber: number;
899
899
  bodyExcerpt: string;
@@ -904,7 +904,7 @@ export declare const RetrospectReportSchema: z.ZodObject<{
904
904
  file: string;
905
905
  signature: string;
906
906
  tool: "unknown" | "override" | "coderabbit" | "gca" | "sarif";
907
- severityBucket: "critical" | "high" | "medium" | "low" | "nit";
907
+ severityBucket: "high" | "medium" | "critical" | "low" | "nit";
908
908
  coveredByRule: boolean;
909
909
  roundNumber: number;
910
910
  bodyExcerpt: string;
@@ -0,0 +1,133 @@
1
+ /**
2
+ * ADR-091 Stage 4 Verify-Against-Codebase verifier (mmnto-ai/totem#1682).
3
+ *
4
+ * Runs a compiled rule deterministically (zero LLM) against the consumer's
5
+ * existing codebase before promoting it to Active status. Catches the class
6
+ * of false positive that Layer 3 (ADR-088) cannot — Layer 3 verifies the
7
+ * pattern matches the lesson's authored `badExample` (internal consistency);
8
+ * Stage 4 verifies the pattern doesn't accidentally fire on legitimate code
9
+ * (global false-positive safety).
10
+ *
11
+ * Four outcomes per ADR-091 §"Stage 4: Verify-Against-Codebase":
12
+ *
13
+ * - **No matches** (`outcome: 'no-matches'`) — the verifier ran, found zero
14
+ * hits in the codebase. Caller sets `status: 'untested-against-codebase'`;
15
+ * subsequent compile cycles in a populated repo can re-run Stage 4 and
16
+ * promote.
17
+ * - **Out-of-scope baseline match** (`outcome: 'out-of-scope'`) — the rule
18
+ * fired on at least one file in the verification baseline (test files,
19
+ * fixture directories, or files outside the rule's `fileGlobs` scope).
20
+ * The pattern is over-broad. Caller archives the rule with
21
+ * `reasonCode: 'stage4-out-of-scope-match'` and the offending paths.
22
+ * - **In-scope `badExample`-shape match** (`outcome: 'in-scope-bad-example'`)
23
+ * — the rule fired only on in-scope files AND every in-scope match line is
24
+ * structurally equivalent to the rule's `badExample`. The rule fires on
25
+ * real code in the exact authored shape. Caller sets `status: 'active'`
26
+ * with `confidence: 'high'`.
27
+ * - **Candidate Debt** (`outcome: 'candidate-debt'`) — the rule fired only
28
+ * on in-scope files but at least one match line differs from the
29
+ * `badExample` shape. The rule may be catching real debt, or producing
30
+ * false positives the LLM-generated pattern overshoots into. Caller
31
+ * accepts as `status: 'active'` and forces `severity: 'warning'` so it
32
+ * never breaks CI on first run; `totem doctor` (mmnto-ai/totem#1685)
33
+ * surfaces the candidate-debt sites for human confirmation.
34
+ *
35
+ * Bootstrap modes: T1 ships local-compile fully (the verifier runs against
36
+ * the consumer's working tree before `totem lesson compile` serializes the
37
+ * rule). Pack install→lint promotion lands in T3 (mmnto-ai/totem#1684).
38
+ * Consumer baseline overrides land in T2 (mmnto-ai/totem#1683). Perf
39
+ * optimizations (single-pass, file-tree caching, streaming short-circuit)
40
+ * land in T5 (mmnto-ai/totem#1686). T1 walks per-rule, no caching.
41
+ *
42
+ * Architecture: callback-based filesystem. The verifier accepts `listFiles`
43
+ * + `readFile` callbacks instead of touching `fs` directly so core stays
44
+ * orchestration-only. CLI implementations back the callbacks with `git
45
+ * ls-files` and `fs.readFile`; tests stub them with synthetic file maps.
46
+ */
47
+ import type { CompiledRule } from './compiler-schema.js';
48
+ import type { RuleEngineContext } from './rule-engine.js';
49
+ export interface Stage4Baseline {
50
+ /**
51
+ * Glob patterns the rule MUST NOT fire on. Files matching any of these
52
+ * globs are part of the verification baseline — a match on one of them
53
+ * is evidence the pattern is over-broad. T1 ships with `DEFAULT_BASELINE_GLOBS`
54
+ * (test + fixture patterns); T2 (mmnto-ai/totem#1683) layers consumer
55
+ * `extend` / `exclude` overrides via `review.stage4Baseline` config.
56
+ *
57
+ * Files outside the rule's `fileGlobs` scope are implicitly in the baseline
58
+ * — no need to list them here. The verifier computes the implicit case
59
+ * from `rule.fileGlobs` at evaluation time.
60
+ */
61
+ readonly excludeFileGlobs: readonly string[];
62
+ }
63
+ export type Stage4Outcome = 'no-matches' | 'out-of-scope' | 'in-scope-bad-example' | 'candidate-debt';
64
+ export interface Stage4VerificationResult {
65
+ outcome: Stage4Outcome;
66
+ /** Repo-relative paths where the rule fired AND the file is in the baseline. */
67
+ readonly baselineMatches: readonly string[];
68
+ /** Repo-relative paths where the rule fired AND the file is in scope. */
69
+ readonly inScopeMatches: readonly string[];
70
+ /**
71
+ * Match lines from in-scope hits that did NOT match the `badExample`
72
+ * shape (after trimming). Empty when `outcome === 'in-scope-bad-example'`.
73
+ * Populated when `outcome === 'candidate-debt'` to feed the `totem doctor`
74
+ * UX surface in T4 (mmnto-ai/totem#1685).
75
+ */
76
+ readonly candidateDebtLines: readonly string[];
77
+ }
78
+ export interface Stage4VerifierDeps {
79
+ /**
80
+ * Returns repo-relative paths of all files to verify against. CLI
81
+ * implementation calls `git ls-files --recurse-submodules`. Tests pass
82
+ * a synthetic list. Empty array is valid input — the verifier returns
83
+ * `outcome: 'no-matches'` (the zero-files case is indistinguishable from
84
+ * the no-hits case at the API level; both produce `untested-against-codebase`
85
+ * status downstream).
86
+ */
87
+ listFiles: () => Promise<readonly string[]>;
88
+ /**
89
+ * Returns the file content as a string. CLI implementation reads from
90
+ * the working tree (`fs.readFile`). MUST throw if the file is missing —
91
+ * Stage 4 is a fail-loud contract per Tenet 4.
92
+ */
93
+ readFile: (file: string) => Promise<string>;
94
+ /**
95
+ * Optional working directory absolute path. Required when the verifier
96
+ * encounters ast / ast-grep rules — `applyAstRulesToAdditions` resolves
97
+ * file content against this root. Regex-only verification does not need
98
+ * it. T1 callers always pass the repo root.
99
+ */
100
+ workingDirectory?: string;
101
+ /** Optional rule-engine context. Defaults to a no-op logger. */
102
+ ruleCtx?: RuleEngineContext;
103
+ }
104
+ /**
105
+ * Glob shapes the test-contract scope classifier (mmnto-ai/totem#1626 /
106
+ * mmnto-ai/totem#1652) promotes-to-test-inclusive when emitting LLM scope.
107
+ * Stage 4 mirrors them as the default baseline so any rule that fires on a
108
+ * test or fixture file is treated as out-of-scope by default. T2
109
+ * (mmnto-ai/totem#1683) lets consumers `exclude` from this list when their
110
+ * project legitimately treats `tests/` as production.
111
+ */
112
+ export declare const DEFAULT_BASELINE_GLOBS: readonly string[];
113
+ export declare function getDefaultBaseline(): Stage4Baseline;
114
+ /**
115
+ * Run Stage 4 verification for a single compiled rule against the consumer's
116
+ * codebase. Caller decides what to do with the returned outcome:
117
+ *
118
+ * - `'no-matches'` → set rule.status = 'untested-against-codebase'
119
+ * - `'out-of-scope'` → archive rule with reasonCode 'stage4-out-of-scope-match'
120
+ * - `'in-scope-bad-example'` → set rule.status = 'active', confidence = 'high'
121
+ * - `'candidate-debt'` → set rule.status = 'active', force severity = 'warning'
122
+ *
123
+ * The verifier itself does NOT mutate the rule. Mutation happens at the
124
+ * compileLesson integration site so the trace event and lifecycle field
125
+ * preservation remain centralized.
126
+ *
127
+ * For Pipeline 1 manual rules, the integration site bypasses Stage 4
128
+ * entirely — those rules are human-authored and Stage 4 is a safety net
129
+ * for LLM-generated patterns. The verifier itself is engine-agnostic and
130
+ * will run on any rule it's handed.
131
+ */
132
+ export declare function verifyAgainstCodebase(rule: CompiledRule, baseline: Stage4Baseline, deps: Stage4VerifierDeps): Promise<Stage4VerificationResult>;
133
+ //# sourceMappingURL=stage4-verifier.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"stage4-verifier.d.ts","sourceRoot":"","sources":["../src/stage4-verifier.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6CG;AAEH,OAAO,KAAK,EAAE,YAAY,EAA2B,MAAM,sBAAsB,CAAC;AAClF,OAAO,KAAK,EAAc,iBAAiB,EAAE,MAAM,kBAAkB,CAAC;AAKtE,MAAM,WAAW,cAAc;IAC7B;;;;;;;;;;OAUG;IACH,QAAQ,CAAC,gBAAgB,EAAE,SAAS,MAAM,EAAE,CAAC;CAC9C;AAED,MAAM,MAAM,aAAa,GACrB,YAAY,GACZ,cAAc,GACd,sBAAsB,GACtB,gBAAgB,CAAC;AAErB,MAAM,WAAW,wBAAwB;IACvC,OAAO,EAAE,aAAa,CAAC;IACvB,gFAAgF;IAChF,QAAQ,CAAC,eAAe,EAAE,SAAS,MAAM,EAAE,CAAC;IAC5C,yEAAyE;IACzE,QAAQ,CAAC,cAAc,EAAE,SAAS,MAAM,EAAE,CAAC;IAC3C;;;;;OAKG;IACH,QAAQ,CAAC,kBAAkB,EAAE,SAAS,MAAM,EAAE,CAAC;CAChD;AAED,MAAM,WAAW,kBAAkB;IACjC;;;;;;;OAOG;IACH,SAAS,EAAE,MAAM,OAAO,CAAC,SAAS,MAAM,EAAE,CAAC,CAAC;IAC5C;;;;OAIG;IACH,QAAQ,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,OAAO,CAAC,MAAM,CAAC,CAAC;IAC5C;;;;;OAKG;IACH,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,gEAAgE;IAChE,OAAO,CAAC,EAAE,iBAAiB,CAAC;CAC7B;AAID;;;;;;;GAOG;AACH,eAAO,MAAM,sBAAsB,EAAE,SAAS,MAAM,EAOnD,CAAC;AAEF,wBAAgB,kBAAkB,IAAI,cAAc,CAMnD;AAsMD;;;;;;;;;;;;;;;;;GAiBG;AACH,wBAAsB,qBAAqB,CACzC,IAAI,EAAE,YAAY,EAClB,QAAQ,EAAE,cAAc,EACxB,IAAI,EAAE,kBAAkB,GACvB,OAAO,CAAC,wBAAwB,CAAC,CA2FnC"}