Files
localmodelroutex/backend/migrations/000003_content_log.down.sql
LovroG05 d7bd1cced0 feat: content logging and per-key analytics
- Migration 000003: request_log_content table (messages jsonb, completion text)
- InsertRequestLog now returns the new row's ID so content can be linked
- Chat handler captures prompt messages and completion text (streaming accumulates deltas)
- ListRequestLogs left-joins content; logs API passes key filter through
- KeyStats query aggregates requests/tokens/cost/errors per key prefix
- GET /api/admin/stats/keys endpoint
- Logs page: expandable rows show prompt + completion inline
- Analytics page: per-key usage table below the chart
2026-06-29 00:01:25 +02:00

2 lines
42 B
SQL

DROP TABLE IF EXISTS request_log_content;