ZYAONS/dsh-plugin-mascot ↗★ 0

dsh-plugin-mascot

显示Token缓存、上下文压力与余额的看板娘 用于直观监控账户状态。适合需要随时查看Token消耗、余额和上下文压力的用户。

套件
dsh-plugin-mascot
相容性
待驗證
版本
0.1.0
授權
NOASSERTION
最近更新
2026年9月16日

安裝

此插件尚未提供可驗證的 bundle,或相容性檢查未通過。請先閱讀倉庫說明。 閱讀完整 README ↗

Configuration

Add a config block to either form (see Configuration):

- insert:
    - id: mascot
      name: dsh-plugin-mascot
      config:
        baseUrl: 'https://api.deepseek.com'
        cacheTtlMs: 30000

Usage

InteractionResult
Click the spriteToggle the panel
Click either mini portrait in the panelSwitch mascot (choice is stored in localStorage)
Click the backdrop or press EscClose the panel
Click "刷新"Re-read the balance immediately (it also refreshes every 2 minutes while open)

While open, the pill under the sprite shows the balance. If the lookup fails it reads "点我 Token / 余额" instead of pretending to know.


Configuration

Every field has a default, so the config block is optional.

FieldDefaultMeaning
routePrefix/dsh-mascotPath prefix this plugin claims on the host webserver
baseUrlhttps://api.deepseek.comProvider origin hosting the balance endpoint
apiKeyRefDEEPSEEK_API_KEYCredentials reference name (~/.dsh/.credentials.yaml)
cacheTtlMs60000Freshness of one balance answer; failures are never cached
timeoutMs10000Upstream request budget

Behind a proxy or self-hosted gateway, point baseUrl at it — the only requirement is that it implements GET /user/balance.