把消耗的 token 变成从窗口顶端掉落的米饭
30.8/100
综合分
1
GitHub 星标
—
npm 周下载
—/5
用户评分
数据截至 2026/10/5 · 周下载取自 npm 全网(含 CI / 镜像),非本站安装数;综合分由星标、活跃度与兼容性检查合成。
自动兼容检查有告警:未发布到 npm registry,仅可从源码安装。
安装命令 · 需先装 dsh CLI 引擎
dsh plugin --profile web add zczgagat/token2rice该包不可直接 npm 安装,改从 GitHub 源安装(明细见下方安装检查)
状态速览
判定依据:实装验证 · 静态安装检查 · 自动扫描 · 仓库维护状态信任档位:已验证
是什么
dsh 原生插件 · other
安全吗
本站尚未对该插件做风险分级
暂未覆盖,不等同于无风险
还在维护吗
活跃:最近一次提交在 29 天前
档位由哪些信号合成
本站实装验证(真实安装 L4 覆盖全站;L5 为运行时冒烟或实机截图,覆盖范围小于 L4) · 验证所用 dsh 版本 · 静态安装检查 · 风险分级 · 仓库维护状态。 下方各区块是它的证据明细。
社区实装还没有人打卡 · 装过的第一个就是你
安装兼容性检查⚠ 装前注意未发布到 npm registry,仅可从源码安装
展开查看检查明细 ↓
以下结论由程序自动检查 npm 包、engines 声明与入口文件得出,未做人工实机验证——能装不等于用着没问题。
✗npm 包token2rice(未发布到 npm,仅可源码安装)
✓Node 引擎未声明 engines.node
✓dsh CLI 依赖未声明 dsh 版本约束
✓入口文件main/exports/bin 已声明
验证方式:npm registry 存在性 + package.json 静态校验 · 最后检查 2026/10/12 21:23:21
安全扫描自动 · 静态分析源码v2.7.0🔵 扫描:含敏感能力尚无人工评估展开查看扫描说明与证据 ↓
安全扫描自动 · 静态分析源码
v2.7.0静态扫描发现插件具备触达本地系统的能力:执行外部命令、读写/删除本地文件、读取剪贴板或密钥类环境变量(至少其一)。这是能力清单,不是危险判定——具体能力项与证据见下方,安装前请自行判断是否需要。
读写/删除本地文件发起外部网络请求
查看扫描证据(共 19 处,展示前 19 条)
- 写入本地文件index.js:132
await writeFile(temp, JSON.stringify(value, null, 1), 'utf8') - 写入本地文件index.js:133
await rename(temp, path) - 删除本地文件index.js:135
await unlink(temp).catch(() => {}) - 写入本地文件index.js:144
await writeFile(temp, bytes) - 写入本地文件index.js:145
await rename(temp, path) - 删除本地文件index.js:147
await unlink(temp).catch(() => {}) - 读取本地文件index.js:228
const info = await stat(join(PLUGIN_DIR, 'assets', 'bowl.png')) - 读取本地文件index.js:239
const info = await stat(artPath) - 读取本地文件index.js:240
const bytes = await readFile(artPath) - 读取本地文件index.js:254
const raw = await readFile(statePath, 'utf8') - 写入本地文件index.js:275
await mkdir(stateDir, { recursive: true }) - 读取本地文件index.js:316
imageCache = await readFile(join(PLUGIN_DIR, 'assets', 'bowl.png')) - 删除本地文件index.js:391
await unlink(artPath) - 写入本地文件index.js:418
await mkdir(stateDir, { recursive: true }) - 发起网络请求client.js:264
const response = await fetch(url, { signal: AbortSignal.timeout(4000), cache: 'no-store' }) - 发起网络请求client.js:1076
const response = await fetch(probeRef.current.sibling('art'), { - 发起网络请求client.js:1466
const response = await fetch(url, { method: 'POST', signal: AbortSignal.timeout(4000) }) - 发起网络请求client.js:1533
const response = await fetch(probeRef.current.sibling('art'), { - 发起网络请求client.js:1585
const response = await fetch(probeRef.current.sibling('art'), { method: 'DELETE', signal: AbortSignal.timeout(8000) })
扫描于 2026/11/4(0 天前) · 范围 入口闭包 + 发布文件清单 · 来源 GitHub 仓库
静态扫描只反映源码中出现的调用,不构成安全背书;人工评估与自动扫描相互独立、互不覆盖。
给这个插件打分还没有人投票↓
用户评分
还没有人投票,来当第一个
功能亮点
- token转换为白米饭
- 窗口顶端掉落米饭
一个能把你消耗的token转换为白米饭的dsh插件
README
由 DeepSeek 最新模型翻译生成token2rice
每花掉一笔 token,就从 DSH 窗口顶端掉下一碗白米饭。 Every N tokens you spend drops a bowl of rice from the top of the DSH window.
rice bowl
花掉的 token ÷ 每碗额度 = 画面上的碗数 spent tokens ÷ tokens-per-bowl = bowls on screen
一个 DeepSeek Harness(DSH)Web 界面插件:把「烧掉的 token」变成看得见的东西。
A DeepSeek Harness (DSH) web-UI plugin that turns burned tokens into something you can see.
它做什么 / What it does
- 宿主半边:折叠全进程 session/event 里 assistant/message 的 provider 用量(input / output / cacheRead / cacheWrite),原子写入 $DSH_HOME/token2rice/state.json,重启不丢。
- 浏览器半边:注册进窗口级浮层 shell.overlay,在 requestAnimationFrame 循环里跑 2D 物理。
展开完整文档(README 剩余 1 节)
token2rice 每花掉一笔 token,就从 DSH 窗口顶端掉下一碗白米饭。 Every N tokens you spend drops a bowl of rice from the top of the DSH window. rice bowl 花掉的 token ÷ 每碗额度 = 画面上的碗数 spent tokens ÷ tokens-per-bowl = bowls on screen 一个 DeepSeek Harness(DSH)Web 界面插件:把「烧掉的 token」变成看得见的东西。 A DeepSeek Harness (DSH) web-UI plugin that turns burned tokens into something you can see. 它做什么 / What it does - 宿主半边:折叠全进程 session/event 里 assistant/message 的 provider 用量(input / output / cacheRead / cacheWrite),原子写入 $DSH_HOME/token2rice/state.json,重启不丢。 - 浏览器半边:注册进窗口级浮层 shell.overlay,在 requestAnimationFrame 循环里跑 2D 物理。 - Host half folds provider-reported usage from every session into a durable ledger at $DSH_HOME/token2rice/state.json. - Browser half registers into the frame-wide shell.overlay slot and runs a small 2D physics loop. 玩法 / What you can do | 掉落 | 每攒够一碗的额度就从视口顶端生成一碗:初始朝向随机、自转 0~1 r/s 方向随机、初速度方向随机但一定向下;之后重力自由落体、落地弹跳、压扁回弹、溅几粒米 | | 拖动 | 鼠标就是手:碗吊在你抓住的那个点上,拖着走会绕着鼠标摆、甩一下会荡起来,松手按当前速度继续飞 | | 暴风吸入 | 计数牌左边的漩涡钮:点一下把所有碗卷进风眼;把一碗拖到钮上松手则只吸这一碗(靠近时钮会点亮)。两种吸入都会播放音效 | | 扔掉 | 双击一碗把它从画面上删掉;面板里「清空画面」一次全清 | | 计数牌 | 右下角(可拖到任意位置)显示已换多少碗、当前花了多少 token;轻点开面板 | | 换图 | 面板里「选择图片…」或把图片拖到面板上,换成自己的图(PNG / JPEG / WebP / GIF,≤4MB) | - Drops: each bowl spawns with a random orientation, a random spin (0–1 r/s, either direction) and a random initial velocity (any direction, but always downward); then gravity, bounce, squash-and-rebound and a few flying grains on impact. - Drag any bowl: the cursor is the hand — the bowl hangs from the point you grabbed and swings around the cursor under gravity (a pendulum pivoting at the grab point); releasing hands its momentum to the free fall. - Double-click a bowl to remove it; the panel can clear the whole screen. - The vortex button beside the counter (assets/vortex.svg) sucks every bowl into the eye of the storm along an inward spiral — they shrink and fade as they go; the earned count is untouched. - The badge (bottom-right, draggable) shows bowls earned and tokens counted; click it for settings. - Bring your own artwork (PNG/JPEG/WebP/GIF, ≤ 4MB) — pick a file or drag it onto the panel. 安装 / Install 从仓库装 / from the repo: dsh plugin --profile desktop add github:zczgagat/token2rice 本地开发安装 / local development: dsh plugin --profile desktop add link:C:\path\to\token2rice 装完刷新一次页面 / refresh the page afterwards. 卸载 / uninstall: dsh plugin --profile desktop remove token2rice 设置 / Settings 点计数牌开面板,设置存在浏览器 localStorage(token2rice.settings.v1),不需要改 profile。 | 旋钮 | 默认 | 说明 | | 每碗 token | 1000000 | 攒够这么多 token 掉一碗;预设 100K / 500K / 1M / 2M / 5M,也可直接填 | | 米饭大小 | 56px | 碗宽 28–140px,已落地和飞行中的碗都会立刻跟着变 | | 最多摆几碗 | 24 | 画面同时显示的上限,滑杆 4–80;超出时最旧的先被顶掉(计数不受影响) | | 计入缓存 token | 开 | 关掉只算新算的 input + output,缓存读取不计入 | | 显示计数牌 | 开 | 关掉只留一个小圆点,仍可点开设置 | | 落地自动回正 | 开 | 关掉后碗保持落地那一刻的倾角,歪着堆在一起,不再自己摆正 | | 吸入音效 | 开 | 点暴风钮、或把碗拖到钮上松手时播放 assets/food.mp3 | | 位置 | 右下角 | 拖计数牌或面板标题栏即可移动;「归位」按钮回默认位置 | 面板内容较长时会自己滚动(标题栏固定在上方,仍可拖动移动面板)。 口径 / What counts 默认把四个桶都算上(input / output / cacheRead / cacheWrite)——缓存读取通常占大头,重度使用一天可能就是几千万,这样才有「掉米饭」的观感。想更接近「真正新算的 token」就关掉「计入缓存 token」。 计数自插件首次启用起算,不回溯安装之前的花费。 By default all four provider buckets count; turn off "count cached tokens" for a stricter measure. Counting starts when the plugin is first enabled, never retroactively. 自带米饭图 / Your own artwork - 正常路径:图交给宿主存成 $DSH_HOME/token2rice/art.img,换浏览器、重开会话、重启 DSH 都还在。 - 兜底路径:宿主还没有 /token2rice/art 路由时(例如升级插件后还没重启),图存进当前浏览器的 IndexedDB,刷新即可用;宿主路由上线后,下一次挂载会自动把本地那张搬到宿主。 - 恢复默认两边一起清,回到仓库里的 assets/bowl.png。 已知边界 / Known limits - 只认 assistant/message 上 provider 上报的 usage:路由不上报用量就是零。 - 画面最多同时摆 24 碗(默认,面板里可调 4–80),超出的只进计数牌,最旧的先退场。 - 刷新页面会把已经挣到的碗直接摆好,只有新挣到的才下落;一次最多 4 碗做下落动画。 - 宿主半边的代码改动要重启 DSH 才生效(已安装的包不会热替换宿主模块);浏览器半边改完刷新即可。 - 宿主进程会缓存读过的米饭图,换 assets/bowl.png 之后同样要重启才吃得到新字节。 文件 / Layout | 文件 | 作用 | | index.js | 宿主半边:session/event 折叠、账本落盘、HTTP 路由 | | client.js | 浏览器半边:浮层、物理、面板、导入图片 | | cordis.patch.yml | bundle patch,把插件行插进 profile | | docs/notes.zh.md | 中文实现笔记(路由表、缓存、竞态处理等细节) | | tools/ | 米饭图来源脚本:rawcopy.py(原样拷贝)/ cutout.py(自动抠底);build-vortex-icon.py 生成暴风图标;embed-sound.py 把 assets/food.mp3 内嵌进 client.js | License MIT
预览分享卡片长什么样 ↓
分享 · DeepSeek Harness Hub
zczgagat/token2rice
把消耗的 token 变成从窗口顶端掉落的米饭
相关插件 · 其他
模型破甲清洗HunYiSage/dsh-purge
⚔️ DeepSeek Harness 网络安全红队工具dsh-purge
★ 16,993已汉化DeepSeek 客户端
73
女娲蒸馏alchaincyf/nuwa-skill
输入名人名字,提炼其思维模型与决策方式供你调用
★ 37,308已汉化DSH
72
逆向分析桥接Fanqi89/dsh-rea
REA(Reverse Engineer Anything)MCP 桥接,用来把 REA 逆向工具接入 DSH 插件
★ 51已汉化DSH
72
语音女友beiyege-01/dsh-voice-ai-girlfriend
语音 AI 女友Voice AI girlfriend for DeepSeek Harness:Whisper…
★ 888已汉化DSH
71.6
红队越狱测试套件Minglink/dsh-infinite-gen-5
DeepSeek v4.1 flash 逆向工具无限五代 求 Star 收藏 ⭐欢迎大家提交项目的改进
★ 3,759已汉化DSH
71.4
协同办公空间dream-num/univer-workspace
一个让人类与 AI Agent 共同创作、协作和审阅的开源 Office 工作空间。
★ 2,269已汉化DSH
70.8
这是你的仓库?认领条目