Repository navigation
Conversation
Community plugin: token usage query (token_usage MCP tool, /usage command, skill) plus a desktop floating status bar (speed, usage, context, plan quota, Git status) and a per-answer rate line. Desktop status bar install modifies app.asar (removable patch, opt-out respected, documented in the bilingual README). Plain Python 3.8 stdlib + plain JS, no third-party code, MIT.
Collaborator
|
✅ Internal validation passed. A ZCode maintainer will review the change next; after acceptance, release checks run separately and this PR is closed automatically. |
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Plugin type (required) / 插件类型(必填)
Affected plugin name(s) / 涉及的插件名称:
zcode-token-usage-statusbarNo
ui.surfaces, no_meta.ui.resourceUri; the MCP server and the renderer-bridge status bar do not provide MCP Apps pages.What / 改动内容
New community plugin zcode-token-usage-statusbar v1.5.3, registered under
external_plugins/with categorydeveloper-tools.User problem it solves / 解决的用户问题: ZCode's UI shows no token usage, model speed, context consumption, or plan-quota usage, so users cannot see what a session costs or how fast the model actually streams. This plugin makes that visible without leaving the chat.
What users get / 用户可见行为:
/usagecommand (today / week / models / current),token_usage(scope)MCP tool, and a skill for agent-driven queries.How to test / 测试方式:
app.asar; fully quit and reopen ZCode)./usage today→ usage report; thetoken_usageMCP tool answers scope queries./uninstall-overlayremoves the status bar and leaves an opt-out marker;"plugin_auto_install_overlay": falsekeeps query-tools-only mode.Version & marketplace registration / 版本与市场注册: v1.5.3 in
plugin.json(both manifests) andmarketplace.json,description_i18nidentical in all three. 1.5.2 exists on this plugin's own GitHub release channel (immutable), so this content change bumps to 1.5.3.Dependencies, network, permissions, side effects / 依赖、网络请求、权限与副作用 (also documented in both READMEs):
app.asarto inject the status bar loader (removable patch, keeps a backup, opt-out respected, full disclosure in README).SessionStart(runtime-file sync, update check, restart notice),UserPromptSubmit(prompt timestamp + rate line). MCP: stdiousage_mcp.pyexposingtoken_usage, read-only on the local usage DB.~/.zcode/zcode-token-usage-statusbar/(runtime files, config, state; secrets0600), theapp.asarpatch + backup, overlay settings in~/.zcode/zusage3.git(no fetch).Third-party material / 第三方材料: none — no third-party code, assets, or services bundled. Source: ByteRax/zcode-token-usage-statusbar (MIT).
Self-check / 自查清单
external_plugins/<name>/; existing fixes retain ownership / 插件名唯一且 kebab-case,外部新增插件位于external_plugins/<name>/,已有插件修复保留原归属categoryis set independently of publisher ownership / 用途分类category已填写,与维护归属分开versionbumped in BOTHplugin.jsonandmarketplace.json(artifacts are immutable) /plugin.json与marketplace.json两处版本号已同步升级(制品不可变)README.md(EN) andREADME_CN.md(中文) both updated and equivalent / 中英文 README 均已更新且语义一致description_i18nhas bothenandzh-CN/description_i18n包含en与zh-CNpython3 scripts/validate.pyandpython3 scripts/build_dist.pypass locally / 本地校验与构建均通过Notes on the checks / 校验说明:
scripts/validate.py: OK: 52 plugin(s) validated (includes this one).git diff --check: clean.scripts/build_dist.py: the full-repo run stops at the pre-existingexcalidrawstep in this shallow clone (incomplete build; run pnpm build first— reproduced on unmodifiedmain, it needs the CI pnpm build artifacts, unrelated to this PR). To verify this plugin's packaging,build_zip+build_index_entryfromscripts/build_dist.pywere invoked directly onexternal_plugins/zcode-token-usage-statusbar: 31 entries, no__pycache__/.pyc, README_CN.md included, marketplacesourcerewrite to the zip install source works, and the build is deterministic (identical sha256 on rebuild).