@uluops/core 0.5.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 +543 -0
- package/definitions/starter/code-validator.agent.yaml +134 -0
- package/definitions/starter/docs-validator.agent.yaml +142 -0
- package/definitions/starter/public-interface-validator.agent.yaml +138 -0
- package/definitions/starter/security-analyst.agent.yaml +144 -0
- package/definitions/starter/test-architect.agent.yaml +137 -0
- package/dist/ai/AIProvider.d.ts +198 -0
- package/dist/ai/AIProvider.d.ts.map +1 -0
- package/dist/ai/AIProvider.js +557 -0
- package/dist/ai/AIProvider.js.map +1 -0
- package/dist/ai/ModelCatalog.d.ts +78 -0
- package/dist/ai/ModelCatalog.d.ts.map +1 -0
- package/dist/ai/ModelCatalog.js +193 -0
- package/dist/ai/ModelCatalog.js.map +1 -0
- package/dist/ai/ShellExecutor.d.ts +42 -0
- package/dist/ai/ShellExecutor.d.ts.map +1 -0
- package/dist/ai/ShellExecutor.js +62 -0
- package/dist/ai/ShellExecutor.js.map +1 -0
- package/dist/ai/TokenBudgetTracker.d.ts +49 -0
- package/dist/ai/TokenBudgetTracker.d.ts.map +1 -0
- package/dist/ai/TokenBudgetTracker.js +61 -0
- package/dist/ai/TokenBudgetTracker.js.map +1 -0
- package/dist/ai/ToolAdapter.d.ts +25 -0
- package/dist/ai/ToolAdapter.d.ts.map +1 -0
- package/dist/ai/ToolAdapter.js +135 -0
- package/dist/ai/ToolAdapter.js.map +1 -0
- package/dist/ai/index.d.ts +6 -0
- package/dist/ai/index.d.ts.map +1 -0
- package/dist/ai/index.js +4 -0
- package/dist/ai/index.js.map +1 -0
- package/dist/client/UluOpsClient.d.ts +111 -0
- package/dist/client/UluOpsClient.d.ts.map +1 -0
- package/dist/client/UluOpsClient.js +329 -0
- package/dist/client/UluOpsClient.js.map +1 -0
- package/dist/constants.d.ts +6 -0
- package/dist/constants.d.ts.map +1 -0
- package/dist/constants.js +9 -0
- package/dist/constants.js.map +1 -0
- package/dist/errors/UluOpsError.d.ts +10 -0
- package/dist/errors/UluOpsError.d.ts.map +1 -0
- package/dist/errors/UluOpsError.js +13 -0
- package/dist/errors/UluOpsError.js.map +1 -0
- package/dist/errors/index.d.ts +64 -0
- package/dist/errors/index.d.ts.map +1 -0
- package/dist/errors/index.js +93 -0
- package/dist/errors/index.js.map +1 -0
- package/dist/executor/AgentExecutor.d.ts +57 -0
- package/dist/executor/AgentExecutor.d.ts.map +1 -0
- package/dist/executor/AgentExecutor.js +331 -0
- package/dist/executor/AgentExecutor.js.map +1 -0
- package/dist/executor/CommandExecutor.d.ts +33 -0
- package/dist/executor/CommandExecutor.d.ts.map +1 -0
- package/dist/executor/CommandExecutor.js +183 -0
- package/dist/executor/CommandExecutor.js.map +1 -0
- package/dist/executor/PipelineExecutor.d.ts +55 -0
- package/dist/executor/PipelineExecutor.d.ts.map +1 -0
- package/dist/executor/PipelineExecutor.js +273 -0
- package/dist/executor/PipelineExecutor.js.map +1 -0
- package/dist/executor/ToolHandler.d.ts +47 -0
- package/dist/executor/ToolHandler.d.ts.map +1 -0
- package/dist/executor/ToolHandler.js +615 -0
- package/dist/executor/ToolHandler.js.map +1 -0
- package/dist/executor/WorkflowExecutor.d.ts +55 -0
- package/dist/executor/WorkflowExecutor.d.ts.map +1 -0
- package/dist/executor/WorkflowExecutor.js +368 -0
- package/dist/executor/WorkflowExecutor.js.map +1 -0
- package/dist/executor/preflight.d.ts +8 -0
- package/dist/executor/preflight.d.ts.map +1 -0
- package/dist/executor/preflight.js +102 -0
- package/dist/executor/preflight.js.map +1 -0
- package/dist/executor/symbols.d.ts +13 -0
- package/dist/executor/symbols.d.ts.map +1 -0
- package/dist/executor/symbols.js +102 -0
- package/dist/executor/symbols.js.map +1 -0
- package/dist/index.d.ts +32 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +25 -0
- package/dist/index.js.map +1 -0
- package/dist/parser/OutputExtractor.d.ts +52 -0
- package/dist/parser/OutputExtractor.d.ts.map +1 -0
- package/dist/parser/OutputExtractor.js +818 -0
- package/dist/parser/OutputExtractor.js.map +1 -0
- package/dist/parser/outputSchemas.d.ts +223 -0
- package/dist/parser/outputSchemas.d.ts.map +1 -0
- package/dist/parser/outputSchemas.js +73 -0
- package/dist/parser/outputSchemas.js.map +1 -0
- package/dist/registry/RegistryClient.d.ts +75 -0
- package/dist/registry/RegistryClient.d.ts.map +1 -0
- package/dist/registry/RegistryClient.js +419 -0
- package/dist/registry/RegistryClient.js.map +1 -0
- package/dist/registry/index.d.ts +2 -0
- package/dist/registry/index.d.ts.map +1 -0
- package/dist/registry/index.js +2 -0
- package/dist/registry/index.js.map +1 -0
- package/dist/types/agent.d.ts +406 -0
- package/dist/types/agent.d.ts.map +1 -0
- package/dist/types/agent.js +2 -0
- package/dist/types/agent.js.map +1 -0
- package/dist/types/ai.d.ts +14 -0
- package/dist/types/ai.d.ts.map +1 -0
- package/dist/types/ai.js +2 -0
- package/dist/types/ai.js.map +1 -0
- package/dist/types/command.d.ts +153 -0
- package/dist/types/command.d.ts.map +1 -0
- package/dist/types/command.js +2 -0
- package/dist/types/command.js.map +1 -0
- package/dist/types/config.d.ts +136 -0
- package/dist/types/config.d.ts.map +1 -0
- package/dist/types/config.js +2 -0
- package/dist/types/config.js.map +1 -0
- package/dist/types/execution.d.ts +172 -0
- package/dist/types/execution.d.ts.map +1 -0
- package/dist/types/execution.js +2 -0
- package/dist/types/execution.js.map +1 -0
- package/dist/types/index.d.ts +12 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/index.js +2 -0
- package/dist/types/index.js.map +1 -0
- package/dist/types/parser.d.ts +75 -0
- package/dist/types/parser.d.ts.map +1 -0
- package/dist/types/parser.js +2 -0
- package/dist/types/parser.js.map +1 -0
- package/dist/types/pipeline.d.ts +155 -0
- package/dist/types/pipeline.d.ts.map +1 -0
- package/dist/types/pipeline.js +2 -0
- package/dist/types/pipeline.js.map +1 -0
- package/dist/types/registry.d.ts +232 -0
- package/dist/types/registry.d.ts.map +1 -0
- package/dist/types/registry.js +2 -0
- package/dist/types/registry.js.map +1 -0
- package/dist/types/tools.d.ts +29 -0
- package/dist/types/tools.d.ts.map +1 -0
- package/dist/types/tools.js +2 -0
- package/dist/types/tools.js.map +1 -0
- package/dist/types/validation.d.ts +237 -0
- package/dist/types/validation.d.ts.map +1 -0
- package/dist/types/validation.js +2 -0
- package/dist/types/validation.js.map +1 -0
- package/dist/types/workflow.d.ts +131 -0
- package/dist/types/workflow.d.ts.map +1 -0
- package/dist/types/workflow.js +2 -0
- package/dist/types/workflow.js.map +1 -0
- package/dist/utils/formatError.d.ts +6 -0
- package/dist/utils/formatError.d.ts.map +1 -0
- package/dist/utils/formatError.js +10 -0
- package/dist/utils/formatError.js.map +1 -0
- package/dist/utils/parseRef.d.ts +11 -0
- package/dist/utils/parseRef.d.ts.map +1 -0
- package/dist/utils/parseRef.js +16 -0
- package/dist/utils/parseRef.js.map +1 -0
- package/dist/utils/sumTokenMetrics.d.ts +9 -0
- package/dist/utils/sumTokenMetrics.d.ts.map +1 -0
- package/dist/utils/sumTokenMetrics.js +20 -0
- package/dist/utils/sumTokenMetrics.js.map +1 -0
- package/dist/utils/topoSort.d.ts +24 -0
- package/dist/utils/topoSort.d.ts.map +1 -0
- package/dist/utils/topoSort.js +60 -0
- package/dist/utils/topoSort.js.map +1 -0
- package/dist/validation/ValidationClient.d.ts +51 -0
- package/dist/validation/ValidationClient.d.ts.map +1 -0
- package/dist/validation/ValidationClient.js +179 -0
- package/dist/validation/ValidationClient.js.map +1 -0
- package/dist/validation/index.d.ts +2 -0
- package/dist/validation/index.d.ts.map +1 -0
- package/dist/validation/index.js +2 -0
- package/dist/validation/index.js.map +1 -0
- package/package.json +76 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"workflow.js","sourceRoot":"","sources":["../../src/types/workflow.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"formatError.d.ts","sourceRoot":"","sources":["../../src/utils/formatError.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,OAAO,GAAG,MAAM,CAGzD"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Extract a human-readable message from an unknown error value.
|
|
3
|
+
* Safely handles Error instances, strings, and arbitrary objects.
|
|
4
|
+
*/
|
|
5
|
+
export function formatErrorMessage(error) {
|
|
6
|
+
if (error instanceof Error)
|
|
7
|
+
return error.message;
|
|
8
|
+
return String(error);
|
|
9
|
+
}
|
|
10
|
+
//# sourceMappingURL=formatError.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"formatError.js","sourceRoot":"","sources":["../../src/utils/formatError.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,MAAM,UAAU,kBAAkB,CAAC,KAAc;IAC/C,IAAI,KAAK,YAAY,KAAK;QAAE,OAAO,KAAK,CAAC,OAAO,CAAC;IACjD,OAAO,MAAM,CAAC,KAAK,CAAC,CAAC;AACvB,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Parse a definition reference string into name and optional version.
|
|
3
|
+
*
|
|
4
|
+
* Handles `name`, `name@version`, and edge cases like multiple `@` symbols
|
|
5
|
+
* (only splits on the first `@`).
|
|
6
|
+
*
|
|
7
|
+
* @example parseRef('code-validator') → ['code-validator', undefined]
|
|
8
|
+
* @example parseRef('code-validator@1.0.0') → ['code-validator', '1.0.0']
|
|
9
|
+
*/
|
|
10
|
+
export declare function parseRef(ref: string): [name: string, version: string | undefined];
|
|
11
|
+
//# sourceMappingURL=parseRef.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"parseRef.d.ts","sourceRoot":"","sources":["../../src/utils/parseRef.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AACH,wBAAgB,QAAQ,CAAC,GAAG,EAAE,MAAM,GAAG,CAAC,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,SAAS,CAAC,CAIjF"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Parse a definition reference string into name and optional version.
|
|
3
|
+
*
|
|
4
|
+
* Handles `name`, `name@version`, and edge cases like multiple `@` symbols
|
|
5
|
+
* (only splits on the first `@`).
|
|
6
|
+
*
|
|
7
|
+
* @example parseRef('code-validator') → ['code-validator', undefined]
|
|
8
|
+
* @example parseRef('code-validator@1.0.0') → ['code-validator', '1.0.0']
|
|
9
|
+
*/
|
|
10
|
+
export function parseRef(ref) {
|
|
11
|
+
const atIndex = ref.indexOf('@');
|
|
12
|
+
if (atIndex === -1)
|
|
13
|
+
return [ref, undefined];
|
|
14
|
+
return [ref.slice(0, atIndex), ref.slice(atIndex + 1) || undefined];
|
|
15
|
+
}
|
|
16
|
+
//# sourceMappingURL=parseRef.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"parseRef.js","sourceRoot":"","sources":["../../src/utils/parseRef.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AACH,MAAM,UAAU,QAAQ,CAAC,GAAW;IAClC,MAAM,OAAO,GAAG,GAAG,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC;IACjC,IAAI,OAAO,KAAK,CAAC,CAAC;QAAE,OAAO,CAAC,GAAG,EAAE,SAAS,CAAC,CAAC;IAC5C,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC,EAAE,OAAO,CAAC,EAAE,GAAG,CAAC,KAAK,CAAC,OAAO,GAAG,CAAC,CAAC,IAAI,SAAS,CAAC,CAAC;AACtE,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { ExecutionMetrics } from '../types/execution.js';
|
|
2
|
+
type TokenFields = Pick<ExecutionMetrics, 'inputTokens' | 'outputTokens' | 'cacheCreationTokens' | 'cacheReadTokens' | 'totalEffectiveTokens'>;
|
|
3
|
+
/**
|
|
4
|
+
* Sum token-related fields across an array of execution metrics.
|
|
5
|
+
* Returns only token totals — caller adds durationMs, model, etc.
|
|
6
|
+
*/
|
|
7
|
+
export declare function sumTokenMetrics(items: ReadonlyArray<TokenFields>): Required<TokenFields>;
|
|
8
|
+
export {};
|
|
9
|
+
//# sourceMappingURL=sumTokenMetrics.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sumTokenMetrics.d.ts","sourceRoot":"","sources":["../../src/utils/sumTokenMetrics.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AAE9D,KAAK,WAAW,GAAG,IAAI,CAAC,gBAAgB,EAAE,aAAa,GAAG,cAAc,GAAG,qBAAqB,GAAG,iBAAiB,GAAG,sBAAsB,CAAC,CAAC;AAE/I;;;GAGG;AACH,wBAAgB,eAAe,CAAC,KAAK,EAAE,aAAa,CAAC,WAAW,CAAC,GAAG,QAAQ,CAAC,WAAW,CAAC,CAgBxF"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Sum token-related fields across an array of execution metrics.
|
|
3
|
+
* Returns only token totals — caller adds durationMs, model, etc.
|
|
4
|
+
*/
|
|
5
|
+
export function sumTokenMetrics(items) {
|
|
6
|
+
let inputTokens = 0;
|
|
7
|
+
let outputTokens = 0;
|
|
8
|
+
let cacheCreationTokens = 0;
|
|
9
|
+
let cacheReadTokens = 0;
|
|
10
|
+
let totalEffectiveTokens = 0;
|
|
11
|
+
for (const m of items) {
|
|
12
|
+
inputTokens += m.inputTokens;
|
|
13
|
+
outputTokens += m.outputTokens;
|
|
14
|
+
cacheCreationTokens += m.cacheCreationTokens ?? 0;
|
|
15
|
+
cacheReadTokens += m.cacheReadTokens ?? 0;
|
|
16
|
+
totalEffectiveTokens += m.totalEffectiveTokens;
|
|
17
|
+
}
|
|
18
|
+
return { inputTokens, outputTokens, cacheCreationTokens, cacheReadTokens, totalEffectiveTokens };
|
|
19
|
+
}
|
|
20
|
+
//# sourceMappingURL=sumTokenMetrics.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sumTokenMetrics.js","sourceRoot":"","sources":["../../src/utils/sumTokenMetrics.ts"],"names":[],"mappings":"AAIA;;;GAGG;AACH,MAAM,UAAU,eAAe,CAAC,KAAiC;IAC/D,IAAI,WAAW,GAAG,CAAC,CAAC;IACpB,IAAI,YAAY,GAAG,CAAC,CAAC;IACrB,IAAI,mBAAmB,GAAG,CAAC,CAAC;IAC5B,IAAI,eAAe,GAAG,CAAC,CAAC;IACxB,IAAI,oBAAoB,GAAG,CAAC,CAAC;IAE7B,KAAK,MAAM,CAAC,IAAI,KAAK,EAAE,CAAC;QACtB,WAAW,IAAI,CAAC,CAAC,WAAW,CAAC;QAC7B,YAAY,IAAI,CAAC,CAAC,YAAY,CAAC;QAC/B,mBAAmB,IAAI,CAAC,CAAC,mBAAmB,IAAI,CAAC,CAAC;QAClD,eAAe,IAAI,CAAC,CAAC,eAAe,IAAI,CAAC,CAAC;QAC1C,oBAAoB,IAAI,CAAC,CAAC,oBAAoB,CAAC;IACjD,CAAC;IAED,OAAO,EAAE,WAAW,EAAE,YAAY,EAAE,mBAAmB,EAAE,eAAe,EAAE,oBAAoB,EAAE,CAAC;AACnG,CAAC"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Topological sort for workflow phase DAG execution.
|
|
3
|
+
*
|
|
4
|
+
* Groups phases into execution levels where all phases in a level
|
|
5
|
+
* have their dependencies satisfied by phases in earlier levels.
|
|
6
|
+
* Phases within the same level are independent and can run in parallel.
|
|
7
|
+
*/
|
|
8
|
+
interface HasDependencies {
|
|
9
|
+
id: string;
|
|
10
|
+
depends_on?: string[];
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* Group phases into topological execution levels.
|
|
14
|
+
*
|
|
15
|
+
* Level 0 contains phases with no dependencies (root set).
|
|
16
|
+
* Level N contains phases whose dependencies are all in levels 0..N-1.
|
|
17
|
+
* Phases within the same level are independent by construction.
|
|
18
|
+
*
|
|
19
|
+
* @throws Error if the dependency graph contains a cycle
|
|
20
|
+
* @throws Error if a dependency references a non-existent phase
|
|
21
|
+
*/
|
|
22
|
+
export declare function topoGroupLevels<T extends HasDependencies>(phases: T[]): T[][];
|
|
23
|
+
export {};
|
|
24
|
+
//# sourceMappingURL=topoSort.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"topoSort.d.ts","sourceRoot":"","sources":["../../src/utils/topoSort.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,UAAU,eAAe;IACvB,EAAE,EAAE,MAAM,CAAC;IACX,UAAU,CAAC,EAAE,MAAM,EAAE,CAAC;CACvB;AAED;;;;;;;;;GASG;AACH,wBAAgB,eAAe,CAAC,CAAC,SAAS,eAAe,EAAE,MAAM,EAAE,CAAC,EAAE,GAAG,CAAC,EAAE,EAAE,CAqD7E"}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Topological sort for workflow phase DAG execution.
|
|
3
|
+
*
|
|
4
|
+
* Groups phases into execution levels where all phases in a level
|
|
5
|
+
* have their dependencies satisfied by phases in earlier levels.
|
|
6
|
+
* Phases within the same level are independent and can run in parallel.
|
|
7
|
+
*/
|
|
8
|
+
/**
|
|
9
|
+
* Group phases into topological execution levels.
|
|
10
|
+
*
|
|
11
|
+
* Level 0 contains phases with no dependencies (root set).
|
|
12
|
+
* Level N contains phases whose dependencies are all in levels 0..N-1.
|
|
13
|
+
* Phases within the same level are independent by construction.
|
|
14
|
+
*
|
|
15
|
+
* @throws Error if the dependency graph contains a cycle
|
|
16
|
+
* @throws Error if a dependency references a non-existent phase
|
|
17
|
+
*/
|
|
18
|
+
export function topoGroupLevels(phases) {
|
|
19
|
+
if (phases.length === 0)
|
|
20
|
+
return [];
|
|
21
|
+
const phaseMap = new Map();
|
|
22
|
+
for (const phase of phases) {
|
|
23
|
+
phaseMap.set(phase.id, phase);
|
|
24
|
+
}
|
|
25
|
+
// Validate all dependencies reference existing phases
|
|
26
|
+
for (const phase of phases) {
|
|
27
|
+
for (const dep of phase.depends_on ?? []) {
|
|
28
|
+
if (!phaseMap.has(dep)) {
|
|
29
|
+
throw new Error(`Phase "${phase.id}" depends on "${dep}" which does not exist`);
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
const levels = [];
|
|
34
|
+
const placed = new Set();
|
|
35
|
+
while (placed.size < phases.length) {
|
|
36
|
+
const level = [];
|
|
37
|
+
for (const phase of phases) {
|
|
38
|
+
if (placed.has(phase.id))
|
|
39
|
+
continue;
|
|
40
|
+
const deps = phase.depends_on ?? [];
|
|
41
|
+
const allDepsSatisfied = deps.every(dep => placed.has(dep));
|
|
42
|
+
if (allDepsSatisfied) {
|
|
43
|
+
level.push(phase);
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
if (level.length === 0) {
|
|
47
|
+
// No progress possible — cycle detected
|
|
48
|
+
const remaining = phases
|
|
49
|
+
.filter(p => !placed.has(p.id))
|
|
50
|
+
.map(p => p.id);
|
|
51
|
+
throw new Error(`Cycle detected in phase dependencies: ${remaining.join(', ')}`);
|
|
52
|
+
}
|
|
53
|
+
for (const phase of level) {
|
|
54
|
+
placed.add(phase.id);
|
|
55
|
+
}
|
|
56
|
+
levels.push(level);
|
|
57
|
+
}
|
|
58
|
+
return levels;
|
|
59
|
+
}
|
|
60
|
+
//# sourceMappingURL=topoSort.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"topoSort.js","sourceRoot":"","sources":["../../src/utils/topoSort.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAOH;;;;;;;;;GASG;AACH,MAAM,UAAU,eAAe,CAA4B,MAAW;IACpE,IAAI,MAAM,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,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AM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC;iBAC9B,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC;YAClB,MAAM,IAAI,KAAK,CACb,yCAAyC,SAAS,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAChE,CAAC;QACJ,CAAC;QAED,KAAK,MAAM,KAAK,IAAI,KAAK,EAAE,CAAC;YAC1B,MAAM,CAAC,GAAG,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC;QACvB,CAAC;QACD,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;IACrB,CAAC;IAED,OAAO,MAAM,CAAC;AAChB,CAAC"}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import type { ResolvedConfig } from '../types/config.js';
|
|
2
|
+
import type { ExecutionResult } from '../types/execution.js';
|
|
3
|
+
import type { AgentResult } from '../types/agent.js';
|
|
4
|
+
import type { RunSubmission, RunSubmissionResponse, RunHistoryEntry, ValidationQueryOptions } from '../types/validation.js';
|
|
5
|
+
/**
|
|
6
|
+
* Thin wrapper around @uluops/ops-sdk for execution result submission.
|
|
7
|
+
*
|
|
8
|
+
* Delegates all API operations to OpsClient (which handles retry,
|
|
9
|
+
* rate limiting, error mapping, auth). This class transforms
|
|
10
|
+
* SDK ExecutionResult objects into the format expected by OpsClient.
|
|
11
|
+
*
|
|
12
|
+
* For full issue management, analytics, and taxonomy operations,
|
|
13
|
+
* use `@uluops/ops-sdk` directly.
|
|
14
|
+
*/
|
|
15
|
+
export declare class ValidationClient {
|
|
16
|
+
private config;
|
|
17
|
+
private ops;
|
|
18
|
+
constructor(config: ResolvedConfig);
|
|
19
|
+
/**
|
|
20
|
+
* Submit execution results to validation service
|
|
21
|
+
*/
|
|
22
|
+
submit(submission: RunSubmission): Promise<RunSubmissionResponse>;
|
|
23
|
+
/**
|
|
24
|
+
* Preview what a submission would do without saving (dry run).
|
|
25
|
+
*
|
|
26
|
+
* Accepts individual parameters matching the public UluOpsClient API.
|
|
27
|
+
*/
|
|
28
|
+
validateRun(project: string, workflowType: string, result: ExecutionResult | AgentResult): Promise<{
|
|
29
|
+
wouldCreate: boolean;
|
|
30
|
+
wouldUpdate: boolean;
|
|
31
|
+
wouldRegress: boolean;
|
|
32
|
+
validationErrors: string[];
|
|
33
|
+
}>;
|
|
34
|
+
/**
|
|
35
|
+
* Get run history for a project
|
|
36
|
+
*/
|
|
37
|
+
getHistory(project: string, options?: Omit<ValidationQueryOptions, 'project'>): Promise<RunHistoryEntry[]>;
|
|
38
|
+
/**
|
|
39
|
+
* Get details for a specific run by ID
|
|
40
|
+
*/
|
|
41
|
+
getRun(runId: string): Promise<RunSubmissionResponse>;
|
|
42
|
+
/**
|
|
43
|
+
* Transform SDK RunSubmission to OpsClient SaveFeaturesListInput format
|
|
44
|
+
*/
|
|
45
|
+
private transformToOpsInput;
|
|
46
|
+
/**
|
|
47
|
+
* Create a local-only response when tracking is disabled
|
|
48
|
+
*/
|
|
49
|
+
private createLocalResponse;
|
|
50
|
+
}
|
|
51
|
+
//# sourceMappingURL=ValidationClient.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ValidationClient.d.ts","sourceRoot":"","sources":["../../src/validation/ValidationClient.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACzD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAC7D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AACrD,OAAO,KAAK,EAAE,aAAa,EAAE,qBAAqB,EAAE,eAAe,EAAE,sBAAsB,EAAE,MAAM,wBAAwB,CAAC;AAE5H;;;;;;;;;GASG;AACH,qBAAa,gBAAgB;IAGf,OAAO,CAAC,MAAM;IAF1B,OAAO,CAAC,GAAG,CAAY;gBAEH,MAAM,EAAE,cAAc;IAQ1C;;OAEG;IACG,MAAM,CAAC,UAAU,EAAE,aAAa,GAAG,OAAO,CAAC,qBAAqB,CAAC;IAwBvE;;;;OAIG;IACG,WAAW,CACf,OAAO,EAAE,MAAM,EACf,YAAY,EAAE,MAAM,EACpB,MAAM,EAAE,eAAe,GAAG,WAAW,GACpC,OAAO,CAAC;QACT,WAAW,EAAE,OAAO,CAAC;QACrB,WAAW,EAAE,OAAO,CAAC;QACrB,YAAY,EAAE,OAAO,CAAC;QACtB,gBAAgB,EAAE,MAAM,EAAE,CAAC;KAC5B,CAAC;IAYF;;OAEG;IACG,UAAU,CACd,OAAO,EAAE,MAAM,EACf,OAAO,CAAC,EAAE,IAAI,CAAC,sBAAsB,EAAE,SAAS,CAAC,GAChD,OAAO,CAAC,eAAe,EAAE,CAAC;IAuB7B;;OAEG;IACG,MAAM,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAAC,qBAAqB,CAAC;IAkB3D;;OAEG;IACH,OAAO,CAAC,mBAAmB;IAqD3B;;OAEG;IACH,OAAO,CAAC,mBAAmB;CAgB5B"}
|
|
@@ -0,0 +1,179 @@
|
|
|
1
|
+
import { OpsClient } from '@uluops/ops-sdk';
|
|
2
|
+
/**
|
|
3
|
+
* Thin wrapper around @uluops/ops-sdk for execution result submission.
|
|
4
|
+
*
|
|
5
|
+
* Delegates all API operations to OpsClient (which handles retry,
|
|
6
|
+
* rate limiting, error mapping, auth). This class transforms
|
|
7
|
+
* SDK ExecutionResult objects into the format expected by OpsClient.
|
|
8
|
+
*
|
|
9
|
+
* For full issue management, analytics, and taxonomy operations,
|
|
10
|
+
* use `@uluops/ops-sdk` directly.
|
|
11
|
+
*/
|
|
12
|
+
export class ValidationClient {
|
|
13
|
+
config;
|
|
14
|
+
ops;
|
|
15
|
+
constructor(config) {
|
|
16
|
+
this.config = config;
|
|
17
|
+
this.ops = new OpsClient({
|
|
18
|
+
apiKey: config.apiKey,
|
|
19
|
+
baseUrl: config.validationUrl,
|
|
20
|
+
timeout: config.timeout,
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* Submit execution results to validation service
|
|
25
|
+
*/
|
|
26
|
+
async submit(submission) {
|
|
27
|
+
if (!this.config.trackingEnabled) {
|
|
28
|
+
return this.createLocalResponse(submission);
|
|
29
|
+
}
|
|
30
|
+
const input = this.transformToOpsInput(submission);
|
|
31
|
+
const response = await this.ops.runs.save(input);
|
|
32
|
+
return {
|
|
33
|
+
runId: response.run.id,
|
|
34
|
+
runNumber: response.run.runNumber,
|
|
35
|
+
projectId: response.run.projectId,
|
|
36
|
+
dashboardUrl: `${this.config.dashboardUrl}/runs/${response.run.id}`,
|
|
37
|
+
allGatesPassed: response.run.allGatesPassed,
|
|
38
|
+
averageScore: response.run.averageScore ?? 0,
|
|
39
|
+
correlation: {
|
|
40
|
+
newIssues: response.correlation?.newIssues ?? 0,
|
|
41
|
+
recurringIssues: response.correlation?.recurringIssues ?? 0,
|
|
42
|
+
regressions: response.correlation?.regressions ?? 0,
|
|
43
|
+
},
|
|
44
|
+
deduplicated: response.deduplicated,
|
|
45
|
+
};
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* Preview what a submission would do without saving (dry run).
|
|
49
|
+
*
|
|
50
|
+
* Accepts individual parameters matching the public UluOpsClient API.
|
|
51
|
+
*/
|
|
52
|
+
async validateRun(project, workflowType, result) {
|
|
53
|
+
const input = this.transformToOpsInput({ project, workflowType, result });
|
|
54
|
+
const response = await this.ops.runs.validate(input);
|
|
55
|
+
return {
|
|
56
|
+
wouldCreate: Boolean(response.wouldCreate),
|
|
57
|
+
wouldUpdate: Boolean(response.wouldUpdate),
|
|
58
|
+
wouldRegress: Boolean(response.wouldRegress),
|
|
59
|
+
validationErrors: response.validationErrors,
|
|
60
|
+
};
|
|
61
|
+
}
|
|
62
|
+
/**
|
|
63
|
+
* Get run history for a project
|
|
64
|
+
*/
|
|
65
|
+
async getHistory(project, options) {
|
|
66
|
+
const runs = await this.ops.runs.listByProject(project, {
|
|
67
|
+
workflowType: options?.workflowType,
|
|
68
|
+
limit: options?.limit,
|
|
69
|
+
});
|
|
70
|
+
return runs.map(r => ({
|
|
71
|
+
id: r.id,
|
|
72
|
+
projectId: r.projectId,
|
|
73
|
+
runNumber: r.runNumber,
|
|
74
|
+
workflowType: r.workflowType,
|
|
75
|
+
timestamp: r.timestamp,
|
|
76
|
+
allGatesPassed: r.allGatesPassed,
|
|
77
|
+
averageScore: r.averageScore ?? 0,
|
|
78
|
+
rawMarkdown: r.rawMarkdown ?? undefined,
|
|
79
|
+
archivedAt: r.archivedAt ?? undefined,
|
|
80
|
+
archiveReason: r.archiveReason ?? undefined,
|
|
81
|
+
idempotencyKey: r.idempotencyKey,
|
|
82
|
+
createdAt: r.createdAt,
|
|
83
|
+
updatedAt: r.updatedAt ?? r.createdAt,
|
|
84
|
+
}));
|
|
85
|
+
}
|
|
86
|
+
/**
|
|
87
|
+
* Get details for a specific run by ID
|
|
88
|
+
*/
|
|
89
|
+
async getRun(runId) {
|
|
90
|
+
const run = await this.ops.runs.get(runId);
|
|
91
|
+
return {
|
|
92
|
+
runId: run.id,
|
|
93
|
+
runNumber: run.runNumber,
|
|
94
|
+
projectId: run.projectId,
|
|
95
|
+
dashboardUrl: `${this.config.dashboardUrl}/runs/${run.id}`,
|
|
96
|
+
allGatesPassed: run.allGatesPassed,
|
|
97
|
+
averageScore: run.averageScore ?? 0,
|
|
98
|
+
correlation: { newIssues: 0, recurringIssues: 0, regressions: 0 },
|
|
99
|
+
deduplicated: false,
|
|
100
|
+
};
|
|
101
|
+
}
|
|
102
|
+
// ─────────────────────────────────────────────────────────────────────────────
|
|
103
|
+
// Private Methods
|
|
104
|
+
// ─────────────────────────────────────────────────────────────────────────────
|
|
105
|
+
/**
|
|
106
|
+
* Transform SDK RunSubmission to OpsClient SaveFeaturesListInput format
|
|
107
|
+
*/
|
|
108
|
+
transformToOpsInput(submission) {
|
|
109
|
+
const { result } = submission;
|
|
110
|
+
return {
|
|
111
|
+
project: submission.project,
|
|
112
|
+
workflowType: submission.workflowType,
|
|
113
|
+
idempotencyKey: submission.idempotencyKey,
|
|
114
|
+
agents: [{
|
|
115
|
+
name: result.name,
|
|
116
|
+
score: result.score ?? 0,
|
|
117
|
+
maxScore: 100,
|
|
118
|
+
decision: result.decision,
|
|
119
|
+
model: result.metrics.model,
|
|
120
|
+
tokens: {
|
|
121
|
+
inputTokens: result.metrics.inputTokens,
|
|
122
|
+
outputTokens: result.metrics.outputTokens,
|
|
123
|
+
cacheCreationTokens: result.metrics.cacheCreationTokens,
|
|
124
|
+
cacheReadTokens: result.metrics.cacheReadTokens,
|
|
125
|
+
totalEffectiveTokens: result.metrics.totalEffectiveTokens,
|
|
126
|
+
},
|
|
127
|
+
durationMs: result.metrics.durationMs,
|
|
128
|
+
}],
|
|
129
|
+
recommendations: result.recommendations.map(r => ({
|
|
130
|
+
agent: r.validator ?? 'unknown',
|
|
131
|
+
validator: r.validator ?? 'unknown',
|
|
132
|
+
title: r.title,
|
|
133
|
+
priority: r.priority,
|
|
134
|
+
severity: r.severity,
|
|
135
|
+
failureCode: r.failureCode,
|
|
136
|
+
failureDomain: r.failureDomain,
|
|
137
|
+
failureMode: r.failureMode,
|
|
138
|
+
category: r.category,
|
|
139
|
+
filePath: r.filePath,
|
|
140
|
+
lineNumber: r.lineNumber,
|
|
141
|
+
description: r.description,
|
|
142
|
+
classificationConfidence: r.classificationConfidence,
|
|
143
|
+
classifiedBy: r.classifiedBy,
|
|
144
|
+
secondaryFailureCodes: r.secondaryFailureCodes,
|
|
145
|
+
taxonomyVersion: r.taxonomyVersion,
|
|
146
|
+
})),
|
|
147
|
+
timestamp: new Date().toISOString(),
|
|
148
|
+
rawMarkdown: submission.rawMarkdown,
|
|
149
|
+
summary: {
|
|
150
|
+
allGatesPassed: result.decision === 'PASS' || result.decision === 'SHIP',
|
|
151
|
+
averageScore: result.score ?? 0,
|
|
152
|
+
},
|
|
153
|
+
definitionType: result.type,
|
|
154
|
+
definitionName: result.name,
|
|
155
|
+
definitionVersion: result.version !== 'unknown' ? result.version : undefined,
|
|
156
|
+
definitionHash: result.definitionHash?.replace(/^sha256:/, ''),
|
|
157
|
+
};
|
|
158
|
+
}
|
|
159
|
+
/**
|
|
160
|
+
* Create a local-only response when tracking is disabled
|
|
161
|
+
*/
|
|
162
|
+
createLocalResponse(submission) {
|
|
163
|
+
return {
|
|
164
|
+
runId: 'local',
|
|
165
|
+
runNumber: 0,
|
|
166
|
+
projectId: 'local',
|
|
167
|
+
dashboardUrl: '',
|
|
168
|
+
allGatesPassed: submission.result.decision === 'PASS' || submission.result.decision === 'SHIP',
|
|
169
|
+
averageScore: submission.result.score ?? 0,
|
|
170
|
+
correlation: {
|
|
171
|
+
newIssues: submission.result.recommendations.length,
|
|
172
|
+
recurringIssues: 0,
|
|
173
|
+
regressions: 0,
|
|
174
|
+
},
|
|
175
|
+
deduplicated: false,
|
|
176
|
+
};
|
|
177
|
+
}
|
|
178
|
+
}
|
|
179
|
+
//# sourceMappingURL=ValidationClient.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ValidationClient.js","sourceRoot":"","sources":["../../src/validation/ValidationClient.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAM5C;;;;;;;;;GASG;AACH,MAAM,OAAO,gBAAgB;IAGP;IAFZ,GAAG,CAAY;IAEvB,YAAoB,MAAsB;QAAtB,WAAM,GAAN,MAAM,CAAgB;QACxC,IAAI,CAAC,GAAG,GAAG,IAAI,SAAS,CAAC;YACvB,MAAM,EAAE,MAAM,CAAC,MAAM;YACrB,OAAO,EAAE,MAAM,CAAC,aAAa;YAC7B,OAAO,EAAE,MAAM,CAAC,OAAO;SACxB,CAAC,CAAC;IACL,CAAC;IAED;;OAEG;IACH,KAAK,CAAC,MAAM,CAAC,UAAyB;QACpC,IAAI,CAAC,IAAI,CAAC,MA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AM,CAAC,cAAc,EAAE,OAAO,CAAC,UAAU,EAAE,EAAE,CAAC;SAC/D,CAAC;IACJ,CAAC;IAED;;OAEG;IACK,mBAAmB,CAAC,UAAyB;QACnD,OAAO;YACL,KAAK,EAAE,OAAO;YACd,SAAS,EAAE,CAAC;YACZ,SAAS,EAAE,OAAO;YAClB,YAAY,EAAE,EAAE;YAChB,cAAc,EAAE,UAAU,CAAC,MAAM,CAAC,QAAQ,KAAK,MAAM,IAAI,UAAU,CAAC,MAAM,CAAC,QAAQ,KAAK,MAAM;YAC9F,YAAY,EAAE,UAAU,CAAC,MAAM,CAAC,KAAK,IAAI,CAAC;YAC1C,WAAW,EAAE;gBACX,SAAS,EAAE,UAAU,CAAC,MAAM,CAAC,eAAe,CAAC,MAAM;gBACnD,eAAe,EAAE,CAAC;gBAClB,WAAW,EAAE,CAAC;aACf;YACD,YAAY,EAAE,KAAK;SACpB,CAAC;IACJ,CAAC;CACF"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/validation/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/validation/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC"}
|
package/package.json
ADDED
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@uluops/core",
|
|
3
|
+
"version": "0.5.0",
|
|
4
|
+
"description": "The foundational execution engine for UluOps. Orchestrates AI-powered code analysis through a 4-layer execution hierarchy (Agent > Command > Workflow > Pipeline), manages LLM tool loops via Vercel AI SDK, and integrates with UluOps Registry and Validation services.",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"main": "dist/index.js",
|
|
7
|
+
"types": "dist/index.d.ts",
|
|
8
|
+
"exports": {
|
|
9
|
+
".": {
|
|
10
|
+
"import": "./dist/index.js",
|
|
11
|
+
"types": "./dist/index.d.ts"
|
|
12
|
+
},
|
|
13
|
+
"./types": {
|
|
14
|
+
"import": "./dist/types/index.js",
|
|
15
|
+
"types": "./dist/types/index.d.ts"
|
|
16
|
+
},
|
|
17
|
+
"./errors": {
|
|
18
|
+
"import": "./dist/errors/index.js",
|
|
19
|
+
"types": "./dist/errors/index.d.ts"
|
|
20
|
+
}
|
|
21
|
+
},
|
|
22
|
+
"files": [
|
|
23
|
+
"dist",
|
|
24
|
+
"definitions"
|
|
25
|
+
],
|
|
26
|
+
"scripts": {
|
|
27
|
+
"build": "tsc",
|
|
28
|
+
"typecheck": "tsc --noEmit",
|
|
29
|
+
"test": "vitest run",
|
|
30
|
+
"test:watch": "vitest watch",
|
|
31
|
+
"test:coverage": "vitest run --coverage",
|
|
32
|
+
"lint": "eslint src/",
|
|
33
|
+
"prepublishOnly": "npm run build"
|
|
34
|
+
},
|
|
35
|
+
"keywords": [
|
|
36
|
+
"uluops",
|
|
37
|
+
"validation",
|
|
38
|
+
"agent",
|
|
39
|
+
"workflow",
|
|
40
|
+
"pipeline",
|
|
41
|
+
"sdk",
|
|
42
|
+
"llm",
|
|
43
|
+
"ai"
|
|
44
|
+
],
|
|
45
|
+
"author": "Uluops <engineering@uluops.com>",
|
|
46
|
+
"license": "MIT",
|
|
47
|
+
"repository": {
|
|
48
|
+
"type": "git",
|
|
49
|
+
"url": "git+https://github.com/Uluops/uluops-core.git"
|
|
50
|
+
},
|
|
51
|
+
"dependencies": {
|
|
52
|
+
"@ai-sdk/anthropic": "^3.0.0",
|
|
53
|
+
"@ai-sdk/google": "^3.0.31",
|
|
54
|
+
"@ai-sdk/openai": "^3.0.33",
|
|
55
|
+
"@uluops/ops-sdk": "^1.1.0",
|
|
56
|
+
"@uluops/registry-sdk": "^0.3.0",
|
|
57
|
+
"@uluops/sdk-core": "^0.5.0",
|
|
58
|
+
"ai": "^6.0.0",
|
|
59
|
+
"glob": "^11.0.0",
|
|
60
|
+
"yaml": "^2.7.0",
|
|
61
|
+
"zod": "^3.24.1"
|
|
62
|
+
},
|
|
63
|
+
"devDependencies": {
|
|
64
|
+
"@types/node": "^22.12.0",
|
|
65
|
+
"@typescript-eslint/eslint-plugin": "^8.54.0",
|
|
66
|
+
"@typescript-eslint/parser": "^8.54.0",
|
|
67
|
+
"eslint": "^9.39.2",
|
|
68
|
+
"nock": "^14.0.1",
|
|
69
|
+
"typescript": "^5.7.3",
|
|
70
|
+
"typescript-eslint": "^8.54.0",
|
|
71
|
+
"vitest": "^3.0.4"
|
|
72
|
+
},
|
|
73
|
+
"engines": {
|
|
74
|
+
"node": ">=18.0.0"
|
|
75
|
+
}
|
|
76
|
+
}
|