agent-usage-all-in-one 0.2.2 → 0.4.0

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.
Files changed (34) hide show
  1. package/BUNDLED_DEPENDENCIES.json +4 -1
  2. package/BUNDLED_LICENSES.md +283 -0
  3. package/README.md +24 -12
  4. package/README.zh-CN.md +17 -10
  5. package/THIRD_PARTY_LICENSES.md +3 -1
  6. package/dist/cli.js +1125 -119
  7. package/dist/cli.js.map +1 -1
  8. package/dist/web/_app/immutable/assets/2.BWrFQDDF.css +1 -0
  9. package/dist/web/_app/immutable/chunks/3vuWay1s.js +3 -0
  10. package/dist/web/_app/immutable/chunks/CIxAYfti.js +1 -0
  11. package/dist/web/_app/immutable/chunks/DrMah8OK.js +1 -0
  12. package/dist/web/_app/immutable/entry/app.BJJ5ybn9.js +2 -0
  13. package/dist/web/_app/immutable/entry/start.C8pSj-JI.js +1 -0
  14. package/dist/web/_app/immutable/nodes/0.f03zL-fK.js +1 -0
  15. package/dist/web/_app/immutable/nodes/1.zxn5xzLP.js +1 -0
  16. package/dist/web/_app/immutable/nodes/2.CeZkCUZN.js +27 -0
  17. package/dist/web/_app/version.json +1 -1
  18. package/dist/web/brand/agent-usage-showcase.jpg +0 -0
  19. package/dist/web/brands/README.md +4 -4
  20. package/dist/web/index.html +30 -8
  21. package/docs/open-source.md +1 -1
  22. package/package.json +2 -1
  23. package/static/brand/agent-usage-showcase.jpg +0 -0
  24. package/static/brands/README.md +4 -4
  25. package/dist/web/_app/immutable/assets/2.Bb7EkOVL.css +0 -1
  26. package/dist/web/_app/immutable/chunks/Cui19qu3.js +0 -1
  27. package/dist/web/_app/immutable/chunks/DQaovcqE.js +0 -3
  28. package/dist/web/_app/immutable/entry/app.CpOB18I2.js +0 -2
  29. package/dist/web/_app/immutable/entry/start.Csw0voA2.js +0 -1
  30. package/dist/web/_app/immutable/nodes/0.Di1qFV6d.js +0 -1
  31. package/dist/web/_app/immutable/nodes/1.CVs4QxxY.js +0 -1
  32. package/dist/web/_app/immutable/nodes/2.ByyWXaMo.js +0 -31
  33. package/dist/web/brand/agent-usage-banner.svg +0 -27
  34. package/static/brand/agent-usage-banner.svg +0 -27
@@ -3,7 +3,10 @@
3
3
  "@sveltejs/kit",
4
4
  "clsx",
5
5
  "devalue",
6
+ "echarts",
6
7
  "esm-env",
7
- "svelte"
8
+ "svelte",
9
+ "tslib",
10
+ "zrender"
8
11
  ]
9
12
  }
@@ -47,6 +47,234 @@ The above copyright notice and this permission notice shall be included in all c
47
47
  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
