@qulib/core 0.10.0 → 0.11.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/README.md +2 -0
- package/dist/baseline/baseline.schema.d.ts +26 -26
- package/dist/baseline/baseline.schema.d.ts.map +1 -1
- package/dist/baseline/baseline.schema.js +1 -0
- package/dist/cli/confidence-run.js +5 -5
- package/dist/index.d.ts +6 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -0
- package/dist/llm/provider.interface.d.ts +4 -1
- package/dist/llm/provider.interface.d.ts.map +1 -1
- package/dist/llm/providers/anthropic.d.ts +2 -2
- package/dist/llm/providers/anthropic.d.ts.map +1 -1
- package/dist/llm/providers/anthropic.js +2 -1
- package/dist/phases/think.d.ts.map +1 -1
- package/dist/phases/think.js +4 -1
- package/dist/reporters/heatmap.d.ts +1 -1
- package/dist/reporters/heatmap.d.ts.map +1 -1
- package/dist/reporters/heatmap.js +2 -0
- package/dist/schemas/bug-report-score.schema.d.ts +163 -0
- package/dist/schemas/bug-report-score.schema.d.ts.map +1 -0
- package/dist/schemas/bug-report-score.schema.js +32 -0
- package/dist/schemas/confidence.schema.d.ts +35 -35
- package/dist/schemas/confidence.schema.d.ts.map +1 -1
- package/dist/schemas/confidence.schema.js +1 -0
- package/dist/schemas/decision-score.schema.d.ts +157 -0
- package/dist/schemas/decision-score.schema.d.ts.map +1 -0
- package/dist/schemas/decision-score.schema.js +39 -0
- package/dist/schemas/gap-analysis.schema.d.ts +8 -8
- package/dist/schemas/gap-analysis.schema.js +1 -1
- package/dist/schemas/golden-manifest.schema.d.ts +137 -0
- package/dist/schemas/golden-manifest.schema.d.ts.map +1 -0
- package/dist/schemas/golden-manifest.schema.js +25 -0
- package/dist/schemas/index.d.ts +3 -0
- package/dist/schemas/index.d.ts.map +1 -1
- package/dist/schemas/index.js +3 -0
- package/dist/schemas/public-surface.schema.d.ts +15 -5
- package/dist/schemas/public-surface.schema.d.ts.map +1 -1
- package/dist/schemas/route-inventory.schema.d.ts +20 -0
- package/dist/schemas/route-inventory.schema.d.ts.map +1 -1
- package/dist/schemas/route-inventory.schema.js +4 -0
- package/dist/schemas/views.schema.d.ts +12 -12
- package/dist/tools/scoring/bug-report-score.d.ts +34 -0
- package/dist/tools/scoring/bug-report-score.d.ts.map +1 -0
- package/dist/tools/scoring/bug-report-score.js +320 -0
- package/dist/tools/scoring/confidence.d.ts.map +1 -1
- package/dist/tools/scoring/confidence.js +140 -14
- package/dist/tools/scoring/prompt-leakage.d.ts +29 -0
- package/dist/tools/scoring/prompt-leakage.d.ts.map +1 -0
- package/dist/tools/scoring/prompt-leakage.js +256 -0
- package/dist/tools/scoring/score-decisions.d.ts +30 -0
- package/dist/tools/scoring/score-decisions.d.ts.map +1 -0
- package/dist/tools/scoring/score-decisions.js +348 -0
- package/package.json +2 -2
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
/** Partial ground-truth for auth detection — only fields stated with confidence. */
|
|
3
|
+
export declare const GoldenSiteExpectedSchema: z.ZodObject<{
|
|
4
|
+
hasAuth: z.ZodOptional<z.ZodBoolean>;
|
|
5
|
+
type: z.ZodOptional<z.ZodEnum<["none", "form-login", "oauth", "magic-link", "unknown"]>>;
|
|
6
|
+
leaksPrompt: z.ZodOptional<z.ZodBoolean>;
|
|
7
|
+
}, "strict", z.ZodTypeAny, {
|
|
8
|
+
type?: "unknown" | "form-login" | "oauth" | "magic-link" | "none" | undefined;
|
|
9
|
+
hasAuth?: boolean | undefined;
|
|
10
|
+
leaksPrompt?: boolean | undefined;
|
|
11
|
+
}, {
|
|
12
|
+
type?: "unknown" | "form-login" | "oauth" | "magic-link" | "none" | undefined;
|
|
13
|
+
hasAuth?: boolean | undefined;
|
|
14
|
+
leaksPrompt?: boolean | undefined;
|
|
15
|
+
}>;
|
|
16
|
+
export declare const GoldenSiteSchema: z.ZodObject<{
|
|
17
|
+
id: z.ZodString;
|
|
18
|
+
url: z.ZodString;
|
|
19
|
+
name: z.ZodString;
|
|
20
|
+
rationale: z.ZodOptional<z.ZodString>;
|
|
21
|
+
coverage_tags: z.ZodArray<z.ZodString, "many">;
|
|
22
|
+
expected: z.ZodObject<{
|
|
23
|
+
hasAuth: z.ZodOptional<z.ZodBoolean>;
|
|
24
|
+
type: z.ZodOptional<z.ZodEnum<["none", "form-login", "oauth", "magic-link", "unknown"]>>;
|
|
25
|
+
leaksPrompt: z.ZodOptional<z.ZodBoolean>;
|
|
26
|
+
}, "strict", z.ZodTypeAny, {
|
|
27
|
+
type?: "unknown" | "form-login" | "oauth" | "magic-link" | "none" | undefined;
|
|
28
|
+
hasAuth?: boolean | undefined;
|
|
29
|
+
leaksPrompt?: boolean | undefined;
|
|
30
|
+
}, {
|
|
31
|
+
type?: "unknown" | "form-login" | "oauth" | "magic-link" | "none" | undefined;
|
|
32
|
+
hasAuth?: boolean | undefined;
|
|
33
|
+
leaksPrompt?: boolean | undefined;
|
|
34
|
+
}>;
|
|
35
|
+
}, "strip", z.ZodTypeAny, {
|
|
36
|
+
expected: {
|
|
37
|
+
type?: "unknown" | "form-login" | "oauth" | "magic-link" | "none" | undefined;
|
|
38
|
+
hasAuth?: boolean | undefined;
|
|
39
|
+
leaksPrompt?: boolean | undefined;
|
|
40
|
+
};
|
|
41
|
+
name: string;
|
|
42
|
+
id: string;
|
|
43
|
+
url: string;
|
|
44
|
+
coverage_tags: string[];
|
|
45
|
+
rationale?: string | undefined;
|
|
46
|
+
}, {
|
|
47
|
+
expected: {
|
|
48
|
+
type?: "unknown" | "form-login" | "oauth" | "magic-link" | "none" | undefined;
|
|
49
|
+
hasAuth?: boolean | undefined;
|
|
50
|
+
leaksPrompt?: boolean | undefined;
|
|
51
|
+
};
|
|
52
|
+
name: string;
|
|
53
|
+
id: string;
|
|
54
|
+
url: string;
|
|
55
|
+
coverage_tags: string[];
|
|
56
|
+
rationale?: string | undefined;
|
|
57
|
+
}>;
|
|
58
|
+
export declare const GoldenManifestSchema: z.ZodObject<{
|
|
59
|
+
schemaVersion: z.ZodLiteral<1>;
|
|
60
|
+
coverage_tags: z.ZodArray<z.ZodString, "many">;
|
|
61
|
+
sites: z.ZodArray<z.ZodObject<{
|
|
62
|
+
id: z.ZodString;
|
|
63
|
+
url: z.ZodString;
|
|
64
|
+
name: z.ZodString;
|
|
65
|
+
rationale: z.ZodOptional<z.ZodString>;
|
|
66
|
+
coverage_tags: z.ZodArray<z.ZodString, "many">;
|
|
67
|
+
expected: z.ZodObject<{
|
|
68
|
+
hasAuth: z.ZodOptional<z.ZodBoolean>;
|
|
69
|
+
type: z.ZodOptional<z.ZodEnum<["none", "form-login", "oauth", "magic-link", "unknown"]>>;
|
|
70
|
+
leaksPrompt: z.ZodOptional<z.ZodBoolean>;
|
|
71
|
+
}, "strict", z.ZodTypeAny, {
|
|
72
|
+
type?: "unknown" | "form-login" | "oauth" | "magic-link" | "none" | undefined;
|
|
73
|
+
hasAuth?: boolean | undefined;
|
|
74
|
+
leaksPrompt?: boolean | undefined;
|
|
75
|
+
}, {
|
|
76
|
+
type?: "unknown" | "form-login" | "oauth" | "magic-link" | "none" | undefined;
|
|
77
|
+
hasAuth?: boolean | undefined;
|
|
78
|
+
leaksPrompt?: boolean | undefined;
|
|
79
|
+
}>;
|
|
80
|
+
}, "strip", z.ZodTypeAny, {
|
|
81
|
+
expected: {
|
|
82
|
+
type?: "unknown" | "form-login" | "oauth" | "magic-link" | "none" | undefined;
|
|
83
|
+
hasAuth?: boolean | undefined;
|
|
84
|
+
leaksPrompt?: boolean | undefined;
|
|
85
|
+
};
|
|
86
|
+
name: string;
|
|
87
|
+
id: string;
|
|
88
|
+
url: string;
|
|
89
|
+
coverage_tags: string[];
|
|
90
|
+
rationale?: string | undefined;
|
|
91
|
+
}, {
|
|
92
|
+
expected: {
|
|
93
|
+
type?: "unknown" | "form-login" | "oauth" | "magic-link" | "none" | undefined;
|
|
94
|
+
hasAuth?: boolean | undefined;
|
|
95
|
+
leaksPrompt?: boolean | undefined;
|
|
96
|
+
};
|
|
97
|
+
name: string;
|
|
98
|
+
id: string;
|
|
99
|
+
url: string;
|
|
100
|
+
coverage_tags: string[];
|
|
101
|
+
rationale?: string | undefined;
|
|
102
|
+
}>, "many">;
|
|
103
|
+
}, "strip", z.ZodTypeAny, {
|
|
104
|
+
coverage_tags: string[];
|
|
105
|
+
schemaVersion: 1;
|
|
106
|
+
sites: {
|
|
107
|
+
expected: {
|
|
108
|
+
type?: "unknown" | "form-login" | "oauth" | "magic-link" | "none" | undefined;
|
|
109
|
+
hasAuth?: boolean | undefined;
|
|
110
|
+
leaksPrompt?: boolean | undefined;
|
|
111
|
+
};
|
|
112
|
+
name: string;
|
|
113
|
+
id: string;
|
|
114
|
+
url: string;
|
|
115
|
+
coverage_tags: string[];
|
|
116
|
+
rationale?: string | undefined;
|
|
117
|
+
}[];
|
|
118
|
+
}, {
|
|
119
|
+
coverage_tags: string[];
|
|
120
|
+
schemaVersion: 1;
|
|
121
|
+
sites: {
|
|
122
|
+
expected: {
|
|
123
|
+
type?: "unknown" | "form-login" | "oauth" | "magic-link" | "none" | undefined;
|
|
124
|
+
hasAuth?: boolean | undefined;
|
|
125
|
+
leaksPrompt?: boolean | undefined;
|
|
126
|
+
};
|
|
127
|
+
name: string;
|
|
128
|
+
id: string;
|
|
129
|
+
url: string;
|
|
130
|
+
coverage_tags: string[];
|
|
131
|
+
rationale?: string | undefined;
|
|
132
|
+
}[];
|
|
133
|
+
}>;
|
|
134
|
+
export type GoldenSiteExpected = z.infer<typeof GoldenSiteExpectedSchema>;
|
|
135
|
+
export type GoldenSite = z.infer<typeof GoldenSiteSchema>;
|
|
136
|
+
export type GoldenManifest = z.infer<typeof GoldenManifestSchema>;
|
|
137
|
+
//# sourceMappingURL=golden-manifest.schema.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"golden-manifest.schema.d.ts","sourceRoot":"","sources":["../../src/schemas/golden-manifest.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,oFAAoF;AACpF,eAAO,MAAM,wBAAwB;;;;;;;;;;;;EAM1B,CAAC;AAEZ,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAU3B,CAAC;AAEH,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAI/B,CAAC;AAEH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,CAAC;AAC1E,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAC1D,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
/** Partial ground-truth for auth detection — only fields stated with confidence. */
|
|
3
|
+
export const GoldenSiteExpectedSchema = z
|
|
4
|
+
.object({
|
|
5
|
+
hasAuth: z.boolean().optional(),
|
|
6
|
+
type: z.enum(['none', 'form-login', 'oauth', 'magic-link', 'unknown']).optional(),
|
|
7
|
+
leaksPrompt: z.boolean().optional(),
|
|
8
|
+
})
|
|
9
|
+
.strict();
|
|
10
|
+
export const GoldenSiteSchema = z.object({
|
|
11
|
+
id: z
|
|
12
|
+
.string()
|
|
13
|
+
.min(1)
|
|
14
|
+
.regex(/^[a-z0-9]+(?:-[a-z0-9]+)*$/, 'site id must be kebab-case'),
|
|
15
|
+
url: z.string().url(),
|
|
16
|
+
name: z.string().min(1),
|
|
17
|
+
rationale: z.string().min(1).optional(),
|
|
18
|
+
coverage_tags: z.array(z.string().min(1)).min(1),
|
|
19
|
+
expected: GoldenSiteExpectedSchema,
|
|
20
|
+
});
|
|
21
|
+
export const GoldenManifestSchema = z.object({
|
|
22
|
+
schemaVersion: z.literal(1),
|
|
23
|
+
coverage_tags: z.array(z.string().min(1)).min(1),
|
|
24
|
+
sites: z.array(GoldenSiteSchema),
|
|
25
|
+
});
|
package/dist/schemas/index.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
export { GoldenManifestSchema, GoldenSiteSchema, GoldenSiteExpectedSchema, type GoldenManifest, type GoldenSite, type GoldenSiteExpected, } from './golden-manifest.schema.js';
|
|
1
2
|
export { HarnessConfigSchema, resolveMaxOutputTokensPerLlmCall, AuthConfigSchema, DetectedAuthSchema, AuthPathRequirementsSchema, AuthPathSchema, AuthExplorationSchema, type ExplorerType, type AdapterType, type FormLoginAuthConfig, type StorageStateAuthConfig, type AuthConfig, type HarnessConfig, type DetectedAuth, type AuthPathRequirements, type AuthPath, type AuthExploration, } from './config.schema.js';
|
|
2
3
|
export { DecisionLogEntrySchema, type DecisionLogEntry, } from './decision-log.schema.js';
|
|
3
4
|
export { RouteInventorySchema, RouteSchema, A11yViolationSchema, BrokenLinkSchema, type RouteInventory, type Route, } from './route-inventory.schema.js';
|
|
@@ -8,5 +9,7 @@ export { AutomationMaturitySchema, AutomationMaturityDimensionSchema, Automation
|
|
|
8
9
|
export { PublicSurfaceSchema, PublicSurfaceViolationSchema, PublicSurfaceBrokenLinkSchema, type PublicSurface, type PublicSurfaceViolation, type PublicSurfaceBrokenLink, } from './public-surface.schema.js';
|
|
9
10
|
export { RecipeIdSchema, RecipeConfigSchema, type RecipeId, type RecipeConfig, } from './recipe.schema.js';
|
|
10
11
|
export { EvidenceSourceKindSchema, EvidenceItemSchema, ConfidenceSubjectSchema, ConfidenceInputSchema, ConfidencePolicySchema, ConfidenceVerdictSchema, ConfidenceContributionSchema, ReleaseConfidenceSchema, type EvidenceSourceKind, type EvidenceItem, type ConfidenceSubject, type ConfidenceInput, type ConfidencePolicy, type ConfidenceVerdict, type ConfidenceContribution, type ReleaseConfidence, } from './confidence.schema.js';
|
|
12
|
+
export { BugReportSeveritySchema, BugReportInputSchema, BugReportTargetSchema, ScoreBugReportInputSchema, BugReportRubricSchema, BugReportScoringPathSchema, BugReportScoreResultSchema, type BugReportSeverity, type BugReportInput, type BugReportTarget, type ScoreBugReportInput, type BugReportRubric, type BugReportScoringPath, type BugReportScoreResult, } from './bug-report-score.schema.js';
|
|
13
|
+
export { ForkKindSchema, DecisionForkSchema, ScoreDecisionsInputSchema, DecisionScoringPathSchema, ScoredDecisionForkSchema, DecisionScoreAggregateSchema, DecisionScoreResultSchema, type ForkKind, type DecisionFork, type ScoreDecisionsInput, type DecisionScoringPath, type ScoredDecisionFork, type DecisionScoreAggregate, type DecisionScoreResult, } from './decision-score.schema.js';
|
|
11
14
|
export { DeliveryTrafficPointSchema, InboxItemKindSchema, InboxItemSchema, ReplayStepSchema, ReplayTraceSchema, AuditEntrySchema, type DeliveryTrafficPoint, type InboxItemKind, type InboxItem, type ReplayStep, type ReplayTrace, type AuditEntry, } from './views.schema.js';
|
|
12
15
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/schemas/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,mBAAmB,EACnB,gCAAgC,EAChC,gBAAgB,EAChB,kBAAkB,EAClB,0BAA0B,EAC1B,cAAc,EACd,qBAAqB,EACrB,KAAK,YAAY,EACjB,KAAK,WAAW,EAChB,KAAK,mBAAmB,EACxB,KAAK,sBAAsB,EAC3B,KAAK,UAAU,EACf,KAAK,aAAa,EAClB,KAAK,YAAY,EACjB,KAAK,oBAAoB,EACzB,KAAK,QAAQ,EACb,KAAK,eAAe,GACrB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EACL,sBAAsB,EACtB,KAAK,gBAAgB,GACtB,MAAM,0BAA0B,CAAC;AAClC,OAAO,EACL,oBAAoB,EACpB,WAAW,EACX,mBAAmB,EACnB,gBAAgB,EAChB,KAAK,cAAc,EACnB,KAAK,KAAK,GACX,MAAM,6BAA6B,CAAC;AACrC,OAAO,EACL,iBAAiB,EACjB,SAAS,EACT,qBAAqB,EACrB,mBAAmB,EACnB,cAAc,EACd,6BAA6B,EAC7B,KAAK,WAAW,EAChB,KAAK,GAAG,EACR,KAAK,eAAe,EACpB,KAAK,aAAa,EAClB,KAAK,QAAQ,EACb,KAAK,uBAAuB,GAC7B,MAAM,0BAA0B,CAAC;AAClC,OAAO,EACL,sBAAsB,EACtB,oBAAoB,EACpB,oBAAoB,EACpB,sBAAsB,EACtB,uBAAuB,EACvB,2BAA2B,EAC3B,KAAK,gBAAgB,EACrB,KAAK,cAAc,EACnB,KAAK,cAAc,EACnB,KAAK,gBAAgB,EACrB,KAAK,iBAAiB,EACtB,KAAK,qBAAqB,GAC3B,MAAM,+BAA+B,CAAC;AACvC,OAAO,EACL,kBAAkB,EAClB,wBAAwB,EACxB,8BAA8B,EAC9B,kCAAkC,EAClC,2BAA2B,EAC3B,KAAK,YAAY,EACjB,KAAK,wBAAwB,EAC7B,KAAK,wBAAwB,GAC9B,MAAM,2BAA2B,CAAC;AACnC,OAAO,EACL,wBAAwB,EACxB,iCAAiC,EACjC,qCAAqC,EACrC,KAAK,kBAAkB,EACvB,KAAK,2BAA2B,EAChC,KAAK,+BAA+B,GACrC,MAAM,iCAAiC,CAAC;AACzC,OAAO,EACL,mBAAmB,EACnB,4BAA4B,EAC5B,6BAA6B,EAC7B,KAAK,aAAa,EAClB,KAAK,sBAAsB,EAC3B,KAAK,uBAAuB,GAC7B,MAAM,4BAA4B,CAAC;AACpC,OAAO,EACL,cAAc,EACd,kBAAkB,EAClB,KAAK,QAAQ,EACb,KAAK,YAAY,GAClB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EACL,wBAAwB,EACxB,kBAAkB,EAClB,uBAAuB,EACvB,qBAAqB,EACrB,sBAAsB,EACtB,uBAAuB,EACvB,4BAA4B,EAC5B,uBAAuB,EACvB,KAAK,kBAAkB,EACvB,KAAK,YAAY,EACjB,KAAK,iBAAiB,EACtB,KAAK,eAAe,EACpB,KAAK,gBAAgB,EACrB,KAAK,iBAAiB,EACtB,KAAK,sBAAsB,EAC3B,KAAK,iBAAiB,GACvB,MAAM,wBAAwB,CAAC;AAChC,OAAO,EACL,0BAA0B,EAC1B,mBAAmB,EACnB,eAAe,EACf,gBAAgB,EAChB,iBAAiB,EACjB,gBAAgB,EAChB,KAAK,oBAAoB,EACzB,KAAK,aAAa,EAClB,KAAK,SAAS,EACd,KAAK,UAAU,EACf,KAAK,WAAW,EAChB,KAAK,UAAU,GAChB,MAAM,mBAAmB,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/schemas/index.ts"],"names":[],"mappings":"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"}
|
package/dist/schemas/index.js
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
export { GoldenManifestSchema, GoldenSiteSchema, GoldenSiteExpectedSchema, } from './golden-manifest.schema.js';
|
|
1
2
|
export { HarnessConfigSchema, resolveMaxOutputTokensPerLlmCall, AuthConfigSchema, DetectedAuthSchema, AuthPathRequirementsSchema, AuthPathSchema, AuthExplorationSchema, } from './config.schema.js';
|
|
2
3
|
export { DecisionLogEntrySchema, } from './decision-log.schema.js';
|
|
3
4
|
export { RouteInventorySchema, RouteSchema, A11yViolationSchema, BrokenLinkSchema, } from './route-inventory.schema.js';
|
|
@@ -8,4 +9,6 @@ export { AutomationMaturitySchema, AutomationMaturityDimensionSchema, Automation
|
|
|
8
9
|
export { PublicSurfaceSchema, PublicSurfaceViolationSchema, PublicSurfaceBrokenLinkSchema, } from './public-surface.schema.js';
|
|
9
10
|
export { RecipeIdSchema, RecipeConfigSchema, } from './recipe.schema.js';
|
|
10
11
|
export { EvidenceSourceKindSchema, EvidenceItemSchema, ConfidenceSubjectSchema, ConfidenceInputSchema, ConfidencePolicySchema, ConfidenceVerdictSchema, ConfidenceContributionSchema, ReleaseConfidenceSchema, } from './confidence.schema.js';
|
|
12
|
+
export { BugReportSeveritySchema, BugReportInputSchema, BugReportTargetSchema, ScoreBugReportInputSchema, BugReportRubricSchema, BugReportScoringPathSchema, BugReportScoreResultSchema, } from './bug-report-score.schema.js';
|
|
13
|
+
export { ForkKindSchema, DecisionForkSchema, ScoreDecisionsInputSchema, DecisionScoringPathSchema, ScoredDecisionForkSchema, DecisionScoreAggregateSchema, DecisionScoreResultSchema, } from './decision-score.schema.js';
|
|
11
14
|
export { DeliveryTrafficPointSchema, InboxItemKindSchema, InboxItemSchema, ReplayStepSchema, ReplayTraceSchema, AuditEntrySchema, } from './views.schema.js';
|
|
@@ -74,6 +74,8 @@ export declare const PublicSurfaceSchema: z.ZodObject<{
|
|
|
74
74
|
nodeCount: number;
|
|
75
75
|
}>, "many">;
|
|
76
76
|
statusCode: z.ZodOptional<z.ZodNumber>;
|
|
77
|
+
headers: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
78
|
+
bodySnippet: z.ZodOptional<z.ZodString>;
|
|
77
79
|
}, "strip", z.ZodTypeAny, {
|
|
78
80
|
path: string;
|
|
79
81
|
pageTitle: string;
|
|
@@ -93,6 +95,8 @@ export declare const PublicSurfaceSchema: z.ZodObject<{
|
|
|
93
95
|
nodeCount: number;
|
|
94
96
|
}[];
|
|
95
97
|
statusCode?: number | undefined;
|
|
98
|
+
headers?: Record<string, string> | undefined;
|
|
99
|
+
bodySnippet?: string | undefined;
|
|
96
100
|
}, {
|
|
97
101
|
path: string;
|
|
98
102
|
pageTitle: string;
|
|
@@ -112,13 +116,15 @@ export declare const PublicSurfaceSchema: z.ZodObject<{
|
|
|
112
116
|
nodeCount: number;
|
|
113
117
|
}[];
|
|
114
118
|
statusCode?: number | undefined;
|
|
119
|
+
headers?: Record<string, string> | undefined;
|
|
120
|
+
bodySnippet?: string | undefined;
|
|
115
121
|
}>, "many">;
|
|
116
122
|
gaps: z.ZodArray<z.ZodObject<{
|
|
117
123
|
id: z.ZodString;
|
|
118
124
|
path: z.ZodString;
|
|
119
125
|
severity: z.ZodEnum<["critical", "high", "medium", "low"]>;
|
|
120
126
|
reason: z.ZodString;
|
|
121
|
-
category: z.ZodEnum<["untested-route", "a11y", "console-error", "broken-link", "auth-surface", "coverage", "untested-api-endpoint"]>;
|
|
127
|
+
category: z.ZodEnum<["untested-route", "a11y", "console-error", "broken-link", "auth-surface", "coverage", "untested-api-endpoint", "prompt-leakage"]>;
|
|
122
128
|
description: z.ZodOptional<z.ZodString>;
|
|
123
129
|
recommendation: z.ZodOptional<z.ZodString>;
|
|
124
130
|
}, "strip", z.ZodTypeAny, {
|
|
@@ -126,7 +132,7 @@ export declare const PublicSurfaceSchema: z.ZodObject<{
|
|
|
126
132
|
id: string;
|
|
127
133
|
severity: "critical" | "high" | "medium" | "low";
|
|
128
134
|
reason: string;
|
|
129
|
-
category: "untested-route" | "a11y" | "console-error" | "broken-link" | "auth-surface" | "coverage" | "untested-api-endpoint";
|
|
135
|
+
category: "untested-route" | "a11y" | "console-error" | "broken-link" | "auth-surface" | "coverage" | "untested-api-endpoint" | "prompt-leakage";
|
|
130
136
|
recommendation?: string | undefined;
|
|
131
137
|
description?: string | undefined;
|
|
132
138
|
}, {
|
|
@@ -134,7 +140,7 @@ export declare const PublicSurfaceSchema: z.ZodObject<{
|
|
|
134
140
|
id: string;
|
|
135
141
|
severity: "critical" | "high" | "medium" | "low";
|
|
136
142
|
reason: string;
|
|
137
|
-
category: "untested-route" | "a11y" | "console-error" | "broken-link" | "auth-surface" | "coverage" | "untested-api-endpoint";
|
|
143
|
+
category: "untested-route" | "a11y" | "console-error" | "broken-link" | "auth-surface" | "coverage" | "untested-api-endpoint" | "prompt-leakage";
|
|
138
144
|
recommendation?: string | undefined;
|
|
139
145
|
description?: string | undefined;
|
|
140
146
|
}>, "many">;
|
|
@@ -181,7 +187,7 @@ export declare const PublicSurfaceSchema: z.ZodObject<{
|
|
|
181
187
|
id: string;
|
|
182
188
|
severity: "critical" | "high" | "medium" | "low";
|
|
183
189
|
reason: string;
|
|
184
|
-
category: "untested-route" | "a11y" | "console-error" | "broken-link" | "auth-surface" | "coverage" | "untested-api-endpoint";
|
|
190
|
+
category: "untested-route" | "a11y" | "console-error" | "broken-link" | "auth-surface" | "coverage" | "untested-api-endpoint" | "prompt-leakage";
|
|
185
191
|
recommendation?: string | undefined;
|
|
186
192
|
description?: string | undefined;
|
|
187
193
|
}[];
|
|
@@ -210,6 +216,8 @@ export declare const PublicSurfaceSchema: z.ZodObject<{
|
|
|
210
216
|
nodeCount: number;
|
|
211
217
|
}[];
|
|
212
218
|
statusCode?: number | undefined;
|
|
219
|
+
headers?: Record<string, string> | undefined;
|
|
220
|
+
bodySnippet?: string | undefined;
|
|
213
221
|
}[];
|
|
214
222
|
accessibilityViolations: {
|
|
215
223
|
path: string;
|
|
@@ -224,7 +232,7 @@ export declare const PublicSurfaceSchema: z.ZodObject<{
|
|
|
224
232
|
id: string;
|
|
225
233
|
severity: "critical" | "high" | "medium" | "low";
|
|
226
234
|
reason: string;
|
|
227
|
-
category: "untested-route" | "a11y" | "console-error" | "broken-link" | "auth-surface" | "coverage" | "untested-api-endpoint";
|
|
235
|
+
category: "untested-route" | "a11y" | "console-error" | "broken-link" | "auth-surface" | "coverage" | "untested-api-endpoint" | "prompt-leakage";
|
|
228
236
|
recommendation?: string | undefined;
|
|
229
237
|
description?: string | undefined;
|
|
230
238
|
}[];
|
|
@@ -253,6 +261,8 @@ export declare const PublicSurfaceSchema: z.ZodObject<{
|
|
|
253
261
|
nodeCount: number;
|
|
254
262
|
}[];
|
|
255
263
|
statusCode?: number | undefined;
|
|
264
|
+
headers?: Record<string, string> | undefined;
|
|
265
|
+
bodySnippet?: string | undefined;
|
|
256
266
|
}[];
|
|
257
267
|
accessibilityViolations: {
|
|
258
268
|
path: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"public-surface.schema.d.ts","sourceRoot":"","sources":["../../src/schemas/public-surface.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;;;;;;;EAEvC,CAAC;AAEH,eAAO,MAAM,6BAA6B;;;;;;;;;;;;;;;;EAExC,CAAC;AAEH,eAAO,MAAM,mBAAmB
|
|
1
|
+
{"version":3,"file":"public-surface.schema.d.ts","sourceRoot":"","sources":["../../src/schemas/public-surface.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;;;;;;;EAEvC,CAAC;AAEH,eAAO,MAAM,6BAA6B;;;;;;;;;;;;;;;;EAExC,CAAC;AAEH,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAK9B,CAAC;AAEH,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAChE,MAAM,MAAM,sBAAsB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,4BAA4B,CAAC,CAAC;AAClF,MAAM,MAAM,uBAAuB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,6BAA6B,CAAC,CAAC"}
|
|
@@ -65,6 +65,10 @@ export declare const RouteSchema: z.ZodObject<{
|
|
|
65
65
|
nodeCount: number;
|
|
66
66
|
}>, "many">;
|
|
67
67
|
statusCode: z.ZodOptional<z.ZodNumber>;
|
|
68
|
+
/** Optional: response headers from the page fetch (populated by explorers that capture them). */
|
|
69
|
+
headers: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
70
|
+
/** Optional: first ~4000 chars of the raw HTML body (populated by explorers that capture it). */
|
|
71
|
+
bodySnippet: z.ZodOptional<z.ZodString>;
|
|
68
72
|
}, "strip", z.ZodTypeAny, {
|
|
69
73
|
path: string;
|
|
70
74
|
pageTitle: string;
|
|
@@ -84,6 +88,8 @@ export declare const RouteSchema: z.ZodObject<{
|
|
|
84
88
|
nodeCount: number;
|
|
85
89
|
}[];
|
|
86
90
|
statusCode?: number | undefined;
|
|
91
|
+
headers?: Record<string, string> | undefined;
|
|
92
|
+
bodySnippet?: string | undefined;
|
|
87
93
|
}, {
|
|
88
94
|
path: string;
|
|
89
95
|
pageTitle: string;
|
|
@@ -103,6 +109,8 @@ export declare const RouteSchema: z.ZodObject<{
|
|
|
103
109
|
nodeCount: number;
|
|
104
110
|
}[];
|
|
105
111
|
statusCode?: number | undefined;
|
|
112
|
+
headers?: Record<string, string> | undefined;
|
|
113
|
+
bodySnippet?: string | undefined;
|
|
106
114
|
}>;
|
|
107
115
|
export declare const RouteInventorySchema: z.ZodObject<{
|
|
108
116
|
scannedAt: z.ZodString;
|
|
@@ -144,6 +152,10 @@ export declare const RouteInventorySchema: z.ZodObject<{
|
|
|
144
152
|
nodeCount: number;
|
|
145
153
|
}>, "many">;
|
|
146
154
|
statusCode: z.ZodOptional<z.ZodNumber>;
|
|
155
|
+
/** Optional: response headers from the page fetch (populated by explorers that capture them). */
|
|
156
|
+
headers: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
157
|
+
/** Optional: first ~4000 chars of the raw HTML body (populated by explorers that capture it). */
|
|
158
|
+
bodySnippet: z.ZodOptional<z.ZodString>;
|
|
147
159
|
}, "strip", z.ZodTypeAny, {
|
|
148
160
|
path: string;
|
|
149
161
|
pageTitle: string;
|
|
@@ -163,6 +175,8 @@ export declare const RouteInventorySchema: z.ZodObject<{
|
|
|
163
175
|
nodeCount: number;
|
|
164
176
|
}[];
|
|
165
177
|
statusCode?: number | undefined;
|
|
178
|
+
headers?: Record<string, string> | undefined;
|
|
179
|
+
bodySnippet?: string | undefined;
|
|
166
180
|
}, {
|
|
167
181
|
path: string;
|
|
168
182
|
pageTitle: string;
|
|
@@ -182,6 +196,8 @@ export declare const RouteInventorySchema: z.ZodObject<{
|
|
|
182
196
|
nodeCount: number;
|
|
183
197
|
}[];
|
|
184
198
|
statusCode?: number | undefined;
|
|
199
|
+
headers?: Record<string, string> | undefined;
|
|
200
|
+
bodySnippet?: string | undefined;
|
|
185
201
|
}>, "many">;
|
|
186
202
|
pagesSkipped: z.ZodNumber;
|
|
187
203
|
budgetExceeded: z.ZodBoolean;
|
|
@@ -207,6 +223,8 @@ export declare const RouteInventorySchema: z.ZodObject<{
|
|
|
207
223
|
nodeCount: number;
|
|
208
224
|
}[];
|
|
209
225
|
statusCode?: number | undefined;
|
|
226
|
+
headers?: Record<string, string> | undefined;
|
|
227
|
+
bodySnippet?: string | undefined;
|
|
210
228
|
}[];
|
|
211
229
|
pagesSkipped: number;
|
|
212
230
|
budgetExceeded: boolean;
|
|
@@ -232,6 +250,8 @@ export declare const RouteInventorySchema: z.ZodObject<{
|
|
|
232
250
|
nodeCount: number;
|
|
233
251
|
}[];
|
|
234
252
|
statusCode?: number | undefined;
|
|
253
|
+
headers?: Record<string, string> | undefined;
|
|
254
|
+
bodySnippet?: string | undefined;
|
|
235
255
|
}[];
|
|
236
256
|
pagesSkipped: number;
|
|
237
257
|
budgetExceeded: boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"route-inventory.schema.d.ts","sourceRoot":"","sources":["../../src/schemas/route-inventory.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;EAK9B,CAAC;AAEH,eAAO,MAAM,gBAAgB;;;;;;;;;;;;EAI3B,CAAC;AAEH,eAAO,MAAM,WAAW
|
|
1
|
+
{"version":3,"file":"route-inventory.schema.d.ts","sourceRoot":"","sources":["../../src/schemas/route-inventory.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;EAK9B,CAAC;AAEH,eAAO,MAAM,gBAAgB;;;;;;;;;;;;EAI3B,CAAC;AAEH,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAUtB,iGAAiG;;IAEjG,iGAAiG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAEjG,CAAC;AAEH,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;QAN/B,iGAAiG;;QAEjG,iGAAiG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAUjG,CAAC;AAEH,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC;AAClE,MAAM,MAAM,KAAK,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,WAAW,CAAC,CAAC"}
|
|
@@ -20,6 +20,10 @@ export const RouteSchema = z.object({
|
|
|
20
20
|
brokenLinks: z.array(BrokenLinkSchema),
|
|
21
21
|
a11yViolations: z.array(A11yViolationSchema),
|
|
22
22
|
statusCode: z.number().int().optional(),
|
|
23
|
+
/** Optional: response headers from the page fetch (populated by explorers that capture them). */
|
|
24
|
+
headers: z.record(z.string(), z.string()).optional(),
|
|
25
|
+
/** Optional: first ~4000 chars of the raw HTML body (populated by explorers that capture it). */
|
|
26
|
+
bodySnippet: z.string().max(8000).optional(),
|
|
23
27
|
});
|
|
24
28
|
export const RouteInventorySchema = z.object({
|
|
25
29
|
scannedAt: z.string().datetime(),
|
|
@@ -44,13 +44,13 @@ export declare const InboxItemSchema: z.ZodObject<{
|
|
|
44
44
|
subjectRef: z.ZodString;
|
|
45
45
|
tenantId: z.ZodDefault<z.ZodString>;
|
|
46
46
|
kind: z.ZodEnum<["blocker", "unknown-signal", "approval-needed"]>;
|
|
47
|
-
source: z.ZodEnum<["live-app-quality", "accessibility", "crawl-coverage", "test-automation", "api-coverage", "ci-results", "deploy-metadata", "error-telemetry", "feature-flags", "doc-health", "human-approval", "agent-evidence"]>;
|
|
47
|
+
source: z.ZodEnum<["live-app-quality", "accessibility", "crawl-coverage", "test-automation", "api-coverage", "ci-results", "deploy-metadata", "error-telemetry", "feature-flags", "doc-health", "human-approval", "agent-evidence", "decision-quality"]>;
|
|
48
48
|
summary: z.ZodString;
|
|
49
49
|
raisedAt: z.ZodString;
|
|
50
50
|
resolvedAt: z.ZodOptional<z.ZodString>;
|
|
51
51
|
}, "strip", z.ZodTypeAny, {
|
|
52
52
|
id: string;
|
|
53
|
-
source: "accessibility" | "live-app-quality" | "crawl-coverage" | "test-automation" | "api-coverage" | "ci-results" | "deploy-metadata" | "error-telemetry" | "feature-flags" | "doc-health" | "human-approval" | "agent-evidence";
|
|
53
|
+
source: "accessibility" | "live-app-quality" | "crawl-coverage" | "test-automation" | "api-coverage" | "ci-results" | "deploy-metadata" | "error-telemetry" | "feature-flags" | "doc-health" | "human-approval" | "agent-evidence" | "decision-quality";
|
|
54
54
|
summary: string;
|
|
55
55
|
kind: "blocker" | "unknown-signal" | "approval-needed";
|
|
56
56
|
tenantId: string;
|
|
@@ -59,7 +59,7 @@ export declare const InboxItemSchema: z.ZodObject<{
|
|
|
59
59
|
resolvedAt?: string | undefined;
|
|
60
60
|
}, {
|
|
61
61
|
id: string;
|
|
62
|
-
source: "accessibility" | "live-app-quality" | "crawl-coverage" | "test-automation" | "api-coverage" | "ci-results" | "deploy-metadata" | "error-telemetry" | "feature-flags" | "doc-health" | "human-approval" | "agent-evidence";
|
|
62
|
+
source: "accessibility" | "live-app-quality" | "crawl-coverage" | "test-automation" | "api-coverage" | "ci-results" | "deploy-metadata" | "error-telemetry" | "feature-flags" | "doc-health" | "human-approval" | "agent-evidence" | "decision-quality";
|
|
63
63
|
summary: string;
|
|
64
64
|
kind: "blocker" | "unknown-signal" | "approval-needed";
|
|
65
65
|
subjectRef: string;
|
|
@@ -69,7 +69,7 @@ export declare const InboxItemSchema: z.ZodObject<{
|
|
|
69
69
|
}>;
|
|
70
70
|
export type InboxItem = z.infer<typeof InboxItemSchema>;
|
|
71
71
|
export declare const ReplayStepSchema: z.ZodObject<{
|
|
72
|
-
source: z.ZodEnum<["live-app-quality", "accessibility", "crawl-coverage", "test-automation", "api-coverage", "ci-results", "deploy-metadata", "error-telemetry", "feature-flags", "doc-health", "human-approval", "agent-evidence"]>;
|
|
72
|
+
source: z.ZodEnum<["live-app-quality", "accessibility", "crawl-coverage", "test-automation", "api-coverage", "ci-results", "deploy-metadata", "error-telemetry", "feature-flags", "doc-health", "human-approval", "agent-evidence", "decision-quality"]>;
|
|
73
73
|
tool: z.ZodString;
|
|
74
74
|
inputRef: z.ZodOptional<z.ZodString>;
|
|
75
75
|
score: z.ZodNullable<z.ZodNumber>;
|
|
@@ -87,7 +87,7 @@ export declare const ReplayStepSchema: z.ZodObject<{
|
|
|
87
87
|
outputTokens: number;
|
|
88
88
|
}>>;
|
|
89
89
|
}, "strip", z.ZodTypeAny, {
|
|
90
|
-
source: "accessibility" | "live-app-quality" | "crawl-coverage" | "test-automation" | "api-coverage" | "ci-results" | "deploy-metadata" | "error-telemetry" | "feature-flags" | "doc-health" | "human-approval" | "agent-evidence";
|
|
90
|
+
source: "accessibility" | "live-app-quality" | "crawl-coverage" | "test-automation" | "api-coverage" | "ci-results" | "deploy-metadata" | "error-telemetry" | "feature-flags" | "doc-health" | "human-approval" | "agent-evidence" | "decision-quality";
|
|
91
91
|
score: number | null;
|
|
92
92
|
weight: number;
|
|
93
93
|
tool: string;
|
|
@@ -99,7 +99,7 @@ export declare const ReplayStepSchema: z.ZodObject<{
|
|
|
99
99
|
outputTokens: number;
|
|
100
100
|
} | undefined;
|
|
101
101
|
}, {
|
|
102
|
-
source: "accessibility" | "live-app-quality" | "crawl-coverage" | "test-automation" | "api-coverage" | "ci-results" | "deploy-metadata" | "error-telemetry" | "feature-flags" | "doc-health" | "human-approval" | "agent-evidence";
|
|
102
|
+
source: "accessibility" | "live-app-quality" | "crawl-coverage" | "test-automation" | "api-coverage" | "ci-results" | "deploy-metadata" | "error-telemetry" | "feature-flags" | "doc-health" | "human-approval" | "agent-evidence" | "decision-quality";
|
|
103
103
|
score: number | null;
|
|
104
104
|
weight: number;
|
|
105
105
|
tool: string;
|
|
@@ -116,7 +116,7 @@ export declare const ReplayTraceSchema: z.ZodObject<{
|
|
|
116
116
|
subjectRef: z.ZodString;
|
|
117
117
|
computedAt: z.ZodString;
|
|
118
118
|
steps: z.ZodArray<z.ZodObject<{
|
|
119
|
-
source: z.ZodEnum<["live-app-quality", "accessibility", "crawl-coverage", "test-automation", "api-coverage", "ci-results", "deploy-metadata", "error-telemetry", "feature-flags", "doc-health", "human-approval", "agent-evidence"]>;
|
|
119
|
+
source: z.ZodEnum<["live-app-quality", "accessibility", "crawl-coverage", "test-automation", "api-coverage", "ci-results", "deploy-metadata", "error-telemetry", "feature-flags", "doc-health", "human-approval", "agent-evidence", "decision-quality"]>;
|
|
120
120
|
tool: z.ZodString;
|
|
121
121
|
inputRef: z.ZodOptional<z.ZodString>;
|
|
122
122
|
score: z.ZodNullable<z.ZodNumber>;
|
|
@@ -134,7 +134,7 @@ export declare const ReplayTraceSchema: z.ZodObject<{
|
|
|
134
134
|
outputTokens: number;
|
|
135
135
|
}>>;
|
|
136
136
|
}, "strip", z.ZodTypeAny, {
|
|
137
|
-
source: "accessibility" | "live-app-quality" | "crawl-coverage" | "test-automation" | "api-coverage" | "ci-results" | "deploy-metadata" | "error-telemetry" | "feature-flags" | "doc-health" | "human-approval" | "agent-evidence";
|
|
137
|
+
source: "accessibility" | "live-app-quality" | "crawl-coverage" | "test-automation" | "api-coverage" | "ci-results" | "deploy-metadata" | "error-telemetry" | "feature-flags" | "doc-health" | "human-approval" | "agent-evidence" | "decision-quality";
|
|
138
138
|
score: number | null;
|
|
139
139
|
weight: number;
|
|
140
140
|
tool: string;
|
|
@@ -146,7 +146,7 @@ export declare const ReplayTraceSchema: z.ZodObject<{
|
|
|
146
146
|
outputTokens: number;
|
|
147
147
|
} | undefined;
|
|
148
148
|
}, {
|
|
149
|
-
source: "accessibility" | "live-app-quality" | "crawl-coverage" | "test-automation" | "api-coverage" | "ci-results" | "deploy-metadata" | "error-telemetry" | "feature-flags" | "doc-health" | "human-approval" | "agent-evidence";
|
|
149
|
+
source: "accessibility" | "live-app-quality" | "crawl-coverage" | "test-automation" | "api-coverage" | "ci-results" | "deploy-metadata" | "error-telemetry" | "feature-flags" | "doc-health" | "human-approval" | "agent-evidence" | "decision-quality";
|
|
150
150
|
score: number | null;
|
|
151
151
|
weight: number;
|
|
152
152
|
tool: string;
|
|
@@ -162,7 +162,7 @@ export declare const ReplayTraceSchema: z.ZodObject<{
|
|
|
162
162
|
finalVerdict: z.ZodEnum<["ship", "caution", "hold", "block"]>;
|
|
163
163
|
}, "strip", z.ZodTypeAny, {
|
|
164
164
|
steps: {
|
|
165
|
-
source: "accessibility" | "live-app-quality" | "crawl-coverage" | "test-automation" | "api-coverage" | "ci-results" | "deploy-metadata" | "error-telemetry" | "feature-flags" | "doc-health" | "human-approval" | "agent-evidence";
|
|
165
|
+
source: "accessibility" | "live-app-quality" | "crawl-coverage" | "test-automation" | "api-coverage" | "ci-results" | "deploy-metadata" | "error-telemetry" | "feature-flags" | "doc-health" | "human-approval" | "agent-evidence" | "decision-quality";
|
|
166
166
|
score: number | null;
|
|
167
167
|
weight: number;
|
|
168
168
|
tool: string;
|
|
@@ -180,7 +180,7 @@ export declare const ReplayTraceSchema: z.ZodObject<{
|
|
|
180
180
|
finalVerdict: "ship" | "caution" | "hold" | "block";
|
|
181
181
|
}, {
|
|
182
182
|
steps: {
|
|
183
|
-
source: "accessibility" | "live-app-quality" | "crawl-coverage" | "test-automation" | "api-coverage" | "ci-results" | "deploy-metadata" | "error-telemetry" | "feature-flags" | "doc-health" | "human-approval" | "agent-evidence";
|
|
183
|
+
source: "accessibility" | "live-app-quality" | "crawl-coverage" | "test-automation" | "api-coverage" | "ci-results" | "deploy-metadata" | "error-telemetry" | "feature-flags" | "doc-health" | "human-approval" | "agent-evidence" | "decision-quality";
|
|
184
184
|
score: number | null;
|
|
185
185
|
weight: number;
|
|
186
186
|
tool: string;
|
|
@@ -211,8 +211,8 @@ export declare const AuditEntrySchema: z.ZodObject<{
|
|
|
211
211
|
recordHash: z.ZodString;
|
|
212
212
|
}, "strip", z.ZodTypeAny, {
|
|
213
213
|
computedAt: string;
|
|
214
|
-
tenantId: string;
|
|
215
214
|
schemaVersion: 1;
|
|
215
|
+
tenantId: string;
|
|
216
216
|
confidenceScore: number | null;
|
|
217
217
|
verdict: "ship" | "caution" | "hold" | "block";
|
|
218
218
|
blockers: string[];
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* LLM-as-judge + deterministic fallback for learner bug reports.
|
|
3
|
+
*
|
|
4
|
+
* Ports notquality's grading rubric (coverage/severity/repro/evidence, RUBRIC_MAX_PTS)
|
|
5
|
+
* and keyword/severity/repro/evidence heuristics from lib/scoring.ts, with PI-hardened
|
|
6
|
+
* judge prompts modeled on lib/server/judge.ts.
|
|
7
|
+
*/
|
|
8
|
+
import type { LlmProvider } from '../../llm/provider.interface.js';
|
|
9
|
+
import { type BugReportInput, type BugReportScoreResult, type ScoreBugReportInput } from '../../schemas/bug-report-score.schema.js';
|
|
10
|
+
/** Pinned judge model (claude-haiku-4-5 family). */
|
|
11
|
+
export declare const BUG_REPORT_JUDGE_MODEL = "claude-haiku-4-5-20251001";
|
|
12
|
+
/** Max points per rubric dimension (ported from notquality grading-rubric.ts). */
|
|
13
|
+
export declare const RUBRIC_MAX_PTS = 25;
|
|
14
|
+
/** Relative severity weights for deterministic severity scoring (lib/scoring.ts). */
|
|
15
|
+
export declare const SEVERITY_WEIGHT: Record<'critical' | 'high' | 'medium' | 'low', number>;
|
|
16
|
+
export interface ScoreBugReportOptions {
|
|
17
|
+
/** Inject an LLM provider (tests). Defaults to createProvider with pinned judge model. */
|
|
18
|
+
llm?: Pick<LlmProvider, 'call' | 'model'>;
|
|
19
|
+
/** Force deterministic fallback even when ANTHROPIC_API_KEY is set. */
|
|
20
|
+
forceDeterministic?: boolean;
|
|
21
|
+
}
|
|
22
|
+
export declare function hasQualityRepro(steps: string): boolean;
|
|
23
|
+
export declare function hasEvidence(report: BugReportInput): boolean;
|
|
24
|
+
export declare function scoreBugReportDeterministic(input: ScoreBugReportInput): BugReportScoreResult;
|
|
25
|
+
export declare function delimitUntrusted(label: string, text: string): string;
|
|
26
|
+
export declare function buildBugReportJudgePrompt(input: ScoreBugReportInput): string;
|
|
27
|
+
export declare function parseBugReportJudgeResponse(raw: string): Omit<BugReportScoreResult, 'scoringPath'>;
|
|
28
|
+
/**
|
|
29
|
+
* Score a learner bug report against a planted-bug target.
|
|
30
|
+
* Uses the pinned LLM judge when ANTHROPIC_API_KEY is configured; otherwise
|
|
31
|
+
* falls back to deterministic keyword+rubric scoring.
|
|
32
|
+
*/
|
|
33
|
+
export declare function scoreBugReport(input: ScoreBugReportInput, options?: ScoreBugReportOptions): Promise<BugReportScoreResult>;
|
|
34
|
+
//# sourceMappingURL=bug-report-score.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bug-report-score.d.ts","sourceRoot":"","sources":["../../../src/tools/scoring/bug-report-score.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAGH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,iCAAiC,CAAC;AACnE,OAAO,EAGL,KAAK,cAAc,EAEnB,KAAK,oBAAoB,EAEzB,KAAK,mBAAmB,EACzB,MAAM,0CAA0C,CAAC;AAElD,oDAAoD;AACpD,eAAO,MAAM,sBAAsB,8BAA8B,CAAC;AAElE,kFAAkF;AAClF,eAAO,MAAM,cAAc,KAAK,CAAC;AAEjC,qFAAqF;AACrF,eAAO,MAAM,eAAe,EAAE,MAAM,CAAC,UAAU,GAAG,MAAM,GAAG,QAAQ,GAAG,KAAK,EAAE,MAAM,CAKlF,CAAC;AA+BF,MAAM,WAAW,qBAAqB;IACpC,0FAA0F;IAC1F,GAAG,CAAC,EAAE,IAAI,CAAC,WAAW,EAAE,MAAM,GAAG,OAAO,CAAC,CAAC;IAC1C,uEAAuE;IACvE,kBAAkB,CAAC,EAAE,OAAO,CAAC;CAC9B;AAkBD,wBAAgB,eAAe,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAYtD;AAED,wBAAgB,WAAW,CAAC,MAAM,EAAE,cAAc,GAAG,OAAO,CAW3D;AAgFD,wBAAgB,2BAA2B,CAAC,KAAK,EAAE,mBAAmB,GAAG,oBAAoB,CAe5F;AAED,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,GAAG,MAAM,CAEpE;AAED,wBAAgB,yBAAyB,CAAC,KAAK,EAAE,mBAAmB,GAAG,MAAM,CA+C5E;AAcD,wBAAgB,2BAA2B,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,CAAC,oBAAoB,EAAE,aAAa,CAAC,CAwClG;AAQD;;;;GAIG;AACH,wBAAsB,cAAc,CAClC,KAAK,EAAE,mBAAmB,EAC1B,OAAO,GAAE,qBAA0B,GAClC,OAAO,CAAC,oBAAoB,CAAC,CA+B/B"}
|