@neat.is/types 0.10.6-dev.20261008 → 0.10.6-dev.20261010
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/index.cjs +54 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1100 -11
- package/dist/index.d.ts +1100 -11
- package/dist/index.js +50 -2
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -902,12 +902,54 @@ var IncidentBlastRadiusSchema = z6.object({
|
|
|
902
902
|
var IncidentPolicySchema = z6.object({
|
|
903
903
|
policyName: z6.string(),
|
|
904
904
|
severity: z6.string(),
|
|
905
|
-
message: z6.string().optional()
|
|
905
|
+
message: z6.string().optional(),
|
|
906
|
+
// What the policy does when violated, as the policy overlay already resolves it
|
|
907
|
+
// (explicit onViolation, else the severity default, ADR-044). The grade's
|
|
908
|
+
// policy gate reads it.
|
|
909
|
+
onViolation: z6.enum(["log", "alert", "block"]).optional()
|
|
906
910
|
});
|
|
907
911
|
var IncidentDivergenceSchema = z6.object({
|
|
908
912
|
type: z6.string(),
|
|
909
913
|
summary: z6.string()
|
|
910
914
|
});
|
|
915
|
+
var GradeEvidenceSchema = z6.array(z6.string());
|
|
916
|
+
var IncidentGradeGateSchema = z6.object({
|
|
917
|
+
passed: z6.boolean(),
|
|
918
|
+
evidence: GradeEvidenceSchema
|
|
919
|
+
});
|
|
920
|
+
var IncidentGradeFactorSchema = z6.object({
|
|
921
|
+
value: z6.number().min(0).max(1).nullable(),
|
|
922
|
+
weight: z6.number().positive(),
|
|
923
|
+
// The card fields the value was computed from.
|
|
924
|
+
evidence: GradeEvidenceSchema,
|
|
925
|
+
// Why the value is null, or what it rests on when that isn't obvious.
|
|
926
|
+
reason: z6.string().optional()
|
|
927
|
+
});
|
|
928
|
+
var IncidentGradeBandSchema = z6.enum(["full", "diagnose-only", "out"]);
|
|
929
|
+
var IncidentGradeSchema = z6.object({
|
|
930
|
+
G: z6.number().min(0).max(1),
|
|
931
|
+
gamma: z6.union([z6.literal(0), z6.literal(1)]),
|
|
932
|
+
gates: z6.object({
|
|
933
|
+
policyNotBlock: IncidentGradeGateSchema,
|
|
934
|
+
notSymptomOnly: IncidentGradeGateSchema,
|
|
935
|
+
locusResolves: IncidentGradeGateSchema
|
|
936
|
+
}),
|
|
937
|
+
C: z6.number().min(0).max(1),
|
|
938
|
+
factors: z6.object({
|
|
939
|
+
evidence: IncidentGradeFactorSchema,
|
|
940
|
+
locus: IncidentGradeFactorSchema,
|
|
941
|
+
tests: IncidentGradeFactorSchema,
|
|
942
|
+
reach: IncidentGradeFactorSchema,
|
|
943
|
+
kind: IncidentGradeFactorSchema,
|
|
944
|
+
chain: IncidentGradeFactorSchema,
|
|
945
|
+
recur: IncidentGradeFactorSchema,
|
|
946
|
+
div: IncidentGradeFactorSchema
|
|
947
|
+
}),
|
|
948
|
+
band: IncidentGradeBandSchema,
|
|
949
|
+
// Orders incidents within a band; never raises or lowers a grade.
|
|
950
|
+
urgency: z6.object({ value: z6.number().min(0).max(1).nullable(), reason: z6.string().optional() }),
|
|
951
|
+
priorsVersion: z6.string()
|
|
952
|
+
});
|
|
911
953
|
var IncidentCardSchema = z6.object({
|
|
912
954
|
kind: z6.literal("incident"),
|
|
913
955
|
id: z6.string(),
|
|
@@ -931,7 +973,9 @@ var IncidentCardSchema = z6.object({
|
|
|
931
973
|
divergence: z6.array(IncidentDivergenceSchema).optional(),
|
|
932
974
|
// The rendered one-line sentence — a human/loose-LLM read over the structured
|
|
933
975
|
// body, never the wire format.
|
|
934
|
-
headline: z6.string()
|
|
976
|
+
headline: z6.string(),
|
|
977
|
+
// Derived from the fields above (ADR-238). Optional so older cards still parse.
|
|
978
|
+
grade: IncidentGradeSchema.optional()
|
|
935
979
|
});
|
|
936
980
|
var IncidentEventPayloadSchema = z6.object({
|
|
937
981
|
incidentId: z6.string(),
|
|
@@ -1811,6 +1855,10 @@ export {
|
|
|
1811
1855
|
IncidentChainHopSchema,
|
|
1812
1856
|
IncidentDivergenceSchema,
|
|
1813
1857
|
IncidentEventPayloadSchema,
|
|
1858
|
+
IncidentGradeBandSchema,
|
|
1859
|
+
IncidentGradeFactorSchema,
|
|
1860
|
+
IncidentGradeGateSchema,
|
|
1861
|
+
IncidentGradeSchema,
|
|
1814
1862
|
IncidentKindSchema,
|
|
1815
1863
|
IncidentLocusSchema,
|
|
1816
1864
|
IncidentPolicySchema,
|