Skip to content

🪢 Open source agent evals & observability: Trace, evaluate, and improve LLM applications with one open platform.

fix: prefer exactTimestamp from event for eval trace caching (#10988)

Steffen Schmitz6df248382d9a
diff --git a/worker/src/features/evaluation/evalService.ts b/worker/src/features/evaluation/evalService.ts
index 7d99be5d8e..075a5d8ab8 100644
--- a/worker/src/features/evaluation/evalService.ts
+++ b/worker/src/features/evaluation/evalService.ts
@@ -259,9 +259,11 @@ export const createEvalJobs = async ({
traceId: event.traceId,
projectId: event.projectId,
timestamp:
- "timestamp" in event
- ? new Date(event.timestamp)
- : new Date(jobTimestamp),
+ "exactTimestamp" in event && event.exactTimestamp
+ ? new Date(event.exactTimestamp)
+ : "timestamp" in event
+ ? new Date(event.timestamp)
+ : new Date(jobTimestamp),
clickhouseFeatureTag: "eval-create",
excludeInputOutput: true,
});