@builder.io/dev-tools 1.46.0-dev.202604210746.f5e7329b1 → 1.46.0-dev.202604210823.f5e7329b1
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/cli/index.cjs +52 -91
- package/cli/index.cjs.map +3 -3
- package/core/index.cjs +1 -1
- package/core/index.mjs +1 -1
- package/node/index.cjs +1 -1
- package/node/index.mjs +1 -1
- package/package.json +1 -1
- package/server/index.cjs +2 -5
- package/server/index.mjs +2 -5
- package/types/cli/utils/replay-action-uploader.d.ts +16 -23
- package/types/tsconfig.tsbuildinfo +1 -1
|
@@ -4,23 +4,23 @@ import { type Credentials } from "../credentials";
|
|
|
4
4
|
* `packages/service/codegen/replay/types.ts` — kept inline here to keep
|
|
5
5
|
* the published `@builder.io/dev-tools` package free of cross-package
|
|
6
6
|
* type imports.
|
|
7
|
+
*
|
|
8
|
+
* Only the user-visible content is captured: assistant `text` blocks
|
|
9
|
+
* and `thinking` blocks. Tool calls and chapter markers are
|
|
10
|
+
* deliberately excluded.
|
|
7
11
|
*/
|
|
8
12
|
export interface ReplayActionRecord {
|
|
13
|
+
/** Wall-clock timestamp in ms epoch. */
|
|
9
14
|
ts: number;
|
|
10
|
-
type: "
|
|
11
|
-
|
|
12
|
-
argsSummary?: string;
|
|
13
|
-
resultSummary?: string;
|
|
14
|
-
isError?: boolean;
|
|
15
|
-
title?: string;
|
|
15
|
+
type: "text" | "thinking";
|
|
16
|
+
content: string;
|
|
16
17
|
}
|
|
17
18
|
/**
|
|
18
|
-
* Buffers
|
|
19
|
-
* them as
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
-
* the inflight chain below — no `seq` query parameter is needed.
|
|
19
|
+
* Buffers user-visible agent blocks (`text`, `thinking`) during a
|
|
20
|
+
* `browser-testing` run and POSTs them as JSON to
|
|
21
|
+
* `/codegen/replay/:uuid/actions`. The main service appends them to
|
|
22
|
+
* `replay.actionsStr` on the Firestore doc inside a transaction, so
|
|
23
|
+
* concurrent uploads can't drop entries.
|
|
24
24
|
*
|
|
25
25
|
* Failures are intentionally swallowed: replay is a nice-to-have and
|
|
26
26
|
* must never affect the agent run.
|
|
@@ -32,20 +32,13 @@ export declare class ReplayActionUploader {
|
|
|
32
32
|
replayId: string;
|
|
33
33
|
debug?: boolean;
|
|
34
34
|
});
|
|
35
|
-
recordToolResult(result: {
|
|
36
|
-
tool_name?: string;
|
|
37
|
-
tool_input?: string;
|
|
38
|
-
content?: unknown;
|
|
39
|
-
is_error?: boolean;
|
|
40
|
-
}, ts?: number): void;
|
|
41
35
|
/**
|
|
42
36
|
* `ts` should be the moment the assistant *began* streaming this
|
|
43
|
-
*
|
|
44
|
-
* back-compat but callers are expected to pass an earlier timestamp
|
|
45
|
-
* (e.g. when the previous step ended).
|
|
37
|
+
* block, not when it finished. Defaults to `Date.now()` for
|
|
38
|
+
* back-compat but callers are expected to pass an earlier timestamp.
|
|
46
39
|
*/
|
|
47
|
-
|
|
48
|
-
|
|
40
|
+
recordText(content: string, ts?: number): void;
|
|
41
|
+
recordReasoning(content: string, ts?: number): void;
|
|
49
42
|
flush(): Promise<void>;
|
|
50
43
|
close(): Promise<void>;
|
|
51
44
|
}
|