refactor(ai-usage): 简化模块名称为 AI 用量

This commit is contained in:
ysicing committed 2026-09-29 22:32:10 +08:00
1 parent e19ea53771
commit 578c7c7b64
19 files changed
+51 -51

No files matched your search

@@ -1261,7 +1261,7 @@ Apple 智能本机模型当前不可用。 نموذج Apple Intelligence على
正在刷新 جارٍ التحديث
立即刷新 تحديث الآن
默认关闭 معطّل افتراضيًا
AI 用量与额度 استخدام الذكاء الاصطناعي والحصص
AI 用量 استخدام AI
Codex / Claude Code 本机 Token 用量与订阅额度 استخدام رموز Codex / Claude Code المحلية وحصص الاشتراك
今天 اليوم
模型 النموذج
@@ -1272,7 +1272,7 @@ Codex / Claude Code 本机 Token 用量与订阅额度 استخدام رموز C
缓存命中率 نسبة إصابة الذاكرة المؤقتة
用量记录 سجلات الاستخدام
模型排行 ترتيب النماذج
启用使用统计 تفعيل إحصاءات الاستخدام
启用 AI 用量 تفعيل استخدام AI
订阅额度 Subscription usage
服务端用量 · 与本机 Token 统计不同 Server usage · separate from local token statistics
重置: Resets:
@@ -1280,7 +1280,7 @@ Codex / Claude Code 本机 Token 用量与订阅额度 استخدام رموز C
上次额度 الحصة السابقة
显示本地用量 عرض الاستخدام المحلي
读取本机会话日志;关闭后停止扫描并隐藏 Token 统计。 يقرأ سجلات الجلسات المحلية؛ يؤدي إيقافه إلى وقف الفحص وإخفاء إحصاءات الرموز.
自动检测 Codex / Claude 订阅额度;本地 Token 统计可单独关闭。 يكتشف حصص اشتراك Codex وClaude تلقائيًا؛ ويمكن إيقاف إحصاءات الرموز المحلية بشكل منفصل.
查看 Codex / Claude 的 Token 用量与订阅额度。 عرض استخدام رموز Codex / Claude وحصص الاشتراك.
暂无额度数据 No quota data yet
未检测到登录凭据,请先登录对应 CLI No login credentials found; sign in with the corresponding CLI
登录已失效,请在对应 CLI 重新登录 Login expired; sign in again with the corresponding CLI
1 # Copyright (C) 2026 ysicing
1261 正在刷新
1262 立即刷新
1263 默认关闭
1264 AI 用量与额度 AI 用量
1265 Codex / Claude Code 本机 Token 用量与订阅额度
1266 今天
1267 模型
1272 缓存命中率
1273 用量记录
1274 模型排行
1275 启用使用统计 启用 AI 用量
1276 订阅额度
1277 服务端用量 · 与本机 Token 统计不同
1278 重置:
1280 上次额度
1281 显示本地用量
1282 读取本机会话日志;关闭后停止扫描并隐藏 Token 统计。
1283 自动检测 Codex / Claude 订阅额度;本地 Token 统计可单独关闭。 查看 Codex / Claude 的 Token 用量与订阅额度。
1284 暂无额度数据
1285 未检测到登录凭据,请先登录对应 CLI
1286 登录已失效,请在对应 CLI 重新登录
@@ -1261,7 +1261,7 @@ Apple 智能本机模型当前不可用。 Das lokale Apple Intelligence-Modell
正在刷新 Wird aktualisiert
立即刷新 Jetzt aktualisieren
默认关闭 Standardmäßig aus
AI 用量与额度 KI-Nutzung und Kontingente
AI 用量 KI-Nutzung
Codex / Claude Code 本机 Token 用量与订阅额度 Lokale Codex / Claude Code-Token-Nutzung und Abonnementkontingente
今天 Heute
模型 Modell
@@ -1272,7 +1272,7 @@ Codex / Claude Code 本机 Token 用量与订阅额度 Lokale Codex / Claude Cod
缓存命中率 Cache-Trefferrate
用量记录 Nutzungsdatensätze
模型排行 Modellrangliste
启用使用统计 Nutzungsstatistik aktivieren
启用 AI 用量 KI-Nutzung aktivieren
订阅额度 Subscription usage
服务端用量 · 与本机 Token 统计不同 Server usage · separate from local token statistics
重置: Resets:
@@ -1280,7 +1280,7 @@ Codex / Claude Code 本机 Token 用量与订阅额度 Lokale Codex / Claude Cod
上次额度 Vorheriges Kontingent
显示本地用量 Lokale Nutzung anzeigen
读取本机会话日志;关闭后停止扫描并隐藏 Token 统计。 Liest lokale Sitzungsprotokolle; beim Ausschalten werden Scans beendet und Tokenstatistiken ausgeblendet.
自动检测 Codex / Claude 订阅额度;本地 Token 统计可单独关闭。 Erkennt Codex-/Claude-Abonnementkontingente automatisch; lokale Tokenstatistiken lassen sich separat deaktivieren.
查看 Codex / Claude 的 Token 用量与订阅额度。 Token-Nutzung und Abonnementkontingente von Codex / Claude anzeigen.
暂无额度数据 No quota data yet
未检测到登录凭据,请先登录对应 CLI No login credentials found; sign in with the corresponding CLI
登录已失效,请在对应 CLI 重新登录 Login expired; sign in again with the corresponding CLI
1 # Copyright (C) 2026 ysicing
1261 正在刷新
1262 立即刷新
1263 默认关闭
1264 AI 用量与额度 AI 用量
1265 Codex / Claude Code 本机 Token 用量与订阅额度
1266 今天
1267 模型
1272 缓存命中率
1273 用量记录
1274 模型排行
1275 启用使用统计 启用 AI 用量
1276 订阅额度
1277 服务端用量 · 与本机 Token 统计不同
1278 重置:
1280 上次额度
1281 显示本地用量
1282 读取本机会话日志;关闭后停止扫描并隐藏 Token 统计。
1283 自动检测 Codex / Claude 订阅额度;本地 Token 统计可单独关闭。 查看 Codex / Claude 的 Token 用量与订阅额度。
1284 暂无额度数据
1285 未检测到登录凭据,请先登录对应 CLI
1286 登录已失效,请在对应 CLI 重新登录
@@ -1261,7 +1261,7 @@ Apple 智能本机模型当前不可用。 El modelo de Apple Intelligence en el
正在刷新 Actualizando
立即刷新 Actualizar ahora
默认关闭 Desactivado por defecto
AI 用量与额度 Uso y cuotas de IA
AI 用量 Uso de IA
Codex / Claude Code 本机 Token 用量与订阅额度 Tokens locales de Codex / Claude Code y cuotas de suscripción
今天 Hoy
模型 Modelo
@@ -1272,7 +1272,7 @@ Codex / Claude Code 本机 Token 用量与订阅额度 Tokens locales de Codex /
缓存命中率 Tasa de aciertos de caché
用量记录 Registros de uso
模型排行 Clasificación de modelos
启用使用统计 Activar estadísticas
启用 AI 用量 Activar Uso de IA
订阅额度 Subscription usage
服务端用量 · 与本机 Token 统计不同 Server usage · separate from local token statistics
重置: Resets:
@@ -1280,7 +1280,7 @@ Codex / Claude Code 本机 Token 用量与订阅额度 Tokens locales de Codex /
上次额度 Cuota anterior
显示本地用量 Mostrar uso local
读取本机会话日志;关闭后停止扫描并隐藏 Token 统计。 Lee los registros de sesión locales; al desactivarlo, detiene el análisis y oculta las estadísticas de tokens.
自动检测 Codex / Claude 订阅额度;本地 Token 统计可单独关闭。 Detecta automáticamente las cuotas de suscripción de Codex / Claude; las estadísticas locales de tokens pueden desactivarse por separado.
查看 Codex / Claude 的 Token 用量与订阅额度。 Consulta el uso de tokens y las cuotas de suscripción de Codex / Claude.
暂无额度数据 No quota data yet
未检测到登录凭据,请先登录对应 CLI No login credentials found; sign in with the corresponding CLI
登录已失效,请在对应 CLI 重新登录 Login expired; sign in again with the corresponding CLI
1 # Copyright (C) 2026 ysicing
1261 正在刷新
1262 立即刷新
1263 默认关闭
1264 AI 用量与额度 AI 用量
1265 Codex / Claude Code 本机 Token 用量与订阅额度
1266 今天
1267 模型
1272 缓存命中率
1273 用量记录
1274 模型排行
1275 启用使用统计 启用 AI 用量
1276 订阅额度
1277 服务端用量 · 与本机 Token 统计不同
1278 重置:
1280 上次额度
1281 显示本地用量
1282 读取本机会话日志;关闭后停止扫描并隐藏 Token 统计。
1283 自动检测 Codex / Claude 订阅额度;本地 Token 统计可单独关闭。 查看 Codex / Claude 的 Token 用量与订阅额度。
1284 暂无额度数据
1285 未检测到登录凭据,请先登录对应 CLI
1286 登录已失效,请在对应 CLI 重新登录
@@ -1261,7 +1261,7 @@ Apple 智能本机模型当前不可用。 Le modèle Apple Intelligence sur l
正在刷新 Actualisation
立即刷新 Actualiser maintenant
默认关闭 Désactivé par défaut
AI 用量与额度 Utilisation et quotas IA
AI 用量 Utilisation IA
Codex / Claude Code 本机 Token 用量与订阅额度 Tokens locaux Codex / Claude Code et quotas d’abonnement
今天 Aujourd’hui
模型 Modèle
@@ -1272,7 +1272,7 @@ Codex / Claude Code 本机 Token 用量与订阅额度 Tokens locaux Codex / Cla
缓存命中率 Taux de succès du cache
用量记录 Relevés d’utilisation
模型排行 Classement des modèles
启用使用统计 Activer les statistiques
启用 AI 用量 Activer Utilisation IA
订阅额度 Subscription usage
服务端用量 · 与本机 Token 统计不同 Server usage · separate from local token statistics
重置: Resets:
@@ -1280,7 +1280,7 @@ Codex / Claude Code 本机 Token 用量与订阅额度 Tokens locaux Codex / Cla
上次额度 Quota précédent
显示本地用量 Afficher l’utilisation locale
读取本机会话日志;关闭后停止扫描并隐藏 Token 统计。 Lit les journaux de session locaux ; la désactivation arrête l’analyse et masque les statistiques de tokens.
自动检测 Codex / Claude 订阅额度;本地 Token 统计可单独关闭。 Détecte automatiquement les quotas d’abonnement Codex / Claude ; les statistiques locales de tokens peuvent être désactivées séparément.
查看 Codex / Claude 的 Token 用量与订阅额度。 Consultez l’utilisation des tokens et les quotas d’abonnement Codex / Claude.
暂无额度数据 No quota data yet
未检测到登录凭据,请先登录对应 CLI No login credentials found; sign in with the corresponding CLI
登录已失效,请在对应 CLI 重新登录 Login expired; sign in again with the corresponding CLI
1 # Copyright (C) 2026 ysicing
1261 正在刷新
1262 立即刷新
1263 默认关闭
1264 AI 用量与额度 AI 用量
1265 Codex / Claude Code 本机 Token 用量与订阅额度
1266 今天
1267 模型
1272 缓存命中率
1273 用量记录
1274 模型排行
1275 启用使用统计 启用 AI 用量
1276 订阅额度
1277 服务端用量 · 与本机 Token 统计不同
1278 重置:
1280 上次额度
1281 显示本地用量
1282 读取本机会话日志;关闭后停止扫描并隐藏 Token 统计。
1283 自动检测 Codex / Claude 订阅额度;本地 Token 统计可单独关闭。 查看 Codex / Claude 的 Token 用量与订阅额度。
1284 暂无额度数据
1285 未检测到登录凭据,请先登录对应 CLI
1286 登录已失效,请在对应 CLI 重新登录
@@ -1261,7 +1261,7 @@ Apple 智能本机模型当前不可用。 Apple Intelligenceのオンデバイ
正在刷新 更新中
立即刷新 今すぐ更新
默认关闭 初期状態でオフ
AI 用量与额度 AI の使用量と利用枠
AI 用量 AI 使用量
Codex / Claude Code 本机 Token 用量与订阅额度 Codex / Claude Code のローカル Token 使用量とサブスクリプション利用枠
今天 今日
模型 モデル
@@ -1272,7 +1272,7 @@ Codex / Claude Code 本机 Token 用量与订阅额度 Codex / Claude Code の
缓存命中率 キャッシュヒット率
用量记录 使用記録
模型排行 モデル別使用量
启用使用统计 使用統計を有効にする
启用 AI 用量 AI 使用量を有効にする
订阅额度 Subscription usage
服务端用量 · 与本机 Token 统计不同 Server usage · separate from local token statistics
重置: Resets:
@@ -1280,7 +1280,7 @@ Codex / Claude Code 本机 Token 用量与订阅额度 Codex / Claude Code の
上次额度 前回の利用枠
显示本地用量 ローカル使用量を表示
读取本机会话日志;关闭后停止扫描并隐藏 Token 统计。 ローカルのセッションログを読み取ります。オフにするとスキャンを停止し、トークン統計を非表示にします。
自动检测 Codex / Claude 订阅额度;本地 Token 统计可单独关闭。 Codex / Claude のサブスクリプション利用枠を自動検出します。ローカルのトークン統計は個別にオフにできます。
查看 Codex / Claude 的 Token 用量与订阅额度。 Codex / Claude のトークン使用量とサブスクリプション利用枠を確認します。
暂无额度数据 No quota data yet
未检测到登录凭据,请先登录对应 CLI No login credentials found; sign in with the corresponding CLI
登录已失效,请在对应 CLI 重新登录 Login expired; sign in again with the corresponding CLI
1 # Copyright (C) 2026 ysicing
1261 正在刷新
1262 立即刷新
1263 默认关闭
1264 AI 用量与额度 AI 用量
1265 Codex / Claude Code 本机 Token 用量与订阅额度
1266 今天
1267 模型
1272 缓存命中率
1273 用量记录
1274 模型排行
1275 启用使用统计 启用 AI 用量
1276 订阅额度
1277 服务端用量 · 与本机 Token 统计不同
1278 重置:
1280 上次额度
1281 显示本地用量
1282 读取本机会话日志;关闭后停止扫描并隐藏 Token 统计。
1283 自动检测 Codex / Claude 订阅额度;本地 Token 统计可单独关闭。 查看 Codex / Claude 的 Token 用量与订阅额度。
1284 暂无额度数据
1285 未检测到登录凭据,请先登录对应 CLI
1286 登录已失效,请在对应 CLI 重新登录
@@ -1261,7 +1261,7 @@ Apple 智能本机模型当前不可用。 Apple Intelligence 온디바이스
正在刷新 새로 고치는 중
立即刷新 지금 새로 고침
默认关闭 기본적으로 꺼짐
AI 用量与额度 AI 사용량 및 한도
AI 用量 AI 사용량
Codex / Claude Code 本机 Token 用量与订阅额度 Codex / Claude Code 로컬 토큰 사용량 및 구독 한도
今天 오늘
模型 모델
@@ -1272,7 +1272,7 @@ Codex / Claude Code 本机 Token 用量与订阅额度 Codex / Claude Code 로
缓存命中率 캐시 적중률
用量记录 사용 기록
模型排行 모델 순위
启用使用统计 사용 통계 활성화
启用 AI 用量 AI 사용량 켜기
订阅额度 Subscription usage
服务端用量 · 与本机 Token 统计不同 Server usage · separate from local token statistics
重置: Resets:
@@ -1280,7 +1280,7 @@ Codex / Claude Code 本机 Token 用量与订阅额度 Codex / Claude Code 로
上次额度 이전 한도
显示本地用量 로컬 사용량 표시
读取本机会话日志;关闭后停止扫描并隐藏 Token 统计。 로컬 세션 로그를 읽습니다. 끄면 검사를 중지하고 토큰 통계를 숨깁니다.
自动检测 Codex / Claude 订阅额度;本地 Token 统计可单独关闭。 Codex / Claude 구독 한도를 자동으로 감지합니다. 로컬 토큰 통계는 별도로 끌 수 있습니다.
查看 Codex / Claude 的 Token 用量与订阅额度。 Codex / Claude 토큰 사용량과 구독 한도를 확인합니다.
暂无额度数据 No quota data yet
未检测到登录凭据,请先登录对应 CLI No login credentials found; sign in with the corresponding CLI
登录已失效,请在对应 CLI 重新登录 Login expired; sign in again with the corresponding CLI
1 # Copyright (C) 2026 ysicing
1261 正在刷新
1262 立即刷新
1263 默认关闭
1264 AI 用量与额度 AI 用量
1265 Codex / Claude Code 本机 Token 用量与订阅额度
1266 今天
1267 模型
1272 缓存命中率
1273 用量记录
1274 模型排行
1275 启用使用统计 启用 AI 用量
1276 订阅额度
1277 服务端用量 · 与本机 Token 统计不同
1278 重置:
1280 上次额度
1281 显示本地用量
1282 读取本机会话日志;关闭后停止扫描并隐藏 Token 统计。
1283 自动检测 Codex / Claude 订阅额度;本地 Token 统计可单独关闭。 查看 Codex / Claude 的 Token 用量与订阅额度。
1284 暂无额度数据
1285 未检测到登录凭据,请先登录对应 CLI
1286 登录已失效,请在对应 CLI 重新登录
@@ -1262,7 +1262,7 @@ Apple 智能本机模型当前不可用。 Apple 智能本機模型目前無法
正在刷新 正在更新
立即刷新 立即更新
默认关闭 預設關閉
AI 用量与额度 AI 用量與額度
AI 用量 AI 用量
Codex / Claude Code 本机 Token 用量与订阅额度 Codex / Claude Code 本機 Token 用量與訂閱額度
今天 今天
模型 模型
@@ -1273,7 +1273,7 @@ Codex / Claude Code 本机 Token 用量与订阅额度 Codex / Claude Code 本
缓存命中率 快取命中率
用量记录 用量記錄
模型排行 模型排行
启用使用统计 啟用使用統計
启用 AI 用量 啟用 AI 用量
订阅额度 訂閱額度
服务端用量 · 与本机 Token 统计不同 服務端用量 · 與本機 Token 統計不同
重置: 重置:
@@ -1281,7 +1281,7 @@ Codex / Claude Code 本机 Token 用量与订阅额度 Codex / Claude Code 本
上次额度 上次額度
显示本地用量 顯示本機用量
读取本机会话日志;关闭后停止扫描并隐藏 Token 统计。 讀取本機工作階段記錄;關閉後停止掃描並隱藏 Token 統計。
自动检测 Codex / Claude 订阅额度;本地 Token 统计可单独关闭。 自動偵測 Codex / Claude 訂閱額度;本機 Token 統計可單獨關閉。
查看 Codex / Claude 的 Token 用量与订阅额度。 查看 Codex / Claude 的 Token 用量與訂閱額度。
暂无额度数据 暫無額度資料
未检测到登录凭据,请先登录对应 CLI 未偵測到登入憑證,請先登入對應的 CLI
登录已失效,请在对应 CLI 重新登录 登入已失效,請在對應的 CLI 重新登入
1 # Copyright (c) 2026 GiantAccel, LLC
1262 正在刷新
1263 立即刷新
1264 默认关闭
1265 AI 用量与额度 AI 用量
1266 Codex / Claude Code 本机 Token 用量与订阅额度
1267 今天
1268 模型
1273 缓存命中率
1274 用量记录
1275 模型排行
1276 启用使用统计 启用 AI 用量
1277 订阅额度
1278 服务端用量 · 与本机 Token 统计不同
1279 重置:
1281 上次额度
1282 显示本地用量
1283 读取本机会话日志;关闭后停止扫描并隐藏 Token 统计。
1284 自动检测 Codex / Claude 订阅额度;本地 Token 统计可单独关闭。 查看 Codex / Claude 的 Token 用量与订阅额度。
1285 暂无额度数据
1286 未检测到登录凭据,请先登录对应 CLI
1287 登录已失效,请在对应 CLI 重新登录
@@ -79,10 +79,10 @@ Token 活动 Token activity
{} 当周:{} Tokens Week of {}: {} Tokens
截至 {} 当周累计:{} Tokens Through the week of {}: {} Tokens cumulative
缓存创建 Token Cache creation tokens
AI 用量与额度 AI Usage & Quotas
AI 用量 AI Usage
显示本地用量 Show local usage
读取本机会话日志;关闭后停止扫描并隐藏 Token 统计。 Reads local session logs; turning this off stops scanning and hides token statistics.
自动检测 Codex / Claude 订阅额度;本地 Token 统计可单独关闭。 Automatically detects Codex / Claude subscription quotas; local token statistics can be turned off separately.
查看 Codex / Claude 的 Token 用量与订阅额度。 View Codex / Claude token usage and subscription quotas.
Codex / Claude Code 本机 Token 用量与订阅额度 Local Codex / Claude Code tokens and subscription quotas
今天 Today
模型 Model
@@ -93,7 +93,7 @@ Codex / Claude Code 本机 Token 用量与订阅额度 Local Codex / Claude Code
缓存命中率 Cache hit rate
用量记录 Usage records
模型排行 Model ranking
启用使用统计 Enable usage statistics
启用 AI 用量 Enable AI Usage
订阅额度 Subscription usage
今日消耗的 Token Tokens used today
查看今天 Codex 和 Claude 的 Token 用量 View today's Codex and Claude token usage
@@ -12,7 +12,7 @@ final class AIUsageSettingsWindowController: NSObject, NSWindowDelegate {
private var window: NSWindow?
private(set) var isVisible = false
var onVisibilityChange: ((Bool) -> Void)?
func refreshLanguage() { window?.title = tr("AI 用量与额度") + " · " + tr("设置") }
func refreshLanguage() { window?.title = tr("AI 用量") + " · " + tr("设置") }
init(model: AppModel) {
self.model = model
@@ -34,7 +34,7 @@ final class AIUsageSettingsWindowController: NSObject, NSWindowDelegate {
let window = NSWindow(contentRect: NSRect(x: 0, y: 0, width: 430, height: 560),
styleMask: [.titled, .closable, .miniaturizable, .resizable],
backing: .buffered, defer: false)
window.title = tr("AI 用量与额度") + " · " + tr("设置")
window.title = tr("AI 用量") + " · " + tr("设置")
window.isReleasedWhenClosed = false
window.delegate = self
window.contentMinSize = NSSize(width: 390, height: 480)
@@ -50,11 +50,11 @@ private struct LocalUsageContent: View {
}
if !model.settings.aiUsageEnabled {
Card {
Label(tr("AI 用量与额度"), systemImage: "chart.bar").dsFont(.base, weight: .semibold)
Text(tr("自动检测 Codex / Claude 订阅额度;本地 Token 统计可单独关闭。"))
Label(tr("AI 用量"), systemImage: "chart.bar").dsFont(.base, weight: .semibold)
Text(tr("查看 Codex / Claude 的 Token 用量与订阅额度。"))
.dsFont(.xs).foregroundStyle(DS.Palette.textSecondary)
.fixedSize(horizontal: false, vertical: true)
Button(tr("启用使用统计")) { model.settings.aiUsageEnabled = true }
Button(tr("启用 AI 用量")) { model.settings.aiUsageEnabled = true }
.buttonStyle(DSButtonStyle(kind: .primary))
}
} else if model.settings.aiUsageSources.isEmpty {
@@ -671,7 +671,7 @@ struct AIUsageSettingsButton: View {
@Environment(AppModel.self) private var model
var body: some View {
MiniIconButton(systemName: "slider.horizontal.3", help: tr("AI 用量与额度") + " · " + tr("设置")) {
MiniIconButton(systemName: "slider.horizontal.3", help: tr("AI 用量") + " · " + tr("设置")) {
model.openAIUsageSettings()
}
}
@@ -692,8 +692,8 @@ private struct UsageSettings: View {
@Bindable var settings = model.settings
VStack(alignment: .leading, spacing: DS.Space.s4) {
Text(tr("设置")).dsFont(.base, weight: .semibold)
SettingRow(title: tr("AI 用量与额度"), subtitle: nil) {
DSToggle(isOn: $settings.aiUsageEnabled, label: tr("AI 用量与额度"))
SettingRow(title: tr("AI 用量"), subtitle: nil) {
DSToggle(isOn: $settings.aiUsageEnabled, label: tr("AI 用量"))
}
SettingRow(title: tr("显示本地用量"),
subtitle: tr("读取本机会话日志;关闭后停止扫描并隐藏 Token 统计。")) {
@@ -10,7 +10,7 @@ CPU, GPU, memory, network, temperature, fan, and process metrics come from local
Calendar events and due reminders are off by default. After you explicitly grant access, XStats reads the visible month range from your selected lists through macOS calendar APIs while the panel is open. It displays the contents locally without creating, modifying, deleting, or uploading records, and does not include them in settings backups or widget summaries. Closing the panel clears its displayed list. List selections stay on this Mac. You can turn reading off in calendar settings or revoke access in System Settings.
AI Usage & Quotas is off by default. When enabled, it reads local Codex / Claude Code session logs to summarize token usage by model. It also checks subscription quotas. Codex first uses the installed local Codex CLI App Server, which maintains its own login; if unavailable, XStats reads cached CLI credentials and queries the quota service directly. Claude Code uses its local CLI credentials for direct quota requests. Requests send the login token to the respective provider; XStats does not save tokens in its preferences or statistics database, and does not send session-log contents with quota requests. A quota request may fail or be rate-limited without affecting local token statistics. Turning the feature off stops subsequent scans and quota requests. Apple Intelligence process explanations run on-device and do not send process information to another AI service.
AI Usage is off by default. When enabled, it reads local Codex / Claude Code session logs to summarize token usage by model. It also checks subscription quotas. Codex first uses the installed local Codex CLI App Server, which maintains its own login; if unavailable, XStats reads cached CLI credentials and queries the quota service directly. Claude Code uses its local CLI credentials for direct quota requests. Requests send the login token to the respective provider; XStats does not save tokens in its preferences or statistics database, and does not send session-log contents with quota requests. A quota request may fail or be rate-limited without affecting local token statistics. Turning the feature off stops subsequent scans and quota requests. Apple Intelligence process explanations run on-device and do not send process information to another AI service.
If you manually configure Sub2API as a backup quota source for Codex or Claude Code, the app contacts the HTTPS server specified for that source only when its automatic quota lookup fails. The two configurations are stored separately, and XStats verifies the queried account's platform. Your admin email and password are sent to the corresponding server to sign in. Passwords are stored separately in this Mac's Keychain; addresses, emails, and account IDs stay in local preferences. Background quota requests use `force=false` and do not trigger active probes. Removing one source's configuration deletes its locally stored Sub2API password and connection details.
You choose whether and where to export diagnostics; they are not uploaded automatically. An exported archive may contain a settings summary, the last three days of system logs, cleanup records, and crash reports. Review it before sharing.
@@ -25,7 +25,7 @@ You can set automatic checks to Never in Settings → About. You decide whether
## 3. Other network features
- When AI Usage & Quotas is enabled, Codex quotas are read through the installed local Codex CLI App Server first; if unavailable, XStats uses cached Codex credentials to contact `chatgpt.com` directly. Claude Code uses its local credentials to contact `api.anthropic.com` directly. Those providers can observe the login token and connection metadata. The last successful quota snapshot for each source is stored in this Mac's `ai-usage.sqlite` database with percentages, reset times, source, and fetch time, but no login token. Failed queries may show that snapshot marked as old data. Authentication failure or removal of a manual configuration deletes that source's snapshot. Disabling the feature stops queries and hides quotas but retains the local snapshot for re-enabling. Quota results are not uploaded to XStats servers.
- When AI Usage is enabled, Codex quotas are read through the installed local Codex CLI App Server first; if unavailable, XStats uses cached Codex credentials to contact `chatgpt.com` directly. Claude Code uses its local credentials to contact `api.anthropic.com` directly. Those providers can observe the login token and connection metadata. The last successful quota snapshot for each source is stored in this Mac's `ai-usage.sqlite` database with percentages, reset times, source, and fetch time, but no login token. Failed queries may show that snapshot marked as old data. Authentication failure or removal of a manual configuration deletes that source's snapshot. Disabling the feature stops queries and hides quotas but retains the local snapshot for re-enabling. Quota results are not uploaded to XStats servers.
- With a Codex or Claude Code Sub2API backup configured, a failed automatic lookup for that source causes a direct request to its chosen Sub2API server. That server receives the admin email, password, login token, and account ID being queried. XStats provides no preset Sub2API server and does not upload these values or quota results to XStats servers.
- When you open network details with public-IP lookup enabled, XStats contacts Cloudflare `1.1.1.1`, falling back to ipify. It sends your public IP address to `cleanip.io` for location, ASN, network type, and cleanliness information. Results are cached locally.
- Connection probing sends ICMP packets to your selected target when enabled. Speed tests, egress checks, and DNS lookups contact selected test nodes, websites, or DNS services only when you use those features. Those services can observe connection metadata and the data needed for the test.
@@ -10,7 +10,7 @@ CPU、GPU、内存、网络、温度、风扇、进程等监控数据来自本
日历中的系统日程与到期提醒默认关闭。你主动授权后,XStats 通过 macOS 日历接口在面板打开时读取所选列表的当前月历范围,仅在本机展示,不创建、修改或删除记录,不上传内容,也不将其写入设置备份或小组件摘要。关闭面板后清空展示列表;列表选择保存在本机,可在日历设置中关闭读取,也可在系统设置中撤销权限。
“AI 用量与额度”默认关闭;开启后读取本机 Codex / Claude Code 会话日志,按模型汇总 Token 用量,并查询相应的订阅额度。Codex 优先通过本机已安装的 Codex CLI App Server 读取额度,由 CLI 自行维护登录;若该方式不可用,才读取本机 CLI 登录凭据并直连额度接口。Claude Code 使用本机 CLI 凭据直连。查询请求会向对应服务发送登录令牌;令牌不写入 XStats 设置或统计数据库,日志内容不会随额度请求发送。接口可能变化或限流,额度查询失败不影响本机 Token 统计。关闭此功能后停止后续扫描和额度查询。Apple 智能进程解释在本机运行,不把进程信息发送给其他 AI 服务。
“AI 用量”默认关闭;开启后读取本机 Codex / Claude Code 会话日志,按模型汇总 Token 用量,并查询相应的订阅额度。Codex 优先通过本机已安装的 Codex CLI App Server 读取额度,由 CLI 自行维护登录;若该方式不可用,才读取本机 CLI 登录凭据并直连额度接口。Claude Code 使用本机 CLI 凭据直连。查询请求会向对应服务发送登录令牌;令牌不写入 XStats 设置或统计数据库,日志内容不会随额度请求发送。接口可能变化或限流,额度查询失败不影响本机 Token 统计。关闭此功能后停止后续扫描和额度查询。Apple 智能进程解释在本机运行,不把进程信息发送给其他 AI 服务。
如果你为 Codex 或 Claude Code 手动配置 Sub2API 额度备选来源,只有对应来源的自动额度查询失败时,应用才会连接你为它填写的 HTTPS 服务器。两份配置分别保存,并核对查询账号的平台。管理员邮箱与密码在登录时发送到对应服务器;密码分别保存在本机钥匙串,地址、邮箱和账号 ID 只保存在本机设置中。后台额度请求使用 `force=false`,不触发主动探测。移除某个来源的配置会删除其本机保存的 Sub2API 密码和连接信息。
诊断信息由你主动导出到指定位置,不会自动上传。导出的压缩包可能包含应用设置摘要、最近三天的系统日志、清理记录和崩溃报告;分享前请自行检查内容。
@@ -25,7 +25,7 @@ CPU、GPU、内存、网络、温度、风扇、进程等监控数据来自本
## 3. 其他联网功能
- 启用“AI 用量与额度”后,Codex 优先通过本机已安装的 Codex CLI App Server 查询额度;不可用时使用本机 Codex 登录凭据直连 `chatgpt.com`。Claude Code 使用本机登录凭据直连 `api.anthropic.com`。相应服务可以看到登录令牌及连接元数据。每个来源最近一次成功的额度快照保存在本机 `ai-usage.sqlite`,包含百分比、重置时间、数据来源及获取时间,不含登录令牌;查询失败时可显示并标记为旧数据。认证失效或移除手动配置会删除对应快照。关闭功能后停止查询并隐藏额度,本地快照仍保留以便重新启用;额度结果不上传到 XStats 服务器。
- 启用“AI 用量”后,Codex 优先通过本机已安装的 Codex CLI App Server 查询额度;不可用时使用本机 Codex 登录凭据直连 `chatgpt.com`。Claude Code 使用本机登录凭据直连 `api.anthropic.com`。相应服务可以看到登录令牌及连接元数据。每个来源最近一次成功的额度快照保存在本机 `ai-usage.sqlite`,包含百分比、重置时间、数据来源及获取时间,不含登录令牌;查询失败时可显示并标记为旧数据。认证失效或移除手动配置会删除对应快照。关闭功能后停止查询并隐藏额度,本地快照仍保留以便重新启用;额度结果不上传到 XStats 服务器。
- 配置 Codex 或 Claude Code 的 Sub2API 备选来源后,对应的自动额度查询失败时,应用直接请求你为该来源指定的 Sub2API 服务器;该服务器会收到管理员邮箱、密码、登录令牌和查询账号 ID。XStats 不预设 Sub2API 服务器,也不向 XStats 服务器上传这些信息或额度结果。
- 打开网络详情且启用公网 IP 查询时,应用直接访问 Cloudflare `1.1.1.1`,失败时回退到 ipify;归属地、ASN、网络类型和纯净度查询会把公网 IP 发送给 `cleanip.io`。结果在本机缓存。
- 启用连接探测时,应用向所选目标发送 ICMP 探测。测速、出口检测和 DNS 查询仅在你使用相应功能时,直接连接所选测试节点、网站或 DNS 服务;对方可看到连接元数据及测试所需内容。
@@ -123,10 +123,10 @@ struct GeneralSettings: View {
}
}
GroupRow(showsDivider: false) {
SettingRow(title: tr("AI 用量与额度"),
subtitle: tr("自动检测 Codex / Claude 订阅额度;本地 Token 统计可单独关闭。"),
SettingRow(title: tr("AI 用量"),
subtitle: tr("查看 Codex / Claude 的 Token 用量与订阅额度。"),
icon: "sparkles") {
DSToggle(isOn: $settings.aiUsageEnabled, label: tr("AI 用量与额度"))
DSToggle(isOn: $settings.aiUsageEnabled, label: tr("AI 用量"))
}
}
GroupRow(showsDivider: false) {
@@ -24,7 +24,7 @@ public enum MenuBarItem: String, CaseIterable, Identifiable, Sendable {
case .temperature: tr("CPU 温度")
case .fan: tr("风扇转速")
case .battery: tr("电池")
case .aiUsage: tr("AI 用量与额度")
case .aiUsage: tr("AI 用量")
}
}
@@ -68,7 +68,7 @@ public enum MenuBarItem: String, CaseIterable, Identifiable, Sendable {
case .temperature: tr("温度")
case .fan: tr("风扇")
case .battery: tr("电池")
case .aiUsage: tr("AI 用量与额度")
case .aiUsage: tr("AI 用量")
}
}
@@ -322,7 +322,7 @@ public enum PanelTab: String, CaseIterable, Identifiable, Sendable {
case .overview: tr("仪表盘")
case .system: tr("本机信息")
case .history: tr("历史")
case .aiUsage: tr("AI 用量与额度")
case .aiUsage: tr("AI 用量")
case .cpu: "CPU"
case .gpu: "GPU"
case .memory: tr("内存")
@@ -6,7 +6,7 @@ import Testing
@Test func translatesExactAndTemplates() {
let table = Translations.shared
#expect(table.translate("内存") == "Memory")
#expect(table.translate("AI 用量与额度") == "AI Usage & Quotas")
#expect(table.translate("AI 用量") == "AI Usage")
#expect(table.translate("上次额度") == "Previous quota")
#expect(table.translate("上次成功:20:45") == "Last successful: 20:45")
#expect(table.translate("最近刷新:20:53") == "Last refresh: 20:53")
+2 -2
View File
@@ -58,7 +58,7 @@ brew install --cask xstats
- Processes: view all processes, search, sort, group by app, and end processes.
- Menu bar calendar: Chinese lunar calendar, public holidays and make-up workdays, almanac, plus your calendar events and reminders.
- Pomodoro and eye-rest breaks: a break screen on every display that you can skip, pause or shrink to a mini HUD at any time.
- AI usage and quotas: local Codex / Claude Code token usage and subscription quota checks.
- AI Usage: local Codex / Claude Code token usage and subscription quota checks.
**Desktop widgets**: system overview, Pomodoro, AI quotas, calendar and month view, "Work tomorrow?", IP purity and public IP.
@@ -73,7 +73,7 @@ You can also download the DMG from [GitHub Releases](https://github.com/ysicing/
No account is required. These features go online, and each can be turned off or used only on demand:
- **Update checks**: send the app version and a hashed installation ID.
- **AI Usage & Quotas** (off by default): checks subscription quotas through your local Codex / Claude CLI sign-in, with an optional Sub2API fallback.
- **AI Usage** (off by default): checks subscription quotas through your local Codex / Claude CLI sign-in, with an optional Sub2API fallback.
- **Public IP, speed tests and connection probes**: contact their services only when used.
Read the [Privacy Policy](Packages/XStatsKit/Sources/XStatsUI/Resources/Legal/Privacy.en.md) and [Terms of Service](Packages/XStatsKit/Sources/XStatsUI/Resources/Legal/Terms.en.md) for details.
+2 -2
View File
@@ -58,7 +58,7 @@ brew install --cask xstats
- プロセス:全プロセスの表示、検索、並べ替え、アプリごとのグループ化、終了に対応します。
- メニューバーカレンダー:旧暦、中国の祝日と振替出勤日、暦注に加え、カレンダーの予定とリマインダーも表示します。
- ポモドーロと目の休憩:すべてのディスプレイに休憩画面を表示し、いつでもスキップ、一時停止、ミニ HUD への縮小ができます。
- AI の使用量と利用枠:Codex / Claude Code のローカルのトークン使用量とサブスクリプション利用枠を確認します。
- AI 使用量:Codex / Claude Code のローカルのトークン使用量とサブスクリプション利用枠を確認します。
**デスクトップウィジェット**:システム概要、ポモドーロ、AI 利用枠、カレンダーと月表示、「明日は出勤?」、IP クリーン度、公開 IP。
@@ -73,7 +73,7 @@ brew install --cask xstats
アカウントは不要です。次の機能は通信を行い、いずれも設定でオフにするか必要なときだけ使えます。
- **アップデートの確認**:バージョンとインストール ID のハッシュを送信します。
- **AI の使用量と利用枠**(初期状態はオフ):ローカルの Codex / Claude CLI のログインで利用枠を確認します。Sub2API を代替ソースとして設定できます。
- **AI 使用量**(初期状態はオフ):ローカルの Codex / Claude CLI のログインで利用枠を確認します。Sub2API を代替ソースとして設定できます。
- **公開 IP・速度テスト・接続テスト**:使用するときだけ各サービスに接続します。
詳細は[プライバシーポリシー(英語)](Packages/XStatsKit/Sources/XStatsUI/Resources/Legal/Privacy.en.md)と[利用規約(英語)](Packages/XStatsKit/Sources/XStatsUI/Resources/Legal/Terms.en.md)を参照してください。
+2 -2
View File
@@ -58,7 +58,7 @@ brew install --cask xstats
- 프로세스: 모든 프로세스를 보고 검색, 정렬, 앱별 그룹화 및 종료를 할 수 있습니다.
- 메뉴 막대 달력: 음력, 중국 공휴일과 대체 근무일, 역서에 더해 캘린더 일정과 미리 알림도 표시합니다.
- 뽀모도로와 눈 휴식: 모든 디스플레이에 휴식 화면을 띄우며 언제든 건너뛰거나 일시 정지하거나 미니 HUD로 줄일 수 있습니다.
- AI 사용량 및 한도: Codex / Claude Code의 로컬 토큰 사용량과 구독 한도를 확인합니다.
- AI 사용량: Codex / Claude Code의 로컬 토큰 사용량과 구독 한도를 확인합니다.
**데스크톱 위젯**: 시스템 개요, 뽀모도로, AI 한도, 달력과 월 달력, "내일 출근?", IP 순도, 공인 IP.
@@ -73,7 +73,7 @@ brew install --cask xstats
계정은 필요하지 않습니다. 다음 기능은 네트워크에 접속하며, 모두 설정에서 끄거나 필요할 때만 사용할 수 있습니다.
- **업데이트 확인**: 앱 버전과 설치 ID의 해시를 보냅니다.
- **AI 사용량 및 한도**(기본값 꺼짐): 로컬 Codex / Claude CLI 로그인으로 구독 한도를 확인하며, Sub2API를 예비 소스로 설정할 수 있습니다.
- **AI 사용량**(기본값 꺼짐): 로컬 Codex / Claude CLI 로그인으로 구독 한도를 확인하며, Sub2API를 예비 소스로 설정할 수 있습니다.
- **공인 IP, 속도 테스트, 연결 테스트**: 사용할 때만 해당 서비스에 접속합니다.
자세한 내용은 [개인정보 처리방침(영어)](Packages/XStatsKit/Sources/XStatsUI/Resources/Legal/Privacy.en.md)과 [서비스 약관(영어)](Packages/XStatsKit/Sources/XStatsUI/Resources/Legal/Terms.en.md)을 확인하세요.
+2 -2
View File
@@ -58,7 +58,7 @@ brew install --cask xstats
- 进程:查看全部进程,支持搜索、排序、按应用分组与结束进程。
- 菜单栏日历:农历、节假日与调休、黄历,可显示系统日程和提醒事项。
- 番茄钟与护眼休息:多屏休息幕布,可随时跳过、暂停或收起到迷你 HUD。
- AI 用量与额度:统计 Codex / Claude Code 本机 Token 用量,查询订阅额度。
- AI 用量:统计 Codex / Claude Code 本机 Token 用量,查询订阅额度。
**桌面小组件**:系统概览、番茄钟、AI 额度、日历与整月日历、明天上班吗、IP 纯净度和公网 IP。
@@ -73,7 +73,7 @@ brew install --cask xstats
无需账号。以下功能会联网,均可在设置中关闭或按需使用:
- **检查更新**:发送版本号和安装标识的哈希。
- **AI 用量与额度**(默认关闭):通过本机 Codex / Claude CLI 的登录查询订阅额度,可选配置 Sub2API 作为备用来源。
- **AI 用量**(默认关闭):通过本机 Codex / Claude CLI 的登录查询订阅额度,可选配置 Sub2API 作为备用来源。
- **公网 IP、测速与连接探测**:仅在使用时请求对应服务。
完整说明见[隐私政策](Packages/XStatsKit/Sources/XStatsUI/Resources/Legal/Privacy.zh-Hans.md)和[服务条款](Packages/XStatsKit/Sources/XStatsUI/Resources/Legal/Terms.zh-Hans.md)。