@oh-my-pi/omp-stats 18.0.1 → 18.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/README.md +4 -2
- package/dist/client/index.js +84 -84
- package/dist/types/client/data/formatters.d.ts +5 -0
- package/dist/types/client/data/view-models.d.ts +1 -0
- package/dist/types/db.d.ts +3 -2
- package/dist/types/shared-types.d.ts +10 -0
- package/package.json +4 -4
- package/src/client/data/formatters.ts +13 -0
- package/src/client/data/view-models.ts +3 -0
- package/src/client/routes/CostsRoute.tsx +28 -10
- package/src/client/routes/ErrorsRoute.tsx +5 -5
- package/src/client/routes/ModelsRoute.tsx +3 -2
- package/src/client/routes/OverviewRoute.tsx +6 -6
- package/src/client/routes/ProjectsRoute.tsx +7 -5
- package/src/client/routes/ProvidersRoute.tsx +30 -5
- package/src/client/routes/RequestsRoute.tsx +5 -5
- package/src/client/routes/ToolsRoute.tsx +23 -11
- package/src/client/ui/MetricCluster.tsx +7 -3
- package/src/client/ui/RequestDrawer.tsx +3 -3
- package/src/db.ts +107 -29
- package/src/index.ts +10 -9
- package/src/shared-types.ts +10 -0
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,12 @@
|
|
|
2
2
|
|
|
3
3
|
## [Unreleased]
|
|
4
4
|
|
|
5
|
+
## [18.0.4] - 2026-08-24
|
|
6
|
+
|
|
7
|
+
### Fixed
|
|
8
|
+
|
|
9
|
+
- Fixed SuperGrok usage appearing as free by applying matching public xAI API pricing (including 200K-token rates), labeling costs as API-equivalent estimates, backfilling existing usage records, and displaying subscription-only models as N/A ([#9512](https://github.com/can1357/oh-my-pi/issues/9512)).
|
|
10
|
+
|
|
5
11
|
## [18.0.1] - 2026-08-23
|
|
6
12
|
|
|
7
13
|
### Fixed
|
package/README.md
CHANGED
|
@@ -17,10 +17,12 @@ Local observability dashboard for AI usage statistics.
|
|
|
17
17
|
| Cache Rate | `cache_read / (input + cache_read) * 100` |
|
|
18
18
|
| Cache Savings | `(uncached prompt cost - actual prompt cost) / uncached prompt cost * 100` |
|
|
19
19
|
| Error Rate | `count(stopReason=error) / total_calls * 100` |
|
|
20
|
-
|
|
|
20
|
+
| API-equivalent estimate | Sum of token usage priced with the matching public API rate card |
|
|
21
21
|
| Avg Latency | Mean of `duration` |
|
|
22
22
|
| TTFT | Mean of `ttft` (time to first token) |
|
|
23
23
|
|
|
24
|
+
Subscription-backed models use matching public API prices when an exact public model exists; these values estimate API-equivalent usage rather than the user's bill. Subscription-only models without a public price are reported as N/A and excluded from dollar totals.
|
|
25
|
+
|
|
24
26
|
## Usage
|
|
25
27
|
|
|
26
28
|
### Via CLI
|
|
@@ -72,7 +74,7 @@ console.log(stats.byModel[0].avgTokensPerSecond);
|
|
|
72
74
|
|
|
73
75
|
The web dashboard provides:
|
|
74
76
|
|
|
75
|
-
- Overall metrics cards (requests,
|
|
77
|
+
- Overall metrics cards (requests, API-equivalent estimate, cache rate, cache savings, error rate, duration, tokens/s)
|
|
76
78
|
- Time series chart showing requests and errors over time
|
|
77
79
|
- Per-model breakdown table
|
|
78
80
|
- Per-folder breakdown table
|