We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 84b6cc1 commit 7f20a18Copy full SHA for 7f20a18
llmstack/play/output_stream.py
@@ -4,6 +4,7 @@
4
5
import asyncio
6
import logging
7
+import time
8
import uuid
9
from collections import defaultdict
10
from typing import Any, Dict, Type
@@ -230,7 +231,10 @@ def bookkeep(self, data: BaseModel) -> None:
230
231
"""
232
Bookkeeping entry.
233
- self._bookkeeping_queue.put_nowait((self._stream_id, data.model_dump()))
234
+ timestamp = time.time()
235
+ timestamped_data = {**data.model_dump(), "timestamp": timestamp}
236
+
237
+ self._bookkeeping_queue.put_nowait((self._stream_id, timestamped_data))
238
239
def error(self, error: Exception) -> None:
240
0 commit comments