@uluops/ops-sdk 3.3.0 → 4.0.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/CHANGELOG.md +161 -0
- package/README.md +76 -14
- package/dist/client.d.ts +76 -0
- package/dist/client.d.ts.map +1 -1
- package/dist/client.js +76 -0
- package/dist/client.js.map +1 -1
- package/dist/config/constants.d.ts +1 -1
- package/dist/config/generated-version.d.ts +1 -1
- package/dist/config/generated-version.js +1 -1
- package/dist/config/loaders.d.ts +30 -4
- package/dist/config/loaders.d.ts.map +1 -1
- package/dist/config/loaders.js +34 -4
- package/dist/config/loaders.js.map +1 -1
- package/dist/config/validators.d.ts +3 -0
- package/dist/config/validators.d.ts.map +1 -1
- package/dist/config/validators.js +8 -0
- package/dist/config/validators.js.map +1 -1
- package/dist/errors/errors.d.ts +7 -1
- package/dist/errors/errors.d.ts.map +1 -1
- package/dist/errors/errors.js +7 -1
- package/dist/errors/errors.js.map +1 -1
- package/dist/http/http-client.d.ts +10 -0
- package/dist/http/http-client.d.ts.map +1 -1
- package/dist/http/http-client.js +12 -1
- package/dist/http/http-client.js.map +1 -1
- package/dist/operations/analytics.d.ts +1 -1
- package/dist/operations/analytics.js +1 -1
- package/dist/operations/query-utils.d.ts +10 -0
- package/dist/operations/query-utils.d.ts.map +1 -1
- package/dist/operations/query-utils.js +10 -0
- package/dist/operations/query-utils.js.map +1 -1
- package/dist/operations/runs.d.ts +2 -1
- package/dist/operations/runs.d.ts.map +1 -1
- package/dist/operations/runs.js +2 -1
- package/dist/operations/runs.js.map +1 -1
- package/dist/types/analytics.d.ts +61 -328
- package/dist/types/analytics.d.ts.map +1 -1
- package/dist/types/response-schemas.d.ts +30 -30
- package/dist/types/response-schemas.d.ts.map +1 -1
- package/dist/types/response-schemas.js +56 -60
- package/dist/types/response-schemas.js.map +1 -1
- package/dist/utils/helpers.d.ts +2 -9
- package/dist/utils/helpers.d.ts.map +1 -1
- package/dist/utils/helpers.js +2 -13
- package/dist/utils/helpers.js.map +1 -1
- package/package.json +3 -1
|
@@ -145,7 +145,7 @@ export declare function isValidMetric(metric: string): metric is AnalyticsMetric
|
|
|
145
145
|
* @param metric - One of: agent_performance, resolution_rates, cross_project_patterns, file_hotspots, regression_analysis, trend_summary, cost_analysis, taxonomy_distribution
|
|
146
146
|
* @param query - Optional: project, days
|
|
147
147
|
* @returns Unvalidated response data
|
|
148
|
-
* @throws {
|
|
148
|
+
* @throws {InputValidationError} If metric is not in ANALYTICS_METRICS
|
|
149
149
|
*/
|
|
150
150
|
export declare function getByMetric(client: OpsHttpClient, metric: AnalyticsMetric, query?: AnalyticsQuery): Promise<unknown>;
|
|
151
151
|
//# sourceMappingURL=analytics.d.ts.map
|
|
@@ -187,7 +187,7 @@ export function isValidMetric(metric) {
|
|
|
187
187
|
* @param metric - One of: agent_performance, resolution_rates, cross_project_patterns, file_hotspots, regression_analysis, trend_summary, cost_analysis, taxonomy_distribution
|
|
188
188
|
* @param query - Optional: project, days
|
|
189
189
|
* @returns Unvalidated response data
|
|
190
|
-
* @throws {
|
|
190
|
+
* @throws {InputValidationError} If metric is not in ANALYTICS_METRICS
|
|
191
191
|
*/
|
|
192
192
|
export async function getByMetric(client, metric, query) {
|
|
193
193
|
if (!isValidMetric(metric)) {
|
|
@@ -16,6 +16,16 @@ interface IssueListQuery {
|
|
|
16
16
|
dateStart?: string;
|
|
17
17
|
dateEnd?: string;
|
|
18
18
|
}
|
|
19
|
+
/**
|
|
20
|
+
* Build snake_case API query params from an issue-list filter object.
|
|
21
|
+
* Shared by `issues.listByProject` and `projects.listIssues`.
|
|
22
|
+
*
|
|
23
|
+
* @param query - Optional camelCase filters (status, priority, severity, agent,
|
|
24
|
+
* pagination, date range). Keys are converted to snake_case; `undefined`/empty
|
|
25
|
+
* inputs yield `undefined` so the caller omits the query string entirely.
|
|
26
|
+
* @returns {@link QueryParams} ready for the request layer, or `undefined` when
|
|
27
|
+
* no filters are present.
|
|
28
|
+
*/
|
|
19
29
|
export declare function buildIssueListParams(query?: IssueListQuery): QueryParams | undefined;
|
|
20
30
|
export {};
|
|
21
31
|
//# sourceMappingURL=query-utils.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"query-utils.d.ts","sourceRoot":"","sources":["../../src/operations/query-utils.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAGH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,wBAAwB,CAAC;AAE1D,UAAU,cAAc;IACtB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,wBAAgB,oBAAoB,CAAC,KAAK,CAAC,EAAE,cAAc,GAAG,WAAW,GAAG,SAAS,CAGpF"}
|
|
1
|
+
{"version":3,"file":"query-utils.d.ts","sourceRoot":"","sources":["../../src/operations/query-utils.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAGH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,wBAAwB,CAAC;AAE1D,UAAU,cAAc;IACtB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED;;;;;;;;;GASG;AACH,wBAAgB,oBAAoB,CAAC,KAAK,CAAC,EAAE,cAAc,GAAG,WAAW,GAAG,SAAS,CAGpF"}
|
|
@@ -3,6 +3,16 @@
|
|
|
3
3
|
* Used by both issues.listByProject and projects.listIssues.
|
|
4
4
|
*/
|
|
5
5
|
import { toApiQuery } from '../http/http-client.js';
|
|
6
|
+
/**
|
|
7
|
+
* Build snake_case API query params from an issue-list filter object.
|
|
8
|
+
* Shared by `issues.listByProject` and `projects.listIssues`.
|
|
9
|
+
*
|
|
10
|
+
* @param query - Optional camelCase filters (status, priority, severity, agent,
|
|
11
|
+
* pagination, date range). Keys are converted to snake_case; `undefined`/empty
|
|
12
|
+
* inputs yield `undefined` so the caller omits the query string entirely.
|
|
13
|
+
* @returns {@link QueryParams} ready for the request layer, or `undefined` when
|
|
14
|
+
* no filters are present.
|
|
15
|
+
*/
|
|
6
16
|
export function buildIssueListParams(query) {
|
|
7
17
|
if (!query)
|
|
8
18
|
return undefined;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"query-utils.js","sourceRoot":"","sources":["../../src/operations/query-utils.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAC;AAiBpD,MAAM,UAAU,oBAAoB,CAAC,KAAsB;IACzD,IAAI,CAAC,KAAK;QAAE,OAAO,SAAS,CAAC;IAC7B,OAAO,UAAU,CAAC,KAAK,CAAC,CAAC;AAC3B,CAAC"}
|
|
1
|
+
{"version":3,"file":"query-utils.js","sourceRoot":"","sources":["../../src/operations/query-utils.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAC;AAiBpD;;;;;;;;;GASG;AACH,MAAM,UAAU,oBAAoB,CAAC,KAAsB;IACzD,IAAI,CAAC,KAAK;QAAE,OAAO,SAAS,CAAC;IAC7B,OAAO,UAAU,CAAC,KAAK,CAAC,CAAC;AAC3B,CAAC"}
|
|
@@ -40,8 +40,9 @@ export declare function save(client: OpsHttpClient, input: SaveRunInput, options
|
|
|
40
40
|
* project: 'my-project',
|
|
41
41
|
* workflowType: 'post-implementation',
|
|
42
42
|
* agents: [{ name: 'code-validator', score: 85, decision: 'PASS' }],
|
|
43
|
+
* recommendations: [],
|
|
43
44
|
* });
|
|
44
|
-
* console.log(preview.
|
|
45
|
+
* console.log(preview.wouldCreate, preview.wouldUpdate, preview.wouldRegress); // e.g. 3 1 0
|
|
45
46
|
* ```
|
|
46
47
|
*/
|
|
47
48
|
export declare function validate(client: OpsHttpClient, input: SaveRunInput, options?: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"runs.d.ts","sourceRoot":"","sources":["../../src/operations/runs.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAE5D,OAAO,KAAK,EACV,GAAG,EACH,YAAY,EACZ,eAAe,EACf,mBAAmB,EACnB,YAAY,EACZ,aAAa,EACb,gBAAgB,EAChB,iBAAiB,EACjB,cAAc,EACd,sBAAsB,EACtB,aAAa,EACb,UAAU,EACV,oBAAoB,EACpB,oBAAoB,EACpB,sBAAsB,EACvB,MAAM,kBAAkB,CAAC;AAC1B,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAC;AAC1D,OAAO,EAEL,wBAAwB,EAOxB,yBAAyB,EACzB,iCAAiC,EACjC,iCAAiC,EACjC,+BAA+B,EAChC,MAAM,8BAA8B,CAAC;AAOtC;;;;;;;;;;;;;;;;;;;GAmBG;AAKH,wBAAsB,IAAI,CACxB,MAAM,EAAE,aAAa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H,wBAAsB,SAAS,CAC7B,MAAM,EAAE,aAAa,EACrB,KAAK,EAAE,MAAM,GACZ,OAAO,CAAC,YAAY,CAAC,CAEvB;AAMD;;;;;;;GAOG;AACH,wBAAsB,WAAW,CAC/B,MAAM,EAAE,aAAa,EACrB,KAAK,EAAE,MAAM,GACZ,OAAO,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,yBAAyB,CAAC,CAAC,CAEpD;AAED;;;;;;;;GAQG;AACH,wBAAsB,kBAAkB,CACtC,MAAM,EAAE,aAAa,EACrB,SAAS,EAAE,MAAM,EACjB,KAAK,CAAC,EAAE,oBAAoB,GAC3B,OAAO,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,iCAAiC,CAAC,CAAC,CAU5D;AAED;;;;;;;GAOG;AACH,wBAAsB,oBAAoB,CACxC,MAAM,EAAE,aAAa,EACrB,KAAK,CAAC,EAAE,oBAAoB,GAC3B,OAAO,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,iCAAiC,CAAC,CAAC,CAQ5D;AAED;;;;;;;;;GASG;AACH,wBAAsB,oBAAoB,CACxC,MAAM,EAAE,aAAa,EACrB,SAAS,EAAE,MAAM,EACjB,KAAK,EAAE,sBAAsB,GAC5B,OAAO,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,+BAA+B,CAAC,CAAC,CAK1D"}
|
package/dist/operations/runs.js
CHANGED
|
@@ -65,8 +65,9 @@ export async function save(client, input, options) {
|
|
|
65
65
|
* project: 'my-project',
|
|
66
66
|
* workflowType: 'post-implementation',
|
|
67
67
|
* agents: [{ name: 'code-validator', score: 85, decision: 'PASS' }],
|
|
68
|
+
* recommendations: [],
|
|
68
69
|
* });
|
|
69
|
-
* console.log(preview.
|
|
70
|
+
* console.log(preview.wouldCreate, preview.wouldUpdate, preview.wouldRegress); // e.g. 3 1 0
|
|
70
71
|
* ```
|
|
71
72
|
*/
|
|
72
73
|
export async function validate(client, input, options) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
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BAAyB,CAAC,KAAK,CAAC,MAAM,MAAM,CAAC,GAAG,CAAU,SAAS,kBAAkB,CAAC,KAAK,CAAC,WAAW,EAAE,SAAS,CAAC,CAAC,CAAC;AAC9H,CAAC;AAED;;;;;;;;GAQG;AACH,MAAM,CAAC,KAAK,UAAU,kBAAkB,CACtC,MAAqB,EACrB,SAAiB,EACjB,KAA4B;IAE5B,uEAAuE;IACvE,uEAAuE;IACvE,4EAA4E;IAC5E,OAAO,iCAAiC,CAAC,KAAK,CAAC,MAAM,MAAM,CAAC,OAAO,CACjE,KAAK,EACL,aAAa,kBAAkB,CAAC,SAAS,CAAC,WAAW,EACrD,UAAU,CAAC,KAAK,CAAC,EACjB,EAAE,WAAW,EAAE,IAAI,EAAE,CACtB,CAAC,CAAC;AACL,CAAC;AAED;;;;;;;GAOG;AACH,MAAM,CAAC,KAAK,UAAU,oBAAoB,CACxC,MAAqB,EACrB,KAA4B;IAE5B,uEAAuE;IACvE,OAAO,iCAAiC,CAAC,KAAK,CAAC,MAAM,MAAM,CAAC,OAAO,CACjE,KAAK,EACL,mBAAmB,EACnB,UAAU,CAAC,KAAK,CAAC,EACjB,EAAE,WAAW,EAAE,IAAI,EAAE,CACtB,CAAC,CAAC;AACL,CAAC;AAED;;;;;;;;;GASG;AACH,MAAM,CAAC,KAAK,UAAU,oBAAoB,CACxC,MAAqB,EACrB,SAAiB,EACjB,KAA6B;IAE7B,OAAO,+BAA+B,CAAC,KAAK,CAAC,MAAM,MAAM,CAAC,GAAG,CAC3D,WAAW,kBAAkB,CAAC,SAAS,CAAC,gBAAgB,EACxD,UAAU,CAAC,KAAK,CAAC,CAClB,CAAC,CAAC;AACL,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { z } from 'zod';
|
|
2
|
-
import type { AgentPerformanceResponseSchema, AgentReliabilityResultResponseSchema, ResolutionRateResponseSchema, FileHotspotResponseSchema, TaxonomyDistributionResponseSchema,
|
|
3
|
-
import type {
|
|
2
|
+
import type { AgentPerformanceResponseSchema, AgentLifecycleEntryResponseSchema, AgentReliabilityResponseSchema, AgentReliabilityResultResponseSchema, ResolutionRateResponseSchema, FileHotspotResponseSchema, TaxonomyDistributionResponseSchema, OutlierPointResponseSchema, ResidualDiagnosticsResponseSchema, DomainTrendResponseSchema, BurndownDataPointResponseSchema, BurndownResultResponseSchema, VelocityItemResponseSchema, VelocitySummaryResponseSchema, VelocityResultResponseSchema, DiscoveryDomainBreakdownSchema, DiscoveryTimelinePointResponseSchema, DiscoverySummaryResponseSchema, DiscoveryResultResponseSchema, AgentMatrixRowResponseSchema, BlindSpotResponseSchema, SinglePointFailureResponseSchema, HighOverlapResponseSchema, MatrixAnalysisResponseSchema, AgentMatrixResultResponseSchema, TrendSummaryResponseSchema, PeriodResponseSchema, FullTaxonomyAnalyticsResponseSchema } from './response-schemas.js';
|
|
3
|
+
import type { Granularity, DiscoveryGroupBy } from './enums.js';
|
|
4
4
|
/**
|
|
5
5
|
* Common query options for analytics endpoints
|
|
6
6
|
*/
|
|
@@ -9,16 +9,12 @@ export interface AnalyticsQuery {
|
|
|
9
9
|
days?: number;
|
|
10
10
|
limit?: number;
|
|
11
11
|
}
|
|
12
|
+
/** Time period metadata — derived from `PeriodResponseSchema`. */
|
|
13
|
+
export type Period = z.infer<typeof PeriodResponseSchema>;
|
|
12
14
|
/**
|
|
13
|
-
*
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
start: string;
|
|
17
|
-
end: string;
|
|
18
|
-
days: number;
|
|
19
|
-
}
|
|
20
|
-
/**
|
|
21
|
-
* Simplified agent info (from performance data).
|
|
15
|
+
* Simplified agent info — a client-side projection built by `listAgents` from
|
|
16
|
+
* agent performance data. No API endpoint returns this shape directly, so it
|
|
17
|
+
* has no response schema.
|
|
22
18
|
* @see {@link AgentInput} in runs.ts for the full agent projection map.
|
|
23
19
|
*/
|
|
24
20
|
export interface AgentInfo {
|
|
@@ -27,32 +23,12 @@ export interface AgentInfo {
|
|
|
27
23
|
averageScore: number;
|
|
28
24
|
passRate: number;
|
|
29
25
|
}
|
|
30
|
-
/**
|
|
31
|
-
* Agent performance metrics — derived from AgentPerformanceResponseSchema
|
|
32
|
-
*/
|
|
26
|
+
/** Agent performance metrics — derived from `AgentPerformanceResponseSchema`. */
|
|
33
27
|
export type AgentPerformance = z.infer<typeof AgentPerformanceResponseSchema>;
|
|
34
|
-
/**
|
|
35
|
-
|
|
36
|
-
*/
|
|
37
|
-
export
|
|
38
|
-
name: string;
|
|
39
|
-
definitionVersion: string;
|
|
40
|
-
firstSeenAt: string;
|
|
41
|
-
runs: number;
|
|
42
|
-
avgScore: number;
|
|
43
|
-
passRate: number;
|
|
44
|
-
}
|
|
45
|
-
/**
|
|
46
|
-
* Agent reliability stats
|
|
47
|
-
*/
|
|
48
|
-
export interface AgentReliability {
|
|
49
|
-
name: string;
|
|
50
|
-
totalIssues: number;
|
|
51
|
-
falsePositiveRate: number;
|
|
52
|
-
resolutionRate: number;
|
|
53
|
-
avgTimeToResolveDays: number | null;
|
|
54
|
-
reliabilityScore: number;
|
|
55
|
-
}
|
|
28
|
+
/** Agent lifecycle entry (version trajectory across time) — derived from `AgentLifecycleEntryResponseSchema`. */
|
|
29
|
+
export type AgentLifecycleEntry = z.infer<typeof AgentLifecycleEntryResponseSchema>;
|
|
30
|
+
/** Agent reliability stats (per-agent element) — derived from `AgentReliabilityResponseSchema`. */
|
|
31
|
+
export type AgentReliability = z.infer<typeof AgentReliabilityResponseSchema>;
|
|
56
32
|
/**
|
|
57
33
|
* Agent reliability query options
|
|
58
34
|
*/
|
|
@@ -61,220 +37,60 @@ export interface AgentReliabilityQuery {
|
|
|
61
37
|
project?: string;
|
|
62
38
|
days?: number;
|
|
63
39
|
}
|
|
40
|
+
/** Project resolution rate — derived from `ResolutionRateResponseSchema`. */
|
|
41
|
+
export type ResolutionRate = z.infer<typeof ResolutionRateResponseSchema>;
|
|
42
|
+
/** File hotspot (files with the most issues) — derived from `FileHotspotResponseSchema`. */
|
|
43
|
+
export type FileHotspot = z.infer<typeof FileHotspotResponseSchema>;
|
|
44
|
+
/** Basic taxonomy distribution — derived from `TaxonomyDistributionResponseSchema`. */
|
|
45
|
+
export type TaxonomyDistribution = z.infer<typeof TaxonomyDistributionResponseSchema>;
|
|
64
46
|
/**
|
|
65
|
-
*
|
|
66
|
-
|
|
67
|
-
export interface ResolutionRate {
|
|
68
|
-
project: string;
|
|
69
|
-
totalIssues: number;
|
|
70
|
-
resolvedIssues: number;
|
|
71
|
-
resolutionRate: number;
|
|
72
|
-
avgTimeToResolveDays: number | null;
|
|
73
|
-
}
|
|
74
|
-
/**
|
|
75
|
-
* File hotspot (files with most issues)
|
|
76
|
-
*/
|
|
77
|
-
export interface FileHotspot {
|
|
78
|
-
filePath: string;
|
|
79
|
-
issueCount: number;
|
|
80
|
-
projects: string[];
|
|
81
|
-
}
|
|
82
|
-
/**
|
|
83
|
-
* Basic taxonomy distribution
|
|
84
|
-
*/
|
|
85
|
-
export interface TaxonomyDistribution {
|
|
86
|
-
domain: FailureDomain;
|
|
87
|
-
mode: string;
|
|
88
|
-
count: number;
|
|
89
|
-
percentage: number;
|
|
90
|
-
}
|
|
91
|
-
/**
|
|
92
|
-
* Full taxonomy analytics (all aggregations from /analytics/taxonomy/full)
|
|
47
|
+
* Full taxonomy analytics (all aggregations from `/analytics/taxonomy/full`).
|
|
48
|
+
* Derived from `FullTaxonomyAnalyticsResponseSchema`.
|
|
93
49
|
*
|
|
94
|
-
* Note: The SDK HttpClient auto-unwraps the API's `{ data }` envelope,
|
|
95
|
-
*
|
|
50
|
+
* Note: The SDK HttpClient auto-unwraps the API's `{ data }` envelope, so this
|
|
51
|
+
* type represents the unwrapped content, not the raw API response.
|
|
96
52
|
*/
|
|
97
|
-
export
|
|
98
|
-
byDomain: Array<{
|
|
99
|
-
domain: FailureDomain;
|
|
100
|
-
label: string;
|
|
101
|
-
count: number;
|
|
102
|
-
percentage: number;
|
|
103
|
-
}>;
|
|
104
|
-
bySeverity: Array<{
|
|
105
|
-
severity: string;
|
|
106
|
-
label: string;
|
|
107
|
-
count: number;
|
|
108
|
-
percentage: number;
|
|
109
|
-
}>;
|
|
110
|
-
byMode: Array<{
|
|
111
|
-
mode: string;
|
|
112
|
-
label: string;
|
|
113
|
-
domain: FailureDomain;
|
|
114
|
-
domainLabel: string;
|
|
115
|
-
count: number;
|
|
116
|
-
percentage: number;
|
|
117
|
-
}>;
|
|
118
|
-
topCodes: Array<{
|
|
119
|
-
code: string;
|
|
120
|
-
domain: string;
|
|
121
|
-
mode: string;
|
|
122
|
-
severity: string;
|
|
123
|
-
label: string;
|
|
124
|
-
count: number;
|
|
125
|
-
percentage: number;
|
|
126
|
-
}>;
|
|
127
|
-
heatmapData: Array<{
|
|
128
|
-
domain: string;
|
|
129
|
-
domainLabel: string;
|
|
130
|
-
mode: string;
|
|
131
|
-
modeLabel: string;
|
|
132
|
-
count: number;
|
|
133
|
-
percentage: number;
|
|
134
|
-
intensity: number;
|
|
135
|
-
}>;
|
|
136
|
-
totals: {
|
|
137
|
-
totalIssues: number;
|
|
138
|
-
classifiedIssues: number;
|
|
139
|
-
unclassifiedIssues: number;
|
|
140
|
-
classificationRate: number;
|
|
141
|
-
};
|
|
142
|
-
period: Period;
|
|
143
|
-
}
|
|
53
|
+
export type FullTaxonomyAnalytics = z.infer<typeof FullTaxonomyAnalyticsResponseSchema>;
|
|
144
54
|
/**
|
|
145
|
-
* Burndown time
|
|
55
|
+
* Burndown time-series data point — derived from `BurndownDataPointResponseSchema`.
|
|
146
56
|
* Domain fields are dynamic — includes well-known domains (STR, SEM, PRA, EPI)
|
|
147
57
|
* plus any server-defined domains.
|
|
148
58
|
*/
|
|
149
|
-
export
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
/**
|
|
155
|
-
|
|
156
|
-
*/
|
|
157
|
-
export
|
|
158
|
-
date: string;
|
|
159
|
-
value: number;
|
|
160
|
-
direction: 'high' | 'low';
|
|
161
|
-
}
|
|
162
|
-
/**
|
|
163
|
-
* Residual diagnostics for trend reliability
|
|
164
|
-
*/
|
|
165
|
-
export interface ResidualDiagnostics {
|
|
166
|
-
durbinWatson: number;
|
|
167
|
-
autocorrelation: 'none' | 'positive' | 'negative' | 'inconclusive';
|
|
168
|
-
varianceRatio: number | null;
|
|
169
|
-
heteroscedasticity: 'constant' | 'increasing' | 'decreasing' | 'inconclusive';
|
|
170
|
-
skewness: number;
|
|
171
|
-
runsTestZ: number;
|
|
172
|
-
assumptionScore: number;
|
|
173
|
-
warnings: string[];
|
|
174
|
-
}
|
|
175
|
-
/**
|
|
176
|
-
* Domain trend analysis
|
|
177
|
-
*/
|
|
178
|
-
export interface DomainTrend {
|
|
179
|
-
netChange: number;
|
|
180
|
-
trend: Trend;
|
|
181
|
-
avgDailyChange: number;
|
|
182
|
-
confidence: 'high' | 'medium' | 'low';
|
|
183
|
-
sampleSize: number;
|
|
184
|
-
rSquared: number;
|
|
185
|
-
standardError: number;
|
|
186
|
-
confidenceInterval: [number, number];
|
|
187
|
-
outliers: OutlierPoint[];
|
|
188
|
-
diagnostics: ResidualDiagnostics | null;
|
|
189
|
-
ciReliable: boolean;
|
|
190
|
-
warnings: string[];
|
|
191
|
-
weeklyPatternDetected: boolean;
|
|
192
|
-
}
|
|
193
|
-
/**
|
|
194
|
-
* Burndown result
|
|
195
|
-
*/
|
|
196
|
-
export interface BurndownResult {
|
|
197
|
-
timeSeries: BurndownDataPoint[];
|
|
198
|
-
trends: Record<string, DomainTrend>;
|
|
199
|
-
}
|
|
59
|
+
export type BurndownDataPoint = z.infer<typeof BurndownDataPointResponseSchema>;
|
|
60
|
+
/** Outlier detection result — derived from `OutlierPointResponseSchema`. */
|
|
61
|
+
export type OutlierPoint = z.infer<typeof OutlierPointResponseSchema>;
|
|
62
|
+
/** Residual diagnostics for trend reliability — derived from `ResidualDiagnosticsResponseSchema`. */
|
|
63
|
+
export type ResidualDiagnostics = z.infer<typeof ResidualDiagnosticsResponseSchema>;
|
|
64
|
+
/** Domain trend analysis — derived from `DomainTrendResponseSchema`. */
|
|
65
|
+
export type DomainTrend = z.infer<typeof DomainTrendResponseSchema>;
|
|
66
|
+
/** Burndown result — derived from `BurndownResultResponseSchema`. */
|
|
67
|
+
export type BurndownResult = z.infer<typeof BurndownResultResponseSchema>;
|
|
200
68
|
/**
|
|
201
69
|
* Burndown query options
|
|
202
70
|
*/
|
|
203
71
|
export interface BurndownQuery extends AnalyticsQuery {
|
|
204
72
|
granularity?: Granularity;
|
|
205
73
|
}
|
|
206
|
-
/**
|
|
207
|
-
|
|
208
|
-
*/
|
|
209
|
-
export
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
failureCode: string;
|
|
213
|
-
currentCount: number;
|
|
214
|
-
previousCount: number;
|
|
215
|
-
velocityPercent: number;
|
|
216
|
-
alert: boolean;
|
|
217
|
-
sparkline: number[];
|
|
218
|
-
trendReliability: 'high' | 'medium' | 'low';
|
|
219
|
-
}
|
|
220
|
-
/**
|
|
221
|
-
* Velocity summary
|
|
222
|
-
*/
|
|
223
|
-
export interface VelocitySummary {
|
|
224
|
-
improving: string[];
|
|
225
|
-
stable: string[];
|
|
226
|
-
degrading: string[];
|
|
227
|
-
mostImproved: string | null;
|
|
228
|
-
mostConcerning: string | null;
|
|
229
|
-
}
|
|
230
|
-
/**
|
|
231
|
-
* Velocity result
|
|
232
|
-
*/
|
|
233
|
-
export interface VelocityResult {
|
|
234
|
-
items: VelocityItem[];
|
|
235
|
-
summary: VelocitySummary;
|
|
236
|
-
}
|
|
74
|
+
/** Velocity item (rate of change per failure mode) — derived from `VelocityItemResponseSchema`. */
|
|
75
|
+
export type VelocityItem = z.infer<typeof VelocityItemResponseSchema>;
|
|
76
|
+
/** Velocity summary — derived from `VelocitySummaryResponseSchema`. */
|
|
77
|
+
export type VelocitySummary = z.infer<typeof VelocitySummaryResponseSchema>;
|
|
78
|
+
/** Velocity result — derived from `VelocityResultResponseSchema`. */
|
|
79
|
+
export type VelocityResult = z.infer<typeof VelocityResultResponseSchema>;
|
|
237
80
|
/**
|
|
238
81
|
* Velocity query options
|
|
239
82
|
*/
|
|
240
83
|
export interface VelocityQuery extends AnalyticsQuery {
|
|
241
84
|
alertThreshold?: number;
|
|
242
85
|
}
|
|
243
|
-
/**
|
|
244
|
-
|
|
245
|
-
*/
|
|
246
|
-
export
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
* Discovery timeline point
|
|
252
|
-
*/
|
|
253
|
-
export interface DiscoveryTimelinePoint {
|
|
254
|
-
period: string;
|
|
255
|
-
newIssues: number;
|
|
256
|
-
recurringIssues: number;
|
|
257
|
-
domains: Record<FailureDomain, DiscoveryDomainBreakdown>;
|
|
258
|
-
}
|
|
259
|
-
/**
|
|
260
|
-
* Discovery summary
|
|
261
|
-
*/
|
|
262
|
-
export interface DiscoverySummary {
|
|
263
|
-
totalNew: number;
|
|
264
|
-
totalRecurring: number;
|
|
265
|
-
newToRecurringRatio: number | null;
|
|
266
|
-
peakNewPeriod: {
|
|
267
|
-
period: string;
|
|
268
|
-
count: number;
|
|
269
|
-
} | null;
|
|
270
|
-
}
|
|
271
|
-
/**
|
|
272
|
-
* Discovery result
|
|
273
|
-
*/
|
|
274
|
-
export interface DiscoveryResult {
|
|
275
|
-
timeline: DiscoveryTimelinePoint[];
|
|
276
|
-
summary: DiscoverySummary;
|
|
277
|
-
}
|
|
86
|
+
/** Domain breakdown for discovery — derived from `DiscoveryDomainBreakdownSchema`. */
|
|
87
|
+
export type DiscoveryDomainBreakdown = z.infer<typeof DiscoveryDomainBreakdownSchema>;
|
|
88
|
+
/** Discovery timeline point — derived from `DiscoveryTimelinePointResponseSchema`. */
|
|
89
|
+
export type DiscoveryTimelinePoint = z.infer<typeof DiscoveryTimelinePointResponseSchema>;
|
|
90
|
+
/** Discovery summary — derived from `DiscoverySummaryResponseSchema`. */
|
|
91
|
+
export type DiscoverySummary = z.infer<typeof DiscoverySummaryResponseSchema>;
|
|
92
|
+
/** Discovery result — derived from `DiscoveryResultResponseSchema`. */
|
|
93
|
+
export type DiscoveryResult = z.infer<typeof DiscoveryResultResponseSchema>;
|
|
278
94
|
/**
|
|
279
95
|
* Discovery query options
|
|
280
96
|
*/
|
|
@@ -283,111 +99,28 @@ export interface DiscoveryQuery extends AnalyticsQuery {
|
|
|
283
99
|
}
|
|
284
100
|
/**
|
|
285
101
|
* Agent matrix row — coverage vector across failure domains.
|
|
102
|
+
* Derived from `AgentMatrixRowResponseSchema`.
|
|
286
103
|
* @see {@link AgentInput} in runs.ts for the full agent projection map.
|
|
287
104
|
*/
|
|
288
|
-
export
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
/**
|
|
296
|
-
|
|
297
|
-
*/
|
|
298
|
-
export
|
|
299
|
-
agent: string;
|
|
300
|
-
missingDomains: FailureDomain[];
|
|
301
|
-
}
|
|
302
|
-
/**
|
|
303
|
-
* Single point of failure (only one agent detects)
|
|
304
|
-
*/
|
|
305
|
-
export interface SinglePointFailure {
|
|
306
|
-
domain: FailureDomain;
|
|
307
|
-
mode: string;
|
|
308
|
-
onlyAgent: string;
|
|
309
|
-
}
|
|
310
|
-
/**
|
|
311
|
-
* High overlap (multiple agents detect same thing)
|
|
312
|
-
*/
|
|
313
|
-
export interface HighOverlap {
|
|
314
|
-
mode: string;
|
|
315
|
-
agentCount: number;
|
|
316
|
-
agents: string[];
|
|
317
|
-
}
|
|
318
|
-
/**
|
|
319
|
-
* Matrix coverage analysis
|
|
320
|
-
*/
|
|
321
|
-
export interface MatrixAnalysis {
|
|
322
|
-
blindSpots: BlindSpot[];
|
|
323
|
-
singlePoints: SinglePointFailure[];
|
|
324
|
-
highOverlap: HighOverlap[];
|
|
325
|
-
}
|
|
326
|
-
/**
|
|
327
|
-
* Agent matrix result
|
|
328
|
-
*/
|
|
329
|
-
export interface AgentMatrixResult {
|
|
330
|
-
matrix: AgentMatrixRow[];
|
|
331
|
-
analysis: MatrixAnalysis;
|
|
332
|
-
}
|
|
105
|
+
export type AgentMatrixRow = z.infer<typeof AgentMatrixRowResponseSchema>;
|
|
106
|
+
/** Blind spot (agent missing domain coverage) — derived from `BlindSpotResponseSchema`. */
|
|
107
|
+
export type BlindSpot = z.infer<typeof BlindSpotResponseSchema>;
|
|
108
|
+
/** Single point of failure (only one agent detects) — derived from `SinglePointFailureResponseSchema`. */
|
|
109
|
+
export type SinglePointFailure = z.infer<typeof SinglePointFailureResponseSchema>;
|
|
110
|
+
/** High overlap (multiple agents detect the same thing) — derived from `HighOverlapResponseSchema`. */
|
|
111
|
+
export type HighOverlap = z.infer<typeof HighOverlapResponseSchema>;
|
|
112
|
+
/** Matrix coverage analysis — derived from `MatrixAnalysisResponseSchema`. */
|
|
113
|
+
export type MatrixAnalysis = z.infer<typeof MatrixAnalysisResponseSchema>;
|
|
114
|
+
/** Agent matrix result — derived from `AgentMatrixResultResponseSchema`. */
|
|
115
|
+
export type AgentMatrixResult = z.infer<typeof AgentMatrixResultResponseSchema>;
|
|
333
116
|
/**
|
|
334
117
|
* Agent matrix query options
|
|
335
118
|
*/
|
|
336
119
|
export interface AgentMatrixQuery extends AnalyticsQuery {
|
|
337
120
|
minIssues?: number;
|
|
338
121
|
}
|
|
339
|
-
/**
|
|
340
|
-
|
|
341
|
-
*/
|
|
342
|
-
export interface TrendSummary {
|
|
343
|
-
period: string;
|
|
344
|
-
newIssues: number;
|
|
345
|
-
resolvedIssues: number;
|
|
346
|
-
regressions: number;
|
|
347
|
-
averageScore: number | null;
|
|
348
|
-
}
|
|
349
|
-
/**
|
|
350
|
-
* Cross-project pattern (shared issues across projects)
|
|
351
|
-
*/
|
|
352
|
-
export interface CrossProjectPattern {
|
|
353
|
-
pattern: string;
|
|
354
|
-
projects: string[];
|
|
355
|
-
projectCount: number;
|
|
356
|
-
totalOccurrences: number;
|
|
357
|
-
severity: string;
|
|
358
|
-
}
|
|
359
|
-
/**
|
|
360
|
-
* Regression analysis entry (issues that regressed after resolution)
|
|
361
|
-
*/
|
|
362
|
-
export interface RegressionEntry {
|
|
363
|
-
issueId: string;
|
|
364
|
-
title: string;
|
|
365
|
-
project: string;
|
|
366
|
-
timesRegressed: number;
|
|
367
|
-
lastRegression: string;
|
|
368
|
-
agent: string;
|
|
369
|
-
}
|
|
370
|
-
/**
|
|
371
|
-
* Cost analysis entry (token usage and cost per agent/project)
|
|
372
|
-
*/
|
|
373
|
-
export interface CostEntry {
|
|
374
|
-
name: string;
|
|
375
|
-
totalRuns: number;
|
|
376
|
-
totalInputTokens: number;
|
|
377
|
-
totalOutputTokens: number;
|
|
378
|
-
totalEffectiveTokens: number;
|
|
379
|
-
estimatedCost: number;
|
|
380
|
-
}
|
|
381
|
-
/**
|
|
382
|
-
* Category performance entry (issue resolution by category)
|
|
383
|
-
*/
|
|
384
|
-
export interface CategoryPerformanceEntry {
|
|
385
|
-
category: string;
|
|
386
|
-
totalIssues: number;
|
|
387
|
-
resolvedIssues: number;
|
|
388
|
-
resolutionRate: number;
|
|
389
|
-
avgTimeToResolveDays: number | null;
|
|
390
|
-
}
|
|
122
|
+
/** Weekly trend summary — one entry per period — derived from `TrendSummaryResponseSchema`. */
|
|
123
|
+
export type TrendSummary = z.infer<typeof TrendSummaryResponseSchema>;
|
|
391
124
|
/** Agent reliability result from `GET /analytics/agent-reliability` */
|
|
392
125
|
export type AgentReliabilityResult = z.infer<typeof AgentReliabilityResultResponseSchema>;
|
|
393
126
|
/** Resolution rate entry from `GET /analytics/resolution-rates` */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"analytics.d.ts","sourceRoot":"","sources":["../../src/types/analytics.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAC7B,OAAO,KAAK,EACV,8BAA8B,EAC9B,oCAAoC,EACpC,4BAA4B,EAC5B,yBAAyB,EACzB,kCAAkC,EAClC,
|
|
1
|
+
{"version":3,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