48
48
  ```
49
49
 
50
+ ## echarts 6.1.0
51
+
52
+ Declared license: Apache-2.0
53
+
54
+ ```text
55
+ Apache License
56
+ Version 2.0, January 2004
57
+ http://www.apache.org/licenses/
58
+
59
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
60
+
61
+ 1. Definitions.
62
+
63
+ "License" shall mean the terms and conditions for use, reproduction,
64
+ and distribution as defined by Sections 1 through 9 of this document.
65
+
66
+ "Licensor" shall mean the copyright owner or entity authorized by
67
+ the copyright owner that is granting the License.
68
+
69
+ "Legal Entity" shall mean the union of the acting entity and all
70
+ other entities that control, are controlled by, or are under common
71
+ control with that entity. For the purposes of this definition,
72
+ "control" means (i) the power, direct or indirect, to cause the
73
+ direction or management of such entity, whether by contract or
74
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
75
+ outstanding shares, or (iii) beneficial ownership of such entity.
76
+
77
+ "You" (or "Your") shall mean an individual or Legal Entity
78
+ exercising permissions granted by this License.
79
+
80
+ "Source" form shall mean the preferred form for making modifications,
81
+ including but not limited to software source code, documentation
82
+ source, and configuration files.
83
+
84
+ "Object" form shall mean any form resulting from mechanical
85
+ transformation or translation of a Source form, including but
86
+ not limited to compiled object code, generated documentation,
87
+ and conversions to other media types.
88
+
89
+ "Work" shall mean the work of authorship, whether in Source or
90
+ Object form, made available under the License, as indicated by a
91
+ copyright notice that is included in or attached to the work
92
+ (an example is provided in the Appendix below).
93
+
94
+ "Derivative Works" shall mean any work, whether in Source or Object
95
+ form, that is based on (or derived from) the Work and for which the
96
+ editorial revisions, annotations, elaborations, or other modifications
97
+ represent, as a whole, an original work of authorship. For the purposes
98
+ of this License, Derivative Works shall not include works that remain
99
+ separable from, or merely link (or bind by name) to the interfaces of,
100
+ the Work and Derivative Works thereof.
101
+
102
+ "Contribution" shall mean any work of authorship, including
103
+ the original version of the Work and any modifications or additions
104
+ to that Work or Derivative Works thereof, that is intentionally
105
+ submitted to Licensor for inclusion in the Work by the copyright owner
106
+ or by an individual or Legal Entity authorized to submit on behalf of
107
+ the copyright owner. For the purposes of this definition, "submitted"
108
+ means any form of electronic, verbal, or written communication sent
109
+ to the Licensor or its representatives, including but not limited to
110
+ communication on electronic mailing lists, source code control systems,
111
+ and issue tracking systems that are managed by, or on behalf of, the
112
+ Licensor for the purpose of discussing and improving the Work, but
113
+ excluding communication that is conspicuously marked or otherwise
114
+ designated in writing by the copyright owner as "Not a Contribution."
115
+
116
+ "Contributor" shall mean Licensor and any individual or Legal Entity
117
+ on behalf of whom a Contribution has been received by Licensor and
118
+ subsequently incorporated within the Work.
119
+
120
+ 2. Grant of Copyright License. Subject to the terms and conditions of
121
+ this License, each Contributor hereby grants to You a perpetual,
122
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
123
+ copyright license to reproduce, prepare Derivative Works of,
124
+ publicly display, publicly perform, sublicense, and distribute the
125
+ Work and such Derivative Works in Source or Object form.
126
+
127
+ 3. Grant of Patent License. Subject to the terms and conditions of
128
+ this License, each Contributor hereby grants to You a perpetual,
129
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
130
+ (except as stated in this section) patent license to make, have made,
131
+ use, offer to sell, sell, import, and otherwise transfer the Work,
132
+ where such license applies only to those patent claims licensable
133
+ by such Contributor that are necessarily infringed by their
134
+ Contribution(s) alone or by combination of their Contribution(s)
135
+ with the Work to which such Contribution(s) was submitted. If You
136
+ institute patent litigation against any entity (including a
137
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
138
+ or a Contribution incorporated within the Work constitutes direct
139
+ or contributory patent infringement, then any patent licenses
140
+ granted to You under this License for that Work shall terminate
141
+ as of the date such litigation is filed.
142
+
143
+ 4. Redistribution. You may reproduce and distribute copies of the
144
+ Work or Derivative Works thereof in any medium, with or without
145
+ modifications, and in Source or Object form, provided that You
146
+ meet the following conditions:
147
+
148
+ (a) You must give any other recipients of the Work or
149
+ Derivative Works a copy of this License; and
150
+
151
+ (b) You must cause any modified files to carry prominent notices
152
+ stating that You changed the files; and
153
+
154
+ (c) You must retain, in the Source form of any Derivative Works
155
+ that You distribute, all copyright, patent, trademark, and
156
+ attribution notices from the Source form of the Work,
157
+ excluding those notices that do not pertain to any part of
158
+ the Derivative Works; and
159
+
160
+ (d) If the Work includes a "NOTICE" text file as part of its
161
+ distribution, then any Derivative Works that You distribute must
162
+ include a readable copy of the attribution notices contained
163
+ within such NOTICE file, excluding those notices that do not
164
+ pertain to any part of the Derivative Works, in at least one
165
+ of the following places: within a NOTICE text file distributed
166
+ as part of the Derivative Works; within the Source form or
167
+ documentation, if provided along with the Derivative Works; or,
168
+ within a display generated by the Derivative Works, if and
169
+ wherever such third-party notices normally appear. The contents
170
+ of the NOTICE file are for informational purposes only and
171
+ do not modify the License. You may add Your own attribution
172
+ notices within Derivative Works that You distribute, alongside
173
+ or as an addendum to the NOTICE text from the Work, provided
174
+ that such additional attribution notices cannot be construed
175
+ as modifying the License.
176
+
177
+ You may add Your own copyright statement to Your modifications and
178
+ may provide additional or different license terms and conditions
179
+ for use, reproduction, or distribution of Your modifications, or
180
+ for any such Derivative Works as a whole, provided Your use,
181
+ reproduction, and distribution of the Work otherwise complies with
182
+ the conditions stated in this License.
183
+
184
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
185
+ any Contribution intentionally submitted for inclusion in the Work
186
+ by You to the Licensor shall be under the terms and conditions of
187
+ this License, without any additional terms or conditions.
188
+ Notwithstanding the above, nothing herein shall supersede or modify
189
+ the terms of any separate license agreement you may have executed
190
+ with Licensor regarding such Contributions.
191
+
192
+ 6. Trademarks. This License does not grant permission to use the trade
193
+ names, trademarks, service marks, or product names of the Licensor,
194
+ except as required for reasonable and customary use in describing the
195
+ origin of the Work and reproducing the content of the NOTICE file.
196
+
197
+ 7. Disclaimer of Warranty. Unless required by applicable law or
198
+ agreed to in writing, Licensor provides the Work (and each
199
+ Contributor provides its Contributions) on an "AS IS" BASIS,
200
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
201
+ implied, including, without limitation, any warranties or conditions
202
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
203
+ PARTICULAR PURPOSE. You are solely responsible for determining the
204
+ appropriateness of using or redistributing the Work and assume any
205
+ risks associated with Your exercise of permissions under this License.
206
+
207
+ 8. Limitation of Liability. In no event and under no legal theory,
208
+ whether in tort (including negligence), contract, or otherwise,
209
+ unless required by applicable law (such as deliberate and grossly
210
+ negligent acts) or agreed to in writing, shall any Contributor be
211
+ liable to You for damages, including any direct, indirect, special,
212
+ incidental, or consequential damages of any character arising as a
213
+ result of this License or out of the use or inability to use the
214
+ Work (including but not limited to damages for loss of goodwill,
215
+ work stoppage, computer failure or malfunction, or any and all
216
+ other commercial damages or losses), even if such Contributor
217
+ has been advised of the possibility of such damages.
218
+
219
+ 9. Accepting Warranty or Additional Liability. While redistributing
220
+ the Work or Derivative Works thereof, You may choose to offer,
221
+ and charge a fee for, acceptance of support, warranty, indemnity,
222
+ or other liability obligations and/or rights consistent with this
223
+ License. However, in accepting such obligations, You may act only
224
+ on Your own behalf and on Your sole responsibility, not on behalf
225
+ of any other Contributor, and only if You agree to indemnify,
226
+ defend, and hold each Contributor harmless for any liability
227
+ incurred by, or claims asserted against, such Contributor by reason
228
+ of your accepting any such warranty or additional liability.
229
+
230
+ END OF TERMS AND CONDITIONS
231
+
232
+ APPENDIX: How to apply the Apache License to your work.
233
+
234
+ To apply the Apache License to your work, attach the following
235
+ boilerplate notice, with the fields enclosed by brackets "[]"
236
+ replaced with your own identifying information. (Don't include
237
+ the brackets!) The text should be enclosed in the appropriate
238
+ comment syntax for the file format. We also recommend that a
239
+ file or class name and description of purpose be included on the
240
+ same "printed page" as the copyright notice for easier
241
+ identification within third-party archives.
242
+
243
+ Copyright [yyyy] [name of copyright owner]
244
+
245
+ Licensed under the Apache License, Version 2.0 (the "License");
246
+ you may not use this file except in compliance with the License.
247
+ You may obtain a copy of the License at
248
+
249
+ http://www.apache.org/licenses/LICENSE-2.0
250
+
251
+ Unless required by applicable law or agreed to in writing, software
252
+ distributed under the License is distributed on an "AS IS" BASIS,
253
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
254
+ See the License for the specific language governing permissions and
255
+ limitations under the License.
256
+
257
+
258
+
259
+
260
+
261
+ ========================================================================
262
+ Apache ECharts Subcomponents:
263
+
264
+ The Apache ECharts project contains subcomponents with separate copyright
265
+ notices and license terms. Your use of the source code for these
266
+ subcomponents is also subject to the terms and conditions of the following
267
+ licenses.
268
+
269
+ BSD 3-Clause (d3.js):
270
+ The following files embed [d3.js](https://github.com/d3/d3) BSD 3-Clause:
271
+ `/src/chart/treemap/treemapLayout.ts`,
272
+ `/src/chart/tree/layoutHelper.ts`,
273
+ `/src/chart/graph/forceHelper.ts`,
274
+ `/src/util/number.ts`
275
+ See `/licenses/LICENSE-d3` for details of the license.
276
+ ```
277
+
50
278
  ## esm-env 1.2.2
51
279
 
52
280
  Declared license: MIT
@@ -74,3 +302,58 @@ The above copyright notice and this permission notice shall be included in all c
74
302
 
75
303
  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
76
304
  ```
305
+
306
+ ## tslib 2.3.0, 2.8.1
307
+
308
+ Declared license: 0BSD
309
+
310
+ ```text
311
+ Copyright (c) Microsoft Corporation.
312
+
313
+ Permission to use, copy, modify, and/or distribute this software for any
314
+ purpose with or without fee is hereby granted.
315
+
316
+ THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
317
+ REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
318
+ AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
319
+ INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
320
+ LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
321
+ OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
322
+ PERFORMANCE OF THIS SOFTWARE.
323
+ ```
324
+
325
+ ## zrender 6.1.0
326
+
327
+ Declared license: BSD-3-Clause
328
+
329
+ ```text
330
+ BSD 3-Clause License
331
+
332
+ Copyright (c) 2017, Baidu Inc.
333
+ All rights reserved.
334
+
335
+ Redistribution and use in source and binary forms, with or without
336
+ modification, are permitted provided that the following conditions are met:
337
+
338
+ * Redistributions of source code must retain the above copyright notice, this
339
+ list of conditions and the following disclaimer.
340
+
341
+ * Redistributions in binary form must reproduce the above copyright notice,
342
+ this list of conditions and the following disclaimer in the documentation
343
+ and/or other materials provided with the distribution.
344
+
345
+ * Neither the name of the copyright holder nor the names of its
346
+ contributors may be used to endorse or promote products derived from
347
+ this software without specific prior written permission.
348
+
349
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
350
+ AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
351
+ IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
352
+ DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
353
+ FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
354
+ DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
355
+ SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
356
+ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
357
+ OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
358
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
359
+ ```
package/README.md CHANGED
@@ -1,4 +1,4 @@
1
- ![Agent Usage banner](static/brand/agent-usage-banner.svg)
1
+ ![Agent Usage dashboard showcase](static/brand/agent-usage-showcase.jpg)
2
2
 
3
3
  # Agent Usage
4
4
 
@@ -9,7 +9,7 @@
9
9
  [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE)
10
10
 
11
11
  Agent Usage is a macOS-first, fully local usage center for Codex, Claude Code,
12
- OpenCode Go, and Grok. One command opens a dashboard for native quota windows,
12
+ OpenCode, and Grok. One command opens a dashboard for native quota windows,
13
13
  reset times, tokens, model rankings, equivalent API cost, history, and diagnostics.
14
14
  It offers advice but never switches agents automatically.
15
15
 
@@ -19,9 +19,20 @@ The dashboard has two primary tabs:
19
19
 
20
20
  - **Agent usage** preserves each provider's native five-hour, weekly, monthly,
21
21
  All models, and Fable-only quota labels and reset times.
22
- - **Tokens & model costs** supports 24-hour, 7-day, and 30-day ranges. It shows
23
- token categories, provider totals, daily trends, model rankings, and the public
24
- API retail equivalent of eligible token usage.
22
+ - **Tokens & model costs** supports 24-hour, 7-day, and 30-day ranges. It puts
23
+ totals first, charts Provider share and the interactive daily trend, then shows
24
+ model rankings with visual share bars and the public API retail equivalent of
25
+ eligible token usage.
26
+
27
+ Declare what each plan costs in Settings and the same tab adds a **subscription
28
+ value** view: it prorates that price over the selected range and compares it with
29
+ the API retail equivalent of the tokens the plan produced, mapping every
30
+ subscription against a break-even line and ranking the value multiple beside what
31
+ a million tokens actually cost you. Adding the plan's renewal date also measures
32
+ each subscription over its own billing period, showing how far into that cycle it
33
+ is and whether it is on pace to pay for itself, so a plan in its first week is
34
+ never read against one in its fourth. The plan price is a local declaration; it
35
+ never becomes a cost record and never enters any cost total.
25
36
 
26
37
  Actual charges, provider-reported estimates, fixed subscription fees, and API
27
38
  retail equivalents are separate evidence. The API retail equivalent is not a bill
@@ -96,13 +107,14 @@ agent-usage clear --yes
96
107
 
97
108
  ## Provider coverage
98
109
 
99
- | Provider / billing domain | Native quota | Token history | Cost evidence |
100
- | ------------------------- | ----------------------------------------------------------------------- | --------------------------------------------------- | -------------------------------------------------------------------------------------- |
101
- | Codex | Official account buckets when available | Local rollouts with account-day reconciliation | API retail equivalent |
102
- | Claude Code | Experimental official-client usage, including All models and Fable only | Local session transcripts; optional OTLP supplement | Client estimate and API retail equivalent |
103
- | OpenCode Go | Official account-wide five-hour, weekly, and monthly windows | Official CLI/session export | Provider-reported or explicitly estimated values |
104
- | Grok Build / SuperGrok | Experimental shared subscription allowance | Local `updates.jsonl`; optional OTLP supplement | Client estimate and API retail equivalent, including recognized Grok 4.6 Build aliases |
105
- | Grok · xAI API | No subscription quota | Official Management API aggregation | Actual USD amounts, balance, limit, and invoice when available |
110
+ | Provider / billing domain | Native quota | Token history | Cost evidence |
111
+ | ------------------------- | ----------------------------------------------------------------------- | -------------------------------------------------------- | -------------------------------------------------------------------------------------- |
112
+ | Codex | Official account buckets when available | Local rollouts with account-day reconciliation | API retail equivalent |
113
+ | Claude Code | Experimental official-client usage, including All models and Fable only | Local session transcripts; optional OTLP supplement | Client estimate and API retail equivalent |
114
+ | OpenCode Go | Official account-wide five-hour, weekly, and monthly windows | Kept separate from local history | Quota context only |
115
+ | OpenCode · local history | No subscription quota | All completed local requests across configured Providers | Client-reported estimate; API retail equivalent when eligible |
116
+ | Grok Build / SuperGrok | Experimental shared subscription allowance | Local `updates.jsonl`; optional OTLP supplement | Client estimate and API retail equivalent, including recognized Grok 4.6 Build aliases |
117
+ | Grok · xAI API | No subscription quota | Official Management API aggregation | Actual USD amounts, balance, limit, and invoice when available |
106
118
 
107
119
  Every value retains its authority and observation time. Account-wide and this-Mac
108
120
  evidence remain visibly distinct.
package/README.zh-CN.md CHANGED
@@ -1,4 +1,4 @@
1
- ![Agent Usage 横幅](static/brand/agent-usage-banner.svg)
1
+ ![Agent Usage 仪表盘功能展示](static/brand/agent-usage-showcase.jpg)
2
2
 
3
3
  # Agent Usage
4
4
 
@@ -9,7 +9,7 @@
9
9
  [![许可证:MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE)
10
10
 
11
11
  Agent Usage 是一个 macOS 优先、完全在本地运行的用量中心。一次启动即可统一查看
12
- Codex、Claude Code、OpenCode Go 与 Grok 的原生额度窗口、刷新时间、Token、模型排行、
12
+ Codex、Claude Code、OpenCode 与 Grok 的原生额度窗口、刷新时间、Token、模型排行、
13
13
  API 对等费用、历史与诊断。它只提供建议,不会自动切换 Agent。
14
14
 
15
15
  ## 核心页面
@@ -17,7 +17,13 @@ API 对等费用、历史与诊断。它只提供建议,不会自动切换 Age
17
17
  页面只有两个主要标签页:
18
18
 
19
19
  - **Agent 用量**:保留各平台原生的 5 小时、周、月、All models 和 Fable only 等额度标签与刷新时间。
20
- - **Token 与模型费用**:支持 24 小时、7 天和 30 天范围,展示 Token 分类、平台汇总、每日趋势、模型排行,以及符合条件的 Token 按公开 API 价格计算出的对等费用。
20
+ - **Token 与模型费用**:支持 24 小时、7 天和 30 天范围。顶部优先展示汇总信息,随后用图表展示 Provider 占比和可交互的每日趋势,再以占比条呈现模型排行及符合条件的 Token 按公开 API 价格计算出的对等费用。
21
+
22
+ 在设置中填写各订阅的价格后,同一标签页会多出**订阅性价比**视图:把订阅价按所选时间窗摊销,
23
+ 与该订阅产出的 Token 的 API 对等价做对比,在图谱上以保本线定位每个订阅,并给出价值倍数、
24
+ 你实际付出的每百万 Token 单价与市场单价。再填上续费日,还会按每个订阅**自己的计费周期**单独衡量:
25
+ 显示本周期已经走了多少天、已回本多少,以及按当前进度能否回本,这样处在第一周的订阅不会和处在第四周的订阅被放在一起比。
26
+ 订阅价只是本机声明,不会变成费用记录,也不会进入任何费用合计。
21
27
 
22
28
  实际账单、平台报告估算、固定订阅费和 API 对等零售价是四类互不混合的证据。
23
29
  API 对等零售价不是账单,也不会被描述成订阅支出。模型或价格未知时保持未分类或未定价,
@@ -84,13 +90,14 @@ agent-usage clear --yes
84
90
 
85
91
  ## 平台覆盖范围
86
92
 
87
- | 平台 / 计费域 | 原生额度 | Token 历史 | 费用证据 |
88
- | ---------------------- | --------------------------------------------------- | ------------------------------------ | ------------------------------------------------------------- |
89
- | Codex | 可用时读取官方账户额度桶 | 本地 rollout,并与账户日汇总对账 | API 对等零售价 |
90
- | Claude Code | 实验性官方客户端用量,包括 All models 与 Fable only | 本地会话记录;可选 OTLP 补充 | 客户端估算与 API 对等零售价 |
91
- | OpenCode Go | 官方账户级 5 小时、周、月窗口 | 官方命令行或会话导出 | 平台报告值或明确标注的估算 |
92
- | Grok Build / SuperGrok | 实验性共享订阅额度 | 本地 `updates.jsonl`;可选 OTLP 补充 | 客户端估算与 API 对等零售价,包括可识别的 Grok 4.6 Build 别名 |
93
- | Grok · xAI API | 没有订阅额度 | 官方 Management API 聚合 | 可用时展示实际美元金额、余额、上限与账单 |
93
+ | 平台 / 计费域 | 原生额度 | Token 历史 | 费用证据 |
94
+ | ---------------------- | --------------------------------------------------- | ----------------------------------------- | ------------------------------------------------------------- |
95
+ | Codex | 可用时读取官方账户额度桶 | 本地 rollout,并与账户日汇总对账 | API 对等零售价 |
96
+ | Claude Code | 实验性官方客户端用量,包括 All models 与 Fable only | 本地会话记录;可选 OTLP 补充 | 客户端估算与 API 对等零售价 |
97
+ | OpenCode Go | 官方账户级 5 小时、周、月窗口 | 与本地历史分开 | 仅作为额度上下文 |
98
+ | OpenCode · 本地历史 | 没有订阅额度 | 所有已完成的本地请求,覆盖已配置 Provider | 客户端报告估算;符合条件时计算 API 对等零售价 |
99
+ | Grok Build / SuperGrok | 实验性共享订阅额度 | 本地 `updates.jsonl`;可选 OTLP 补充 | 客户端估算与 API 对等零售价,包括可识别的 Grok 4.6 Build 别名 |
100
+ | Grok · xAI API | 没有订阅额度 | 官方 Management API 聚合 | 可用时展示实际美元金额、余额、上限与账单 |
94
101
 
95
102
  每个数字都会保留来源权威等级和观测时间;账户全局与仅此 Mac 的证据始终明确区分。
96
103
 
@@ -112,6 +112,7 @@ Run `pnpm licenses:generate` after dependency changes and review the diff before
112
112
  | `define-lazy-prop` | 3.0.0 | MIT | [link](https://github.com/sindresorhus/define-lazy-prop#readme) |
113
113
  | `detect-libc` | 2.1.2 | Apache-2.0 | [link](https://github.com/lovell/detect-libc#readme) |
114
114
  | `devalue` | 5.9.2 | MIT | [link](https://github.com/sveltejs/devalue#readme) |
115
+ | `echarts` | 6.1.0 | Apache-2.0 | [link](https://echarts.apache.org) |
115
116
  | `es-module-lexer` | 2.3.2 | MIT | [link](https://github.com/guybedford/es-module-lexer#readme) |
116
117
  | `esbuild` | 0.27.7, 0.28.2 | MIT | [link](https://github.com/evanw/esbuild#readme) |
117
118
  | `escape-string-regexp` | 4.0.0 | MIT | [link](https://github.com/sindresorhus/escape-string-regexp#readme) |
@@ -242,7 +243,7 @@ Run `pnpm licenses:generate` after dependency changes and review the diff before
242
243
  | `tree-kill` | 1.2.2 | MIT | [link](https://github.com/pkrumins/node-tree-kill) |
243
244
  | `ts-api-utils` | 2.5.0 | MIT | [link](https://github.com/JoshuaKGoldberg/ts-api-utils#readme) |
244
245
  | `ts-interface-checker` | 0.1.13 | Apache-2.0 | [link](https://github.com/gristlabs/ts-interface-checker#readme) |
245
- | `tslib` | 2.8.1 | 0BSD | [link](https://www.typescriptlang.org/) |
246
+ | `tslib` | 2.3.0, 2.8.1 | 0BSD | [link](https://www.typescriptlang.org/) |
246
247
  | `tsup` | 8.5.1 | MIT | [link](https://tsup.egoist.dev/) |
247
248
  | `tsx` | 4.23.12 | MIT | [link](https://tsx.hirok.io) |
248
249
  | `type-check` | 0.4.0 | MIT | [link](https://github.com/gkz/type-check) |
@@ -263,6 +264,7 @@ Run `pnpm licenses:generate` after dependency changes and review the diff before
263
264
  | `yocto-queue` | 0.1.0 | MIT | [link](https://github.com/sindresorhus/yocto-queue#readme) |
264
265
  | `zimmerframe` | 1.1.4 | MIT | [link](https://github.com/sveltejs/zimmerframe#readme) |
265
266
  | `zod` | 4.4.3 | MIT | [link](https://zod.dev) |
267
+ | `zrender` | 6.1.0 | BSD-3-Clause | [link](https://github.com/ecomfe/zrender#readme) |
266
268
 
267
269
  Complete license texts for dependencies bundled into the browser distribution are in
268
270
  [BUNDLED_LICENSES.md](BUNDLED_LICENSES.md). Dependencies installed separately retain