@salesforce/plugin-agent 1.36.1 → 1.38.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 +294 -19
- package/lib/agentSessionScanner.d.ts +12 -0
- package/lib/agentSessionScanner.js +56 -0
- package/lib/agentSessionScanner.js.map +1 -0
- package/lib/commands/agent/test/run-eval.d.ts +1 -5
- package/lib/commands/agent/test/run-eval.js +54 -149
- package/lib/commands/agent/test/run-eval.js.map +1 -1
- package/lib/commands/agent/trace/delete.d.ts +21 -0
- package/lib/commands/agent/trace/delete.js +118 -0
- package/lib/commands/agent/trace/delete.js.map +1 -0
- package/lib/commands/agent/trace/list.d.ts +22 -0
- package/lib/commands/agent/trace/list.js +101 -0
- package/lib/commands/agent/trace/list.js.map +1 -0
- package/lib/commands/agent/trace/read.d.ts +75 -0
- package/lib/commands/agent/trace/read.js +308 -0
- package/lib/commands/agent/trace/read.js.map +1 -0
- package/messages/agent.test.run-eval.md +0 -4
- package/messages/agent.trace.delete.md +87 -0
- package/messages/agent.trace.list.md +87 -0
- package/messages/agent.trace.read.md +171 -0
- package/oclif.manifest.json +801 -525
- package/package.json +4 -4
- package/schemas/agent-trace-delete.json +28 -0
- package/schemas/agent-trace-list.json +34 -0
- package/schemas/agent-trace-read.json +466 -0
- package/lib/evalFormatter.d.ts +0 -30
- package/lib/evalFormatter.js +0 -263
- package/lib/evalFormatter.js.map +0 -1
- package/lib/evalNormalizer.d.ts +0 -57
- package/lib/evalNormalizer.js +0 -431
- package/lib/evalNormalizer.js.map +0 -1
- package/lib/yamlSpecTranslator.d.ts +0 -20
- package/lib/yamlSpecTranslator.js +0 -227
- package/lib/yamlSpecTranslator.js.map +0 -1
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
import { SfCommand } from '@salesforce/sf-plugins-core';
|
|
2
|
+
import { type PlannerResponse } from '@salesforce/agents';
|
|
3
|
+
export declare const DIMENSIONS: readonly ["actions", "grounding", "routing", "errors"];
|
|
4
|
+
export type Dimension = (typeof DIMENSIONS)[number];
|
|
5
|
+
export type TurnSummary = {
|
|
6
|
+
turn: number;
|
|
7
|
+
planId: string;
|
|
8
|
+
topic: string;
|
|
9
|
+
userInput: string;
|
|
10
|
+
agentResponse: string;
|
|
11
|
+
actionsExecuted: string[];
|
|
12
|
+
latencyMs: number;
|
|
13
|
+
error: string | null;
|
|
14
|
+
};
|
|
15
|
+
export type ActionsRow = {
|
|
16
|
+
dimension: 'actions';
|
|
17
|
+
turn: number;
|
|
18
|
+
planId: string;
|
|
19
|
+
action: string;
|
|
20
|
+
input: string;
|
|
21
|
+
output: string;
|
|
22
|
+
latencyMs: number;
|
|
23
|
+
error: string | null;
|
|
24
|
+
};
|
|
25
|
+
export type GroundingRow = {
|
|
26
|
+
dimension: 'grounding';
|
|
27
|
+
turn: number;
|
|
28
|
+
planId: string;
|
|
29
|
+
prompt: string;
|
|
30
|
+
response: string;
|
|
31
|
+
latencyMs: number;
|
|
32
|
+
};
|
|
33
|
+
export type RoutingRow = {
|
|
34
|
+
dimension: 'routing';
|
|
35
|
+
turn: number;
|
|
36
|
+
planId: string;
|
|
37
|
+
fromTopic: string;
|
|
38
|
+
toTopic: string;
|
|
39
|
+
intent: string;
|
|
40
|
+
};
|
|
41
|
+
export type ErrorsRow = {
|
|
42
|
+
dimension: 'errors';
|
|
43
|
+
turn: number;
|
|
44
|
+
planId: string;
|
|
45
|
+
source: string;
|
|
46
|
+
errorCode: string;
|
|
47
|
+
message: string;
|
|
48
|
+
};
|
|
49
|
+
export type DimensionRow = ActionsRow | GroundingRow | RoutingRow | ErrorsRow;
|
|
50
|
+
export type AgentTraceReadResult = {
|
|
51
|
+
sessionId: string;
|
|
52
|
+
format: 'summary' | 'detail' | 'raw';
|
|
53
|
+
dimension?: Dimension;
|
|
54
|
+
turns?: TurnSummary[];
|
|
55
|
+
detail?: DimensionRow[];
|
|
56
|
+
raw?: PlannerResponse[];
|
|
57
|
+
};
|
|
58
|
+
export default class AgentTraceRead extends SfCommand<AgentTraceReadResult> {
|
|
59
|
+
static readonly summary: string;
|
|
60
|
+
static readonly description: string;
|
|
61
|
+
static readonly examples: string[];
|
|
62
|
+
static readonly requiresProject = true;
|
|
63
|
+
static readonly flags: {
|
|
64
|
+
'session-id': import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
|
|
65
|
+
format: import("@oclif/core/interfaces").OptionFlag<"summary" | "detail" | "raw", import("@oclif/core/interfaces").CustomOptions>;
|
|
66
|
+
dimension: import("@oclif/core/interfaces").OptionFlag<"errors" | "actions" | "grounding" | "routing" | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
67
|
+
turn: import("@oclif/core/interfaces").OptionFlag<number | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
68
|
+
};
|
|
69
|
+
run(): Promise<AgentTraceReadResult>;
|
|
70
|
+
private resolveAgentId;
|
|
71
|
+
private formatOutput;
|
|
72
|
+
private formatDetail;
|
|
73
|
+
private renderDetailTable;
|
|
74
|
+
private formatSummary;
|
|
75
|
+
}
|
|
@@ -0,0 +1,308 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright 2026, Salesforce, Inc.
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
import { Flags, SfCommand } from '@salesforce/sf-plugins-core';
|
|
17
|
+
import { Messages, SfError } from '@salesforce/core';
|
|
18
|
+
import { listSessionTraces, readSessionTrace, readTurnIndex, } from '@salesforce/agents';
|
|
19
|
+
import { listAllAgentSessions } from '../../../agentSessionScanner.js';
|
|
20
|
+
Messages.importMessagesDirectoryFromMetaUrl(import.meta.url);
|
|
21
|
+
const messages = Messages.loadMessages('@salesforce/plugin-agent', 'agent.trace.read');
|
|
22
|
+
export const DIMENSIONS = ['actions', 'grounding', 'routing', 'errors'];
|
|
23
|
+
const isFunctionStep = (s) => s.type === 'FunctionStep';
|
|
24
|
+
const asFunctionWithErrors = (s) => s;
|
|
25
|
+
function summarizeTurn(turn, planId, trace) {
|
|
26
|
+
const plan = trace.plan;
|
|
27
|
+
const userInput = plan.find((s) => s.type === 'UserInputStep');
|
|
28
|
+
const finalResponse = plan.find((s) => s.type === 'PlannerResponseStep');
|
|
29
|
+
const functionSteps = plan.filter(isFunctionStep).map(asFunctionWithErrors);
|
|
30
|
+
const errorStep = functionSteps.find((s) => s.function.errors?.length);
|
|
31
|
+
const errorMsg = errorStep?.function.errors?.[0]?.message ?? null;
|
|
32
|
+
const totalLatency = functionSteps.reduce((acc, s) => acc + (s.executionLatency ?? 0), 0);
|
|
33
|
+
return {
|
|
34
|
+
turn,
|
|
35
|
+
planId,
|
|
36
|
+
topic: trace.topic,
|
|
37
|
+
userInput: userInput?.type === 'UserInputStep' ? userInput.message : '',
|
|
38
|
+
agentResponse: finalResponse?.type === 'PlannerResponseStep' ? finalResponse.message : '',
|
|
39
|
+
actionsExecuted: functionSteps.map((s) => s.function.name),
|
|
40
|
+
latencyMs: totalLatency,
|
|
41
|
+
error: errorMsg,
|
|
42
|
+
};
|
|
43
|
+
}
|
|
44
|
+
function extractActions(turn, planId, trace) {
|
|
45
|
+
return trace.plan
|
|
46
|
+
.filter(isFunctionStep)
|
|
47
|
+
.map(asFunctionWithErrors)
|
|
48
|
+
.map((step) => ({
|
|
49
|
+
dimension: 'actions',
|
|
50
|
+
turn,
|
|
51
|
+
planId,
|
|
52
|
+
action: step.function.name,
|
|
53
|
+
input: JSON.stringify(step.function.input),
|
|
54
|
+
output: JSON.stringify(step.function.output),
|
|
55
|
+
latencyMs: step.executionLatency,
|
|
56
|
+
error: step.function.errors?.length ? step.function.errors[0].message : null,
|
|
57
|
+
}));
|
|
58
|
+
}
|
|
59
|
+
function extractGrounding(turn, planId, trace) {
|
|
60
|
+
return trace.plan
|
|
61
|
+
.filter((s) => s.type === 'LLMExecutionStep')
|
|
62
|
+
.filter((s) => s.promptName.includes('React'))
|
|
63
|
+
.map((step) => ({
|
|
64
|
+
dimension: 'grounding',
|
|
65
|
+
turn,
|
|
66
|
+
planId,
|
|
67
|
+
prompt: step.promptName,
|
|
68
|
+
response: step.promptResponse.slice(0, 500),
|
|
69
|
+
latencyMs: step.executionLatency,
|
|
70
|
+
}));
|
|
71
|
+
}
|
|
72
|
+
function extractRouting(turn, planId, trace) {
|
|
73
|
+
const topicStep = trace.plan.find((s) => s.type === 'UpdateTopicStep');
|
|
74
|
+
const eventStep = trace.plan.find((s) => s.type === 'EventStep' && s.eventName === 'topicChangeEvent');
|
|
75
|
+
const fromTopic = eventStep?.type === 'EventStep' ? eventStep.payload.oldTopic : 'null';
|
|
76
|
+
const toTopic = topicStep?.type === 'UpdateTopicStep' ? topicStep.topic : trace.topic;
|
|
77
|
+
return [{ dimension: 'routing', turn, planId, fromTopic, toTopic, intent: trace.intent }];
|
|
78
|
+
}
|
|
79
|
+
function extractErrors(turn, planId, trace) {
|
|
80
|
+
const rows = [];
|
|
81
|
+
for (const step of trace.plan) {
|
|
82
|
+
if (step.type === 'FunctionStep') {
|
|
83
|
+
const errors = asFunctionWithErrors(step).function.errors ?? [];
|
|
84
|
+
for (const e of errors) {
|
|
85
|
+
rows.push({
|
|
86
|
+
dimension: 'errors',
|
|
87
|
+
turn,
|
|
88
|
+
planId,
|
|
89
|
+
source: step.function.name,
|
|
90
|
+
errorCode: e.statusCode,
|
|
91
|
+
message: e.message,
|
|
92
|
+
});
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
if (step.type === 'EventStep' && step.isError) {
|
|
96
|
+
rows.push({
|
|
97
|
+
dimension: 'errors',
|
|
98
|
+
turn,
|
|
99
|
+
planId,
|
|
100
|
+
source: step.eventName,
|
|
101
|
+
errorCode: 'EVENT_ERROR',
|
|
102
|
+
message: JSON.stringify(step.payload),
|
|
103
|
+
});
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
return rows;
|
|
107
|
+
}
|
|
108
|
+
async function resolvePlanIds(agentId, sessionId, turn) {
|
|
109
|
+
const turnIndex = await readTurnIndex(agentId, sessionId);
|
|
110
|
+
if (turn !== undefined) {
|
|
111
|
+
// Try the turn index first (planId may be null if trace wasn't correlated)
|
|
112
|
+
const entry = turnIndex?.turns.find((t) => t.turn === turn && t.planId);
|
|
113
|
+
if (entry?.planId) {
|
|
114
|
+
return [{ turn: entry.turn, planId: entry.planId }];
|
|
115
|
+
}
|
|
116
|
+
// Fall back to positional order from trace files on disk
|
|
117
|
+
const traceFiles = await listSessionTraces(agentId, sessionId);
|
|
118
|
+
const byPosition = traceFiles[turn - 1];
|
|
119
|
+
if (!byPosition) {
|
|
120
|
+
throw new SfError(messages.getMessage('error.turnNotFound', [turn, sessionId]), 'TurnNotFound');
|
|
121
|
+
}
|
|
122
|
+
return [{ turn, planId: byPosition.planId }];
|
|
123
|
+
}
|
|
124
|
+
if (turnIndex) {
|
|
125
|
+
return turnIndex.turns.filter((t) => t.planId !== null).map((t) => ({ turn: t.turn, planId: t.planId }));
|
|
126
|
+
}
|
|
127
|
+
// Fall back to listing trace files when no turn index exists
|
|
128
|
+
const traceFiles = await listSessionTraces(agentId, sessionId);
|
|
129
|
+
return traceFiles.map((f, i) => ({ turn: i + 1, planId: f.planId }));
|
|
130
|
+
}
|
|
131
|
+
async function readTraces(agentId, sessionId, planIds) {
|
|
132
|
+
const traces = [];
|
|
133
|
+
const failedFiles = [];
|
|
134
|
+
for (const { turn, planId } of planIds) {
|
|
135
|
+
// eslint-disable-next-line no-await-in-loop
|
|
136
|
+
const trace = await readSessionTrace(agentId, sessionId, planId);
|
|
137
|
+
if (!trace?.plan || !Array.isArray(trace.plan)) {
|
|
138
|
+
failedFiles.push(planId);
|
|
139
|
+
continue;
|
|
140
|
+
}
|
|
141
|
+
traces.push({ turn, planId, trace });
|
|
142
|
+
}
|
|
143
|
+
return { traces, failedFiles };
|
|
144
|
+
}
|
|
145
|
+
function extractDimension(turn, planId, trace, dimension) {
|
|
146
|
+
if (dimension === 'actions')
|
|
147
|
+
return extractActions(turn, planId, trace);
|
|
148
|
+
if (dimension === 'grounding')
|
|
149
|
+
return extractGrounding(turn, planId, trace);
|
|
150
|
+
if (dimension === 'routing')
|
|
151
|
+
return extractRouting(turn, planId, trace);
|
|
152
|
+
return extractErrors(turn, planId, trace);
|
|
153
|
+
}
|
|
154
|
+
export default class AgentTraceRead extends SfCommand {
|
|
155
|
+
static summary = messages.getMessage('summary');
|
|
156
|
+
static description = messages.getMessage('description');
|
|
157
|
+
static examples = messages.getMessages('examples');
|
|
158
|
+
static requiresProject = true;
|
|
159
|
+
static flags = {
|
|
160
|
+
'session-id': Flags.string({
|
|
161
|
+
summary: messages.getMessage('flags.session-id.summary'),
|
|
162
|
+
required: true,
|
|
163
|
+
char: 's',
|
|
164
|
+
}),
|
|
165
|
+
format: Flags.option({
|
|
166
|
+
options: ['summary', 'detail', 'raw'],
|
|
167
|
+
default: 'summary',
|
|
168
|
+
summary: messages.getMessage('flags.format.summary'),
|
|
169
|
+
char: 'f',
|
|
170
|
+
})(),
|
|
171
|
+
dimension: Flags.option({
|
|
172
|
+
options: DIMENSIONS,
|
|
173
|
+
summary: messages.getMessage('flags.dimension.summary'),
|
|
174
|
+
char: 'd',
|
|
175
|
+
})(),
|
|
176
|
+
turn: Flags.integer({
|
|
177
|
+
summary: messages.getMessage('flags.turn.summary'),
|
|
178
|
+
char: 't',
|
|
179
|
+
}),
|
|
180
|
+
};
|
|
181
|
+
async run() {
|
|
182
|
+
const { flags } = await this.parse(AgentTraceRead);
|
|
183
|
+
const sessionId = flags['session-id'];
|
|
184
|
+
if (flags.format === 'detail' && !flags.dimension) {
|
|
185
|
+
throw new SfError(messages.getMessage('error.detailRequiresDimension'), 'MissingDimension');
|
|
186
|
+
}
|
|
187
|
+
if (flags.dimension && flags.format !== 'detail') {
|
|
188
|
+
this.warn(messages.getMessage('warn.dimensionIgnored', [flags.format]));
|
|
189
|
+
}
|
|
190
|
+
const agentId = await this.resolveAgentId(sessionId);
|
|
191
|
+
const planIds = await resolvePlanIds(agentId, sessionId, flags.turn);
|
|
192
|
+
if (planIds.length === 0) {
|
|
193
|
+
this.log(messages.getMessage('output.empty'));
|
|
194
|
+
return { sessionId, format: flags.format, turns: [], detail: [], raw: [] };
|
|
195
|
+
}
|
|
196
|
+
const { traces, failedFiles } = await readTraces(agentId, sessionId, planIds);
|
|
197
|
+
if (failedFiles.length > 0 && traces.length === 0) {
|
|
198
|
+
throw new SfError(messages.getMessage('error.parseFailedAll', [failedFiles.join(', ')]), 'TraceParseError');
|
|
199
|
+
}
|
|
200
|
+
if (failedFiles.length > 0) {
|
|
201
|
+
this.warn(messages.getMessage('warn.parseFailed', [failedFiles.join(', ')]));
|
|
202
|
+
}
|
|
203
|
+
return this.formatOutput(sessionId, flags.format, flags.dimension, traces);
|
|
204
|
+
}
|
|
205
|
+
async resolveAgentId(sessionId) {
|
|
206
|
+
const allSessions = await listAllAgentSessions(this.project);
|
|
207
|
+
const entry = allSessions.find((s) => s.sessionId === sessionId);
|
|
208
|
+
if (!entry) {
|
|
209
|
+
throw new SfError(messages.getMessage('error.sessionNotFound', [sessionId]), 'SessionNotFound');
|
|
210
|
+
}
|
|
211
|
+
return entry.agentId;
|
|
212
|
+
}
|
|
213
|
+
formatOutput(sessionId, format, dimension, traces) {
|
|
214
|
+
if (format === 'raw') {
|
|
215
|
+
const raw = traces.map((t) => t.trace);
|
|
216
|
+
if (!this.jsonEnabled())
|
|
217
|
+
this.log(JSON.stringify(raw, null, 2));
|
|
218
|
+
return { sessionId, format: 'raw', raw };
|
|
219
|
+
}
|
|
220
|
+
if (format === 'detail') {
|
|
221
|
+
return this.formatDetail(sessionId, dimension, traces);
|
|
222
|
+
}
|
|
223
|
+
return this.formatSummary(sessionId, traces);
|
|
224
|
+
}
|
|
225
|
+
formatDetail(sessionId, dimension, traces) {
|
|
226
|
+
const detail = traces.flatMap(({ turn, planId, trace }) => extractDimension(turn, planId, trace, dimension));
|
|
227
|
+
if (detail.length === 0) {
|
|
228
|
+
this.log(messages.getMessage('output.emptyDimension', [dimension]));
|
|
229
|
+
return { sessionId, format: 'detail', dimension, detail: [] };
|
|
230
|
+
}
|
|
231
|
+
if (!this.jsonEnabled()) {
|
|
232
|
+
this.renderDetailTable(dimension, detail);
|
|
233
|
+
}
|
|
234
|
+
return { sessionId, format: 'detail', dimension, detail };
|
|
235
|
+
}
|
|
236
|
+
renderDetailTable(dimension, detail) {
|
|
237
|
+
if (dimension === 'actions') {
|
|
238
|
+
this.table({
|
|
239
|
+
data: detail,
|
|
240
|
+
columns: [
|
|
241
|
+
{ key: 'turn', name: messages.getMessage('output.tableHeader.turn') },
|
|
242
|
+
{ key: 'action', name: messages.getMessage('output.tableHeader.action') },
|
|
243
|
+
{ key: 'input', name: messages.getMessage('output.tableHeader.input') },
|
|
244
|
+
{ key: 'output', name: messages.getMessage('output.tableHeader.output') },
|
|
245
|
+
{ key: 'latencyMs', name: messages.getMessage('output.tableHeader.latencyMs') },
|
|
246
|
+
{ key: 'error', name: messages.getMessage('output.tableHeader.error') },
|
|
247
|
+
],
|
|
248
|
+
});
|
|
249
|
+
}
|
|
250
|
+
else if (dimension === 'grounding') {
|
|
251
|
+
this.table({
|
|
252
|
+
data: detail,
|
|
253
|
+
columns: [
|
|
254
|
+
{ key: 'turn', name: messages.getMessage('output.tableHeader.turn') },
|
|
255
|
+
{ key: 'prompt', name: messages.getMessage('output.tableHeader.prompt') },
|
|
256
|
+
{ key: 'response', name: messages.getMessage('output.tableHeader.response') },
|
|
257
|
+
{ key: 'latencyMs', name: messages.getMessage('output.tableHeader.latencyMs') },
|
|
258
|
+
],
|
|
259
|
+
});
|
|
260
|
+
}
|
|
261
|
+
else if (dimension === 'routing') {
|
|
262
|
+
this.table({
|
|
263
|
+
data: detail,
|
|
264
|
+
columns: [
|
|
265
|
+
{ key: 'turn', name: messages.getMessage('output.tableHeader.turn') },
|
|
266
|
+
{ key: 'intent', name: messages.getMessage('output.tableHeader.intent') },
|
|
267
|
+
{ key: 'fromTopic', name: messages.getMessage('output.tableHeader.fromTopic') },
|
|
268
|
+
{ key: 'toTopic', name: messages.getMessage('output.tableHeader.toTopic') },
|
|
269
|
+
],
|
|
270
|
+
});
|
|
271
|
+
}
|
|
272
|
+
else {
|
|
273
|
+
this.table({
|
|
274
|
+
data: detail,
|
|
275
|
+
columns: [
|
|
276
|
+
{ key: 'turn', name: messages.getMessage('output.tableHeader.turn') },
|
|
277
|
+
{ key: 'source', name: messages.getMessage('output.tableHeader.source') },
|
|
278
|
+
{ key: 'errorCode', name: messages.getMessage('output.tableHeader.errorCode') },
|
|
279
|
+
{ key: 'message', name: messages.getMessage('output.tableHeader.message') },
|
|
280
|
+
],
|
|
281
|
+
});
|
|
282
|
+
}
|
|
283
|
+
}
|
|
284
|
+
formatSummary(sessionId, traces) {
|
|
285
|
+
const turns = traces.map(({ turn, planId, trace }) => summarizeTurn(turn, planId, trace));
|
|
286
|
+
if (!this.jsonEnabled()) {
|
|
287
|
+
this.table({
|
|
288
|
+
data: turns.map((t) => ({
|
|
289
|
+
...t,
|
|
290
|
+
actionsExecuted: t.actionsExecuted.join(', ') || '—',
|
|
291
|
+
error: t.error ?? '—',
|
|
292
|
+
latencyMs: `${t.latencyMs}ms`,
|
|
293
|
+
})),
|
|
294
|
+
columns: [
|
|
295
|
+
{ key: 'turn', name: messages.getMessage('output.tableHeader.turn') },
|
|
296
|
+
{ key: 'topic', name: messages.getMessage('output.tableHeader.topic') },
|
|
297
|
+
{ key: 'userInput', name: messages.getMessage('output.tableHeader.userInput') },
|
|
298
|
+
{ key: 'agentResponse', name: messages.getMessage('output.tableHeader.agentResponse') },
|
|
299
|
+
{ key: 'actionsExecuted', name: messages.getMessage('output.tableHeader.actionsExecuted') },
|
|
300
|
+
{ key: 'latencyMs', name: messages.getMessage('output.tableHeader.latencyMs') },
|
|
301
|
+
{ key: 'error', name: messages.getMessage('output.tableHeader.error') },
|
|
302
|
+
],
|
|
303
|
+
});
|
|
304
|
+
}
|
|
305
|
+
return { sessionId, format: 'summary', turns };
|
|
306
|
+
}
|
|
307
|
+
}
|
|
308
|
+
//# sourceMappingURL=read.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"read.js","sourceRoot":"","sources":["../../../../src/commands/agent/trace/read.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EAAE,KAAK,EAAE,SAAS,EAAE,MAAM,6BAA6B,CAAC;AAC/D,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AACrD,OAAO,EACL,iBAAiB,EACjB,gBAAgB,EAChB,aAAa,GAId,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAE,oBAAoB,EAAE,MAAM,iCAAiC,CAAC;AAEvE,QAAQ,CAAC,kCAAkC,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAC7D,MAAM,QAAQ,GAAG,QAAQ,CAAC,YAAY,CAAC,0BAA0B,EAAE,kBAAkB,CAAC,CAAC;AAEvF,MAAM,CAAC,MAAM,UAAU,GAAG,CAAC,SAAS,EAAE,WAAW,EAAE,SAAS,EAAE,QAAQ,CAAU,CAAC;AAkEjF,MAAM,cAAc,GAAG,CAAC,CAAW,EAAqB,EAAE,CAAC,CAAC,CAAC,IAAI,KAAK,cAAc,CAAC;AACrF,MAAM,oBAAoB,GAAG,CAAC,CAAe,EAA0B,EAAE,CAAC,CAA2B,CAAC;AAEtG,SAAS,aAAa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UAAU,CAAC,8BAA8B,CAAC,EAAE;oBAC/E,EAAE,GAAG,EAAE,eAAe,EAAE,IAAI,EAAE,QAAQ,CAAC,UAAU,CAAC,kCAAkC,CAAC,EAAE;oBACvF,EAAE,GAAG,EAAE,iBAAiB,EAAE,IAAI,EAAE,QAAQ,CAAC,UAAU,CAAC,oCAAoC,CAAC,EAAE;oBAC3F,EAAE,GAAG,EAAE,WAAW,EAAE,IAAI,EAAE,QAAQ,CAAC,UAAU,CAAC,8BAA8B,CAAC,EAAE;oBAC/E,EAAE,GAAG,EAAE,OAAO,EAAE,IAAI,EAAE,QAAQ,CAAC,UAAU,CAAC,0BAA0B,CAAC,EAAE;iBACxE;aACF,CAAC,CAAC;QACL,CAAC;QAED,OAAO,EAAE,SAAS,EAAE,MAAM,EAAE,SAAS,EAAE,KAAK,EAAE,CAAC;IACjD,CAAC"}
|
|
@@ -20,10 +20,6 @@ Path to test spec file (YAML or JSON). Supports reading from stdin when piping c
|
|
|
20
20
|
|
|
21
21
|
Agent DeveloperName (also called API name) to resolve agent_id and agent_version_id. Auto-inferred from the YAML spec's subjectName.
|
|
22
22
|
|
|
23
|
-
# flags.wait.summary
|
|
24
|
-
|
|
25
|
-
Number of minutes to wait for results.
|
|
26
|
-
|
|
27
23
|
# flags.result-format.summary
|
|
28
24
|
|
|
29
25
|
Format of the agent test results.
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
# summary
|
|
2
|
+
|
|
3
|
+
Delete agent preview trace files.
|
|
4
|
+
|
|
5
|
+
# description
|
|
6
|
+
|
|
7
|
+
Deletes trace files recorded during agent preview sessions. By default, shows a preview of what will be deleted and prompts for confirmation. Use --no-prompt to skip confirmation.
|
|
8
|
+
|
|
9
|
+
Without filters, deletes all traces for all agents and sessions. Use flags to narrow the scope: filter by agent name (--agent), by session (--session-id), or by age (--older-than).
|
|
10
|
+
|
|
11
|
+
# flags.agent.summary
|
|
12
|
+
|
|
13
|
+
Only delete traces for this agent name (substring match). Matches against the name used when starting the session, whether that's an authoring bundle or a published agent API name.
|
|
14
|
+
|
|
15
|
+
# flags.session-id.summary
|
|
16
|
+
|
|
17
|
+
Only delete traces from this session ID.
|
|
18
|
+
|
|
19
|
+
# flags.older-than.summary
|
|
20
|
+
|
|
21
|
+
Only delete traces older than this duration. Accepts a number followed by a unit: m/minutes, h/hours, d/days, w/weeks (e.g. 7d, 24h, 2w).
|
|
22
|
+
|
|
23
|
+
# flags.no-prompt.summary
|
|
24
|
+
|
|
25
|
+
Skip the confirmation prompt and delete immediately.
|
|
26
|
+
|
|
27
|
+
# error.invalidOlderThan
|
|
28
|
+
|
|
29
|
+
Invalid --older-than value: '%s'. Use a number followed by a unit: m/minutes, h/hours, d/days, w/weeks (e.g. 7d, 24h, 30m, 2w).
|
|
30
|
+
|
|
31
|
+
# prompt.confirm
|
|
32
|
+
|
|
33
|
+
Delete %s trace file(s)? This cannot be undone.
|
|
34
|
+
|
|
35
|
+
# output.noneFound
|
|
36
|
+
|
|
37
|
+
No trace files matched the specified filters.
|
|
38
|
+
|
|
39
|
+
# output.preview
|
|
40
|
+
|
|
41
|
+
Found %s trace file(s) to delete:
|
|
42
|
+
|
|
43
|
+
# output.cancelled
|
|
44
|
+
|
|
45
|
+
Deletion cancelled.
|
|
46
|
+
|
|
47
|
+
# output.deleted
|
|
48
|
+
|
|
49
|
+
Deleted %s trace file(s).
|
|
50
|
+
|
|
51
|
+
# output.tableHeader.agent
|
|
52
|
+
|
|
53
|
+
Agent
|
|
54
|
+
|
|
55
|
+
# output.tableHeader.sessionId
|
|
56
|
+
|
|
57
|
+
Session ID
|
|
58
|
+
|
|
59
|
+
# output.tableHeader.planId
|
|
60
|
+
|
|
61
|
+
Plan ID
|
|
62
|
+
|
|
63
|
+
# examples
|
|
64
|
+
|
|
65
|
+
- Delete all traces for all agents and sessions (with confirmation prompt):
|
|
66
|
+
|
|
67
|
+
<%= config.bin %> <%= command.id %>
|
|
68
|
+
|
|
69
|
+
- Delete all traces for a specific agent:
|
|
70
|
+
|
|
71
|
+
<%= config.bin %> <%= command.id %> --agent My_Agent
|
|
72
|
+
|
|
73
|
+
- Delete traces from a specific session:
|
|
74
|
+
|
|
75
|
+
<%= config.bin %> <%= command.id %> --session-id <SESSION_ID>
|
|
76
|
+
|
|
77
|
+
- Delete traces older than 7 days:
|
|
78
|
+
|
|
79
|
+
<%= config.bin %> <%= command.id %> --older-than 7d
|
|
80
|
+
|
|
81
|
+
- Delete traces older than 24 hours for a specific agent, no prompt:
|
|
82
|
+
|
|
83
|
+
<%= config.bin %> <%= command.id %> --agent My_Agent --older-than 24h --no-prompt
|
|
84
|
+
|
|
85
|
+
- Delete all traces without confirmation:
|
|
86
|
+
|
|
87
|
+
<%= config.bin %> <%= command.id %> --no-prompt
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
# summary
|
|
2
|
+
|
|
3
|
+
List the trace files that were recorded during all agent preview sessions.
|
|
4
|
+
|
|
5
|
+
# description
|
|
6
|
+
|
|
7
|
+
Lists trace files recorded during agent preview sessions. By default, lists all traces for all agents and all of their sessions. Use flags to narrow results: filter by agent name (--agent), by session (--session-id), or by date (--since).
|
|
8
|
+
|
|
9
|
+
Each row in the output corresponds to one trace file, which in turn corresponds to one agent session. The Agent column shows the authoring bundle or API name used when starting the session.
|
|
10
|
+
|
|
11
|
+
# flags.agent.summary
|
|
12
|
+
|
|
13
|
+
Only show traces for this agent name (substring match). Matches against the name used when starting the session, whether that's an authoring bundle or a published agent API name.
|
|
14
|
+
|
|
15
|
+
# flags.session-id.summary
|
|
16
|
+
|
|
17
|
+
Session ID used to filter the list of trace files.
|
|
18
|
+
|
|
19
|
+
# flags.since.summary
|
|
20
|
+
|
|
21
|
+
Date used to filter the list of trace files; only those recorded on or after the date are listed.
|
|
22
|
+
|
|
23
|
+
# flags.since.description
|
|
24
|
+
|
|
25
|
+
Accepts ISO 8601 format: date-only (2026-04-20), date-time (2026-04-20T14:00:00Z), or date-time with milliseconds (2026-04-20T14:00:00.000Z). The "Recorded At" values shown in the table output are valid inputs.
|
|
26
|
+
|
|
27
|
+
# error.invalidSince
|
|
28
|
+
|
|
29
|
+
Invalid --since value: '%s'. Use ISO 8601 format — date-only (2026-04-20), date-time (2026-04-20T14:00:00Z), or with milliseconds (2026-04-20T14:00:00.000Z). The "Recorded At" values shown in the table output are valid inputs.
|
|
30
|
+
|
|
31
|
+
# output.empty
|
|
32
|
+
|
|
33
|
+
No trace files found.
|
|
34
|
+
|
|
35
|
+
# output.tableHeader.agent
|
|
36
|
+
|
|
37
|
+
Agent
|
|
38
|
+
|
|
39
|
+
# output.tableHeader.sessionId
|
|
40
|
+
|
|
41
|
+
Session ID
|
|
42
|
+
|
|
43
|
+
# output.tableHeader.planId
|
|
44
|
+
|
|
45
|
+
Plan ID
|
|
46
|
+
|
|
47
|
+
# output.tableHeader.mtime
|
|
48
|
+
|
|
49
|
+
Recorded At
|
|
50
|
+
|
|
51
|
+
# output.tableHeader.size
|
|
52
|
+
|
|
53
|
+
Size
|
|
54
|
+
|
|
55
|
+
# output.tableHeader.path
|
|
56
|
+
|
|
57
|
+
Path
|
|
58
|
+
|
|
59
|
+
# examples
|
|
60
|
+
|
|
61
|
+
- List all traces for all agents and sessions:
|
|
62
|
+
|
|
63
|
+
<%= config.bin %> <%= command.id %>
|
|
64
|
+
|
|
65
|
+
- List all traces for a specific agent:
|
|
66
|
+
|
|
67
|
+
<%= config.bin %> <%= command.id %> --agent My_Agent
|
|
68
|
+
|
|
69
|
+
- List traces for a specific session:
|
|
70
|
+
|
|
71
|
+
<%= config.bin %> <%= command.id %> --session-id <SESSION_ID>
|
|
72
|
+
|
|
73
|
+
- List traces recorded on or after April 20, 2026 (date-only, interpreted as UTC midnight):
|
|
74
|
+
|
|
75
|
+
<%= config.bin %> <%= command.id %> --since 2026-04-20
|
|
76
|
+
|
|
77
|
+
- List traces recorded on or after a specific UTC time:
|
|
78
|
+
|
|
79
|
+
<%= config.bin %> <%= command.id %> --since 2026-04-20T14:00:00Z
|
|
80
|
+
|
|
81
|
+
- Filter by agent and date together:
|
|
82
|
+
|
|
83
|
+
<%= config.bin %> <%= command.id %> --agent My_Agent --since 2026-04-20
|
|
84
|
+
|
|
85
|
+
- Return results as JSON:
|
|
86
|
+
|
|
87
|
+
<%= config.bin %> <%= command.id %> --json
|