feat: add first valid response timing and related metrics

- Introduced `first_valid_response_ms` and `ttfr_ms` to track the timing of the first valid response in LLM calls.
- Updated relevant interfaces and components to display and utilize the new metrics, including CallDetails, CallTable, and LatencyChart.
- Enhanced the database schema to accommodate the new timing fields.
- Implemented logic in the service layer to record the first valid response during model interactions.
This commit is contained in:
leookun
2026-08-28 22:56:39 +08:00
parent 5a0bc2e0e9
commit 5cc2401ce2
20 changed files with 461 additions and 52 deletions
@@ -0,0 +1,2 @@
ALTER TABLE llm_calls ADD COLUMN first_valid_response_at_ms INTEGER;
ALTER TABLE llm_calls ADD COLUMN ttfr_ms INTEGER;