@intutic/shared-types 0.1.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/.dist/anomaly.d.ts +227 -0
- package/.dist/anomaly.d.ts.map +1 -0
- package/.dist/anomaly.js +35 -0
- package/.dist/anomaly.js.map +1 -0
- package/.dist/api-contracts.d.ts +176 -0
- package/.dist/api-contracts.d.ts.map +1 -0
- package/.dist/api-contracts.js +110 -0
- package/.dist/api-contracts.js.map +1 -0
- package/.dist/auth.d.ts +222 -0
- package/.dist/auth.d.ts.map +1 -0
- package/.dist/auth.js +59 -0
- package/.dist/auth.js.map +1 -0
- package/.dist/enums.d.ts +156 -0
- package/.dist/enums.d.ts.map +1 -0
- package/.dist/enums.js +161 -0
- package/.dist/enums.js.map +1 -0
- package/.dist/errors.d.ts +106 -0
- package/.dist/errors.d.ts.map +1 -0
- package/.dist/errors.js +110 -0
- package/.dist/errors.js.map +1 -0
- package/.dist/finops.d.ts +117 -0
- package/.dist/finops.d.ts.map +1 -0
- package/.dist/finops.js +14 -0
- package/.dist/finops.js.map +1 -0
- package/.dist/identity.d.ts +176 -0
- package/.dist/identity.d.ts.map +1 -0
- package/.dist/identity.js +32 -0
- package/.dist/identity.js.map +1 -0
- package/.dist/index.d.ts +27 -0
- package/.dist/index.d.ts.map +1 -0
- package/.dist/index.js +75 -0
- package/.dist/index.js.map +1 -0
- package/.dist/policy.d.ts +104 -0
- package/.dist/policy.d.ts.map +1 -0
- package/.dist/policy.js +14 -0
- package/.dist/policy.js.map +1 -0
- package/.dist/session.d.ts +62 -0
- package/.dist/session.d.ts.map +1 -0
- package/.dist/session.js +14 -0
- package/.dist/session.js.map +1 -0
- package/.dist/sop.d.ts +329 -0
- package/.dist/sop.d.ts.map +1 -0
- package/.dist/sop.js +44 -0
- package/.dist/sop.js.map +1 -0
- package/.dist/sync.d.ts +204 -0
- package/.dist/sync.d.ts.map +1 -0
- package/.dist/sync.js +45 -0
- package/.dist/sync.js.map +1 -0
- package/package.json +19 -0
|
@@ -0,0 +1,227 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Anomaly detection types for the Anomaly Recognition Engine (ARE).
|
|
3
|
+
*
|
|
4
|
+
* These types support the 12-category runtime anomaly taxonomy,
|
|
5
|
+
* corrective prompt card system, trust scoring, and ARE probe battery.
|
|
6
|
+
*
|
|
7
|
+
* HLD §3.5 (Anomaly Detection), HLD §7.7 (Drift Detector)
|
|
8
|
+
* LLD #5 — Anomaly Detection + ARE
|
|
9
|
+
*
|
|
10
|
+
* @module
|
|
11
|
+
*/
|
|
12
|
+
import type { AnomalyType } from './enums.js';
|
|
13
|
+
/**
|
|
14
|
+
* A detected anomaly event emitted by the ARE pipeline.
|
|
15
|
+
*
|
|
16
|
+
* Anomaly events are evaluated per-trace and may trigger enforcement
|
|
17
|
+
* actions, governance incidents, or corrective prompt injection.
|
|
18
|
+
*
|
|
19
|
+
* HLD §3.5 — 12-category runtime taxonomy
|
|
20
|
+
*/
|
|
21
|
+
export interface AnomalyEvent {
|
|
22
|
+
/** Classification from the 12-category anomaly taxonomy. */
|
|
23
|
+
type: AnomalyType;
|
|
24
|
+
/** Detection confidence score (0.0–1.0). */
|
|
25
|
+
confidence: number;
|
|
26
|
+
/** Optional structured metadata for forensic analysis. */
|
|
27
|
+
metadata?: Record<string, unknown>;
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* Full classification result from the anomaly detector.
|
|
31
|
+
* Includes severity mapping and whether an incident was created.
|
|
32
|
+
*
|
|
33
|
+
* LLD #5 §2.2 — classifyAnomaly() return type
|
|
34
|
+
*/
|
|
35
|
+
export interface AnomalyClassification {
|
|
36
|
+
/** Whether an anomaly was detected. */
|
|
37
|
+
detected: boolean;
|
|
38
|
+
/** Classification from the 12-category taxonomy. Null if not detected. */
|
|
39
|
+
anomalyType: AnomalyType | null;
|
|
40
|
+
/** Detection confidence score (0.0–1.0). */
|
|
41
|
+
confidence: number;
|
|
42
|
+
/** Severity level derived from anomaly type. */
|
|
43
|
+
severity: AnomalySeverity;
|
|
44
|
+
/** Generated corrective prompt card, if applicable. */
|
|
45
|
+
correctiveCard: CorrectivePromptCard | null;
|
|
46
|
+
/** Probe results that contributed to the classification. */
|
|
47
|
+
probeResults: ProbeResult[];
|
|
48
|
+
/** ID of the governance incident created, if severity >= HIGH. */
|
|
49
|
+
incidentId: string | null;
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* Anomaly severity levels, mapped from anomaly type.
|
|
53
|
+
*
|
|
54
|
+
* HLD §3.5 — Alert Route column
|
|
55
|
+
*/
|
|
56
|
+
export type AnomalySeverity = 'CRITICAL' | 'HIGH' | 'MEDIUM' | 'LOW' | 'INFORMATIONAL';
|
|
57
|
+
/**
|
|
58
|
+
* Static mapping from anomaly type to default severity.
|
|
59
|
+
*
|
|
60
|
+
* HLD §3.5 — 12-category table, Alert Route column
|
|
61
|
+
* LLD #5 Appendix B
|
|
62
|
+
*/
|
|
63
|
+
export declare const ANOMALY_SEVERITY_MAP: Record<AnomalyType, AnomalySeverity>;
|
|
64
|
+
/**
|
|
65
|
+
* A corrective prompt card generated in response to an anomaly.
|
|
66
|
+
*
|
|
67
|
+
* Prompt cards contain a remediation prompt, evidence chain, and a
|
|
68
|
+
* link to the SOP that governs the expected behavior. They are injected
|
|
69
|
+
* into the agent context to steer it back on track.
|
|
70
|
+
*
|
|
71
|
+
* HLD §3.5 — Corrective prompt injection
|
|
72
|
+
*/
|
|
73
|
+
export interface CorrectivePromptCard {
|
|
74
|
+
/** The corrective prompt text to inject into agent context. */
|
|
75
|
+
promptText: string;
|
|
76
|
+
/** Confidence that this prompt will resolve the anomaly (0.0–1.0). */
|
|
77
|
+
confidence: number;
|
|
78
|
+
/** Evidence chain supporting the corrective action. */
|
|
79
|
+
sourceEvidence: string[];
|
|
80
|
+
/** SOP ID that defines the expected behavior — `newId('sp')`. */
|
|
81
|
+
sopId: string | null;
|
|
82
|
+
}
|
|
83
|
+
/**
|
|
84
|
+
* ARE probe tier classification.
|
|
85
|
+
*
|
|
86
|
+
* HLD §3.5 — ARE Probe Battery table
|
|
87
|
+
*/
|
|
88
|
+
export type ProbeType = 'PATTERN' | 'SCHEMA' | 'LLM';
|
|
89
|
+
/**
|
|
90
|
+
* Result from an individual ARE probe execution.
|
|
91
|
+
*
|
|
92
|
+
* LLD #5 §2.2 — runProbes() return type
|
|
93
|
+
*/
|
|
94
|
+
export interface ProbeResult {
|
|
95
|
+
/** Probe tier. */
|
|
96
|
+
probeType: ProbeType;
|
|
97
|
+
/** Probe name (e.g., 'WorkspaceHygieneProbe', 'MCPHealthProbe'). */
|
|
98
|
+
probeName: string;
|
|
99
|
+
/** Whether the probe detected an issue. */
|
|
100
|
+
triggered: boolean;
|
|
101
|
+
/** Confidence score if triggered (0.0–1.0). */
|
|
102
|
+
confidence: number;
|
|
103
|
+
/** Whether the probe was skipped (e.g., LLM probe in Phase 1). */
|
|
104
|
+
skipped: boolean;
|
|
105
|
+
/** Reason for skip if applicable. */
|
|
106
|
+
skipReason?: string;
|
|
107
|
+
/** Execution latency in milliseconds. */
|
|
108
|
+
latencyMs: number;
|
|
109
|
+
/** Additional probe-specific details. */
|
|
110
|
+
details?: Record<string, unknown>;
|
|
111
|
+
}
|
|
112
|
+
/**
|
|
113
|
+
* Trust score for a user/agent within a workspace.
|
|
114
|
+
*
|
|
115
|
+
* LLD #5 §4.4 — Trust Score Algorithm
|
|
116
|
+
* Decay: score * 0.85 per anomaly
|
|
117
|
+
* Boost: score * 1.02 per clean session
|
|
118
|
+
* Clamped to [0, 100]. Initial: 80.
|
|
119
|
+
*/
|
|
120
|
+
export interface TrustScoreResult {
|
|
121
|
+
/** Trust score ID — `newId('ts')`. */
|
|
122
|
+
scoreId: string;
|
|
123
|
+
/** Workspace ID. */
|
|
124
|
+
workspaceId: string;
|
|
125
|
+
/** User/agent ID. */
|
|
126
|
+
userId: string;
|
|
127
|
+
/** Current trust score (0–100). */
|
|
128
|
+
currentScore: number;
|
|
129
|
+
/** Total anomaly count. */
|
|
130
|
+
anomalyCount: number;
|
|
131
|
+
/** Total clean sessions. */
|
|
132
|
+
cleanSessions: number;
|
|
133
|
+
/** Timestamp of last anomaly. */
|
|
134
|
+
lastAnomalyAt: string | null;
|
|
135
|
+
/** Timestamp of last boost. */
|
|
136
|
+
lastBoostAt: string | null;
|
|
137
|
+
}
|
|
138
|
+
/**
|
|
139
|
+
* Result of a trust score update operation.
|
|
140
|
+
*
|
|
141
|
+
* LLD #5 §2.2 — updateTrustScore() return type
|
|
142
|
+
*/
|
|
143
|
+
export interface TrustScoreUpdate {
|
|
144
|
+
/** Previous score before update. */
|
|
145
|
+
previousScore: number;
|
|
146
|
+
/** New score after update. */
|
|
147
|
+
newScore: number;
|
|
148
|
+
/** Delta applied. */
|
|
149
|
+
delta: number;
|
|
150
|
+
/** Reason for the update. */
|
|
151
|
+
reason: string;
|
|
152
|
+
}
|
|
153
|
+
/**
|
|
154
|
+
* Events that can modify a trust score.
|
|
155
|
+
*
|
|
156
|
+
* LLD #5 §4.4
|
|
157
|
+
*/
|
|
158
|
+
export interface TrustEvent {
|
|
159
|
+
type: 'ANOMALY_DETECTED' | 'CLEAN_SESSION';
|
|
160
|
+
anomalyType?: AnomalyType;
|
|
161
|
+
traceId?: string;
|
|
162
|
+
sessionId?: string;
|
|
163
|
+
}
|
|
164
|
+
import type { IncidentStatus } from './enums.js';
|
|
165
|
+
/**
|
|
166
|
+
* @deprecated Use {@link IncidentStatus} from enums.ts instead.
|
|
167
|
+
* Kept as alias for backward compatibility.
|
|
168
|
+
*/
|
|
169
|
+
export type GovernanceIncidentStatus = IncidentStatus;
|
|
170
|
+
/**
|
|
171
|
+
* CAPABILITY_MISS event — logged when an agent encounters a task
|
|
172
|
+
* for which no governing SOP exists.
|
|
173
|
+
*
|
|
174
|
+
* HLD §3.5 — CAPABILITY_MISS (Non-Anomaly Informational Event)
|
|
175
|
+
*/
|
|
176
|
+
export interface CapabilityMissEvent {
|
|
177
|
+
/** Miss ID — `newId('cm')`. */
|
|
178
|
+
missId: string;
|
|
179
|
+
/** Workspace ID. */
|
|
180
|
+
workspaceId: string;
|
|
181
|
+
/** Session ID where the miss occurred. */
|
|
182
|
+
sessionId: string | null;
|
|
183
|
+
/** Brief description of the ungoverned task. */
|
|
184
|
+
taskDescription: string;
|
|
185
|
+
/** Tools the agent attempted. */
|
|
186
|
+
toolSequence: string[];
|
|
187
|
+
/** Closest SOP by embedding similarity, or null. */
|
|
188
|
+
nearestSopId: string | null;
|
|
189
|
+
/** How close the nearest SOP was (0.0–1.0). */
|
|
190
|
+
similarityScore: number | null;
|
|
191
|
+
/** Recommended action for Dream Cycle. */
|
|
192
|
+
recommendedAction: 'AUTHOR_NEW_SOP' | 'EXTEND_EXISTING_SOP';
|
|
193
|
+
}
|
|
194
|
+
/**
|
|
195
|
+
* Input for recording a capability miss.
|
|
196
|
+
*
|
|
197
|
+
* LLD #5 §2.2 — recordCapabilityMiss() parameter
|
|
198
|
+
*/
|
|
199
|
+
export interface CapabilityMissInput {
|
|
200
|
+
workspaceId: string;
|
|
201
|
+
sessionId?: string;
|
|
202
|
+
taskDescription: string;
|
|
203
|
+
toolSequence: string[];
|
|
204
|
+
nearestSopId?: string;
|
|
205
|
+
similarityScore?: number;
|
|
206
|
+
recommendedAction?: 'AUTHOR_NEW_SOP' | 'EXTEND_EXISTING_SOP';
|
|
207
|
+
}
|
|
208
|
+
/**
|
|
209
|
+
* Drift direction classification.
|
|
210
|
+
*
|
|
211
|
+
* HLD §7.7 — Behavioral Drift Detector
|
|
212
|
+
*/
|
|
213
|
+
export type DriftDirection = 'POSITIVE_DRIFT' | 'NEGATIVE_DRIFT' | 'NEUTRAL_DRIFT';
|
|
214
|
+
/**
|
|
215
|
+
* Drift detection event payload.
|
|
216
|
+
*
|
|
217
|
+
* LLD #5 §2.3 — anomaly.drift.detected event
|
|
218
|
+
*/
|
|
219
|
+
export interface DriftEvent {
|
|
220
|
+
workspaceId: string;
|
|
221
|
+
sopId: string;
|
|
222
|
+
driftScore: number;
|
|
223
|
+
driftDirection: DriftDirection;
|
|
224
|
+
baselineScore: number;
|
|
225
|
+
currentScore: number;
|
|
226
|
+
}
|
|
227
|
+
//# sourceMappingURL=anomaly.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"anomaly.d.ts","sourceRoot":"","sources":["../src/anomaly.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,YAAY,CAAA;AAI7C;;;;;;;GAOG;AACH,MAAM,WAAW,YAAY;IAC3B,4DAA4D;IAC5D,IAAI,EAAE,WAAW,CAAA;IAEjB,4CAA4C;IAC5C,UAAU,EAAE,MAAM,CAAA;IAElB,0DAA0D;IAC1D,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;CACnC;AAID;;;;;GAKG;AACH,MAAM,WAAW,qBAAqB;IACpC,uCAAuC;IACvC,QAAQ,EAAE,OAAO,CAAA;IAEjB,0EAA0E;IAC1E,WAAW,EAAE,WAAW,GAAG,IAAI,CAAA;IAE/B,4CAA4C;IAC5C,UAAU,EAAE,MAAM,CAAA;IAElB,gDAAgD;IAChD,QAAQ,EAAE,eAAe,CAAA;IAEzB,uDAAuD;IACvD,cAAc,EAAE,oBAAoB,GAAG,IAAI,CAAA;IAE3C,4DAA4D;IAC5D,YAAY,EAAE,WAAW,EAAE,CAAA;IAE3B,kEAAkE;IAClE,UAAU,EAAE,MAAM,GAAG,IAAI,CAAA;CAC1B;AAID;;;;GAIG;AACH,MAAM,MAAM,eAAe,GAAG,UAAU,GAAG,MAAM,GAAG,QAAQ,GAAG,KAAK,GAAG,eAAe,CAAA;AAEtF;;;;;GAKG;AACH,eAAO,MAAM,oBAAoB,EAAE,MAAM,CAAC,WAAW,EAAE,eAAe,CAa5D,CAAA;AAIV;;;;;;;;GAQG;AACH,MAAM,WAAW,oBAAoB;IACnC,+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B,GAAG,qBAAqB,CAAA;CAC7D;AAID;;;;GAIG;AACH,MAAM,MAAM,cAAc,GAAG,gBAAgB,GAAG,gBAAgB,GAAG,eAAe,CAAA;AAElF;;;;GAIG;AACH,MAAM,WAAW,UAAU;IACzB,WAAW,EAAE,MAAM,CAAA;IACnB,KAAK,EAAE,MAAM,CAAA;IACb,UAAU,EAAE,MAAM,CAAA;IAClB,cAAc,EAAE,cAAc,CAAA;IAC9B,aAAa,EAAE,MAAM,CAAA;IACrB,YAAY,EAAE,MAAM,CAAA;CACrB"}
|
package/.dist/anomaly.js
ADDED
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Anomaly detection types for the Anomaly Recognition Engine (ARE).
|
|
4
|
+
*
|
|
5
|
+
* These types support the 12-category runtime anomaly taxonomy,
|
|
6
|
+
* corrective prompt card system, trust scoring, and ARE probe battery.
|
|
7
|
+
*
|
|
8
|
+
* HLD §3.5 (Anomaly Detection), HLD §7.7 (Drift Detector)
|
|
9
|
+
* LLD #5 — Anomaly Detection + ARE
|
|
10
|
+
*
|
|
11
|
+
* @module
|
|
12
|
+
*/
|
|
13
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
14
|
+
exports.ANOMALY_SEVERITY_MAP = void 0;
|
|
15
|
+
/**
|
|
16
|
+
* Static mapping from anomaly type to default severity.
|
|
17
|
+
*
|
|
18
|
+
* HLD §3.5 — 12-category table, Alert Route column
|
|
19
|
+
* LLD #5 Appendix B
|
|
20
|
+
*/
|
|
21
|
+
exports.ANOMALY_SEVERITY_MAP = {
|
|
22
|
+
TOOL_ABUSE: 'HIGH',
|
|
23
|
+
TOKEN_WASTE: 'MEDIUM',
|
|
24
|
+
LOOP_DETECTED: 'HIGH',
|
|
25
|
+
UNAUTHORIZED_TOOL: 'HIGH',
|
|
26
|
+
DATA_EXFILTRATION: 'CRITICAL',
|
|
27
|
+
PROMPT_INJECTION: 'CRITICAL',
|
|
28
|
+
HALLUCINATION: 'HIGH',
|
|
29
|
+
SCOPE_VIOLATION: 'MEDIUM',
|
|
30
|
+
BUDGET_BREACH: 'HIGH',
|
|
31
|
+
SPAWN_BUDGET_BREACH: 'HIGH',
|
|
32
|
+
WORKFLOW_BUDGET_BREACH: 'HIGH',
|
|
33
|
+
WORKFLOW_GOAL_DRIFT: 'MEDIUM',
|
|
34
|
+
};
|
|
35
|
+
//# sourceMappingURL=anomaly.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"anomaly.js","sourceRoot":"","sources":["../src/anomaly.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;GAUG;;;AAiEH;;;;;GAKG;AACU,QAAA,oBAAoB,GAAyC;IACxE,UAAU,EAAE,MAAM;IAClB,WAAW,EAAE,QAAQ;IACrB,aAAa,EAAE,MAAM;IACrB,iBAAiB,EAAE,MAAM;IACzB,iBAAiB,EAAE,UAAU;IAC7B,gBAAgB,EAAE,UAAU;IAC5B,aAAa,EAAE,MAAM;IACrB,eAAe,EAAE,QAAQ;IACzB,aAAa,EAAE,MAAM;IACrB,mBAAmB,EAAE,MAAM;IAC3B,sBAAsB,EAAE,MAAM;IAC9B,mBAAmB,EAAE,QAAQ;CACrB,CAAA"}
|
|
@@ -0,0 +1,176 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Zod schemas for API request/response validation.
|
|
3
|
+
*
|
|
4
|
+
* Each schema is exported alongside its inferred TypeScript type.
|
|
5
|
+
* Services use these schemas in route handlers to validate incoming
|
|
6
|
+
* payloads; the inferred types are used in service function signatures.
|
|
7
|
+
*
|
|
8
|
+
* HLD §3.1 (Proxy Gateway), §3.6 (FinOps), §3.3 (PCAS)
|
|
9
|
+
*
|
|
10
|
+
* @module
|
|
11
|
+
*/
|
|
12
|
+
import { z } from 'zod';
|
|
13
|
+
/**
|
|
14
|
+
* Zod schema for the `POST /api/v1/sessions` request body.
|
|
15
|
+
*
|
|
16
|
+
* Creates a new agent session in the control plane.
|
|
17
|
+
*/
|
|
18
|
+
export declare const CreateSessionSchema: z.ZodObject<{
|
|
19
|
+
/** Workspace to create the session in. */
|
|
20
|
+
workspaceId: z.ZodString;
|
|
21
|
+
/** User initiating the session. */
|
|
22
|
+
userId: z.ZodString;
|
|
23
|
+
/** Optional project to scope the session. */
|
|
24
|
+
projectId: z.ZodOptional<z.ZodString>;
|
|
25
|
+
/** Optional SOP to govern the session. */
|
|
26
|
+
activeSopId: z.ZodOptional<z.ZodString>;
|
|
27
|
+
/** Agent harness type. */
|
|
28
|
+
harnessType: z.ZodEnum<["cursor" | "claude-code" | "antigravity" | "n8n" | "codex" | "windsurf" | "aider" | "openhands" | "openclaw" | "hermes" | "pi", ...("cursor" | "claude-code" | "antigravity" | "n8n" | "codex" | "windsurf" | "aider" | "openhands" | "openclaw" | "hermes" | "pi")[]]>;
|
|
29
|
+
/** Budget tier — defaults to JUNIOR on the server. */
|
|
30
|
+
budgetTier: z.ZodOptional<z.ZodEnum<["JUNIOR" | "SENIOR" | "STAFF" | "PRINCIPAL", ...("JUNIOR" | "SENIOR" | "STAFF" | "PRINCIPAL")[]]>>;
|
|
31
|
+
/** Execution mode — defaults to STANDARD on the server. */
|
|
32
|
+
executionMode: z.ZodOptional<z.ZodEnum<["STANDARD" | "PLAN_ONLY" | "SHADOW" | "AUTONOMOUS", ...("STANDARD" | "PLAN_ONLY" | "SHADOW" | "AUTONOMOUS")[]]>>;
|
|
33
|
+
}, "strip", z.ZodTypeAny, {
|
|
34
|
+
workspaceId: string;
|
|
35
|
+
userId: string;
|
|
36
|
+
harnessType: "cursor" | "claude-code" | "antigravity" | "n8n" | "codex" | "windsurf" | "aider" | "openhands" | "openclaw" | "hermes" | "pi";
|
|
37
|
+
projectId?: string | undefined;
|
|
38
|
+
activeSopId?: string | undefined;
|
|
39
|
+
budgetTier?: "JUNIOR" | "SENIOR" | "STAFF" | "PRINCIPAL" | undefined;
|
|
40
|
+
executionMode?: "STANDARD" | "PLAN_ONLY" | "SHADOW" | "AUTONOMOUS" | undefined;
|
|
41
|
+
}, {
|
|
42
|
+
workspaceId: string;
|
|
43
|
+
userId: string;
|
|
44
|
+
harnessType: "cursor" | "claude-code" | "antigravity" | "n8n" | "codex" | "windsurf" | "aider" | "openhands" | "openclaw" | "hermes" | "pi";
|
|
45
|
+
projectId?: string | undefined;
|
|
46
|
+
activeSopId?: string | undefined;
|
|
47
|
+
budgetTier?: "JUNIOR" | "SENIOR" | "STAFF" | "PRINCIPAL" | undefined;
|
|
48
|
+
executionMode?: "STANDARD" | "PLAN_ONLY" | "SHADOW" | "AUTONOMOUS" | undefined;
|
|
49
|
+
}>;
|
|
50
|
+
/** Inferred type for a create-session request payload. */
|
|
51
|
+
export type CreateSessionInput = z.infer<typeof CreateSessionSchema>;
|
|
52
|
+
/**
|
|
53
|
+
* Zod schema for the `POST /api/v1/traces` request body.
|
|
54
|
+
*
|
|
55
|
+
* Appends a new row to the `execution_traces` ledger.
|
|
56
|
+
* Fields with server-side defaults (e.g., `timestamp`) are optional.
|
|
57
|
+
*/
|
|
58
|
+
export declare const CreateTraceSchema: z.ZodObject<{
|
|
59
|
+
/** Session that produced this trace. */
|
|
60
|
+
sessionId: z.ZodString;
|
|
61
|
+
/** Idempotency key — must be unique across all traces. */
|
|
62
|
+
requestId: z.ZodString;
|
|
63
|
+
/** Effective date of the governing SOP (ISO 8601). */
|
|
64
|
+
sopEffectiveDate: z.ZodString;
|
|
65
|
+
requestedModel: z.ZodString;
|
|
66
|
+
actualModelRouted: z.ZodString;
|
|
67
|
+
routingTier: z.ZodEnum<["frontier" | "economy" | "local", ...("frontier" | "economy" | "local")[]]>;
|
|
68
|
+
complexityScore: z.ZodNumber;
|
|
69
|
+
rawInputTokens: z.ZodNumber;
|
|
70
|
+
compressedInputTokens: z.ZodNumber;
|
|
71
|
+
outputTokens: z.ZodNumber;
|
|
72
|
+
rawCostUsd: z.ZodNumber;
|
|
73
|
+
actualCostUsd: z.ZodNumber;
|
|
74
|
+
tokenUtility: z.ZodOptional<z.ZodEnum<["USEFUL" | "WASTED", ...("USEFUL" | "WASTED")[]]>>;
|
|
75
|
+
tokenUtilityScore: z.ZodOptional<z.ZodNumber>;
|
|
76
|
+
complianceScore: z.ZodNumber;
|
|
77
|
+
enforcementAction: z.ZodEnum<["BYPASS" | "ENHANCE" | "HIJACK" | "KILL", ...("BYPASS" | "ENHANCE" | "HIJACK" | "KILL")[]]>;
|
|
78
|
+
anomalyDetected: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
79
|
+
anomalyConfidenceScore: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
80
|
+
taxonomyMetadata: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
81
|
+
rawPayloadJson: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
82
|
+
appId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
83
|
+
agentChainId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
84
|
+
agentChain: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
85
|
+
cacheHit: z.ZodOptional<z.ZodBoolean>;
|
|
86
|
+
cacheSavingsUsd: z.ZodOptional<z.ZodNumber>;
|
|
87
|
+
rootCauseAttribution: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
88
|
+
correctivePromptCard: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
89
|
+
}, "strip", z.ZodTypeAny, {
|
|
90
|
+
sessionId: string;
|
|
91
|
+
requestId: string;
|
|
92
|
+
sopEffectiveDate: string;
|
|
93
|
+
requestedModel: string;
|
|
94
|
+
actualModelRouted: string;
|
|
95
|
+
routingTier: "frontier" | "economy" | "local";
|
|
96
|
+
complexityScore: number;
|
|
97
|
+
rawInputTokens: number;
|
|
98
|
+
compressedInputTokens: number;
|
|
99
|
+
outputTokens: number;
|
|
100
|
+
rawCostUsd: number;
|
|
101
|
+
actualCostUsd: number;
|
|
102
|
+
complianceScore: number;
|
|
103
|
+
enforcementAction: "BYPASS" | "ENHANCE" | "HIJACK" | "KILL";
|
|
104
|
+
tokenUtility?: "USEFUL" | "WASTED" | undefined;
|
|
105
|
+
tokenUtilityScore?: number | undefined;
|
|
106
|
+
anomalyDetected?: string | null | undefined;
|
|
107
|
+
anomalyConfidenceScore?: number | null | undefined;
|
|
108
|
+
taxonomyMetadata?: Record<string, unknown> | null | undefined;
|
|
109
|
+
rawPayloadJson?: Record<string, unknown> | null | undefined;
|
|
110
|
+
appId?: string | null | undefined;
|
|
111
|
+
agentChainId?: string | null | undefined;
|
|
112
|
+
agentChain?: Record<string, unknown> | null | undefined;
|
|
113
|
+
cacheHit?: boolean | undefined;
|
|
114
|
+
cacheSavingsUsd?: number | undefined;
|
|
115
|
+
rootCauseAttribution?: Record<string, unknown> | null | undefined;
|
|
116
|
+
correctivePromptCard?: Record<string, unknown> | null | undefined;
|
|
117
|
+
}, {
|
|
118
|
+
sessionId: string;
|
|
119
|
+
requestId: string;
|
|
120
|
+
sopEffectiveDate: string;
|
|
121
|
+
requestedModel: string;
|
|
122
|
+
actualModelRouted: string;
|
|
123
|
+
routingTier: "frontier" | "economy" | "local";
|
|
124
|
+
complexityScore: number;
|
|
125
|
+
rawInputTokens: number;
|
|
126
|
+
compressedInputTokens: number;
|
|
127
|
+
outputTokens: number;
|
|
128
|
+
rawCostUsd: number;
|
|
129
|
+
actualCostUsd: number;
|
|
130
|
+
complianceScore: number;
|
|
131
|
+
enforcementAction: "BYPASS" | "ENHANCE" | "HIJACK" | "KILL";
|
|
132
|
+
tokenUtility?: "USEFUL" | "WASTED" | undefined;
|
|
133
|
+
tokenUtilityScore?: number | undefined;
|
|
134
|
+
anomalyDetected?: string | null | undefined;
|
|
135
|
+
anomalyConfidenceScore?: number | null | undefined;
|
|
136
|
+
taxonomyMetadata?: Record<string, unknown> | null | undefined;
|
|
137
|
+
rawPayloadJson?: Record<string, unknown> | null | undefined;
|
|
138
|
+
appId?: string | null | undefined;
|
|
139
|
+
agentChainId?: string | null | undefined;
|
|
140
|
+
agentChain?: Record<string, unknown> | null | undefined;
|
|
141
|
+
cacheHit?: boolean | undefined;
|
|
142
|
+
cacheSavingsUsd?: number | undefined;
|
|
143
|
+
rootCauseAttribution?: Record<string, unknown> | null | undefined;
|
|
144
|
+
correctivePromptCard?: Record<string, unknown> | null | undefined;
|
|
145
|
+
}>;
|
|
146
|
+
/** Inferred type for a create-trace request payload. */
|
|
147
|
+
export type CreateTraceInput = z.infer<typeof CreateTraceSchema>;
|
|
148
|
+
/**
|
|
149
|
+
* Zod schema for a policy verdict (used in Circuit Breaker responses
|
|
150
|
+
* and inter-service communication).
|
|
151
|
+
*
|
|
152
|
+
* HLD §3.3 — PCAS enforcement
|
|
153
|
+
*/
|
|
154
|
+
export declare const PolicyVerdictSchema: z.ZodObject<{
|
|
155
|
+
/** Enforcement action to apply. */
|
|
156
|
+
action: z.ZodEnum<["BYPASS" | "ENHANCE" | "HIJACK" | "KILL", ...("BYPASS" | "ENHANCE" | "HIJACK" | "KILL")[]]>;
|
|
157
|
+
/** Confidence score (0.0–1.0). */
|
|
158
|
+
confidence: z.ZodNumber;
|
|
159
|
+
/** Human-readable reason. */
|
|
160
|
+
reason: z.ZodString;
|
|
161
|
+
/** Optional policy rule ID. */
|
|
162
|
+
policyId: z.ZodOptional<z.ZodString>;
|
|
163
|
+
}, "strip", z.ZodTypeAny, {
|
|
164
|
+
action: "BYPASS" | "ENHANCE" | "HIJACK" | "KILL";
|
|
165
|
+
confidence: number;
|
|
166
|
+
reason: string;
|
|
167
|
+
policyId?: string | undefined;
|
|
168
|
+
}, {
|
|
169
|
+
action: "BYPASS" | "ENHANCE" | "HIJACK" | "KILL";
|
|
170
|
+
confidence: number;
|
|
171
|
+
reason: string;
|
|
172
|
+
policyId?: string | undefined;
|
|
173
|
+
}>;
|
|
174
|
+
/** Inferred type for a policy verdict. */
|
|
175
|
+
export type PolicyVerdictInput = z.infer<typeof PolicyVerdictSchema>;
|
|
176
|
+
//# sourceMappingURL=api-contracts.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"api-contracts.d.ts","sourceRoot":"","sources":["../src/api-contracts.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAmBvB;;;;GAIG;AACH,eAAO,MAAM,mBAAmB;IAC9B,0CAA0C;;IAG1C,mCAAmC;;IAGnC,6CAA6C;;IAG7C,0CAA0C;;IAG1C,0BAA0B;;IAG1B,sDAAsD;;IAGtD,2DAA2D;;;;;;;;;;;;;;;;;;EAE3D,CAAA;AAEF,0DAA0D;AAC1D,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAA;AAIpE;;;;;GAKG;AACH,eAAO,MAAM,iBAAiB;IAC5B,wCAAwC;;IAGxC,0DAA0D;;IAG1D,sDAAsD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA8CtD,CAAA;AAEF,wDAAwD;AACxD,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAA;AAIhE;;;;;GAKG;AACH,eAAO,MAAM,mBAAmB;IAC9B,mCAAmC;;IAGnC,kCAAkC;;IAGlC,6BAA6B;;IAG7B,+BAA+B;;;;;;;;;;;;EAE/B,CAAA;AAEF,0CAA0C;AAC1C,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAA"}
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Zod schemas for API request/response validation.
|
|
4
|
+
*
|
|
5
|
+
* Each schema is exported alongside its inferred TypeScript type.
|
|
6
|
+
* Services use these schemas in route handlers to validate incoming
|
|
7
|
+
* payloads; the inferred types are used in service function signatures.
|
|
8
|
+
*
|
|
9
|
+
* HLD §3.1 (Proxy Gateway), §3.6 (FinOps), §3.3 (PCAS)
|
|
10
|
+
*
|
|
11
|
+
* @module
|
|
12
|
+
*/
|
|
13
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
14
|
+
exports.PolicyVerdictSchema = exports.CreateTraceSchema = exports.CreateSessionSchema = void 0;
|
|
15
|
+
const zod_1 = require("zod");
|
|
16
|
+
const enums_js_1 = require("./enums.js");
|
|
17
|
+
// ─── Helpers ─────────────────────────────────────────────────────────
|
|
18
|
+
/** Extract the values array from a const object for use in `z.enum()`. */
|
|
19
|
+
function constValues(obj) {
|
|
20
|
+
return Object.values(obj);
|
|
21
|
+
}
|
|
22
|
+
// ─── CreateSession ───────────────────────────────────────────────────
|
|
23
|
+
/**
|
|
24
|
+
* Zod schema for the `POST /api/v1/sessions` request body.
|
|
25
|
+
*
|
|
26
|
+
* Creates a new agent session in the control plane.
|
|
27
|
+
*/
|
|
28
|
+
exports.CreateSessionSchema = zod_1.z.object({
|
|
29
|
+
/** Workspace to create the session in. */
|
|
30
|
+
workspaceId: zod_1.z.string().min(1),
|
|
31
|
+
/** User initiating the session. */
|
|
32
|
+
userId: zod_1.z.string().min(1),
|
|
33
|
+
/** Optional project to scope the session. */
|
|
34
|
+
projectId: zod_1.z.string().min(1).optional(),
|
|
35
|
+
/** Optional SOP to govern the session. */
|
|
36
|
+
activeSopId: zod_1.z.string().min(1).optional(),
|
|
37
|
+
/** Agent harness type. */
|
|
38
|
+
harnessType: zod_1.z.enum(constValues(enums_js_1.HarnessType)),
|
|
39
|
+
/** Budget tier — defaults to JUNIOR on the server. */
|
|
40
|
+
budgetTier: zod_1.z.enum(constValues(enums_js_1.BudgetTier)).optional(),
|
|
41
|
+
/** Execution mode — defaults to STANDARD on the server. */
|
|
42
|
+
executionMode: zod_1.z.enum(constValues(enums_js_1.ExecutionMode)).optional(),
|
|
43
|
+
});
|
|
44
|
+
// ─── CreateTrace ─────────────────────────────────────────────────────
|
|
45
|
+
/**
|
|
46
|
+
* Zod schema for the `POST /api/v1/traces` request body.
|
|
47
|
+
*
|
|
48
|
+
* Appends a new row to the `execution_traces` ledger.
|
|
49
|
+
* Fields with server-side defaults (e.g., `timestamp`) are optional.
|
|
50
|
+
*/
|
|
51
|
+
exports.CreateTraceSchema = zod_1.z.object({
|
|
52
|
+
/** Session that produced this trace. */
|
|
53
|
+
sessionId: zod_1.z.string().min(1),
|
|
54
|
+
/** Idempotency key — must be unique across all traces. */
|
|
55
|
+
requestId: zod_1.z.string().min(1),
|
|
56
|
+
/** Effective date of the governing SOP (ISO 8601). */
|
|
57
|
+
sopEffectiveDate: zod_1.z.string().datetime(),
|
|
58
|
+
// ── Model routing ──
|
|
59
|
+
requestedModel: zod_1.z.string().min(1),
|
|
60
|
+
actualModelRouted: zod_1.z.string().min(1),
|
|
61
|
+
routingTier: zod_1.z.enum(constValues(enums_js_1.RoutingTier)),
|
|
62
|
+
complexityScore: zod_1.z.number().min(0).max(1),
|
|
63
|
+
// ── Token accounting ──
|
|
64
|
+
rawInputTokens: zod_1.z.number().int().nonnegative(),
|
|
65
|
+
compressedInputTokens: zod_1.z.number().int().nonnegative(),
|
|
66
|
+
outputTokens: zod_1.z.number().int().nonnegative(),
|
|
67
|
+
// ── Cost accounting ──
|
|
68
|
+
rawCostUsd: zod_1.z.number().nonnegative(),
|
|
69
|
+
actualCostUsd: zod_1.z.number().nonnegative(),
|
|
70
|
+
// ── Token utility ──
|
|
71
|
+
tokenUtility: zod_1.z.enum(constValues(enums_js_1.TokenUtility)).optional(),
|
|
72
|
+
tokenUtilityScore: zod_1.z.number().min(0).max(1).optional(),
|
|
73
|
+
// ── Enforcement ──
|
|
74
|
+
complianceScore: zod_1.z.number().min(0).max(1),
|
|
75
|
+
enforcementAction: zod_1.z.enum(constValues(enums_js_1.EnforcementAction)),
|
|
76
|
+
// ── Anomaly ──
|
|
77
|
+
anomalyDetected: zod_1.z.string().nullable().optional(),
|
|
78
|
+
anomalyConfidenceScore: zod_1.z.number().min(0).max(1).nullable().optional(),
|
|
79
|
+
taxonomyMetadata: zod_1.z.record(zod_1.z.unknown()).nullable().optional(),
|
|
80
|
+
// ── Forensics ──
|
|
81
|
+
rawPayloadJson: zod_1.z.record(zod_1.z.unknown()).nullable().optional(),
|
|
82
|
+
// ── 4D Attribution ──
|
|
83
|
+
appId: zod_1.z.string().nullable().optional(),
|
|
84
|
+
agentChainId: zod_1.z.string().nullable().optional(),
|
|
85
|
+
agentChain: zod_1.z.record(zod_1.z.unknown()).nullable().optional(),
|
|
86
|
+
// ── Cache ──
|
|
87
|
+
cacheHit: zod_1.z.boolean().optional(),
|
|
88
|
+
cacheSavingsUsd: zod_1.z.number().nonnegative().optional(),
|
|
89
|
+
// ── Root cause ──
|
|
90
|
+
rootCauseAttribution: zod_1.z.record(zod_1.z.unknown()).nullable().optional(),
|
|
91
|
+
correctivePromptCard: zod_1.z.record(zod_1.z.unknown()).nullable().optional(),
|
|
92
|
+
});
|
|
93
|
+
// ─── PolicyVerdict ───────────────────────────────────────────────────
|
|
94
|
+
/**
|
|
95
|
+
* Zod schema for a policy verdict (used in Circuit Breaker responses
|
|
96
|
+
* and inter-service communication).
|
|
97
|
+
*
|
|
98
|
+
* HLD §3.3 — PCAS enforcement
|
|
99
|
+
*/
|
|
100
|
+
exports.PolicyVerdictSchema = zod_1.z.object({
|
|
101
|
+
/** Enforcement action to apply. */
|
|
102
|
+
action: zod_1.z.enum(constValues(enums_js_1.EnforcementAction)),
|
|
103
|
+
/** Confidence score (0.0–1.0). */
|
|
104
|
+
confidence: zod_1.z.number().min(0).max(1),
|
|
105
|
+
/** Human-readable reason. */
|
|
106
|
+
reason: zod_1.z.string().min(1),
|
|
107
|
+
/** Optional policy rule ID. */
|
|
108
|
+
policyId: zod_1.z.string().optional(),
|
|
109
|
+
});
|
|
110
|
+
//# sourceMappingURL=api-contracts.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"api-contracts.js","sourceRoot":"","sources":["../src/api-contracts.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;GAUG;;;AAEH,6BAAuB;AACvB,yCAOmB;AAEnB,wEAAwE;AAExE,0EAA0E;AAC1E,SAAS,WAAW,CAAmC,GAAM;IAC3D,OAAO,MAAM,CAAC,MAAM,CAAC,GAAG,CAAkC,CAAA;AAC5D,CAAC;AAED,wEAAwE;AAExE;;;;GAIG;AACU,QAAA,mBAAmB,GAAG,OAAC,CAAC,MAAM,CAAC;IAC1C,0CAA0C;IAC1C,WAAW,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC;IAE9B,mCAAmC;IACnC,MAAM,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC;IAEzB,6CAA6C;IAC7C,SAAS,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE;IAEvC,0CAA0C;IAC1C,WAAW,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE;IAEzC,0BAA0B;IAC1B,WAAW,EAAE,OAAC,CAAC,IAAI,CAAC,WAAW,CAAC,sBAAW,CAAC,CAAC;IAE7C,sDAAsD;IACtD,UAAU,EAAE,OAAC,CAAC,IAAI,CAAC,WAAW,CAAC,qBAAU,CAAC,CAAC,CAAC,QAAQ,EAAE;IAEtD,2DAA2D;IAC3D,aAAa,EAAE,OAAC,CAAC,IAAI,CAAC,WAAW,CAAC,wBAAa,CAAC,CAAC,CAAC,QAAQ,EAAE;CAC7D,CAAC,CAAA;AAKF,wEAAwE;AAExE;;;;;GAKG;AACU,QAAA,iBAAiB,GAAG,OAAC,CAAC,MAA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