@agent-inspect/mcp-server 6.7.2 → 6.7.3
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.cjs +13 -4
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +13 -4
- package/dist/index.mjs.map +1 -1
- package/package.json +3 -3
package/dist/index.mjs
CHANGED
|
@@ -4618,6 +4618,10 @@ function manualTraceEventsToComparableRun(events) {
|
|
|
4618
4618
|
meta = { ...meta ?? {}, agent_inspect_diff_parent_missing: true };
|
|
4619
4619
|
}
|
|
4620
4620
|
const outputPreview = extractOutputPreview(meta);
|
|
4621
|
+
if (meta !== void 0 && ("outputPreview" in meta || "resultPreview" in meta)) {
|
|
4622
|
+
delete meta.outputPreview;
|
|
4623
|
+
delete meta.resultPreview;
|
|
4624
|
+
}
|
|
4621
4625
|
const sc = {
|
|
4622
4626
|
id: acc.id,
|
|
4623
4627
|
name: acc.name,
|
|
@@ -5311,6 +5315,11 @@ function exportMarkdown(tree, options) {
|
|
|
5311
5315
|
function hexFrom(seed, byteLen) {
|
|
5312
5316
|
return crypto.createHash("sha256").update(seed, "utf8").digest("hex").slice(0, byteLen * 2);
|
|
5313
5317
|
}
|
|
5318
|
+
function unixNano(ms) {
|
|
5319
|
+
const whole = Math.trunc(ms);
|
|
5320
|
+
const fractionNs = Math.round((ms - whole) * 1e6);
|
|
5321
|
+
return BigInt(whole) * 1000000n + BigInt(fractionNs);
|
|
5322
|
+
}
|
|
5314
5323
|
function mapInspectKindToOI(kind, warnings) {
|
|
5315
5324
|
switch (kind) {
|
|
5316
5325
|
case "LLM":
|
|
@@ -5360,10 +5369,10 @@ function exportOpenInference(tree, options) {
|
|
|
5360
5369
|
const ev = n.event;
|
|
5361
5370
|
const spanId = hexFrom(`${tree.runId}:${ev.eventId}`, 8);
|
|
5362
5371
|
const parentSpanHex = ev.parentId ? hexFrom(`${tree.runId}:${ev.parentId}`, 8) : void 0;
|
|
5363
|
-
const startNs =
|
|
5372
|
+
const startNs = unixNano(ev.timestamp);
|
|
5364
5373
|
let endNs;
|
|
5365
5374
|
if (ev.durationMs !== void 0 && Number.isFinite(ev.durationMs)) {
|
|
5366
|
-
endNs = startNs +
|
|
5375
|
+
endNs = startNs + unixNano(ev.durationMs);
|
|
5367
5376
|
}
|
|
5368
5377
|
const { openInferenceKind } = mapInspectKindToOI(ev.kind, warnings);
|
|
5369
5378
|
const attrs = {
|
|
@@ -5411,8 +5420,8 @@ function exportOpenInference(tree, options) {
|
|
|
5411
5420
|
span_id: spanId,
|
|
5412
5421
|
parent_span_id: parentSpanHex,
|
|
5413
5422
|
name: ev.name,
|
|
5414
|
-
start_time_unix_nano: startNs,
|
|
5415
|
-
end_time_unix_nano: endNs,
|
|
5423
|
+
start_time_unix_nano: startNs.toString(),
|
|
5424
|
+
end_time_unix_nano: endNs?.toString(),
|
|
5416
5425
|
attributes: attrs,
|
|
5417
5426
|
status
|
|
5418
5427
|
});
|