gsxdsm
2797803c0b
FN-7503: add agent log timing metrics
Record and surface request first-token latency and tool processing duration in task logs.
- Add optional agent log timing fields and persist them in file-backed task logs.
- Track Time To First Token from the first visible model output per agent logger request.
- Track FIFO tool durations for tool result and error rows without storing sensitive payloads.
- Render TTFT and duration badges in task chat and agent log viewers with regression coverage.
- Document the new persisted timing fields and add a patch changeset for the CLI package.
Files changed:
.changeset/fn-7503-agent-log-timing.md | 7 ++
docs/storage.md | 1 +
.../src/__tests__/agent-log-file-store.test.ts | 35 ++++++
.../src/__tests__/store-agent-log-file.test.ts | 28 +++++
packages/core/src/agent-log-file-store.ts | 19 ++++
packages/core/src/store.ts | 13 +++
packages/core/src/types.ts | 4 +
.../dashboard/app/components/AgentLogViewer.css | 33 ++++++
.../dashboard/app/components/AgentLogViewer.tsx | 39 ++++++-
packages/dashboard/app/components/TaskChatTab.css | 23 +++-
packages/dashboard/app/components/TaskChatTab.tsx | 17 ++-
.../__tests__/AgentLogViewer.rendering.test.tsx | 24 +++++
.../app/components/__tests__/TaskChatTab.test.tsx | 18 ++++
packages/engine/src/__tests__/agent-logger.test.ts | 120 ++++++++++++++++++---
packages/engine/src/agent-logger.ts | 97 ++++++++++++++---
15 files changed, 446 insertions(+), 32 deletions(-)
Fusion-Task-Id: FN-7503
Fusion-Task-Lineage: 7e62034f-4c35-420d-a670-3f7f4a7948df
Co-authored-by: Fusion (runfusion.ai) <noreply@runfusion.ai>
2026-07-04 10:42:21 -07:00
..
2026-07-04 10:42:21 -07:00
2026-07-03 13:10:20 -07:00
2026-07-03 13:10:20 -07:00
2026-06-08 15:19:27 -07:00
2026-07-02 11:38:31 -07:00