@qulib/core 0.2.2 → 0.3.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 +31 -3
- package/dist/analyze.d.ts +16 -4
- package/dist/analyze.d.ts.map +1 -1
- package/dist/analyze.js +98 -38
- package/dist/cli/cost-doctor.d.ts +2 -0
- package/dist/cli/cost-doctor.d.ts.map +1 -0
- package/dist/cli/cost-doctor.js +72 -0
- package/dist/cli/index.js +14 -0
- package/dist/harness/progress-log.d.ts +7 -0
- package/dist/harness/progress-log.d.ts.map +1 -0
- package/dist/harness/progress-log.js +1 -0
- package/dist/harness/run-options.d.ts +2 -0
- package/dist/harness/run-options.d.ts.map +1 -1
- package/dist/index.d.ts +4 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/llm/content-hash.d.ts +2 -0
- package/dist/llm/content-hash.d.ts.map +1 -0
- package/dist/llm/content-hash.js +4 -0
- package/dist/llm/context-builder.js +1 -1
- package/dist/llm/cost-intelligence.d.ts +29 -0
- package/dist/llm/cost-intelligence.d.ts.map +1 -0
- package/dist/llm/cost-intelligence.js +153 -0
- package/dist/llm/provider.d.ts +11 -1
- package/dist/llm/provider.d.ts.map +1 -1
- package/dist/llm/provider.js +43 -4
- package/dist/phases/act.d.ts.map +1 -1
- package/dist/phases/act.js +4 -1
- package/dist/phases/observe.js +1 -1
- package/dist/phases/think-finalize.d.ts +6 -0
- package/dist/phases/think-finalize.d.ts.map +1 -0
- package/dist/phases/think-finalize.js +164 -0
- package/dist/phases/think.d.ts +2 -0
- package/dist/phases/think.d.ts.map +1 -1
- package/dist/phases/think.js +16 -65
- package/dist/reporters/markdown-reporter.d.ts.map +1 -1
- package/dist/reporters/markdown-reporter.js +23 -3
- package/dist/schemas/config.schema.d.ts +7 -0
- package/dist/schemas/config.schema.d.ts.map +1 -1
- package/dist/schemas/config.schema.js +18 -1
- package/dist/schemas/cost-intelligence.schema.d.ts +229 -0
- package/dist/schemas/cost-intelligence.schema.d.ts.map +1 -0
- package/dist/schemas/cost-intelligence.schema.js +41 -0
- package/dist/schemas/decision-log.schema.d.ts +2 -2
- package/dist/schemas/gap-analysis.schema.d.ts +270 -31
- package/dist/schemas/gap-analysis.schema.d.ts.map +1 -1
- package/dist/schemas/gap-analysis.schema.js +7 -3
- package/dist/schemas/index.d.ts +3 -1
- package/dist/schemas/index.d.ts.map +1 -1
- package/dist/schemas/index.js +3 -1
- package/dist/schemas/public-surface.schema.d.ts +268 -0
- package/dist/schemas/public-surface.schema.d.ts.map +1 -0
- package/dist/schemas/public-surface.schema.js +15 -0
- package/dist/tools/auth-block-gap.d.ts +3 -0
- package/dist/tools/auth-block-gap.d.ts.map +1 -0
- package/dist/tools/auth-block-gap.js +19 -0
- package/dist/tools/auth-detector.d.ts +2 -1
- package/dist/tools/auth-detector.d.ts.map +1 -1
- package/dist/tools/auth-detector.js +28 -3
- package/dist/tools/auth-explorer.d.ts +2 -1
- package/dist/tools/auth-explorer.d.ts.map +1 -1
- package/dist/tools/auth-explorer.js +30 -8
- package/dist/tools/auth-surface-analyzer.d.ts +4 -0
- package/dist/tools/auth-surface-analyzer.d.ts.map +1 -0
- package/dist/tools/auth-surface-analyzer.js +154 -0
- package/dist/tools/cypress-explorer.d.ts +2 -1
- package/dist/tools/cypress-explorer.d.ts.map +1 -1
- package/dist/tools/cypress-explorer.js +1 -1
- package/dist/tools/explorer.interface.d.ts +2 -1
- package/dist/tools/explorer.interface.d.ts.map +1 -1
- package/dist/tools/gap-engine.d.ts +3 -1
- package/dist/tools/gap-engine.d.ts.map +1 -1
- package/dist/tools/gap-engine.js +39 -12
- package/dist/tools/playwright-explorer.d.ts +2 -1
- package/dist/tools/playwright-explorer.d.ts.map +1 -1
- package/dist/tools/playwright-explorer.js +21 -3
- package/dist/tools/public-surface.d.ts +5 -0
- package/dist/tools/public-surface.d.ts.map +1 -0
- package/dist/tools/public-surface.js +13 -0
- package/package.json +6 -2
|
@@ -2,21 +2,27 @@ import { z } from 'zod';
|
|
|
2
2
|
export declare const GapSchema: z.ZodObject<{
|
|
3
3
|
id: z.ZodString;
|
|
4
4
|
path: z.ZodString;
|
|
5
|
-
severity: z.ZodEnum<["high", "medium", "low"]>;
|
|
5
|
+
severity: z.ZodEnum<["critical", "high", "medium", "low"]>;
|
|
6
6
|
reason: z.ZodString;
|
|
7
|
-
category: z.ZodEnum<["untested-route", "a11y", "console-error", "broken-link"]>;
|
|
7
|
+
category: z.ZodEnum<["untested-route", "a11y", "console-error", "broken-link", "auth-surface", "coverage"]>;
|
|
8
|
+
description: z.ZodOptional<z.ZodString>;
|
|
9
|
+
recommendation: z.ZodOptional<z.ZodString>;
|
|
8
10
|
}, "strip", z.ZodTypeAny, {
|
|
9
11
|
path: string;
|
|
10
12
|
id: string;
|
|
11
|
-
severity: "high" | "medium" | "low";
|
|
13
|
+
severity: "high" | "medium" | "low" | "critical";
|
|
12
14
|
reason: string;
|
|
13
|
-
category: "untested-route" | "a11y" | "console-error" | "broken-link";
|
|
15
|
+
category: "untested-route" | "a11y" | "console-error" | "broken-link" | "auth-surface" | "coverage";
|
|
16
|
+
recommendation?: string | undefined;
|
|
17
|
+
description?: string | undefined;
|
|
14
18
|
}, {
|
|
15
19
|
path: string;
|
|
16
20
|
id: string;
|
|
17
|
-
severity: "high" | "medium" | "low";
|
|
21
|
+
severity: "high" | "medium" | "low" | "critical";
|
|
18
22
|
reason: string;
|
|
19
|
-
category: "untested-route" | "a11y" | "console-error" | "broken-link";
|
|
23
|
+
category: "untested-route" | "a11y" | "console-error" | "broken-link" | "auth-surface" | "coverage";
|
|
24
|
+
recommendation?: string | undefined;
|
|
25
|
+
description?: string | undefined;
|
|
20
26
|
}>;
|
|
21
27
|
export declare const FrameworkRecommendationSchema: z.ZodObject<{
|
|
22
28
|
adapter: z.ZodEnum<["playwright", "cypress-e2e", "cypress-component", "api", "accessibility"]>;
|
|
@@ -37,13 +43,13 @@ export declare const TestStepSchema: z.ZodObject<{
|
|
|
37
43
|
value: z.ZodOptional<z.ZodString>;
|
|
38
44
|
description: z.ZodString;
|
|
39
45
|
}, "strip", z.ZodTypeAny, {
|
|
40
|
-
action: "type" | "navigate" | "click" | "assert-visible" | "assert-hidden" | "assert-text" | "assert-disabled" | "assert-count" | "wait" | "api-call";
|
|
41
46
|
description: string;
|
|
47
|
+
action: "type" | "navigate" | "click" | "assert-visible" | "assert-hidden" | "assert-text" | "assert-disabled" | "assert-count" | "wait" | "api-call";
|
|
42
48
|
value?: string | undefined;
|
|
43
49
|
target?: string | undefined;
|
|
44
50
|
}, {
|
|
45
|
-
action: "type" | "navigate" | "click" | "assert-visible" | "assert-hidden" | "assert-text" | "assert-disabled" | "assert-count" | "wait" | "api-call";
|
|
46
51
|
description: string;
|
|
52
|
+
action: "type" | "navigate" | "click" | "assert-visible" | "assert-hidden" | "assert-text" | "assert-disabled" | "assert-count" | "wait" | "api-call";
|
|
47
53
|
value?: string | undefined;
|
|
48
54
|
target?: string | undefined;
|
|
49
55
|
}>;
|
|
@@ -59,13 +65,13 @@ export declare const NeutralScenarioSchema: z.ZodObject<{
|
|
|
59
65
|
value: z.ZodOptional<z.ZodString>;
|
|
60
66
|
description: z.ZodString;
|
|
61
67
|
}, "strip", z.ZodTypeAny, {
|
|
62
|
-
action: "type" | "navigate" | "click" | "assert-visible" | "assert-hidden" | "assert-text" | "assert-disabled" | "assert-count" | "wait" | "api-call";
|
|
63
68
|
description: string;
|
|
69
|
+
action: "type" | "navigate" | "click" | "assert-visible" | "assert-hidden" | "assert-text" | "assert-disabled" | "assert-count" | "wait" | "api-call";
|
|
64
70
|
value?: string | undefined;
|
|
65
71
|
target?: string | undefined;
|
|
66
72
|
}, {
|
|
67
|
-
action: "type" | "navigate" | "click" | "assert-visible" | "assert-hidden" | "assert-text" | "assert-disabled" | "assert-count" | "wait" | "api-call";
|
|
68
73
|
description: string;
|
|
74
|
+
action: "type" | "navigate" | "click" | "assert-visible" | "assert-hidden" | "assert-text" | "assert-disabled" | "assert-count" | "wait" | "api-call";
|
|
69
75
|
value?: string | undefined;
|
|
70
76
|
target?: string | undefined;
|
|
71
77
|
}>, "many">;
|
|
@@ -90,8 +96,8 @@ export declare const NeutralScenarioSchema: z.ZodObject<{
|
|
|
90
96
|
title: string;
|
|
91
97
|
targetPath: string;
|
|
92
98
|
steps: {
|
|
93
|
-
action: "type" | "navigate" | "click" | "assert-visible" | "assert-hidden" | "assert-text" | "assert-disabled" | "assert-count" | "wait" | "api-call";
|
|
94
99
|
description: string;
|
|
100
|
+
action: "type" | "navigate" | "click" | "assert-visible" | "assert-hidden" | "assert-text" | "assert-disabled" | "assert-count" | "wait" | "api-call";
|
|
95
101
|
value?: string | undefined;
|
|
96
102
|
target?: string | undefined;
|
|
97
103
|
}[];
|
|
@@ -109,8 +115,8 @@ export declare const NeutralScenarioSchema: z.ZodObject<{
|
|
|
109
115
|
title: string;
|
|
110
116
|
targetPath: string;
|
|
111
117
|
steps: {
|
|
112
|
-
action: "type" | "navigate" | "click" | "assert-visible" | "assert-hidden" | "assert-text" | "assert-disabled" | "assert-count" | "wait" | "api-call";
|
|
113
118
|
description: string;
|
|
119
|
+
action: "type" | "navigate" | "click" | "assert-visible" | "assert-hidden" | "assert-text" | "assert-disabled" | "assert-count" | "wait" | "api-call";
|
|
114
120
|
value?: string | undefined;
|
|
115
121
|
target?: string | undefined;
|
|
116
122
|
}[];
|
|
@@ -148,28 +154,34 @@ export declare const GeneratedTestSchema: z.ZodObject<{
|
|
|
148
154
|
export declare const GapAnalysisSchema: z.ZodObject<{
|
|
149
155
|
analyzedAt: z.ZodString;
|
|
150
156
|
mode: z.ZodEnum<["url-only", "url-repo", "auth-required"]>;
|
|
151
|
-
releaseConfidence: z.ZodNumber
|
|
157
|
+
releaseConfidence: z.ZodUnion<[z.ZodNumber, z.ZodNull]>;
|
|
152
158
|
coveragePagesScanned: z.ZodNumber;
|
|
153
159
|
coverageBudgetExceeded: z.ZodBoolean;
|
|
154
160
|
coverageWarning: z.ZodOptional<z.ZodEnum<["budget-exceeded", "low-coverage", "navigation-failures", "auth-required"]>>;
|
|
155
161
|
gaps: z.ZodArray<z.ZodObject<{
|
|
156
162
|
id: z.ZodString;
|
|
157
163
|
path: z.ZodString;
|
|
158
|
-
severity: z.ZodEnum<["high", "medium", "low"]>;
|
|
164
|
+
severity: z.ZodEnum<["critical", "high", "medium", "low"]>;
|
|
159
165
|
reason: z.ZodString;
|
|
160
|
-
category: z.ZodEnum<["untested-route", "a11y", "console-error", "broken-link"]>;
|
|
166
|
+
category: z.ZodEnum<["untested-route", "a11y", "console-error", "broken-link", "auth-surface", "coverage"]>;
|
|
167
|
+
description: z.ZodOptional<z.ZodString>;
|
|
168
|
+
recommendation: z.ZodOptional<z.ZodString>;
|
|
161
169
|
}, "strip", z.ZodTypeAny, {
|
|
162
170
|
path: string;
|
|
163
171
|
id: string;
|
|
164
|
-
severity: "high" | "medium" | "low";
|
|
172
|
+
severity: "high" | "medium" | "low" | "critical";
|
|
165
173
|
reason: string;
|
|
166
|
-
category: "untested-route" | "a11y" | "console-error" | "broken-link";
|
|
174
|
+
category: "untested-route" | "a11y" | "console-error" | "broken-link" | "auth-surface" | "coverage";
|
|
175
|
+
recommendation?: string | undefined;
|
|
176
|
+
description?: string | undefined;
|
|
167
177
|
}, {
|
|
168
178
|
path: string;
|
|
169
179
|
id: string;
|
|
170
|
-
severity: "high" | "medium" | "low";
|
|
180
|
+
severity: "high" | "medium" | "low" | "critical";
|
|
171
181
|
reason: string;
|
|
172
|
-
category: "untested-route" | "a11y" | "console-error" | "broken-link";
|
|
182
|
+
category: "untested-route" | "a11y" | "console-error" | "broken-link" | "auth-surface" | "coverage";
|
|
183
|
+
recommendation?: string | undefined;
|
|
184
|
+
description?: string | undefined;
|
|
173
185
|
}>, "many">;
|
|
174
186
|
scenarios: z.ZodArray<z.ZodObject<{
|
|
175
187
|
id: z.ZodString;
|
|
@@ -183,13 +195,13 @@ export declare const GapAnalysisSchema: z.ZodObject<{
|
|
|
183
195
|
value: z.ZodOptional<z.ZodString>;
|
|
184
196
|
description: z.ZodString;
|
|
185
197
|
}, "strip", z.ZodTypeAny, {
|
|
186
|
-
action: "type" | "navigate" | "click" | "assert-visible" | "assert-hidden" | "assert-text" | "assert-disabled" | "assert-count" | "wait" | "api-call";
|
|
187
198
|
description: string;
|
|
199
|
+
action: "type" | "navigate" | "click" | "assert-visible" | "assert-hidden" | "assert-text" | "assert-disabled" | "assert-count" | "wait" | "api-call";
|
|
188
200
|
value?: string | undefined;
|
|
189
201
|
target?: string | undefined;
|
|
190
202
|
}, {
|
|
191
|
-
action: "type" | "navigate" | "click" | "assert-visible" | "assert-hidden" | "assert-text" | "assert-disabled" | "assert-count" | "wait" | "api-call";
|
|
192
203
|
description: string;
|
|
204
|
+
action: "type" | "navigate" | "click" | "assert-visible" | "assert-hidden" | "assert-text" | "assert-disabled" | "assert-count" | "wait" | "api-call";
|
|
193
205
|
value?: string | undefined;
|
|
194
206
|
target?: string | undefined;
|
|
195
207
|
}>, "many">;
|
|
@@ -214,8 +226,8 @@ export declare const GapAnalysisSchema: z.ZodObject<{
|
|
|
214
226
|
title: string;
|
|
215
227
|
targetPath: string;
|
|
216
228
|
steps: {
|
|
217
|
-
action: "type" | "navigate" | "click" | "assert-visible" | "assert-hidden" | "assert-text" | "assert-disabled" | "assert-count" | "wait" | "api-call";
|
|
218
229
|
description: string;
|
|
230
|
+
action: "type" | "navigate" | "click" | "assert-visible" | "assert-hidden" | "assert-text" | "assert-disabled" | "assert-count" | "wait" | "api-call";
|
|
219
231
|
value?: string | undefined;
|
|
220
232
|
target?: string | undefined;
|
|
221
233
|
}[];
|
|
@@ -233,8 +245,8 @@ export declare const GapAnalysisSchema: z.ZodObject<{
|
|
|
233
245
|
title: string;
|
|
234
246
|
targetPath: string;
|
|
235
247
|
steps: {
|
|
236
|
-
action: "type" | "navigate" | "click" | "assert-visible" | "assert-hidden" | "assert-text" | "assert-disabled" | "assert-count" | "wait" | "api-call";
|
|
237
248
|
description: string;
|
|
249
|
+
action: "type" | "navigate" | "click" | "assert-visible" | "assert-hidden" | "assert-text" | "assert-disabled" | "assert-count" | "wait" | "api-call";
|
|
238
250
|
value?: string | undefined;
|
|
239
251
|
target?: string | undefined;
|
|
240
252
|
}[];
|
|
@@ -269,18 +281,173 @@ export declare const GapAnalysisSchema: z.ZodObject<{
|
|
|
269
281
|
filename: string;
|
|
270
282
|
outputPath: string;
|
|
271
283
|
}>, "many">;
|
|
284
|
+
costIntelligence: z.ZodOptional<z.ZodObject<{
|
|
285
|
+
maxOutputTokensPerLlmCall: z.ZodNumber;
|
|
286
|
+
budgetRole: z.ZodLiteral<"max-output-tokens-per-llm-call">;
|
|
287
|
+
records: z.ZodArray<z.ZodObject<{
|
|
288
|
+
provider: z.ZodString;
|
|
289
|
+
model: z.ZodString;
|
|
290
|
+
inputTokens: z.ZodNumber;
|
|
291
|
+
outputTokens: z.ZodNumber;
|
|
292
|
+
estimatedCostUsd: z.ZodOptional<z.ZodNumber>;
|
|
293
|
+
operationType: z.ZodEnum<["scenario-generation"]>;
|
|
294
|
+
timestamp: z.ZodString;
|
|
295
|
+
promptHash: z.ZodOptional<z.ZodString>;
|
|
296
|
+
resultHash: z.ZodOptional<z.ZodString>;
|
|
297
|
+
dataQuality: z.ZodEnum<["actual", "estimated", "mixed", "none"]>;
|
|
298
|
+
notes: z.ZodOptional<z.ZodString>;
|
|
299
|
+
}, "strip", z.ZodTypeAny, {
|
|
300
|
+
provider: string;
|
|
301
|
+
model: string;
|
|
302
|
+
inputTokens: number;
|
|
303
|
+
outputTokens: number;
|
|
304
|
+
operationType: "scenario-generation";
|
|
305
|
+
timestamp: string;
|
|
306
|
+
dataQuality: "none" | "actual" | "estimated" | "mixed";
|
|
307
|
+
estimatedCostUsd?: number | undefined;
|
|
308
|
+
promptHash?: string | undefined;
|
|
309
|
+
resultHash?: string | undefined;
|
|
310
|
+
notes?: string | undefined;
|
|
311
|
+
}, {
|
|
312
|
+
provider: string;
|
|
313
|
+
model: string;
|
|
314
|
+
inputTokens: number;
|
|
315
|
+
outputTokens: number;
|
|
316
|
+
operationType: "scenario-generation";
|
|
317
|
+
timestamp: string;
|
|
318
|
+
dataQuality: "none" | "actual" | "estimated" | "mixed";
|
|
319
|
+
estimatedCostUsd?: number | undefined;
|
|
320
|
+
promptHash?: string | undefined;
|
|
321
|
+
resultHash?: string | undefined;
|
|
322
|
+
notes?: string | undefined;
|
|
323
|
+
}>, "many">;
|
|
324
|
+
budgetWarnings: z.ZodArray<z.ZodString, "many">;
|
|
325
|
+
usageSummary: z.ZodObject<{
|
|
326
|
+
totalInputTokens: z.ZodNumber;
|
|
327
|
+
totalOutputTokens: z.ZodNumber;
|
|
328
|
+
dataQuality: z.ZodEnum<["actual", "estimated", "mixed", "none"]>;
|
|
329
|
+
}, "strip", z.ZodTypeAny, {
|
|
330
|
+
dataQuality: "none" | "actual" | "estimated" | "mixed";
|
|
331
|
+
totalInputTokens: number;
|
|
332
|
+
totalOutputTokens: number;
|
|
333
|
+
}, {
|
|
334
|
+
dataQuality: "none" | "actual" | "estimated" | "mixed";
|
|
335
|
+
totalInputTokens: number;
|
|
336
|
+
totalOutputTokens: number;
|
|
337
|
+
}>;
|
|
338
|
+
repeatedOperations: z.ZodArray<z.ZodObject<{
|
|
339
|
+
promptHash: z.ZodString;
|
|
340
|
+
count: z.ZodNumber;
|
|
341
|
+
recommendation: z.ZodString;
|
|
342
|
+
}, "strip", z.ZodTypeAny, {
|
|
343
|
+
recommendation: string;
|
|
344
|
+
promptHash: string;
|
|
345
|
+
count: number;
|
|
346
|
+
}, {
|
|
347
|
+
recommendation: string;
|
|
348
|
+
promptHash: string;
|
|
349
|
+
count: number;
|
|
350
|
+
}>, "many">;
|
|
351
|
+
deterministicMaturity: z.ZodObject<{
|
|
352
|
+
level: z.ZodNumber;
|
|
353
|
+
label: z.ZodString;
|
|
354
|
+
rationale: z.ZodString;
|
|
355
|
+
ceilingNote: z.ZodOptional<z.ZodString>;
|
|
356
|
+
}, "strip", z.ZodTypeAny, {
|
|
357
|
+
label: string;
|
|
358
|
+
level: number;
|
|
359
|
+
rationale: string;
|
|
360
|
+
ceilingNote?: string | undefined;
|
|
361
|
+
}, {
|
|
362
|
+
label: string;
|
|
363
|
+
level: number;
|
|
364
|
+
rationale: string;
|
|
365
|
+
ceilingNote?: string | undefined;
|
|
366
|
+
}>;
|
|
367
|
+
conversionRecommendations: z.ZodArray<z.ZodString, "many">;
|
|
368
|
+
}, "strip", z.ZodTypeAny, {
|
|
369
|
+
maxOutputTokensPerLlmCall: number;
|
|
370
|
+
budgetRole: "max-output-tokens-per-llm-call";
|
|
371
|
+
records: {
|
|
372
|
+
provider: string;
|
|
373
|
+
model: string;
|
|
374
|
+
inputTokens: number;
|
|
375
|
+
outputTokens: number;
|
|
376
|
+
operationType: "scenario-generation";
|
|
377
|
+
timestamp: string;
|
|
378
|
+
dataQuality: "none" | "actual" | "estimated" | "mixed";
|
|
379
|
+
estimatedCostUsd?: number | undefined;
|
|
380
|
+
promptHash?: string | undefined;
|
|
381
|
+
resultHash?: string | undefined;
|
|
382
|
+
notes?: string | undefined;
|
|
383
|
+
}[];
|
|
384
|
+
budgetWarnings: string[];
|
|
385
|
+
usageSummary: {
|
|
386
|
+
dataQuality: "none" | "actual" | "estimated" | "mixed";
|
|
387
|
+
totalInputTokens: number;
|
|
388
|
+
totalOutputTokens: number;
|
|
389
|
+
};
|
|
390
|
+
repeatedOperations: {
|
|
391
|
+
recommendation: string;
|
|
392
|
+
promptHash: string;
|
|
393
|
+
count: number;
|
|
394
|
+
}[];
|
|
395
|
+
deterministicMaturity: {
|
|
396
|
+
label: string;
|
|
397
|
+
level: number;
|
|
398
|
+
rationale: string;
|
|
399
|
+
ceilingNote?: string | undefined;
|
|
400
|
+
};
|
|
401
|
+
conversionRecommendations: string[];
|
|
402
|
+
}, {
|
|
403
|
+
maxOutputTokensPerLlmCall: number;
|
|
404
|
+
budgetRole: "max-output-tokens-per-llm-call";
|
|
405
|
+
records: {
|
|
406
|
+
provider: string;
|
|
407
|
+
model: string;
|
|
408
|
+
inputTokens: number;
|
|
409
|
+
outputTokens: number;
|
|
410
|
+
operationType: "scenario-generation";
|
|
411
|
+
timestamp: string;
|
|
412
|
+
dataQuality: "none" | "actual" | "estimated" | "mixed";
|
|
413
|
+
estimatedCostUsd?: number | undefined;
|
|
414
|
+
promptHash?: string | undefined;
|
|
415
|
+
resultHash?: string | undefined;
|
|
416
|
+
notes?: string | undefined;
|
|
417
|
+
}[];
|
|
418
|
+
budgetWarnings: string[];
|
|
419
|
+
usageSummary: {
|
|
420
|
+
dataQuality: "none" | "actual" | "estimated" | "mixed";
|
|
421
|
+
totalInputTokens: number;
|
|
422
|
+
totalOutputTokens: number;
|
|
423
|
+
};
|
|
424
|
+
repeatedOperations: {
|
|
425
|
+
recommendation: string;
|
|
426
|
+
promptHash: string;
|
|
427
|
+
count: number;
|
|
428
|
+
}[];
|
|
429
|
+
deterministicMaturity: {
|
|
430
|
+
label: string;
|
|
431
|
+
level: number;
|
|
432
|
+
rationale: string;
|
|
433
|
+
ceilingNote?: string | undefined;
|
|
434
|
+
};
|
|
435
|
+
conversionRecommendations: string[];
|
|
436
|
+
}>>;
|
|
272
437
|
}, "strip", z.ZodTypeAny, {
|
|
273
438
|
analyzedAt: string;
|
|
274
439
|
mode: "url-only" | "url-repo" | "auth-required";
|
|
275
|
-
releaseConfidence: number;
|
|
440
|
+
releaseConfidence: number | null;
|
|
276
441
|
coveragePagesScanned: number;
|
|
277
442
|
coverageBudgetExceeded: boolean;
|
|
278
443
|
gaps: {
|
|
279
444
|
path: string;
|
|
280
445
|
id: string;
|
|
281
|
-
severity: "high" | "medium" | "low";
|
|
446
|
+
severity: "high" | "medium" | "low" | "critical";
|
|
282
447
|
reason: string;
|
|
283
|
-
category: "untested-route" | "a11y" | "console-error" | "broken-link";
|
|
448
|
+
category: "untested-route" | "a11y" | "console-error" | "broken-link" | "auth-surface" | "coverage";
|
|
449
|
+
recommendation?: string | undefined;
|
|
450
|
+
description?: string | undefined;
|
|
284
451
|
}[];
|
|
285
452
|
scenarios: {
|
|
286
453
|
id: string;
|
|
@@ -288,8 +455,8 @@ export declare const GapAnalysisSchema: z.ZodObject<{
|
|
|
288
455
|
title: string;
|
|
289
456
|
targetPath: string;
|
|
290
457
|
steps: {
|
|
291
|
-
action: "type" | "navigate" | "click" | "assert-visible" | "assert-hidden" | "assert-text" | "assert-disabled" | "assert-count" | "wait" | "api-call";
|
|
292
458
|
description: string;
|
|
459
|
+
action: "type" | "navigate" | "click" | "assert-visible" | "assert-hidden" | "assert-text" | "assert-disabled" | "assert-count" | "wait" | "api-call";
|
|
293
460
|
value?: string | undefined;
|
|
294
461
|
target?: string | undefined;
|
|
295
462
|
}[];
|
|
@@ -311,18 +478,55 @@ export declare const GapAnalysisSchema: z.ZodObject<{
|
|
|
311
478
|
outputPath: string;
|
|
312
479
|
}[];
|
|
313
480
|
coverageWarning?: "auth-required" | "budget-exceeded" | "low-coverage" | "navigation-failures" | undefined;
|
|
481
|
+
costIntelligence?: {
|
|
482
|
+
maxOutputTokensPerLlmCall: number;
|
|
483
|
+
budgetRole: "max-output-tokens-per-llm-call";
|
|
484
|
+
records: {
|
|
485
|
+
provider: string;
|
|
486
|
+
model: string;
|
|
487
|
+
inputTokens: number;
|
|
488
|
+
outputTokens: number;
|
|
489
|
+
operationType: "scenario-generation";
|
|
490
|
+
timestamp: string;
|
|
491
|
+
dataQuality: "none" | "actual" | "estimated" | "mixed";
|
|
492
|
+
estimatedCostUsd?: number | undefined;
|
|
493
|
+
promptHash?: string | undefined;
|
|
494
|
+
resultHash?: string | undefined;
|
|
495
|
+
notes?: string | undefined;
|
|
496
|
+
}[];
|
|
497
|
+
budgetWarnings: string[];
|
|
498
|
+
usageSummary: {
|
|
499
|
+
dataQuality: "none" | "actual" | "estimated" | "mixed";
|
|
500
|
+
totalInputTokens: number;
|
|
501
|
+
totalOutputTokens: number;
|
|
502
|
+
};
|
|
503
|
+
repeatedOperations: {
|
|
504
|
+
recommendation: string;
|
|
505
|
+
promptHash: string;
|
|
506
|
+
count: number;
|
|
507
|
+
}[];
|
|
508
|
+
deterministicMaturity: {
|
|
509
|
+
label: string;
|
|
510
|
+
level: number;
|
|
511
|
+
rationale: string;
|
|
512
|
+
ceilingNote?: string | undefined;
|
|
513
|
+
};
|
|
514
|
+
conversionRecommendations: string[];
|
|
515
|
+
} | undefined;
|
|
314
516
|
}, {
|
|
315
517
|
analyzedAt: string;
|
|
316
518
|
mode: "url-only" | "url-repo" | "auth-required";
|
|
317
|
-
releaseConfidence: number;
|
|
519
|
+
releaseConfidence: number | null;
|
|
318
520
|
coveragePagesScanned: number;
|
|
319
521
|
coverageBudgetExceeded: boolean;
|
|
320
522
|
gaps: {
|
|
321
523
|
path: string;
|
|
322
524
|
id: string;
|
|
323
|
-
severity: "high" | "medium" | "low";
|
|
525
|
+
severity: "high" | "medium" | "low" | "critical";
|
|
324
526
|
reason: string;
|
|
325
|
-
category: "untested-route" | "a11y" | "console-error" | "broken-link";
|
|
527
|
+
category: "untested-route" | "a11y" | "console-error" | "broken-link" | "auth-surface" | "coverage";
|
|
528
|
+
recommendation?: string | undefined;
|
|
529
|
+
description?: string | undefined;
|
|
326
530
|
}[];
|
|
327
531
|
scenarios: {
|
|
328
532
|
id: string;
|
|
@@ -330,8 +534,8 @@ export declare const GapAnalysisSchema: z.ZodObject<{
|
|
|
330
534
|
title: string;
|
|
331
535
|
targetPath: string;
|
|
332
536
|
steps: {
|
|
333
|
-
action: "type" | "navigate" | "click" | "assert-visible" | "assert-hidden" | "assert-text" | "assert-disabled" | "assert-count" | "wait" | "api-call";
|
|
334
537
|
description: string;
|
|
538
|
+
action: "type" | "navigate" | "click" | "assert-visible" | "assert-hidden" | "assert-text" | "assert-disabled" | "assert-count" | "wait" | "api-call";
|
|
335
539
|
value?: string | undefined;
|
|
336
540
|
target?: string | undefined;
|
|
337
541
|
}[];
|
|
@@ -353,6 +557,41 @@ export declare const GapAnalysisSchema: z.ZodObject<{
|
|
|
353
557
|
outputPath: string;
|
|
354
558
|
}[];
|
|
355
559
|
coverageWarning?: "auth-required" | "budget-exceeded" | "low-coverage" | "navigation-failures" | undefined;
|
|
560
|
+
costIntelligence?: {
|
|
561
|
+
maxOutputTokensPerLlmCall: number;
|
|
562
|
+
budgetRole: "max-output-tokens-per-llm-call";
|
|
563
|
+
records: {
|
|
564
|
+
provider: string;
|
|
565
|
+
model: string;
|
|
566
|
+
inputTokens: number;
|
|
567
|
+
outputTokens: number;
|
|
568
|
+
operationType: "scenario-generation";
|
|
569
|
+
timestamp: string;
|
|
570
|
+
dataQuality: "none" | "actual" | "estimated" | "mixed";
|
|
571
|
+
estimatedCostUsd?: number | undefined;
|
|
572
|
+
promptHash?: string | undefined;
|
|
573
|
+
resultHash?: string | undefined;
|
|
574
|
+
notes?: string | undefined;
|
|
575
|
+
}[];
|
|
576
|
+
budgetWarnings: string[];
|
|
577
|
+
usageSummary: {
|
|
578
|
+
dataQuality: "none" | "actual" | "estimated" | "mixed";
|
|
579
|
+
totalInputTokens: number;
|
|
580
|
+
totalOutputTokens: number;
|
|
581
|
+
};
|
|
582
|
+
repeatedOperations: {
|
|
583
|
+
recommendation: string;
|
|
584
|
+
promptHash: string;
|
|
585
|
+
count: number;
|
|
586
|
+
}[];
|
|
587
|
+
deterministicMaturity: {
|
|
588
|
+
label: string;
|
|
589
|
+
level: number;
|
|
590
|
+
rationale: string;
|
|
591
|
+
ceilingNote?: string | undefined;
|
|
592
|
+
};
|
|
593
|
+
conversionRecommendations: string[];
|
|
594
|
+
} | undefined;
|
|
356
595
|
}>;
|
|
357
596
|
export type GapAnalysis = z.infer<typeof GapAnalysisSchema>;
|
|
358
597
|
export type Gap = z.infer<typeof GapSchema>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"gap-analysis.schema.d.ts","sourceRoot":"","sources":["../../src/schemas/gap-analysis.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC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KAAK,CAAC,OAAO,SAAS,CAAC,CAAC;AAC5C,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC;AACpE,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAChE,MAAM,MAAM,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;AACtD,MAAM,MAAM,uBAAuB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,6BAA6B,CAAC,CAAC"}
|
|
@@ -1,10 +1,13 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
+
import { CostIntelligenceSchema } from './cost-intelligence.schema.js';
|
|
2
3
|
export const GapSchema = z.object({
|
|
3
4
|
id: z.string(),
|
|
4
5
|
path: z.string(),
|
|
5
|
-
severity: z.enum(['high', 'medium', 'low']),
|
|
6
|
+
severity: z.enum(['critical', 'high', 'medium', 'low']),
|
|
6
7
|
reason: z.string(),
|
|
7
|
-
category: z.enum(['untested-route', 'a11y', 'console-error', 'broken-link']),
|
|
8
|
+
category: z.enum(['untested-route', 'a11y', 'console-error', 'broken-link', 'auth-surface', 'coverage']),
|
|
9
|
+
description: z.string().optional(),
|
|
10
|
+
recommendation: z.string().optional(),
|
|
8
11
|
});
|
|
9
12
|
export const FrameworkRecommendationSchema = z.object({
|
|
10
13
|
adapter: z.enum(['playwright', 'cypress-e2e', 'cypress-component', 'api', 'accessibility']),
|
|
@@ -50,7 +53,7 @@ export const GeneratedTestSchema = z.object({
|
|
|
50
53
|
export const GapAnalysisSchema = z.object({
|
|
51
54
|
analyzedAt: z.string().datetime(),
|
|
52
55
|
mode: z.enum(['url-only', 'url-repo', 'auth-required']),
|
|
53
|
-
releaseConfidence: z.number().min(0).max(100),
|
|
56
|
+
releaseConfidence: z.union([z.number().min(0).max(100), z.null()]),
|
|
54
57
|
coveragePagesScanned: z.number().int().min(0),
|
|
55
58
|
coverageBudgetExceeded: z.boolean(),
|
|
56
59
|
coverageWarning: z
|
|
@@ -59,4 +62,5 @@ export const GapAnalysisSchema = z.object({
|
|
|
59
62
|
gaps: z.array(GapSchema),
|
|
60
63
|
scenarios: z.array(NeutralScenarioSchema),
|
|
61
64
|
generatedTests: z.array(GeneratedTestSchema),
|
|
65
|
+
costIntelligence: CostIntelligenceSchema.optional(),
|
|
62
66
|
});
|
package/dist/schemas/index.d.ts
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
|
-
export { HarnessConfigSchema, 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';
|
|
1
|
+
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
2
|
export { DecisionLogEntrySchema, type DecisionLogEntry, } from './decision-log.schema.js';
|
|
3
3
|
export { RouteInventorySchema, RouteSchema, A11yViolationSchema, BrokenLinkSchema, type RouteInventory, type Route, } from './route-inventory.schema.js';
|
|
4
4
|
export { GapAnalysisSchema, GapSchema, NeutralScenarioSchema, GeneratedTestSchema, TestStepSchema, FrameworkRecommendationSchema, type GapAnalysis, type Gap, type NeutralScenario, type GeneratedTest, type TestStep, type FrameworkRecommendation, } from './gap-analysis.schema.js';
|
|
5
|
+
export { CostIntelligenceSchema, LlmUsageRecordSchema, LlmDataQualitySchema, LlmOperationTypeSchema, RepeatedAiPatternSchema, DeterministicMaturitySchema, type CostIntelligence, type LlmUsageRecord, type LlmDataQuality, type LlmOperationType, type RepeatedAiPattern, type DeterministicMaturity, } from './cost-intelligence.schema.js';
|
|
5
6
|
export { RepoAnalysisSchema, type RepoAnalysis, } from './repo-analysis.schema.js';
|
|
7
|
+
export { PublicSurfaceSchema, PublicSurfaceViolationSchema, PublicSurfaceBrokenLinkSchema, type PublicSurface, type PublicSurfaceViolation, type PublicSurfaceBrokenLink, } from './public-surface.schema.js';
|
|
6
8
|
//# 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,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,kBAAkB,EAClB,KAAK,YAAY,GAClB,MAAM,2BAA2B,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts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C7B,MAAM,4BAA4B,CAAC"}
|
package/dist/schemas/index.js
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
|
-
export { HarnessConfigSchema, AuthConfigSchema, DetectedAuthSchema, AuthPathRequirementsSchema, AuthPathSchema, AuthExplorationSchema, } from './config.schema.js';
|
|
1
|
+
export { HarnessConfigSchema, resolveMaxOutputTokensPerLlmCall, AuthConfigSchema, DetectedAuthSchema, AuthPathRequirementsSchema, AuthPathSchema, AuthExplorationSchema, } from './config.schema.js';
|
|
2
2
|
export { DecisionLogEntrySchema, } from './decision-log.schema.js';
|
|
3
3
|
export { RouteInventorySchema, RouteSchema, A11yViolationSchema, BrokenLinkSchema, } from './route-inventory.schema.js';
|
|
4
4
|
export { GapAnalysisSchema, GapSchema, NeutralScenarioSchema, GeneratedTestSchema, TestStepSchema, FrameworkRecommendationSchema, } from './gap-analysis.schema.js';
|
|
5
|
+
export { CostIntelligenceSchema, LlmUsageRecordSchema, LlmDataQualitySchema, LlmOperationTypeSchema, RepeatedAiPatternSchema, DeterministicMaturitySchema, } from './cost-intelligence.schema.js';
|
|
5
6
|
export { RepoAnalysisSchema, } from './repo-analysis.schema.js';
|
|
7
|
+
export { PublicSurfaceSchema, PublicSurfaceViolationSchema, PublicSurfaceBrokenLinkSchema, } from './public-surface.schema.js';
|