@kb-labs/agent-contracts 2.89.0 → 2.93.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/index.d.ts +19 -18
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
|
@@ -86,7 +86,7 @@ interface LLMCallEvent extends BaseTraceEntry {
|
|
|
86
86
|
toolCalls?: Array<{
|
|
87
87
|
id: string;
|
|
88
88
|
name: string;
|
|
89
|
-
input:
|
|
89
|
+
input: Record<string, unknown>;
|
|
90
90
|
}>;
|
|
91
91
|
stopReason: 'tool_use' | 'end_turn' | 'max_tokens' | 'stop_sequence';
|
|
92
92
|
usage: {
|
|
@@ -117,10 +117,10 @@ interface ToolExecutionEvent extends BaseTraceEntry {
|
|
|
117
117
|
name: string;
|
|
118
118
|
callId: string;
|
|
119
119
|
};
|
|
120
|
-
input:
|
|
120
|
+
input: Record<string, unknown>;
|
|
121
121
|
output: {
|
|
122
122
|
success: boolean;
|
|
123
|
-
result?:
|
|
123
|
+
result?: unknown;
|
|
124
124
|
error?: {
|
|
125
125
|
message: string;
|
|
126
126
|
code?: string;
|
|
@@ -137,7 +137,7 @@ interface ToolExecutionEvent extends BaseTraceEntry {
|
|
|
137
137
|
metadata?: {
|
|
138
138
|
filesRead?: string[];
|
|
139
139
|
searchesPerformed?: number;
|
|
140
|
-
[key: string]:
|
|
140
|
+
[key: string]: unknown;
|
|
141
141
|
};
|
|
142
142
|
}
|
|
143
143
|
/**
|
|
@@ -148,7 +148,7 @@ interface MemorySnapshotEvent extends BaseTraceEntry {
|
|
|
148
148
|
iteration: number;
|
|
149
149
|
sessionMemory: {
|
|
150
150
|
conversationHistory: number;
|
|
151
|
-
userPreferences: Record<string,
|
|
151
|
+
userPreferences: Record<string, unknown>;
|
|
152
152
|
};
|
|
153
153
|
sharedMemory: {
|
|
154
154
|
facts: string[];
|
|
@@ -320,14 +320,14 @@ interface ErrorCapturedEvent extends BaseTraceEntry {
|
|
|
320
320
|
};
|
|
321
321
|
context: {
|
|
322
322
|
lastLLMCall?: {
|
|
323
|
-
request:
|
|
324
|
-
response:
|
|
323
|
+
request: Record<string, unknown>;
|
|
324
|
+
response: Record<string, unknown>;
|
|
325
325
|
durationMs: number;
|
|
326
326
|
};
|
|
327
327
|
lastToolCall?: {
|
|
328
328
|
name: string;
|
|
329
|
-
input:
|
|
330
|
-
output?:
|
|
329
|
+
input: Record<string, unknown>;
|
|
330
|
+
output?: unknown;
|
|
331
331
|
error?: string;
|
|
332
332
|
};
|
|
333
333
|
currentMessages: Array<{
|
|
@@ -2771,10 +2771,11 @@ type AgentAnalyticsEvent = typeof AGENT_ANALYTICS_EVENTS[keyof typeof AGENT_ANAL
|
|
|
2771
2771
|
* All trace commands support --json flag and return structured responses
|
|
2772
2772
|
* with this format for agent-to-agent debugging.
|
|
2773
2773
|
*/
|
|
2774
|
+
|
|
2774
2775
|
/**
|
|
2775
2776
|
* Base response for all trace commands (AI-friendly)
|
|
2776
2777
|
*/
|
|
2777
|
-
interface TraceCommandResponse<T =
|
|
2778
|
+
interface TraceCommandResponse<T = unknown> {
|
|
2778
2779
|
/** Whether command succeeded */
|
|
2779
2780
|
success: boolean;
|
|
2780
2781
|
/** Command name (e.g., "trace:stats") */
|
|
@@ -2787,7 +2788,7 @@ interface TraceCommandResponse<T = any> {
|
|
|
2787
2788
|
error?: {
|
|
2788
2789
|
code: string;
|
|
2789
2790
|
message: string;
|
|
2790
|
-
details?:
|
|
2791
|
+
details?: unknown;
|
|
2791
2792
|
};
|
|
2792
2793
|
/** Summary for quick reading */
|
|
2793
2794
|
summary: {
|
|
@@ -2839,7 +2840,7 @@ interface StatsResponse {
|
|
|
2839
2840
|
interface FilterResponse {
|
|
2840
2841
|
taskId: string;
|
|
2841
2842
|
eventType: string;
|
|
2842
|
-
events:
|
|
2843
|
+
events: DetailedTraceEntry[];
|
|
2843
2844
|
count: number;
|
|
2844
2845
|
}
|
|
2845
2846
|
/**
|
|
@@ -2848,7 +2849,7 @@ interface FilterResponse {
|
|
|
2848
2849
|
interface TailResponse {
|
|
2849
2850
|
taskId: string;
|
|
2850
2851
|
lines: number;
|
|
2851
|
-
events:
|
|
2852
|
+
events: DetailedTraceEntry[];
|
|
2852
2853
|
}
|
|
2853
2854
|
/**
|
|
2854
2855
|
* trace:iteration response
|
|
@@ -2856,7 +2857,7 @@ interface TailResponse {
|
|
|
2856
2857
|
interface IterationResponse {
|
|
2857
2858
|
taskId: string;
|
|
2858
2859
|
iteration: number;
|
|
2859
|
-
events:
|
|
2860
|
+
events: DetailedTraceEntry[];
|
|
2860
2861
|
summary: {
|
|
2861
2862
|
eventCount: number;
|
|
2862
2863
|
llmCalls: number;
|
|
@@ -2878,7 +2879,7 @@ interface AnalyzeResponse {
|
|
|
2878
2879
|
pattern: string;
|
|
2879
2880
|
cause: string;
|
|
2880
2881
|
fix: string;
|
|
2881
|
-
examples:
|
|
2882
|
+
examples: unknown[];
|
|
2882
2883
|
}>;
|
|
2883
2884
|
recommendations: Array<{
|
|
2884
2885
|
priority: 'low' | 'medium' | 'high' | 'critical';
|
|
@@ -2930,8 +2931,8 @@ interface CompareResponse {
|
|
|
2930
2931
|
divergencePoints: Array<{
|
|
2931
2932
|
iteration: number;
|
|
2932
2933
|
reason: string;
|
|
2933
|
-
task1Event:
|
|
2934
|
-
task2Event:
|
|
2934
|
+
task1Event: unknown;
|
|
2935
|
+
task2Event: unknown;
|
|
2935
2936
|
}>;
|
|
2936
2937
|
summary: {
|
|
2937
2938
|
similar: boolean;
|
|
@@ -2986,7 +2987,7 @@ interface ReplayResponse {
|
|
|
2986
2987
|
iterations: Array<{
|
|
2987
2988
|
iteration: number;
|
|
2988
2989
|
timestamp: string;
|
|
2989
|
-
events:
|
|
2990
|
+
events: DetailedTraceEntry[];
|
|
2990
2991
|
summary: string;
|
|
2991
2992
|
}>;
|
|
2992
2993
|
totalDurationMs: number;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kb-labs/agent-contracts",
|
|
3
3
|
"description": "Type definitions and contracts for KB Labs Agents. IDs, Session, Specification, Gates, Multi-Agent types.",
|
|
4
|
-
"version": "2.
|
|
4
|
+
"version": "2.93.0",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
7
7
|
"types": "./dist/index.d.ts",
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
"tsup": "^8.5.0",
|
|
28
28
|
"typescript": "^5.6.3",
|
|
29
29
|
"vitest": "^3.2.4",
|
|
30
|
-
"@kb-labs/devkit": "2.
|
|
30
|
+
"@kb-labs/devkit": "2.93.0"
|
|
31
31
|
},
|
|
32
32
|
"engines": {
|
|
33
33
|
"node": ">=20.0.0",
|