@agentguard-run/burn 0.3.9 → 0.3.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +13 -0
- package/README.md +1 -1
- package/dist/src/cli.js +6 -4
- package/dist/src/dashboard-model.d.ts +26 -2
- package/dist/src/dashboard-model.js +32 -6
- package/dist/src/dashboard-render.d.ts +1 -0
- package/dist/src/dashboard-render.js +35 -31
- package/dist/src/frames.d.ts +1 -0
- package/dist/src/insights/blocks.d.ts +2 -0
- package/dist/src/insights/blocks.js +6 -0
- package/dist/src/live-panel.js +16 -12
- package/dist/src/render-recording.d.ts +1 -0
- package/dist/src/render-recording.js +4 -1
- package/docs/assets/burn-real-stop-sep20.blocks.json +17 -0
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,18 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.3.11 (2026-09-23)
|
|
4
|
+
|
|
5
|
+
- `render --label <text>` for both the recorded render and the dashboard: a caller-supplied name for what the recording was (for example "deliberate fan-out test"), drawn in the frame and written to the provenance file. Never inferred.
|
|
6
|
+
- Dashboard: header counters step at the recorded event time, in the same frame as the log row and ring marker (no tween that lags them); the elapsed counter is labelled RECORDED TIME; the rate bar ticks read "warn at 8" and "refuse at 16"; the STOP card reads "window counter 16 of 16 · 15 active min · attempt refused"; the cost panel is titled "list cost after the run · not live", shows the final amount once with a fade (no counting up) and carries its qualifications at body size ("15 copies the gate allowed", "list price · not a bill").
|
|
7
|
+
- Recorded renders: "SPAWN ATTEMPTS IN WINDOW" (was AGENT SPAWNS), "COPIES LAUNCHED" with the tag "attempt refused", "Each copy runs its own context window." and "At the ceiling, the attempt is refused." replace the earlier explainers.
|
|
8
|
+
|
|
9
|
+
## 0.3.10 (2026-09-23)
|
|
10
|
+
|
|
11
|
+
- Dashboard render: the COPIES counter and the ring markers now count copies that launched (allowed decisions), not the ledger's spawn-attempt counter, which also counts the attempt that reached the ceiling and was refused. The rate bar is labelled SPAWN ATTEMPTS and keeps the attempt counter. The STOP card reads "attempt 16 of 16 in 15 active min · refused".
|
|
12
|
+
- Dashboard economics: `--economics` now prices only the copies the recording allowed: the earliest children, one per allowed decision, that started within a minute of the first frame. Children spawned later in the same session stay out of the dollars, and the caption says "list cost of the N copies the gate allowed · not a bill". A blocks file without child start times is refused with a message to regenerate it.
|
|
13
|
+
- `blocks --json`: every child row carries `startedAt`, the epoch milliseconds of its earliest timed usage row.
|
|
14
|
+
- Phone and wide recorded renders: the spawn line reads "16 of 16 attempts", never "allowed"; the copies grid fills one block per copy that launched, so a refused attempt leaves its block empty.
|
|
15
|
+
|
|
3
16
|
## 0.3.9 (2026-09-23)
|
|
4
17
|
|
|
5
18
|
- Dashboard render: the subagents caption wraps inside its panel on the 4:5 frame instead of crossing the panel edge.
|
package/README.md
CHANGED
|
@@ -509,7 +509,7 @@ agentguard-burn render run.jsonl --mp4 run.mp4 --gif run.gif
|
|
|
509
509
|
agentguard-burn render run.jsonl --mp4 run-phone.mp4 --phone
|
|
510
510
|
```
|
|
511
511
|
|
|
512
|
-
`--phone` renders a 1080 by 1350 frame with a stacked 40 by 36 cell layout (spawn count, spawn
|
|
512
|
+
`--phone` renders a 1080 by 1350 frame with a stacked 40 by 36 cell layout (spawn count, spawn attempts against the ceiling, one block per copy that launched, the last three decisions, the STOP card and an explainer), so a recorded run stays readable on a phone screen. The provenance file records the layout and frame size. `--label <text>` (1 to 40 printable characters) names what the recording was, for example `--label "deliberate fan-out test"`; it is drawn in the frame (phone: the explainer row; wide: the header; dashboard: the session line) and recorded in the provenance file. It is never inferred from the recording.
|
|
513
513
|
|
|
514
514
|
`record` writes each decision at its real timestamp, with one frame per second
|
|
515
515
|
between decisions. Bounds are optional and otherwise use the session's first
|
package/dist/src/cli.js
CHANGED
|
@@ -162,22 +162,24 @@ async function main(argv) {
|
|
|
162
162
|
process.stdout.write('not supported on this platform yet\n');
|
|
163
163
|
return 0;
|
|
164
164
|
}
|
|
165
|
-
const source = rest[0], mp4 = flag('--mp4'), gif = flag('--gif'), economics = flag('--economics'), fpsFlag = flag('--fps');
|
|
166
|
-
const usage = 'Usage: agentguard-burn render <run.jsonl> --mp4 <out.mp4> [--gif <out.gif>] [--phone] | --dashboard [--wide] [--economics <blocks.json>] [--fps <n>]';
|
|
165
|
+
const source = rest[0], mp4 = flag('--mp4'), gif = flag('--gif'), economics = flag('--economics'), fpsFlag = flag('--fps'), label = flag('--label');
|
|
166
|
+
const usage = 'Usage: agentguard-burn render <run.jsonl> --mp4 <out.mp4> [--gif <out.gif>] [--phone] [--label <text>] | --dashboard [--wide] [--economics <blocks.json>] [--fps <n>] [--label <text>]';
|
|
167
|
+
if (has('--label') && (!label || label.startsWith('--')))
|
|
168
|
+
throw new Error(usage);
|
|
167
169
|
if (!source || source.startsWith('--') || !mp4 || mp4.startsWith('--') || (has('--gif') && (!gif || gif.startsWith('--'))))
|
|
168
170
|
throw new Error(usage);
|
|
169
171
|
if (has('--dashboard')) {
|
|
170
172
|
if (has('--gif') || has('--phone') || (has('--economics') && (!economics || economics.startsWith('--'))) || (has('--fps') && !/^\d{1,2}$/.test(fpsFlag ?? '')))
|
|
171
173
|
throw new Error(usage);
|
|
172
174
|
const { renderDashboard } = await Promise.resolve().then(() => __importStar(require('./dashboard-render')));
|
|
173
|
-
const result = await renderDashboard(source, { mp4, economics, wide: has('--wide'), ...(fpsFlag ? { fps: Number(fpsFlag) } : {}) });
|
|
175
|
+
const result = await renderDashboard(source, { mp4, economics, wide: has('--wide'), ...(fpsFlag ? { fps: Number(fpsFlag) } : {}), ...(label ? { label } : {}) });
|
|
174
176
|
show({ kind: 'command', command: 'render', values: { ...result } }, `PNG frames: ${result.framesDir}\n${result.mp4 ? `MP4: ${result.mp4}\n` : `ffmpeg unavailable. Run: ${result.ffmpegCommand}\n`}Provenance: ${result.provenancePath}\n`);
|
|
175
177
|
return 0;
|
|
176
178
|
}
|
|
177
179
|
if (has('--wide') || has('--economics') || has('--fps'))
|
|
178
180
|
throw new Error(usage);
|
|
179
181
|
const { renderRecording } = await Promise.resolve().then(() => __importStar(require('./render-recording')));
|
|
180
|
-
const result = await renderRecording(source, { mp4, gif, phone: has('--phone') });
|
|
182
|
+
const result = await renderRecording(source, { mp4, gif, phone: has('--phone'), ...(label ? { label } : {}) });
|
|
181
183
|
show({ kind: 'command', command: 'render', values: { ...result } }, `PNG frames: ${result.framesDir}\n${result.mp4 ? `MP4: ${result.mp4}\n` : `ffmpeg unavailable. Run: ${result.ffmpegCommand}\n`}${result.gif ? `GIF: ${result.gif}\n` : ''}Provenance: ${result.provenancePath}\n`);
|
|
182
184
|
return 0;
|
|
183
185
|
}
|
|
@@ -9,17 +9,26 @@ export interface DashboardFrame {
|
|
|
9
9
|
export interface DashboardChild {
|
|
10
10
|
child: string;
|
|
11
11
|
kind: 'fork' | 'fresh';
|
|
12
|
+
startedAt: number | null;
|
|
12
13
|
tokens: number | null;
|
|
13
14
|
usd: DollarRange | null;
|
|
14
15
|
}
|
|
16
|
+
/** `scope` says which children the dollars cover: the copies one recording allowed, or every child of the session. */
|
|
15
17
|
export interface DashboardEconomics {
|
|
16
18
|
session: string;
|
|
19
|
+
scope: 'recording' | 'session';
|
|
20
|
+
launched: number | null;
|
|
17
21
|
children: DashboardChild[];
|
|
18
22
|
measuredCount: number;
|
|
19
23
|
pricedCount: number;
|
|
20
24
|
totalTokens: number;
|
|
21
25
|
totalUsd: DollarRange;
|
|
22
26
|
}
|
|
27
|
+
/** A recording's own window: its first frame time and how many spawn decisions it allowed. */
|
|
28
|
+
export interface RecordingWindow {
|
|
29
|
+
fromMs: number;
|
|
30
|
+
launched: number;
|
|
31
|
+
}
|
|
23
32
|
export interface DashboardEvent {
|
|
24
33
|
id: string;
|
|
25
34
|
atMs: number;
|
|
@@ -44,6 +53,10 @@ export interface DashboardModel {
|
|
|
44
53
|
ceiling: number | null;
|
|
45
54
|
warnAt: number | null;
|
|
46
55
|
windowActiveMinutes: number | null;
|
|
56
|
+
/** Spawn decisions the gate allowed (every non-STOP decision). The ledger's `spawns` counter also counts the refused attempt that reached the ceiling. */
|
|
57
|
+
launched: number;
|
|
58
|
+
/** Caller-supplied name for what the recording was (for example "deliberate fan-out test"); drawn in the header, never inferred. */
|
|
59
|
+
label?: string;
|
|
47
60
|
events: DashboardEvent[];
|
|
48
61
|
samples: DashboardSample[];
|
|
49
62
|
economics: DashboardEconomics | null;
|
|
@@ -60,9 +73,14 @@ export interface DashboardStop {
|
|
|
60
73
|
export interface DashboardState {
|
|
61
74
|
t: number;
|
|
62
75
|
phase: 'run' | 'hold';
|
|
76
|
+
/** The ledger's spawn-attempt counter in the window, the number the rate rule compares with the ceiling. */
|
|
63
77
|
copies: number;
|
|
64
78
|
copiesChangedAt: number;
|
|
65
79
|
previousCopies: number;
|
|
80
|
+
/** Copies that actually launched: allowed decisions so far. */
|
|
81
|
+
launched: number;
|
|
82
|
+
launchedChangedAt: number;
|
|
83
|
+
previousLaunched: number;
|
|
66
84
|
decisions: number;
|
|
67
85
|
refused: number;
|
|
68
86
|
elapsedMs: number;
|
|
@@ -72,9 +90,15 @@ export interface DashboardState {
|
|
|
72
90
|
}
|
|
73
91
|
/** Live frames only, every field known. Unknown fields fail the render instead of being ignored. */
|
|
74
92
|
export declare function readDashboardRecording(file: string): DashboardFrame[];
|
|
75
|
-
/**
|
|
76
|
-
|
|
93
|
+
/**
|
|
94
|
+
* The blocks JSON is the output of `agentguard-burn blocks <session> --json`; only the recorded session's children are used.
|
|
95
|
+
* With a `window`, only the copies that recording allowed are kept: the `launched` earliest children that started at or after
|
|
96
|
+
* the first frame (one minute of slack for hook approval). Children spawned later in the same session stay out of the dollars.
|
|
97
|
+
*/
|
|
98
|
+
export declare function readDashboardEconomics(file: string, session: string, window?: RecordingWindow): DashboardEconomics;
|
|
77
99
|
/** Distinct decisions in time order; each carries the spawn count of the first frame that showed it. */
|
|
78
100
|
export declare function dashboardModel(frames: DashboardFrame[], economics?: DashboardEconomics | null, holdMs?: number): DashboardModel;
|
|
101
|
+
/** The window a recording defines for its own child economics: first frame time and the spawn decisions it allowed. */
|
|
102
|
+
export declare function recordingWindow(frames: DashboardFrame[]): RecordingWindow;
|
|
79
103
|
/** The dashboard at offset t (ms from the first frame): the latest sample and every decision up to t. */
|
|
80
104
|
export declare function dashboardState(model: DashboardModel, t: number): DashboardState;
|
|
@@ -4,6 +4,7 @@ exports.DASHBOARD_HOLD_MS = void 0;
|
|
|
4
4
|
exports.readDashboardRecording = readDashboardRecording;
|
|
5
5
|
exports.readDashboardEconomics = readDashboardEconomics;
|
|
6
6
|
exports.dashboardModel = dashboardModel;
|
|
7
|
+
exports.recordingWindow = recordingWindow;
|
|
7
8
|
exports.dashboardState = dashboardState;
|
|
8
9
|
/** Dashboard data model: a strict reading of a live recording plus the child economics of the same session. */
|
|
9
10
|
const node_fs_1 = require("node:fs");
|
|
@@ -49,22 +50,39 @@ function dollarRange(value) {
|
|
|
49
50
|
throw new Error('Blocks JSON has a child price that is not a dollar range.');
|
|
50
51
|
return { min: range.min, max: range.max };
|
|
51
52
|
}
|
|
52
|
-
/**
|
|
53
|
-
|
|
53
|
+
/**
|
|
54
|
+
* The blocks JSON is the output of `agentguard-burn blocks <session> --json`; only the recorded session's children are used.
|
|
55
|
+
* With a `window`, only the copies that recording allowed are kept: the `launched` earliest children that started at or after
|
|
56
|
+
* the first frame (one minute of slack for hook approval). Children spawned later in the same session stay out of the dollars.
|
|
57
|
+
*/
|
|
58
|
+
function readDashboardEconomics(file, session, window) {
|
|
54
59
|
const report = JSON.parse((0, node_fs_1.readFileSync)(file, 'utf8'));
|
|
55
60
|
const sessions = Array.isArray(report.sessions) ? report.sessions : [];
|
|
56
61
|
const match = sessions.find(entry => typeof entry.session === 'string' && (entry.session === session || entry.session.startsWith(session)));
|
|
57
62
|
const children = match?.economics?.available === true && Array.isArray(match.economics.children) ? match.economics.children : [];
|
|
58
63
|
if (!match || !children.length)
|
|
59
64
|
throw new Error(`Blocks JSON has no child economics for session ${session}.`);
|
|
60
|
-
const
|
|
65
|
+
const all = children.map(child => {
|
|
61
66
|
if (typeof child.child !== 'string' || (child.kind !== 'fork' && child.kind !== 'fresh') || !(child.tokens === null || finite(child.tokens)))
|
|
62
67
|
throw new Error('Blocks JSON has a malformed child row.');
|
|
63
|
-
|
|
68
|
+
// Start times are epoch milliseconds from `blocks --json`; an ISO string is accepted for hand-edited files.
|
|
69
|
+
const startedAt = child.startedAt === undefined || child.startedAt === null ? null
|
|
70
|
+
: typeof child.startedAt === 'number' && Number.isFinite(child.startedAt) && child.startedAt > 0 ? child.startedAt
|
|
71
|
+
: typeof child.startedAt === 'string' && Number.isFinite(Date.parse(child.startedAt)) ? Date.parse(child.startedAt) : NaN;
|
|
72
|
+
if (Number.isNaN(startedAt))
|
|
73
|
+
throw new Error('Blocks JSON has a child start time that is neither epoch milliseconds nor an ISO timestamp.');
|
|
74
|
+
return { child: child.child, kind: child.kind, startedAt, tokens: child.tokens, usd: dollarRange(child.usd) };
|
|
64
75
|
});
|
|
76
|
+
let rows = all;
|
|
77
|
+
if (window) {
|
|
78
|
+
if (all.some(row => row.startedAt === null))
|
|
79
|
+
throw new Error('Blocks JSON has children without start times; regenerate it with agentguard-burn 0.3.10 or later so the dashboard can keep only the copies this recording allowed.');
|
|
80
|
+
rows = all.filter(row => row.startedAt >= window.fromMs - 60_000).sort((a, b) => a.startedAt - b.startedAt || a.child.localeCompare(b.child)).slice(0, window.launched);
|
|
81
|
+
}
|
|
65
82
|
const measured = rows.filter(row => row.tokens !== null), priced = rows.filter(row => row.usd !== null);
|
|
66
83
|
return {
|
|
67
|
-
session: match.session,
|
|
84
|
+
session: match.session, scope: window ? 'recording' : 'session', launched: window ? window.launched : null,
|
|
85
|
+
children: rows, measuredCount: measured.length, pricedCount: priced.length,
|
|
68
86
|
totalTokens: measured.reduce((sum, row) => sum + row.tokens, 0),
|
|
69
87
|
totalUsd: { min: priced.reduce((sum, row) => sum + row.usd.min, 0), max: priced.reduce((sum, row) => sum + row.usd.max, 0) },
|
|
70
88
|
};
|
|
@@ -89,9 +107,15 @@ function dashboardModel(frames, economics = null, holdMs = exports.DASHBOARD_HOL
|
|
|
89
107
|
const firstWarn = events.find(event => event.verdict === 'WARN'), firstStop = events.find(event => event.verdict === 'STOP');
|
|
90
108
|
return {
|
|
91
109
|
session: first.snapshot.session, startAt: first.at, startMs: first.atMs, durationMs: last.atMs - first.atMs, holdMs,
|
|
92
|
-
ceiling, warnAt: firstWarn ? firstWarn.copies : null, windowActiveMinutes,
|
|
110
|
+
ceiling, warnAt: firstWarn ? firstWarn.copies : null, windowActiveMinutes, launched: events.filter(event => event.verdict !== 'STOP').length,
|
|
111
|
+
events, samples, economics, firstStopMs: firstStop ? firstStop.offsetMs : null,
|
|
93
112
|
};
|
|
94
113
|
}
|
|
114
|
+
/** The window a recording defines for its own child economics: first frame time and the spawn decisions it allowed. */
|
|
115
|
+
function recordingWindow(frames) {
|
|
116
|
+
const model = dashboardModel(frames, null);
|
|
117
|
+
return { fromMs: model.startMs, launched: model.launched };
|
|
118
|
+
}
|
|
95
119
|
/** The dashboard at offset t (ms from the first frame): the latest sample and every decision up to t. */
|
|
96
120
|
function dashboardState(model, t) {
|
|
97
121
|
const clamped = Math.max(0, Math.min(t, model.durationMs + model.holdMs));
|
|
@@ -107,9 +131,11 @@ function dashboardState(model, t) {
|
|
|
107
131
|
}
|
|
108
132
|
const log = model.events.filter(event => event.offsetMs <= clamped);
|
|
109
133
|
const stop = log.find(event => event.verdict === 'STOP');
|
|
134
|
+
const allowed = log.filter(event => event.verdict !== 'STOP'), lastAllowed = allowed.at(-1);
|
|
110
135
|
return {
|
|
111
136
|
t: clamped, phase: clamped > model.durationMs ? 'hold' : 'run',
|
|
112
137
|
copies: sample.copies, copiesChangedAt: changedAt, previousCopies: previous.copies,
|
|
138
|
+
launched: allowed.length, launchedChangedAt: lastAllowed?.offsetMs ?? 0, previousLaunched: Math.max(0, allowed.length - 1),
|
|
113
139
|
decisions: log.length, refused: log.filter(event => event.verdict === 'STOP').length,
|
|
114
140
|
elapsedMs: sample.elapsedMs, log,
|
|
115
141
|
stop: stop ? { copies: stop.copies, ceiling: model.ceiling, windowActiveMinutes: model.windowActiveMinutes, offsetMs: stop.offsetMs, reason: stop.reason, blocked: stop.blocked } : null,
|
|
@@ -134,13 +134,14 @@ function header(ctx, model, state, g) {
|
|
|
134
134
|
const wordSize = Math.round(g.number * 1.15);
|
|
135
135
|
const agent = text(ctx, 'Agent', g.margin, g.header.y, wordSize, { weight: 600 });
|
|
136
136
|
text(ctx, 'Guard', g.margin + agent, g.header.y, wordSize, { weight: 600, color: exports.INK.teal });
|
|
137
|
-
text(ctx, `session ${model.session} · ${model.startAt.slice(0, 10)} ${model.startAt.slice(11, 16)} UTC · spawn gate`, g.margin, g.header.y + 34, g.small, { color: exports.INK.secondary });
|
|
138
|
-
|
|
137
|
+
text(ctx, `session ${model.session} · ${model.startAt.slice(0, 10)} ${model.startAt.slice(11, 16)} UTC · spawn gate${model.label ? ` · ${model.label}` : ''}`, g.margin, g.header.y + 34, g.small, { color: exports.INK.secondary });
|
|
138
|
+
// Counters step at the recorded event time, in the same frame as the log row and the ring marker, so no frame shows
|
|
139
|
+
// a marker or log row the counters have not yet counted. Copies = allowed decisions; the ledger's attempt counter drives the rate bar.
|
|
139
140
|
const values = [
|
|
140
|
-
['copies', String(
|
|
141
|
-
['decisions', String(
|
|
142
|
-
['refused', String(
|
|
143
|
-
['
|
|
141
|
+
['copies', String(state.launched), state.warned ? exports.INK.amber : exports.INK.teal],
|
|
142
|
+
['decisions', String(state.decisions), exports.INK.ink],
|
|
143
|
+
['refused', String(state.refused), state.refused ? exports.INK.red : exports.INK.ink],
|
|
144
|
+
['recorded time', clock(state.elapsedMs), exports.INK.ink],
|
|
144
145
|
];
|
|
145
146
|
values.forEach(([label, value, color], index) => {
|
|
146
147
|
const x = g.header.counters.x + index * g.header.counters.step;
|
|
@@ -157,7 +158,8 @@ function ring(ctx, model, state, g, phases) {
|
|
|
157
158
|
ctx.beginPath();
|
|
158
159
|
ctx.arc(cx, cy, r, 0, Math.PI * 2);
|
|
159
160
|
ctx.stroke();
|
|
160
|
-
|
|
161
|
+
// One marker per copy that launched; refused attempts are the red X marks above the gate, never a marker.
|
|
162
|
+
const shown = Math.min(state.launched, slots);
|
|
161
163
|
if (shown > 0) {
|
|
162
164
|
ctx.strokeStyle = state.warned ? exports.INK.amber : exports.INK.teal;
|
|
163
165
|
ctx.lineWidth = 4;
|
|
@@ -238,7 +240,7 @@ function ring(ctx, model, state, g, phases) {
|
|
|
238
240
|
function bar(ctx, model, state, g) {
|
|
239
241
|
const { x, y, w, h } = g.bar, ceiling = model.ceiling ?? 16, fraction = clamp01(counter(state.previousCopies * 100, state.copies * 100, state.copiesChangedAt, state.t) / 100 / ceiling);
|
|
240
242
|
const color = state.refused ? exports.INK.red : state.warned ? exports.INK.amber : exports.INK.teal;
|
|
241
|
-
text(ctx, `SPAWN
|
|
243
|
+
text(ctx, `SPAWN ATTEMPTS · ${model.windowActiveMinutes ?? '?'} ACTIVE MIN`, x, y - 22, g.label, { color: exports.INK.secondary, weight: 600 });
|
|
242
244
|
text(ctx, `${state.copies} / ${ceiling}`, x + w, y - 12, g.number, { family: 'mono', weight: 700, color, align: 'right' });
|
|
243
245
|
ctx.fillStyle = exports.INK.line;
|
|
244
246
|
ctx.beginPath();
|
|
@@ -258,9 +260,9 @@ function bar(ctx, model, state, g) {
|
|
|
258
260
|
ctx.moveTo(wx, y - 8);
|
|
259
261
|
ctx.lineTo(wx, y + h + 8);
|
|
260
262
|
ctx.stroke();
|
|
261
|
-
text(ctx, `warn ${model.warnAt}`, wx + 10, y + h + 30, g.small, { color: exports.INK.amber });
|
|
263
|
+
text(ctx, `warn at ${model.warnAt}`, wx + 10, y + h + 30, g.small, { color: exports.INK.amber });
|
|
262
264
|
}
|
|
263
|
-
text(ctx, `
|
|
265
|
+
text(ctx, `refuse at ${ceiling}`, x + w, y + h + 30, g.small, { color: exports.INK.secondary, align: 'right' });
|
|
264
266
|
}
|
|
265
267
|
function log(ctx, state, g) {
|
|
266
268
|
const { x, y, w, h, rows } = g.log;
|
|
@@ -279,31 +281,28 @@ function log(ctx, state, g) {
|
|
|
279
281
|
}
|
|
280
282
|
function agents(ctx, model, state, g) {
|
|
281
283
|
const { x, y, w, h, rows } = g.agents, economics = model.economics;
|
|
282
|
-
panel(ctx, x, y, w, h, '
|
|
284
|
+
panel(ctx, x, y, w, h, 'list cost after the run · not live', g);
|
|
283
285
|
if (!economics) {
|
|
284
286
|
text(ctx, 'no subagent economics supplied', x + 20, y + 90, g.body, { color: exports.INK.secondary });
|
|
285
287
|
return;
|
|
286
288
|
}
|
|
287
|
-
const revealAt = model.firstStopMs ?? model.durationMs, reveal = easeOut((state.t - revealAt) /
|
|
289
|
+
const revealAt = model.firstStopMs ?? model.durationMs, reveal = easeOut((state.t - revealAt) / 600);
|
|
290
|
+
// Recording scope: the dollars cover only the copies this recording allowed. Session scope: every child of the session.
|
|
291
|
+
const recorded = economics.scope === 'recording', found = economics.children.length, launched = economics.launched ?? found;
|
|
292
|
+
const who = recorded ? (found === launched ? `${found} copies the gate allowed` : `${found} of the ${launched} copies the gate allowed`) : `${found} subagent transcripts`;
|
|
288
293
|
if (reveal <= 0) {
|
|
289
|
-
text(ctx,
|
|
290
|
-
text(ctx, '
|
|
294
|
+
text(ctx, who, x + 20, y + 84, g.body, { color: exports.INK.secondary });
|
|
295
|
+
text(ctx, 'list price shown after the run', x + 20, y + 84 + g.body * 1.4, g.body, { color: exports.INK.secondary });
|
|
291
296
|
return;
|
|
292
297
|
}
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
ctx
|
|
298
|
-
|
|
299
|
-
if (!wrapped)
|
|
300
|
-
text(ctx, caption, x + 20, y + 76 + g.bigNumber, g.small, { color: exports.INK.secondary });
|
|
301
|
-
else {
|
|
302
|
-
text(ctx, `list cost of ${economics.pricedCount} subagent transcripts`, x + 20, y + 76 + g.bigNumber, g.small, { color: exports.INK.secondary });
|
|
303
|
-
text(ctx, 'not a bill', x + 20, y + 76 + g.bigNumber + g.small * 1.15, g.small, { color: exports.INK.secondary });
|
|
304
|
-
}
|
|
298
|
+
// The final amount fades in once, at its full value: it never counts up, so it cannot read as a live meter.
|
|
299
|
+
const big = y + 52 + g.bigNumber, cap1 = big + g.body * 1.3, cap2 = cap1 + g.body * 1.25;
|
|
300
|
+
text(ctx, (0, live_1.dollars)(economics.totalUsd), x + 20, big, g.bigNumber, { family: 'mono', weight: 700, color: exports.INK.ink, alpha: reveal });
|
|
301
|
+
// The qualifications are body size, the same size as the decision log, not fine print, and clear of the amount's descenders.
|
|
302
|
+
text(ctx, who, x + 20, cap1, g.body, { color: exports.INK.ink, alpha: reveal });
|
|
303
|
+
text(ctx, 'list price · not a bill', x + 20, cap2, g.body, { color: exports.INK.secondary, alpha: reveal });
|
|
305
304
|
const sorted = [...economics.children].sort((a, b) => (b.tokens ?? 0) - (a.tokens ?? 0)), top = sorted.slice(0, rows), max = top[0]?.tokens ?? 1;
|
|
306
|
-
const first =
|
|
305
|
+
const first = cap2 + g.body * .7, pitch = (h - (first - y) - 44) / rows, barW = w - 40 - g.number * 3.6;
|
|
307
306
|
top.forEach((child, i) => {
|
|
308
307
|
const row = first + i * pitch, fill = clamp01((child.tokens ?? 0) / max) * reveal;
|
|
309
308
|
ctx.fillStyle = exports.INK.line;
|
|
@@ -332,10 +331,11 @@ function card(ctx, state, g) {
|
|
|
332
331
|
ctx.roundRect(x, y, w, h, 12);
|
|
333
332
|
ctx.fill();
|
|
334
333
|
ctx.stroke();
|
|
335
|
-
const outcome = state.stop.blocked === true ? '
|
|
334
|
+
const outcome = state.stop.blocked === true ? 'attempt refused' : state.stop.blocked === false ? 'shadow, copy allowed' : 'outcome not recorded';
|
|
336
335
|
text(ctx, 'STOP', x + 22, y + h / 2 + g.number * .36, g.number, { family: 'mono', weight: 700, color: exports.INK.red });
|
|
337
336
|
const ceiling = state.stop.ceiling ?? '?', window = state.stop.windowActiveMinutes ?? '?';
|
|
338
|
-
|
|
337
|
+
// The window counter includes the refused attempt that reached the ceiling; later refusals report the same counter value.
|
|
338
|
+
text(ctx, `window counter ${state.stop.copies} of ${ceiling} · ${window} active min · ${outcome}`, x + 22 + g.number * 3, y + h / 2 - 4, g.body, { color: exports.INK.ink });
|
|
339
339
|
text(ctx, `${state.stop.reason} · signed on this machine`, x + 22 + g.number * 3, y + h / 2 + g.small + 6, g.small, { color: exports.INK.secondary });
|
|
340
340
|
ctx.restore();
|
|
341
341
|
}
|
|
@@ -364,6 +364,8 @@ async function renderDashboard(source, options) {
|
|
|
364
364
|
const fps = options.fps ?? 30;
|
|
365
365
|
if (!Number.isInteger(fps) || fps < 1 || fps > 60)
|
|
366
366
|
throw new Error('Dashboard fps must be an integer from 1 to 60.');
|
|
367
|
+
if (options.label !== undefined && !/^[\x20-\x7e]{1,40}$/.test(options.label))
|
|
368
|
+
throw new Error('Render label must be 1 to 40 printable ASCII characters.');
|
|
367
369
|
const sourcePath = (0, node_path_1.resolve)(source), mp4Path = (0, node_path_1.resolve)(options.mp4), provenancePath = `${mp4Path}.provenance.json`;
|
|
368
370
|
const economicsPath = options.economics ? (0, node_path_1.resolve)(options.economics) : null;
|
|
369
371
|
const outputs = [mp4Path, provenancePath];
|
|
@@ -380,10 +382,11 @@ async function renderDashboard(source, options) {
|
|
|
380
382
|
const sourceBytes = await (0, promises_1.readFile)(sourcePath);
|
|
381
383
|
const frames = (0, dashboard_model_1.readDashboardRecording)(sourcePath);
|
|
382
384
|
const economicsBytes = economicsPath ? await (0, promises_1.readFile)(economicsPath) : null;
|
|
383
|
-
|
|
385
|
+
// Only the copies this recording allowed are priced; later children of the same session stay out of the dollars.
|
|
386
|
+
const economics = economicsPath ? (0, dashboard_model_1.readDashboardEconomics)(economicsPath, frames[0].snapshot.session, (0, dashboard_model_1.recordingWindow)(frames)) : null;
|
|
384
387
|
if (!sourceBytes.equals(await (0, promises_1.readFile)(sourcePath)))
|
|
385
388
|
throw new Error('Recording changed while it was being read; render the saved file again.');
|
|
386
|
-
const model = (0, dashboard_model_1.dashboardModel)(frames, economics, dashboard_model_1.DASHBOARD_HOLD_MS);
|
|
389
|
+
const model = { ...(0, dashboard_model_1.dashboardModel)(frames, economics, dashboard_model_1.DASHBOARD_HOLD_MS), ...(options.label ? { label: options.label } : {}) };
|
|
387
390
|
const layout = options.wide ? 'wide' : 'phone', g = geometry(layout), seed = options.seed ?? exports.DASHBOARD_SEED;
|
|
388
391
|
const fonts = await registerFonts();
|
|
389
392
|
const total = Math.round((model.durationMs + model.holdMs) / 1000 * fps), frameCount = total + 1;
|
|
@@ -411,6 +414,7 @@ async function renderDashboard(source, options) {
|
|
|
411
414
|
rendered_at: new Date().toISOString(),
|
|
412
415
|
fonts, layout: 'dashboard', frame_size: { width: g.width, height: g.height }, aspect: layout, fps, seed,
|
|
413
416
|
frame_count: frameCount, frame_times: frameTimes,
|
|
417
|
+
label: options.label ?? null,
|
|
414
418
|
recording_span_seconds: model.durationMs / 1000, final_hold_seconds: model.holdMs / 1000,
|
|
415
419
|
video_timestamp_precision: 'microseconds; fixed 1/fps frame durations from the first recorded timestamp',
|
|
416
420
|
ffmpeg_command: command,
|
package/dist/src/frames.d.ts
CHANGED
|
@@ -41,6 +41,7 @@ export interface FrameOptions {
|
|
|
41
41
|
width?: number;
|
|
42
42
|
height?: number;
|
|
43
43
|
colour?: boolean;
|
|
44
|
+
label?: string;
|
|
44
45
|
}
|
|
45
46
|
export declare function auditFrame(command: 'ps' | 'reap', report: AuditReport): BurnFrame;
|
|
46
47
|
export declare function framePageCount(data: BurnFrame, options?: FrameOptions): number;
|
|
@@ -15,6 +15,8 @@ export interface ChildEconomics {
|
|
|
15
15
|
child: string;
|
|
16
16
|
kind: 'fork' | 'fresh';
|
|
17
17
|
forkContextRef: boolean;
|
|
18
|
+
/** Epoch milliseconds of the child's earliest timed usage row; null when the transcript carries none. */
|
|
19
|
+
startedAt: number | null;
|
|
18
20
|
tokens: number | null;
|
|
19
21
|
usd: DollarRange | null;
|
|
20
22
|
unknownModels: string[];
|
|
@@ -77,6 +77,11 @@ function childStatistics(children) {
|
|
|
77
77
|
medianUsd: children.length && priced.length === children.length ? { min: median(priced.map(child => child.usd.min)), max: median(priced.map(child => child.usd.max)) } : null,
|
|
78
78
|
maxUsd: children.length && priced.length === children.length ? { min: Math.max(...priced.map(child => child.usd.min)), max: Math.max(...priced.map(child => child.usd.max)) } : null };
|
|
79
79
|
}
|
|
80
|
+
/** The child's earliest timed usage row, so a dashboard can keep only the copies one recording allowed. */
|
|
81
|
+
const earliestTurnAt = (turns) => {
|
|
82
|
+
const times = turns.map(turn => turn.at).filter((value) => typeof value === 'number' && Number.isFinite(value));
|
|
83
|
+
return times.length ? Math.min(...times) : null;
|
|
84
|
+
};
|
|
80
85
|
const unavailable = (note) => ({ available: false, children: [], all: childStatistics([]), forks: childStatistics([]), fresh: childStatistics([]), notes: [note] });
|
|
81
86
|
const locationId = (location) => location.host === 'codex'
|
|
82
87
|
? /([a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12})$/i.exec(location.sessionId)?.[1] ?? location.sessionId
|
|
@@ -151,6 +156,7 @@ function readSessionEconomics(location, locations, rates = {}, cache = new Map()
|
|
|
151
156
|
const unknownBoundary = transcript.state.forkHistoryBoundaryUnknown === true;
|
|
152
157
|
const prices = turns.map(turn => (0, pricing_1.priceTurn)(turn, rates));
|
|
153
158
|
return { child: id, kind: transcript.state.lineage?.forked ? 'fork' : 'fresh', forkContextRef: transcript.state.lineage?.forkContextRef === true,
|
|
159
|
+
startedAt: earliestTurnAt(transcript.turns),
|
|
154
160
|
tokens: unknownBoundary || !turns.length ? null : turns.reduce((sum, turn) => sum + (0, render_1.totalTokens)(turn), 0),
|
|
155
161
|
usd: unknownBoundary || !turns.length ? null : (0, render_1.sumPrices)(prices.map(price => price.usd)),
|
|
156
162
|
unknownModels: [...new Set(prices.filter(price => price.usd === null).map(price => price.model ?? 'missing model id'))] };
|
package/dist/src/live-panel.js
CHANGED
|
@@ -47,14 +47,15 @@ function elapsed(ms) {
|
|
|
47
47
|
function renderShowcasePanel(snapshot, options = {}) {
|
|
48
48
|
const c = new canvas_1.Canvas(options), w = c.width, h = c.height, split = Math.floor(w * .45), right = split + 3, room = w - right;
|
|
49
49
|
const at = options.at ?? new Date(snapshot.observedAt).toISOString(), color = spawnBarColor(snapshot.spawns, snapshot.spawnCeiling);
|
|
50
|
-
|
|
50
|
+
// A render label (for example "deliberate fan-out test") names what the recording was; it is caller-supplied, never inferred.
|
|
51
|
+
c.header('AGENTGUARD / BURN', options.label ? `${options.label.toUpperCase()} · RECORDED · 1x` : 'RECORDED RUN · 1x');
|
|
51
52
|
c.footer('local observation only', `elapsed ${snapshot.elapsedMs === null ? 'unknown' : elapsed(snapshot.elapsedMs ?? snapshot.observedAt - snapshot.startedAt)}`);
|
|
52
53
|
c.put(2, 0, `session ${snapshot.session} · ${at.slice(11, 19)} UTC`, 'slate');
|
|
53
54
|
for (let y = 3; y < h - 3; y++)
|
|
54
55
|
c.put(y, split + 1, '│', 'slate');
|
|
55
|
-
c.put(4, 0, '
|
|
56
|
+
c.put(4, 0, 'SPAWN ATTEMPTS IN WINDOW', 'slate');
|
|
56
57
|
c.bigDigits(6, 0, snapshot.spawns === null ? '-' : snapshot.spawns, color);
|
|
57
|
-
c.put(14, 0, `${snapshot.spawns ?? '?'} of ${snapshot.spawnCeiling ?? '?'}
|
|
58
|
+
c.put(14, 0, `${snapshot.spawns ?? '?'} of ${snapshot.spawnCeiling ?? '?'} attempts · ${snapshot.windowActiveMinutes ?? '?'} active min`.slice(0, split), 'white');
|
|
58
59
|
const fraction = snapshot.spawns === null || snapshot.spawnCeiling === null ? 0 : snapshot.spawns / snapshot.spawnCeiling;
|
|
59
60
|
const rate = `${snapshot.spawns ?? '?'} / ${snapshot.spawnCeiling ?? '?'}`;
|
|
60
61
|
c.put(16, 0, 'SPAWN RATE', 'slate').put(16, Math.max(11, split - rate.length), rate, color);
|
|
@@ -71,7 +72,7 @@ function renderShowcasePanel(snapshot, options = {}) {
|
|
|
71
72
|
}
|
|
72
73
|
if (y + 5 < h - 3) {
|
|
73
74
|
c.put(y, 0, 'WHAT A SPAWN IS', 'slate');
|
|
74
|
-
['Each spawn is a new agent copy
|
|
75
|
+
['Each spawn is a new agent copy with its own', 'context window and its own token usage.', 'At the ceiling, the attempt is refused.', 'Every decision is signed on this machine.']
|
|
75
76
|
.forEach((line, i) => c.put(y + 1 + i, 0, line.slice(0, split), 'white'));
|
|
76
77
|
}
|
|
77
78
|
c.put(4, right, 'LAST 8 DECISIONS', 'slate');
|
|
@@ -103,20 +104,22 @@ function renderPhonePanel(snapshot, options = {}) {
|
|
|
103
104
|
c.header('AGENTGUARD / BURN', 'RECORDED · 1x');
|
|
104
105
|
c.footer('signed on this machine', `elapsed ${snapshot.elapsedMs === null ? 'unknown' : elapsed(snapshot.elapsedMs ?? snapshot.observedAt - snapshot.startedAt)}`);
|
|
105
106
|
c.put(2, 0, `session ${snapshot.session} · ${at.slice(11, 19)} UTC`.slice(0, w), 'slate');
|
|
106
|
-
c.put(3, 0, '
|
|
107
|
+
c.put(3, 0, 'SPAWN ATTEMPTS IN WINDOW', 'slate');
|
|
107
108
|
c.bigDigits(4, 0, snapshot.spawns === null ? '-' : snapshot.spawns, color);
|
|
108
|
-
c.put(11, 0, `${snapshot.spawns ?? '?'} of ${snapshot.spawnCeiling ?? '?'}
|
|
109
|
+
c.put(11, 0, `${snapshot.spawns ?? '?'} of ${snapshot.spawnCeiling ?? '?'} attempts · ${snapshot.windowActiveMinutes ?? '?'} active min`.slice(0, w), 'white');
|
|
109
110
|
const fraction = snapshot.spawns === null || snapshot.spawnCeiling === null ? 0 : snapshot.spawns / snapshot.spawnCeiling;
|
|
110
111
|
const rate = `${snapshot.spawns ?? '?'} / ${snapshot.spawnCeiling ?? '?'}`;
|
|
111
112
|
c.put(12, 0, 'SPAWN RATE', 'slate').put(12, Math.max(11, w - rate.length), rate, color);
|
|
112
113
|
c.bar(13, 0, w, fraction, color).bar(14, 0, w, fraction, color);
|
|
113
|
-
// One block per
|
|
114
|
+
// One block per copy that launched. The spawn-rate counter also counts the attempt that reached the ceiling and was refused,
|
|
115
|
+
// so once a STOP is shown the copies that ran are one fewer than the counter. The grid only exists when the ceiling was recorded.
|
|
114
116
|
if (snapshot.spawnCeiling !== null && snapshot.spawnCeiling > 0) {
|
|
115
|
-
const ceiling = snapshot.spawnCeiling,
|
|
117
|
+
const ceiling = snapshot.spawnCeiling, attempts = Math.min(ceiling, Math.max(0, snapshot.spawns ?? 0));
|
|
118
|
+
const filled = snapshot.stop && attempts >= ceiling ? attempts - 1 : attempts;
|
|
116
119
|
const perRow = Math.ceil(ceiling / 2), blockWidth = Math.max(1, Math.floor((w + 1) / perRow) - 1);
|
|
117
120
|
const refused = snapshot.stop !== undefined;
|
|
118
|
-
c.put(16, 0, '
|
|
119
|
-
const tag = refused ? '
|
|
121
|
+
c.put(16, 0, 'COPIES LAUNCHED', 'slate');
|
|
122
|
+
const tag = refused ? 'attempt refused' : 'one block per copy';
|
|
120
123
|
c.put(16, Math.max(13, w - tag.length), tag, refused ? 'red' : 'slate');
|
|
121
124
|
for (let index = 0; index < ceiling; index++) {
|
|
122
125
|
const row = 17 + Math.floor(index / perRow) * 2, col = (index % perRow) * (blockWidth + 1);
|
|
@@ -133,13 +136,14 @@ function renderPhonePanel(snapshot, options = {}) {
|
|
|
133
136
|
});
|
|
134
137
|
if (!snapshot.decisions.length)
|
|
135
138
|
c.put(23, 0, 'No recorded decisions yet.', 'slate');
|
|
136
|
-
|
|
139
|
+
// The caller's label (what this recording was) takes the explainer row when supplied.
|
|
140
|
+
c.put(29, 0, (options.label ? options.label.toUpperCase() : 'Each copy runs its own context window.').slice(0, w), options.label ? 'slate' : 'white');
|
|
137
141
|
if (snapshot.stop) {
|
|
138
142
|
c.put(30, 0, '─'.repeat(w), 'red');
|
|
139
143
|
c.put(31, 0, ('STOP · ' + (snapshot.stop.blocked === true ? 'blocked' : snapshot.stop.blocked === false ? 'shadow / allowed' : 'outcome unknown') + ' · ' + snapshot.stop.reason).slice(0, w), 'red');
|
|
140
144
|
c.put(32, 0, '─'.repeat(w), 'red');
|
|
141
145
|
}
|
|
142
|
-
c.put(33, 0, '
|
|
146
|
+
c.put(33, 0, 'At the ceiling, the attempt is refused.'.slice(0, w), 'white');
|
|
143
147
|
return c;
|
|
144
148
|
}
|
|
145
149
|
function renderLivePanel(snapshot, options = {}) {
|
|
@@ -117,6 +117,8 @@ async function renderCanvasPng(snapshot, width = 1920, height = 1080, style = 'd
|
|
|
117
117
|
return canvas.encode('png');
|
|
118
118
|
}
|
|
119
119
|
async function renderRecording(source, options) {
|
|
120
|
+
if (options.label !== undefined && !/^[\x20-\x7e]{1,40}$/.test(options.label))
|
|
121
|
+
throw new Error('Render label must be 1 to 40 printable ASCII characters.');
|
|
120
122
|
const sourcePath = (0, node_path_1.resolve)(source), mp4Path = (0, node_path_1.resolve)(options.mp4);
|
|
121
123
|
const gifPath = options.gif ? (0, node_path_1.resolve)(options.gif) : null;
|
|
122
124
|
const provenancePath = `${mp4Path}.provenance.json`;
|
|
@@ -160,7 +162,7 @@ async function renderRecording(source, options) {
|
|
|
160
162
|
const frame = frames[index];
|
|
161
163
|
const name = `frame-${String(index).padStart(6, '0')}.png`;
|
|
162
164
|
const viewport = options.phone ? exports.PHONE_VIEWPORT : { width: frame.viewport?.width ?? 104, height: frame.viewport?.height ?? 35 };
|
|
163
|
-
const image = (0, frames_1.renderFrame)(frame.data, { recorded: true, showcase: true, at: frame.at, width: viewport.width, height: viewport.height, colour: true });
|
|
165
|
+
const image = (0, frames_1.renderFrame)(frame.data, { recorded: true, showcase: true, at: frame.at, width: viewport.width, height: viewport.height, colour: true, ...(options.label ? { label: options.label } : {}) });
|
|
164
166
|
const size = options.phone ? exports.PHONE_FRAME : { width: 1920, height: 1080 };
|
|
165
167
|
await (0, promises_1.writeFile)((0, node_path_1.join)(framesDir, name), await renderCanvasPng(image.toJSON(), size.width, size.height, frame.data.kind !== 'live' ? 'default' : options.phone ? 'phone' : 'showcase'), { flag: 'wx', mode: 0o600 });
|
|
166
168
|
}
|
|
@@ -189,6 +191,7 @@ async function renderRecording(source, options) {
|
|
|
189
191
|
frame_times: frames.map(frame => frame.at),
|
|
190
192
|
frame_viewports: frames.map(frame => options.phone ? { ...exports.PHONE_VIEWPORT } : frame.viewport ?? { width: 104, height: 35 }),
|
|
191
193
|
layout: options.phone ? 'phone' : 'wide',
|
|
194
|
+
label: options.label ?? null,
|
|
192
195
|
frame_size: options.phone ? { ...exports.PHONE_FRAME } : { width: 1920, height: 1080 },
|
|
193
196
|
video_frame_indices: videoIndices,
|
|
194
197
|
video_timestamp_precision: 'microseconds; equal timestamps retain the last frame in video and every PNG',
|
|
@@ -143,6 +143,7 @@
|
|
|
143
143
|
"child": "agent-a06a56e09ed61463a",
|
|
144
144
|
"kind": "fresh",
|
|
145
145
|
"forkContextRef": false,
|
|
146
|
+
"startedAt": 1789935679527,
|
|
146
147
|
"tokens": 176765,
|
|
147
148
|
"usd": {
|
|
148
149
|
"min": 0.074071,
|
|
@@ -154,6 +155,7 @@
|
|
|
154
155
|
"child": "agent-a0dc643d58a882fa1",
|
|
155
156
|
"kind": "fresh",
|
|
156
157
|
"forkContextRef": false,
|
|
158
|
+
"startedAt": 1790129337848,
|
|
157
159
|
"tokens": 9849353,
|
|
158
160
|
"usd": {
|
|
159
161
|
"min": 3.3955916,
|
|
@@ -165,6 +167,7 @@
|
|
|
165
167
|
"child": "agent-a16fb6132cdb0f967",
|
|
166
168
|
"kind": "fresh",
|
|
167
169
|
"forkContextRef": false,
|
|
170
|
+
"startedAt": 1789935679631,
|
|
168
171
|
"tokens": 176770,
|
|
169
172
|
"usd": {
|
|
170
173
|
"min": 0.07384284999999999,
|
|
@@ -176,6 +179,7 @@
|
|
|
176
179
|
"child": "agent-a17094fd82226f147",
|
|
177
180
|
"kind": "fresh",
|
|
178
181
|
"forkContextRef": false,
|
|
182
|
+
"startedAt": 1789935679660,
|
|
179
183
|
"tokens": 176908,
|
|
180
184
|
"usd": {
|
|
181
185
|
"min": 0.0739548,
|
|
@@ -187,6 +191,7 @@
|
|
|
187
191
|
"child": "agent-a2121a2540058aa0d",
|
|
188
192
|
"kind": "fresh",
|
|
189
193
|
"forkContextRef": false,
|
|
194
|
+
"startedAt": 1789935679510,
|
|
190
195
|
"tokens": 177009,
|
|
191
196
|
"usd": {
|
|
192
197
|
"min": 0.07452144999999999,
|
|
@@ -198,6 +203,7 @@
|
|
|
198
203
|
"child": "agent-a3f64c75d51f26a8c",
|
|
199
204
|
"kind": "fresh",
|
|
200
205
|
"forkContextRef": false,
|
|
206
|
+
"startedAt": 1789935679669,
|
|
201
207
|
"tokens": 177213,
|
|
202
208
|
"usd": {
|
|
203
209
|
"min": 0.0752782,
|
|
@@ -209,6 +215,7 @@
|
|
|
209
215
|
"child": "agent-a3fbb3e8e2652554f",
|
|
210
216
|
"kind": "fresh",
|
|
211
217
|
"forkContextRef": false,
|
|
218
|
+
"startedAt": 1789935679621,
|
|
212
219
|
"tokens": 176808,
|
|
213
220
|
"usd": {
|
|
214
221
|
"min": 0.0739135,
|
|
@@ -220,6 +227,7 @@
|
|
|
220
227
|
"child": "agent-a453ae1ee034514f5",
|
|
221
228
|
"kind": "fresh",
|
|
222
229
|
"forkContextRef": false,
|
|
230
|
+
"startedAt": 1789935679946,
|
|
223
231
|
"tokens": 176868,
|
|
224
232
|
"usd": {
|
|
225
233
|
"min": 0.07442170000000001,
|
|
@@ -231,6 +239,7 @@
|
|
|
231
239
|
"child": "agent-a67fd6744054cbcfb",
|
|
232
240
|
"kind": "fresh",
|
|
233
241
|
"forkContextRef": false,
|
|
242
|
+
"startedAt": 1789935679499,
|
|
234
243
|
"tokens": 176783,
|
|
235
244
|
"usd": {
|
|
236
245
|
"min": 0.07375100000000001,
|
|
@@ -242,6 +251,7 @@
|
|
|
242
251
|
"child": "agent-a6fc6a81b7cc1fb77",
|
|
243
252
|
"kind": "fresh",
|
|
244
253
|
"forkContextRef": false,
|
|
254
|
+
"startedAt": 1789935680792,
|
|
245
255
|
"tokens": 177329,
|
|
246
256
|
"usd": {
|
|
247
257
|
"min": 0.07525835,
|
|
@@ -253,6 +263,7 @@
|
|
|
253
263
|
"child": "agent-a8a896a8c52bc7509",
|
|
254
264
|
"kind": "fresh",
|
|
255
265
|
"forkContextRef": false,
|
|
266
|
+
"startedAt": 1789935679378,
|
|
256
267
|
"tokens": 177025,
|
|
257
268
|
"usd": {
|
|
258
269
|
"min": 0.07456165,
|
|
@@ -264,6 +275,7 @@
|
|
|
264
275
|
"child": "agent-ac3dfb54b036f4002",
|
|
265
276
|
"kind": "fresh",
|
|
266
277
|
"forkContextRef": false,
|
|
278
|
+
"startedAt": 1789935679467,
|
|
267
279
|
"tokens": 176847,
|
|
268
280
|
"usd": {
|
|
269
281
|
"min": 0.07439969999999999,
|
|
@@ -275,6 +287,7 @@
|
|
|
275
287
|
"child": "agent-ac658891544a74c52",
|
|
276
288
|
"kind": "fresh",
|
|
277
289
|
"forkContextRef": false,
|
|
290
|
+
"startedAt": 1789935679617,
|
|
278
291
|
"tokens": 176689,
|
|
279
292
|
"usd": {
|
|
280
293
|
"min": 0.0735927,
|
|
@@ -286,6 +299,7 @@
|
|
|
286
299
|
"child": "agent-ae1791bbb5ac64267",
|
|
287
300
|
"kind": "fresh",
|
|
288
301
|
"forkContextRef": false,
|
|
302
|
+
"startedAt": 1789935679713,
|
|
289
303
|
"tokens": 129435,
|
|
290
304
|
"usd": {
|
|
291
305
|
"min": 0.0684502,
|
|
@@ -297,6 +311,7 @@
|
|
|
297
311
|
"child": "agent-ae3f1bfbc22e5a169",
|
|
298
312
|
"kind": "fresh",
|
|
299
313
|
"forkContextRef": false,
|
|
314
|
+
"startedAt": 1789935679712,
|
|
300
315
|
"tokens": 176730,
|
|
301
316
|
"usd": {
|
|
302
317
|
"min": 0.0734944,
|
|
@@ -308,6 +323,7 @@
|
|
|
308
323
|
"child": "agent-af2a48f4fad800227",
|
|
309
324
|
"kind": "fresh",
|
|
310
325
|
"forkContextRef": false,
|
|
326
|
+
"startedAt": 1789935680088,
|
|
311
327
|
"tokens": 176803,
|
|
312
328
|
"usd": {
|
|
313
329
|
"min": 0.07378154999999999,
|
|
@@ -319,6 +335,7 @@
|
|
|
319
335
|
"child": "agent-afffbfa53dcc4d022",
|
|
320
336
|
"kind": "fresh",
|
|
321
337
|
"forkContextRef": false,
|
|
338
|
+
"startedAt": 1790133308566,
|
|
322
339
|
"tokens": 442258,
|
|
323
340
|
"usd": {
|
|
324
341
|
"min": 0.14556865,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@agentguard-run/burn",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.11",
|
|
4
4
|
"description": "Local session usage and runaway-agent circuit breaker. Explain tokens, cache rewrites and API list cost, track pace, warn on heavy turns, and gate agent fan-out with signed receipts. Developer command ranking requires explicit --rank.",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE",
|
|
6
6
|
"type": "commonjs",
|