@mmnto/totem 1.64.0 → 1.64.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/artifacts/panel.d.ts +1919 -0
- package/dist/artifacts/panel.d.ts.map +1 -0
- package/dist/artifacts/panel.js +503 -0
- package/dist/artifacts/panel.js.map +1 -0
- package/dist/artifacts/panel.test.d.ts +15 -0
- package/dist/artifacts/panel.test.d.ts.map +1 -0
- package/dist/artifacts/panel.test.js +335 -0
- package/dist/artifacts/panel.test.js.map +1 -0
- package/dist/artifacts/post-checks-rules.d.ts +93 -0
- package/dist/artifacts/post-checks-rules.d.ts.map +1 -0
- package/dist/artifacts/post-checks-rules.js +307 -0
- package/dist/artifacts/post-checks-rules.js.map +1 -0
- package/dist/artifacts/post-checks-rules.test.d.ts +9 -0
- package/dist/artifacts/post-checks-rules.test.d.ts.map +1 -0
- package/dist/artifacts/post-checks-rules.test.js +258 -0
- package/dist/artifacts/post-checks-rules.test.js.map +1 -0
- package/dist/artifacts/post-checks.d.ts +102 -0
- package/dist/artifacts/post-checks.d.ts.map +1 -0
- package/dist/artifacts/post-checks.js +80 -0
- package/dist/artifacts/post-checks.js.map +1 -0
- package/dist/artifacts/post-checks.test.d.ts +12 -0
- package/dist/artifacts/post-checks.test.d.ts.map +1 -0
- package/dist/artifacts/post-checks.test.js +103 -0
- package/dist/artifacts/post-checks.test.js.map +1 -0
- package/dist/compiler-schema.d.ts +329 -0
- package/dist/compiler-schema.d.ts.map +1 -1
- package/dist/compiler-schema.js +136 -1
- package/dist/compiler-schema.js.map +1 -1
- package/dist/compiler-schema.test.js +136 -1
- package/dist/compiler-schema.test.js.map +1 -1
- package/dist/compiler.d.ts +2 -2
- package/dist/compiler.d.ts.map +1 -1
- package/dist/compiler.js +1 -1
- package/dist/compiler.js.map +1 -1
- package/dist/index.d.ts +8 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +4 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
|
@@ -36,6 +36,111 @@ export declare const AstGrepYamlRuleSchema: z.ZodObject<{
|
|
|
36
36
|
rule: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
37
37
|
}, z.ZodTypeAny, "passthrough">>;
|
|
38
38
|
export type AstGrepYamlRule = NapiConfig;
|
|
39
|
+
/**
|
|
40
|
+
* mmnto-ai/totem#2183 — the §3.1 provenance leg of the ADR-110 Gate-1
|
|
41
|
+
* legitimacy bar: the identity of the merged-PR history a regenerated rule was
|
|
42
|
+
* mined from. Structured and **mechanically validated** (NOT a bare string) so
|
|
43
|
+
* a placeholder cannot masquerade as provenance. Promotion state is NOT carried
|
|
44
|
+
* here — it lives on the owning rule's top-level `unverified` flag (ADR-089
|
|
45
|
+
* zero-trust), the single source of truth `deriveRuleClass` reads. Control
|
|
46
|
+
* *evidence* (which PRs/fixtures proved each control) rides the wind-tunnel
|
|
47
|
+
* manifest (ADR-110 §6), not the per-rule marker.
|
|
48
|
+
*/
|
|
49
|
+
export declare const ProvenanceRecordSchema: z.ZodObject<{
|
|
50
|
+
/** Merged PR the rule was mined from (positive integer PR number). */
|
|
51
|
+
mergedPr: z.ZodNumber;
|
|
52
|
+
/**
|
|
53
|
+
* Reference to the review thread that adjudicated the rule. Rejects empty and
|
|
54
|
+
* whitespace-only via a NON-MUTATING refinement (greptile/CR #2186): a
|
|
55
|
+
* `.trim()` transform would silently normalize a padded value on parse, so a
|
|
56
|
+
* stamped rule's on-disk JSON could differ from its parsed form and churn the
|
|
57
|
+
* manifest hash on the next `verify-manifest`. `.refine` validates without
|
|
58
|
+
* mutating, so the stored value round-trips byte-identically.
|
|
59
|
+
*/
|
|
60
|
+
reviewThread: z.ZodEffects<z.ZodString, string, string>;
|
|
61
|
+
/** Full 40-hex git commit SHA the rule was frozen at. */
|
|
62
|
+
commitSha: z.ZodString;
|
|
63
|
+
}, "strip", z.ZodTypeAny, {
|
|
64
|
+
mergedPr: number;
|
|
65
|
+
reviewThread: string;
|
|
66
|
+
commitSha: string;
|
|
67
|
+
}, {
|
|
68
|
+
mergedPr: number;
|
|
69
|
+
reviewThread: string;
|
|
70
|
+
commitSha: string;
|
|
71
|
+
}>;
|
|
72
|
+
export type ProvenanceRecord = z.infer<typeof ProvenanceRecordSchema>;
|
|
73
|
+
/**
|
|
74
|
+
* mmnto-ai/totem#2183 — the three **peer** legs of the ADR-110 §3 legitimacy
|
|
75
|
+
* bar, mapping 1:1 onto the strategy#666 Tenet-9 three-check so the Gate-1
|
|
76
|
+
* wind-tunnel reads per-rule eligibility off the marker with no translation
|
|
77
|
+
* layer: `provenance` (§3.1) / `positiveControl` (§3.2) / `negativeControl`
|
|
78
|
+
* (§3.3). Controls are pass/fail booleans, **required** when `legitimacy` is
|
|
79
|
+
* present (never defaulted, so an absent control can't silently read as a
|
|
80
|
+
* failed one); the evidence behind each pass lives in the wind-tunnel manifest.
|
|
81
|
+
*/
|
|
82
|
+
export declare const LegitimacySchema: z.ZodObject<{
|
|
83
|
+
provenance: z.ZodObject<{
|
|
84
|
+
/** Merged PR the rule was mined from (positive integer PR number). */
|
|
85
|
+
mergedPr: z.ZodNumber;
|
|
86
|
+
/**
|
|
87
|
+
* Reference to the review thread that adjudicated the rule. Rejects empty and
|
|
88
|
+
* whitespace-only via a NON-MUTATING refinement (greptile/CR #2186): a
|
|
89
|
+
* `.trim()` transform would silently normalize a padded value on parse, so a
|
|
90
|
+
* stamped rule's on-disk JSON could differ from its parsed form and churn the
|
|
91
|
+
* manifest hash on the next `verify-manifest`. `.refine` validates without
|
|
92
|
+
* mutating, so the stored value round-trips byte-identically.
|
|
93
|
+
*/
|
|
94
|
+
reviewThread: z.ZodEffects<z.ZodString, string, string>;
|
|
95
|
+
/** Full 40-hex git commit SHA the rule was frozen at. */
|
|
96
|
+
commitSha: z.ZodString;
|
|
97
|
+
}, "strip", z.ZodTypeAny, {
|
|
98
|
+
mergedPr: number;
|
|
99
|
+
reviewThread: string;
|
|
100
|
+
commitSha: string;
|
|
101
|
+
}, {
|
|
102
|
+
mergedPr: number;
|
|
103
|
+
reviewThread: string;
|
|
104
|
+
commitSha: string;
|
|
105
|
+
}>;
|
|
106
|
+
positiveControl: z.ZodBoolean;
|
|
107
|
+
negativeControl: z.ZodBoolean;
|
|
108
|
+
}, "strip", z.ZodTypeAny, {
|
|
109
|
+
provenance: {
|
|
110
|
+
mergedPr: number;
|
|
111
|
+
reviewThread: string;
|
|
112
|
+
commitSha: string;
|
|
113
|
+
};
|
|
114
|
+
positiveControl: boolean;
|
|
115
|
+
negativeControl: boolean;
|
|
116
|
+
}, {
|
|
117
|
+
provenance: {
|
|
118
|
+
mergedPr: number;
|
|
119
|
+
reviewThread: string;
|
|
120
|
+
commitSha: string;
|
|
121
|
+
};
|
|
122
|
+
positiveControl: boolean;
|
|
123
|
+
negativeControl: boolean;
|
|
124
|
+
}>;
|
|
125
|
+
export type Legitimacy = z.infer<typeof LegitimacySchema>;
|
|
126
|
+
/**
|
|
127
|
+
* mmnto-ai/totem#2183 — derive the enforcement tier from the ADR-110 §3
|
|
128
|
+
* legitimacy bar. Pure + deterministic (Tenet 9). A rule is `'hard'` ONLY when
|
|
129
|
+
* all three legs hold AND the rule is promoted: `legitimacy` present, the
|
|
130
|
+
* owning rule's ADR-089 `unverified` flag is not `true`, and both controls
|
|
131
|
+
* passed. Anything else — no legitimacy, unpromoted, or a failed control — is
|
|
132
|
+
* `'advisory'`. Promotion reads the rule's TOP-LEVEL `unverified` (the single
|
|
133
|
+
* source of truth; #1485 / #1479 already read it), never a nested copy.
|
|
134
|
+
*
|
|
135
|
+
* **Unwired** from `buildCompiledRule` in this slice: the rule-compilation
|
|
136
|
+
* freeze stands, so the sanctioned writer is spine regeneration (strategy#516),
|
|
137
|
+
* which owns the wiring. Exposed as a pure helper for that regenerator and for
|
|
138
|
+
* the consistency superRefine below.
|
|
139
|
+
*/
|
|
140
|
+
export declare function deriveRuleClass(rule: {
|
|
141
|
+
legitimacy?: Legitimacy;
|
|
142
|
+
unverified?: boolean;
|
|
143
|
+
}): 'hard' | 'advisory';
|
|
39
144
|
export declare const CompiledRuleSchema: z.ZodEffects<z.ZodObject<{
|
|
40
145
|
/** SHA-256 hash (first 16 hex chars) of heading + body — detects edits */
|
|
41
146
|
lessonHash: z.ZodString;
|
|
@@ -195,6 +300,68 @@ export declare const CompiledRuleSchema: z.ZodEffects<z.ZodObject<{
|
|
|
195
300
|
* produce identical output.
|
|
196
301
|
*/
|
|
197
302
|
unverified: z.ZodOptional<z.ZodBoolean>;
|
|
303
|
+
/**
|
|
304
|
+
* mmnto-ai/totem#2183 — the ADR-110 §3 legitimacy bar (three peer legs). Set
|
|
305
|
+
* by spine rule-regeneration (strategy#516); **absent on every legacy rule.**
|
|
306
|
+
* When present, `ruleClass` MUST also be present and equal to
|
|
307
|
+
* `deriveRuleClass(rule)` — enforced by the superRefine on
|
|
308
|
+
* `CompiledRuleSchema`. Never written with defaults: absence is the legacy
|
|
309
|
+
* signal and preserves pre-#2183 manifest hashes via canonicalStringify.
|
|
310
|
+
*/
|
|
311
|
+
legitimacy: z.ZodOptional<z.ZodObject<{
|
|
312
|
+
provenance: z.ZodObject<{
|
|
313
|
+
/** Merged PR the rule was mined from (positive integer PR number). */
|
|
314
|
+
mergedPr: z.ZodNumber;
|
|
315
|
+
/**
|
|
316
|
+
* Reference to the review thread that adjudicated the rule. Rejects empty and
|
|
317
|
+
* whitespace-only via a NON-MUTATING refinement (greptile/CR #2186): a
|
|
318
|
+
* `.trim()` transform would silently normalize a padded value on parse, so a
|
|
319
|
+
* stamped rule's on-disk JSON could differ from its parsed form and churn the
|
|
320
|
+
* manifest hash on the next `verify-manifest`. `.refine` validates without
|
|
321
|
+
* mutating, so the stored value round-trips byte-identically.
|
|
322
|
+
*/
|
|
323
|
+
reviewThread: z.ZodEffects<z.ZodString, string, string>;
|
|
324
|
+
/** Full 40-hex git commit SHA the rule was frozen at. */
|
|
325
|
+
commitSha: z.ZodString;
|
|
326
|
+
}, "strip", z.ZodTypeAny, {
|
|
327
|
+
mergedPr: number;
|
|
328
|
+
reviewThread: string;
|
|
329
|
+
commitSha: string;
|
|
330
|
+
}, {
|
|
331
|
+
mergedPr: number;
|
|
332
|
+
reviewThread: string;
|
|
333
|
+
commitSha: string;
|
|
334
|
+
}>;
|
|
335
|
+
positiveControl: z.ZodBoolean;
|
|
336
|
+
negativeControl: z.ZodBoolean;
|
|
337
|
+
}, "strip", z.ZodTypeAny, {
|
|
338
|
+
provenance: {
|
|
339
|
+
mergedPr: number;
|
|
340
|
+
reviewThread: string;
|
|
341
|
+
commitSha: string;
|
|
342
|
+
};
|
|
343
|
+
positiveControl: boolean;
|
|
344
|
+
negativeControl: boolean;
|
|
345
|
+
}, {
|
|
346
|
+
provenance: {
|
|
347
|
+
mergedPr: number;
|
|
348
|
+
reviewThread: string;
|
|
349
|
+
commitSha: string;
|
|
350
|
+
};
|
|
351
|
+
positiveControl: boolean;
|
|
352
|
+
negativeControl: boolean;
|
|
353
|
+
}>>;
|
|
354
|
+
/**
|
|
355
|
+
* mmnto-ai/totem#2183 — the first-class, **derived** enforcement-tier marker
|
|
356
|
+
* that retires the engine-type proxy (#2181). `'hard'` blocks (subject to the
|
|
357
|
+
* unchanged severity gate — error blocks, warning does not); `'advisory'` is
|
|
358
|
+
* printed, non-blocking. Derived from `legitimacy` at mint via
|
|
359
|
+
* `deriveRuleClass`; the reader TRUSTS this frozen stamp and never re-derives
|
|
360
|
+
* at lint-time (ADR-110 §1 mint+validate boundary; Tenet-15
|
|
361
|
+
* verifiable-freezing). Present **iff** `legitimacy` is present; absent ⇒ the
|
|
362
|
+
* reader falls back to the legacy engine-type proxy.
|
|
363
|
+
*/
|
|
364
|
+
ruleClass: z.ZodOptional<z.ZodEnum<["hard", "advisory"]>>;
|
|
198
365
|
}, "strip", z.ZodTypeAny, {
|
|
199
366
|
message: string;
|
|
200
367
|
lessonHash: string;
|
|
@@ -220,6 +387,16 @@ export declare const CompiledRuleSchema: z.ZodEffects<z.ZodObject<{
|
|
|
220
387
|
manual?: boolean | undefined;
|
|
221
388
|
immutable?: boolean | undefined;
|
|
222
389
|
unverified?: boolean | undefined;
|
|
390
|
+
legitimacy?: {
|
|
391
|
+
provenance: {
|
|
392
|
+
mergedPr: number;
|
|
393
|
+
reviewThread: string;
|
|
394
|
+
commitSha: string;
|
|
395
|
+
};
|
|
396
|
+
positiveControl: boolean;
|
|
397
|
+
negativeControl: boolean;
|
|
398
|
+
} | undefined;
|
|
399
|
+
ruleClass?: "hard" | "advisory" | undefined;
|
|
223
400
|
}, {
|
|
224
401
|
message: string;
|
|
225
402
|
lessonHash: string;
|
|
@@ -245,6 +422,16 @@ export declare const CompiledRuleSchema: z.ZodEffects<z.ZodObject<{
|
|
|
245
422
|
manual?: boolean | undefined;
|
|
246
423
|
immutable?: boolean | undefined;
|
|
247
424
|
unverified?: boolean | undefined;
|
|
425
|
+
legitimacy?: {
|
|
426
|
+
provenance: {
|
|
427
|
+
mergedPr: number;
|
|
428
|
+
reviewThread: string;
|
|
429
|
+
commitSha: string;
|
|
430
|
+
};
|
|
431
|
+
positiveControl: boolean;
|
|
432
|
+
negativeControl: boolean;
|
|
433
|
+
} | undefined;
|
|
434
|
+
ruleClass?: "hard" | "advisory" | undefined;
|
|
248
435
|
}>, {
|
|
249
436
|
message: string;
|
|
250
437
|
lessonHash: string;
|
|
@@ -270,6 +457,16 @@ export declare const CompiledRuleSchema: z.ZodEffects<z.ZodObject<{
|
|
|
270
457
|
manual?: boolean | undefined;
|
|
271
458
|
immutable?: boolean | undefined;
|
|
272
459
|
unverified?: boolean | undefined;
|
|
460
|
+
legitimacy?: {
|
|
461
|
+
provenance: {
|
|
462
|
+
mergedPr: number;
|
|
463
|
+
reviewThread: string;
|
|
464
|
+
commitSha: string;
|
|
465
|
+
};
|
|
466
|
+
positiveControl: boolean;
|
|
467
|
+
negativeControl: boolean;
|
|
468
|
+
} | undefined;
|
|
469
|
+
ruleClass?: "hard" | "advisory" | undefined;
|
|
273
470
|
}, {
|
|
274
471
|
message: string;
|
|
275
472
|
lessonHash: string;
|
|
@@ -295,6 +492,16 @@ export declare const CompiledRuleSchema: z.ZodEffects<z.ZodObject<{
|
|
|
295
492
|
manual?: boolean | undefined;
|
|
296
493
|
immutable?: boolean | undefined;
|
|
297
494
|
unverified?: boolean | undefined;
|
|
495
|
+
legitimacy?: {
|
|
496
|
+
provenance: {
|
|
497
|
+
mergedPr: number;
|
|
498
|
+
reviewThread: string;
|
|
499
|
+
commitSha: string;
|
|
500
|
+
};
|
|
501
|
+
positiveControl: boolean;
|
|
502
|
+
negativeControl: boolean;
|
|
503
|
+
} | undefined;
|
|
504
|
+
ruleClass?: "hard" | "advisory" | undefined;
|
|
298
505
|
}>;
|
|
299
506
|
export type CompiledRule = z.infer<typeof CompiledRuleSchema>;
|
|
300
507
|
/**
|
|
@@ -578,6 +785,68 @@ export declare const CompiledRulesFileSchema: z.ZodObject<{
|
|
|
578
785
|
* produce identical output.
|
|
579
786
|
*/
|
|
580
787
|
unverified: z.ZodOptional<z.ZodBoolean>;
|
|
788
|
+
/**
|
|
789
|
+
* mmnto-ai/totem#2183 — the ADR-110 §3 legitimacy bar (three peer legs). Set
|
|
790
|
+
* by spine rule-regeneration (strategy#516); **absent on every legacy rule.**
|
|
791
|
+
* When present, `ruleClass` MUST also be present and equal to
|
|
792
|
+
* `deriveRuleClass(rule)` — enforced by the superRefine on
|
|
793
|
+
* `CompiledRuleSchema`. Never written with defaults: absence is the legacy
|
|
794
|
+
* signal and preserves pre-#2183 manifest hashes via canonicalStringify.
|
|
795
|
+
*/
|
|
796
|
+
legitimacy: z.ZodOptional<z.ZodObject<{
|
|
797
|
+
provenance: z.ZodObject<{
|
|
798
|
+
/** Merged PR the rule was mined from (positive integer PR number). */
|
|
799
|
+
mergedPr: z.ZodNumber;
|
|
800
|
+
/**
|
|
801
|
+
* Reference to the review thread that adjudicated the rule. Rejects empty and
|
|
802
|
+
* whitespace-only via a NON-MUTATING refinement (greptile/CR #2186): a
|
|
803
|
+
* `.trim()` transform would silently normalize a padded value on parse, so a
|
|
804
|
+
* stamped rule's on-disk JSON could differ from its parsed form and churn the
|
|
805
|
+
* manifest hash on the next `verify-manifest`. `.refine` validates without
|
|
806
|
+
* mutating, so the stored value round-trips byte-identically.
|
|
807
|
+
*/
|
|
808
|
+
reviewThread: z.ZodEffects<z.ZodString, string, string>;
|
|
809
|
+
/** Full 40-hex git commit SHA the rule was frozen at. */
|
|
810
|
+
commitSha: z.ZodString;
|
|
811
|
+
}, "strip", z.ZodTypeAny, {
|
|
812
|
+
mergedPr: number;
|
|
813
|
+
reviewThread: string;
|
|
814
|
+
commitSha: string;
|
|
815
|
+
}, {
|
|
816
|
+
mergedPr: number;
|
|
817
|
+
reviewThread: string;
|
|
818
|
+
commitSha: string;
|
|
819
|
+
}>;
|
|
820
|
+
positiveControl: z.ZodBoolean;
|
|
821
|
+
negativeControl: z.ZodBoolean;
|
|
822
|
+
}, "strip", z.ZodTypeAny, {
|
|
823
|
+
provenance: {
|
|
824
|
+
mergedPr: number;
|
|
825
|
+
reviewThread: string;
|
|
826
|
+
commitSha: string;
|
|
827
|
+
};
|
|
828
|
+
positiveControl: boolean;
|
|
829
|
+
negativeControl: boolean;
|
|
830
|
+
}, {
|
|
831
|
+
provenance: {
|
|
832
|
+
mergedPr: number;
|
|
833
|
+
reviewThread: string;
|
|
834
|
+
commitSha: string;
|
|
835
|
+
};
|
|
836
|
+
positiveControl: boolean;
|
|
837
|
+
negativeControl: boolean;
|
|
838
|
+
}>>;
|
|
839
|
+
/**
|
|
840
|
+
* mmnto-ai/totem#2183 — the first-class, **derived** enforcement-tier marker
|
|
841
|
+
* that retires the engine-type proxy (#2181). `'hard'` blocks (subject to the
|
|
842
|
+
* unchanged severity gate — error blocks, warning does not); `'advisory'` is
|
|
843
|
+
* printed, non-blocking. Derived from `legitimacy` at mint via
|
|
844
|
+
* `deriveRuleClass`; the reader TRUSTS this frozen stamp and never re-derives
|
|
845
|
+
* at lint-time (ADR-110 §1 mint+validate boundary; Tenet-15
|
|
846
|
+
* verifiable-freezing). Present **iff** `legitimacy` is present; absent ⇒ the
|
|
847
|
+
* reader falls back to the legacy engine-type proxy.
|
|
848
|
+
*/
|
|
849
|
+
ruleClass: z.ZodOptional<z.ZodEnum<["hard", "advisory"]>>;
|
|
581
850
|
}, "strip", z.ZodTypeAny, {
|
|
582
851
|
message: string;
|
|
583
852
|
lessonHash: string;
|
|
@@ -603,6 +872,16 @@ export declare const CompiledRulesFileSchema: z.ZodObject<{
|
|
|
603
872
|
manual?: boolean | undefined;
|
|
604
873
|
immutable?: boolean | undefined;
|
|
605
874
|
unverified?: boolean | undefined;
|
|
875
|
+
legitimacy?: {
|
|
876
|
+
provenance: {
|
|
877
|
+
mergedPr: number;
|
|
878
|
+
reviewThread: string;
|
|
879
|
+
commitSha: string;
|
|
880
|
+
};
|
|
881
|
+
positiveControl: boolean;
|
|
882
|
+
negativeControl: boolean;
|
|
883
|
+
} | undefined;
|
|
884
|
+
ruleClass?: "hard" | "advisory" | undefined;
|
|
606
885
|
}, {
|
|
607
886
|
message: string;
|
|
608
887
|
lessonHash: string;
|
|
@@ -628,6 +907,16 @@ export declare const CompiledRulesFileSchema: z.ZodObject<{
|
|
|
628
907
|
manual?: boolean | undefined;
|
|
629
908
|
immutable?: boolean | undefined;
|
|
630
909
|
unverified?: boolean | undefined;
|
|
910
|
+
legitimacy?: {
|
|
911
|
+
provenance: {
|
|
912
|
+
mergedPr: number;
|
|
913
|
+
reviewThread: string;
|
|
914
|
+
commitSha: string;
|
|
915
|
+
};
|
|
916
|
+
positiveControl: boolean;
|
|
917
|
+
negativeControl: boolean;
|
|
918
|
+
} | undefined;
|
|
919
|
+
ruleClass?: "hard" | "advisory" | undefined;
|
|
631
920
|
}>, {
|
|
632
921
|
message: string;
|
|
633
922
|
lessonHash: string;
|
|
@@ -653,6 +942,16 @@ export declare const CompiledRulesFileSchema: z.ZodObject<{
|
|
|
653
942
|
manual?: boolean | undefined;
|
|
654
943
|
immutable?: boolean | undefined;
|
|
655
944
|
unverified?: boolean | undefined;
|
|
945
|
+
legitimacy?: {
|
|
946
|
+
provenance: {
|
|
947
|
+
mergedPr: number;
|
|
948
|
+
reviewThread: string;
|
|
949
|
+
commitSha: string;
|
|
950
|
+
};
|
|
951
|
+
positiveControl: boolean;
|
|
952
|
+
negativeControl: boolean;
|
|
953
|
+
} | undefined;
|
|
954
|
+
ruleClass?: "hard" | "advisory" | undefined;
|
|
656
955
|
}, {
|
|
657
956
|
message: string;
|
|
658
957
|
lessonHash: string;
|
|
@@ -678,6 +977,16 @@ export declare const CompiledRulesFileSchema: z.ZodObject<{
|
|
|
678
977
|
manual?: boolean | undefined;
|
|
679
978
|
immutable?: boolean | undefined;
|
|
680
979
|
unverified?: boolean | undefined;
|
|
980
|
+
legitimacy?: {
|
|
981
|
+
provenance: {
|
|
982
|
+
mergedPr: number;
|
|
983
|
+
reviewThread: string;
|
|
984
|
+
commitSha: string;
|
|
985
|
+
};
|
|
986
|
+
positiveControl: boolean;
|
|
987
|
+
negativeControl: boolean;
|
|
988
|
+
} | undefined;
|
|
989
|
+
ruleClass?: "hard" | "advisory" | undefined;
|
|
681
990
|
}>, "many">;
|
|
682
991
|
/**
|
|
683
992
|
* Lessons that could not be compiled into a rule. 4-tuple shape since
|
|
@@ -753,6 +1062,16 @@ export declare const CompiledRulesFileSchema: z.ZodObject<{
|
|
|
753
1062
|
manual?: boolean | undefined;
|
|
754
1063
|
immutable?: boolean | undefined;
|
|
755
1064
|
unverified?: boolean | undefined;
|
|
1065
|
+
legitimacy?: {
|
|
1066
|
+
provenance: {
|
|
1067
|
+
mergedPr: number;
|
|
1068
|
+
reviewThread: string;
|
|
1069
|
+
commitSha: string;
|
|
1070
|
+
};
|
|
1071
|
+
positiveControl: boolean;
|
|
1072
|
+
negativeControl: boolean;
|
|
1073
|
+
} | undefined;
|
|
1074
|
+
ruleClass?: "hard" | "advisory" | undefined;
|
|
756
1075
|
}[];
|
|
757
1076
|
nonCompilable?: {
|
|
758
1077
|
hash: string;
|
|
@@ -787,6 +1106,16 @@ export declare const CompiledRulesFileSchema: z.ZodObject<{
|
|
|
787
1106
|
manual?: boolean | undefined;
|
|
788
1107
|
immutable?: boolean | undefined;
|
|
789
1108
|
unverified?: boolean | undefined;
|
|
1109
|
+
legitimacy?: {
|
|
1110
|
+
provenance: {
|
|
1111
|
+
mergedPr: number;
|
|
1112
|
+
reviewThread: string;
|
|
1113
|
+
commitSha: string;
|
|
1114
|
+
};
|
|
1115
|
+
positiveControl: boolean;
|
|
1116
|
+
negativeControl: boolean;
|
|
1117
|
+
} | undefined;
|
|
1118
|
+
ruleClass?: "hard" | "advisory" | undefined;
|
|
790
1119
|
}[];
|
|
791
1120
|
nonCompilable?: (string | {
|
|
792
1121
|
hash: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"compiler-schema.d.ts","sourceRoot":"","sources":["../src/compiler-schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,gBAAgB;;;;;;gCAIb,CAAC;AAEjB,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAE1D;;;;;GAKG;AACH,eAAO,MAAM,qBAAqB;;;;;;gCAAmB,CAAC;AAEtD,MAAM,MAAM,eAAe,GAAG,UAAU,CAAC;
|
|
1
|
+
{"version":3,"file":"compiler-schema.d.ts","sourceRoot":"","sources":["../src/compiler-schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,gBAAgB;;;;;;gCAIb,CAAC;AAEjB,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAE1D;;;;;GAKG;AACH,eAAO,MAAM,qB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b,gCAAgC;IAChC,IAAI,EAAE,MAAM,CAAC;IACb,6DAA6D;IAC7D,UAAU,EAAE,MAAM,CAAC;CACpB;AAID,oEAAoE;AACpE,MAAM,MAAM,UAAU,GAAG,MAAM,GAAG,QAAQ,GAAG,SAAS,GAAG,OAAO,CAAC;AAEjE,MAAM,WAAW,YAAY;IAC3B,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,UAAU,EAAE,MAAM,CAAC;IACnB,8FAA8F;IAC9F,aAAa,EAAE,MAAM,GAAG,IAAI,CAAC;IAC7B,+FAA+F;IAC/F,UAAU,CAAC,EAAE,UAAU,CAAC;CACzB;AAID,MAAM,WAAW,eAAe;IAC9B,KAAK,EAAE,OAAO,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,wEAAwE;AACxE,MAAM,WAAW,gBAAgB;IAC/B,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,uEAAuE;IACvE,UAAU,CAAC,EAAE,UAAU,CAAC;IACxB;;;;;;OAMG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB;;;;;OAKG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB;AAED;;;;;;;;GAQG;AACH,MAAM,MAAM,iBAAiB,GAAG,CAC9B,KAAK,EAAE,SAAS,GAAG,UAAU,GAAG,SAAS,EACzC,UAAU,EAAE,MAAM,EAClB,OAAO,CAAC,EAAE,gBAAgB,KACvB,IAAI,CAAC"}
|
package/dist/compiler-schema.js
CHANGED
|
@@ -27,6 +27,59 @@ export const NapiConfigSchema = z
|
|
|
27
27
|
* right definition without first knowing it's a napi config.
|
|
28
28
|
*/
|
|
29
29
|
export const AstGrepYamlRuleSchema = NapiConfigSchema;
|
|
30
|
+
// ─── Legitimacy marker (mmnto-ai/totem#2183) ────────
|
|
31
|
+
/**
|
|
32
|
+
* Full 40-hex git commit SHA, lowercase. (Git content hashes elsewhere are
|
|
33
|
+
* 64-hex sha-256; a commit SHA is sha-1.) Lowercase-only is deliberate, not an
|
|
34
|
+
* oversight (GCA #2186): git emits canonical lowercase SHA-1, and the sole
|
|
35
|
+
* writer of `commitSha` is spine regeneration (strategy#516) deriving from git,
|
|
36
|
+
* so the canonical form is always lowercase. We validate that canonical form
|
|
37
|
+
* rather than accepting uppercase (`/i`) — admitting a non-canonical SHA would
|
|
38
|
+
* be a silent data-quality hole, and lower-casing it on parse would reintroduce
|
|
39
|
+
* the very transform/hash-stability hazard flagged for `reviewThread` below.
|
|
40
|
+
*/
|
|
41
|
+
const COMMIT_SHA_RE = /^[0-9a-f]{40}$/;
|
|
42
|
+
/**
|
|
43
|
+
* mmnto-ai/totem#2183 — the §3.1 provenance leg of the ADR-110 Gate-1
|
|
44
|
+
* legitimacy bar: the identity of the merged-PR history a regenerated rule was
|
|
45
|
+
* mined from. Structured and **mechanically validated** (NOT a bare string) so
|
|
46
|
+
* a placeholder cannot masquerade as provenance. Promotion state is NOT carried
|
|
47
|
+
* here — it lives on the owning rule's top-level `unverified` flag (ADR-089
|
|
48
|
+
* zero-trust), the single source of truth `deriveRuleClass` reads. Control
|
|
49
|
+
* *evidence* (which PRs/fixtures proved each control) rides the wind-tunnel
|
|
50
|
+
* manifest (ADR-110 §6), not the per-rule marker.
|
|
51
|
+
*/
|
|
52
|
+
export const ProvenanceRecordSchema = z.object({
|
|
53
|
+
/** Merged PR the rule was mined from (positive integer PR number). */
|
|
54
|
+
mergedPr: z.number().int().positive(),
|
|
55
|
+
/**
|
|
56
|
+
* Reference to the review thread that adjudicated the rule. Rejects empty and
|
|
57
|
+
* whitespace-only via a NON-MUTATING refinement (greptile/CR #2186): a
|
|
58
|
+
* `.trim()` transform would silently normalize a padded value on parse, so a
|
|
59
|
+
* stamped rule's on-disk JSON could differ from its parsed form and churn the
|
|
60
|
+
* manifest hash on the next `verify-manifest`. `.refine` validates without
|
|
61
|
+
* mutating, so the stored value round-trips byte-identically.
|
|
62
|
+
*/
|
|
63
|
+
reviewThread: z.string().refine((s) => s.trim().length > 0, {
|
|
64
|
+
message: 'reviewThread must be a non-empty, non-whitespace reference',
|
|
65
|
+
}),
|
|
66
|
+
/** Full 40-hex git commit SHA the rule was frozen at. */
|
|
67
|
+
commitSha: z.string().regex(COMMIT_SHA_RE),
|
|
68
|
+
});
|
|
69
|
+
/**
|
|
70
|
+
* mmnto-ai/totem#2183 — the three **peer** legs of the ADR-110 §3 legitimacy
|
|
71
|
+
* bar, mapping 1:1 onto the strategy#666 Tenet-9 three-check so the Gate-1
|
|
72
|
+
* wind-tunnel reads per-rule eligibility off the marker with no translation
|
|
73
|
+
* layer: `provenance` (§3.1) / `positiveControl` (§3.2) / `negativeControl`
|
|
74
|
+
* (§3.3). Controls are pass/fail booleans, **required** when `legitimacy` is
|
|
75
|
+
* present (never defaulted, so an absent control can't silently read as a
|
|
76
|
+
* failed one); the evidence behind each pass lives in the wind-tunnel manifest.
|
|
77
|
+
*/
|
|
78
|
+
export const LegitimacySchema = z.object({
|
|
79
|
+
provenance: ProvenanceRecordSchema,
|
|
80
|
+
positiveControl: z.boolean(),
|
|
81
|
+
negativeControl: z.boolean(),
|
|
82
|
+
});
|
|
30
83
|
// ─── Compiled rule schemas ──────────────────────────
|
|
31
84
|
const CompiledRuleBaseSchema = z.object({
|
|
32
85
|
/** SHA-256 hash (first 16 hex chars) of heading + body — detects edits */
|
|
@@ -183,6 +236,26 @@ const CompiledRuleBaseSchema = z.object({
|
|
|
183
236
|
* produce identical output.
|
|
184
237
|
*/
|
|
185
238
|
unverified: z.boolean().optional(),
|
|
239
|
+
/**
|
|
240
|
+
* mmnto-ai/totem#2183 — the ADR-110 §3 legitimacy bar (three peer legs). Set
|
|
241
|
+
* by spine rule-regeneration (strategy#516); **absent on every legacy rule.**
|
|
242
|
+
* When present, `ruleClass` MUST also be present and equal to
|
|
243
|
+
* `deriveRuleClass(rule)` — enforced by the superRefine on
|
|
244
|
+
* `CompiledRuleSchema`. Never written with defaults: absence is the legacy
|
|
245
|
+
* signal and preserves pre-#2183 manifest hashes via canonicalStringify.
|
|
246
|
+
*/
|
|
247
|
+
legitimacy: LegitimacySchema.optional(),
|
|
248
|
+
/**
|
|
249
|
+
* mmnto-ai/totem#2183 — the first-class, **derived** enforcement-tier marker
|
|
250
|
+
* that retires the engine-type proxy (#2181). `'hard'` blocks (subject to the
|
|
251
|
+
* unchanged severity gate — error blocks, warning does not); `'advisory'` is
|
|
252
|
+
* printed, non-blocking. Derived from `legitimacy` at mint via
|
|
253
|
+
* `deriveRuleClass`; the reader TRUSTS this frozen stamp and never re-derives
|
|
254
|
+
* at lint-time (ADR-110 §1 mint+validate boundary; Tenet-15
|
|
255
|
+
* verifiable-freezing). Present **iff** `legitimacy` is present; absent ⇒ the
|
|
256
|
+
* reader falls back to the legacy engine-type proxy.
|
|
257
|
+
*/
|
|
258
|
+
ruleClass: z.enum(['hard', 'advisory']).optional(),
|
|
186
259
|
});
|
|
187
260
|
/**
|
|
188
261
|
* Shared mutual-exclusion check between the flat `astGrepPattern` string
|
|
@@ -212,7 +285,69 @@ function refineAstGrepMutualExclusion(data, ctx) {
|
|
|
212
285
|
});
|
|
213
286
|
}
|
|
214
287
|
}
|
|
215
|
-
|
|
288
|
+
/**
|
|
289
|
+
* mmnto-ai/totem#2183 — derive the enforcement tier from the ADR-110 §3
|
|
290
|
+
* legitimacy bar. Pure + deterministic (Tenet 9). A rule is `'hard'` ONLY when
|
|
291
|
+
* all three legs hold AND the rule is promoted: `legitimacy` present, the
|
|
292
|
+
* owning rule's ADR-089 `unverified` flag is not `true`, and both controls
|
|
293
|
+
* passed. Anything else — no legitimacy, unpromoted, or a failed control — is
|
|
294
|
+
* `'advisory'`. Promotion reads the rule's TOP-LEVEL `unverified` (the single
|
|
295
|
+
* source of truth; #1485 / #1479 already read it), never a nested copy.
|
|
296
|
+
*
|
|
297
|
+
* **Unwired** from `buildCompiledRule` in this slice: the rule-compilation
|
|
298
|
+
* freeze stands, so the sanctioned writer is spine regeneration (strategy#516),
|
|
299
|
+
* which owns the wiring. Exposed as a pure helper for that regenerator and for
|
|
300
|
+
* the consistency superRefine below.
|
|
301
|
+
*/
|
|
302
|
+
export function deriveRuleClass(rule) {
|
|
303
|
+
const leg = rule.legitimacy;
|
|
304
|
+
if (!leg)
|
|
305
|
+
return 'advisory';
|
|
306
|
+
if (rule.unverified === true)
|
|
307
|
+
return 'advisory';
|
|
308
|
+
if (!leg.positiveControl || !leg.negativeControl)
|
|
309
|
+
return 'advisory';
|
|
310
|
+
return 'hard';
|
|
311
|
+
}
|
|
312
|
+
/**
|
|
313
|
+
* mmnto-ai/totem#2183 — the Gate-1 guardrail, enforced structurally at the
|
|
314
|
+
* runtime-parse boundary (ADR-110 §1; codex contract-lens). `legitimacy` and
|
|
315
|
+
* `ruleClass` are present together or absent together, and when present
|
|
316
|
+
* `ruleClass` must equal `deriveRuleClass(rule)`:
|
|
317
|
+
* - `ruleClass` without `legitimacy` (a forged hard stamp) → parse-fail.
|
|
318
|
+
* - `legitimacy` without `ruleClass` (a minted rule missing its marker) → parse-fail.
|
|
319
|
+
* - `ruleClass !== deriveRuleClass(rule)` (inconsistent marker) → parse-fail.
|
|
320
|
+
* - both absent (a legacy rule) → valid; the reader uses the engine proxy.
|
|
321
|
+
* Because this fires inside `CompiledRuleSchema` (which `loadCompiledRules`
|
|
322
|
+
* parses), `run-compiled-rules.ts` can never observe a forged stamped state —
|
|
323
|
+
* the engine-type proxy is reachable only by un-stamped legacy rules.
|
|
324
|
+
*/
|
|
325
|
+
function refineLegitimacyRuleClassConsistency(data, ctx) {
|
|
326
|
+
const hasLegitimacy = data.legitimacy !== undefined;
|
|
327
|
+
const hasRuleClass = data.ruleClass !== undefined;
|
|
328
|
+
if (hasLegitimacy !== hasRuleClass) {
|
|
329
|
+
ctx.addIssue({
|
|
330
|
+
code: z.ZodIssueCode.custom,
|
|
331
|
+
message: 'legitimacy and ruleClass must be both present or both absent (mmnto-ai/totem#2183)',
|
|
332
|
+
path: [hasRuleClass ? 'legitimacy' : 'ruleClass'],
|
|
333
|
+
});
|
|
334
|
+
return;
|
|
335
|
+
}
|
|
336
|
+
if (hasLegitimacy && hasRuleClass) {
|
|
337
|
+
const expected = deriveRuleClass(data);
|
|
338
|
+
if (data.ruleClass !== expected) {
|
|
339
|
+
ctx.addIssue({
|
|
340
|
+
code: z.ZodIssueCode.custom,
|
|
341
|
+
message: `ruleClass '${data.ruleClass}' is inconsistent with the derived class '${expected}' (mmnto-ai/totem#2183)`,
|
|
342
|
+
path: ['ruleClass'],
|
|
343
|
+
});
|
|
344
|
+
}
|
|
345
|
+
}
|
|
346
|
+
}
|
|
347
|
+
export const CompiledRuleSchema = CompiledRuleBaseSchema.superRefine((data, ctx) => {
|
|
348
|
+
refineAstGrepMutualExclusion(data, ctx);
|
|
349
|
+
refineLegitimacyRuleClassConsistency(data, ctx);
|
|
350
|
+
});
|
|
216
351
|
/**
|
|
217
352
|
* Machine-readable reason for why a lesson could not be compiled into a rule.
|
|
218
353
|
* mmnto-ai/totem#1481 upgraded the `nonCompilable` ledger from opaque 2-tuples
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"compiler-schema.js","sourceRoot":"","sources":["../src/compiler-schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,uDAAuD;AAEvD;;;;;;;;;;;;;;GAcG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAAC;KAC9B,MAAM,CAAC;IACN,IAAI,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,OAAO,EAAE,CAAC;CAC5B,CAAC;KACD,WAAW,EAAE,CAAC;AAIjB;;;;;GAKG;AACH,MAAM,CAAC,MAAM,qBAAqB,GAAG,gBAAgB,CAAC;AAItD,uDAAuD;AAEvD,MAAM,sBAAsB,GAAG,CAAC,CAAC,MAAM,CAAC;IACtC,0EAA0E;IAC1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