@seanyao/roll 2.602.2 → 2.602.4
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.
- package/CHANGELOG.md +16 -0
- package/bin/roll +29 -4
- package/lib/__pycache__/model_prices.cpython-314.pyc +0 -0
- package/lib/prices/snapshot-2026-05-23-deepseek.json +1 -1
- package/lib/prices/snapshot-2026-06-02-kimi.json +15 -0
- package/package.json +1 -1
- package/lib/prices/snapshot-2026-05-23-kimi.json +0 -15
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,21 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## v2.602.4
|
|
4
|
+
|
|
5
|
+
### 可见性
|
|
6
|
+
|
|
7
|
+
- **kimi 成本按官方实价显示(价格快照校正)** — 之前 kimi 所有模型都按一个旧低价(¥1/¥4)算,成本被低报约 5-7x;现在按官方实价(K2.6 ¥6.5 in / ¥27 out)显示,kimi-code 的用量成本终于对得上账。deepseek 价格本就正确,顺手清掉过期的折扣注释
|
|
8
|
+
|
|
9
|
+
## v2.602.3
|
|
10
|
+
|
|
11
|
+
### 可见性
|
|
12
|
+
|
|
13
|
+
- **deepseek 的 cycle 也能看到 token 和成本(FIX-164)** — 之前 deepseek 跑的 cycle 明明提了 PR、有耗时,token/成本却是空的(压根没采到用量);现在每轮都按当轮实际 agent 落账,deepseek 和 kimi 一样看得见用量和成本 `[loop]`
|
|
14
|
+
|
|
15
|
+
### 稳定性
|
|
16
|
+
|
|
17
|
+
- **roll update 后不再被反向提示"升级"回旧版本(FIX-166)** — 升级后旧的版本检查缓存没清,偶尔还会冒出叫你装回旧号的提示;现在升级会顺手清掉缓存,这点残留也没了 `[loop]`
|
|
18
|
+
|
|
3
19
|
## v2.602.2
|
|
4
20
|
|
|
5
21
|
### 自动化流水线
|
package/bin/roll
CHANGED
|
@@ -4,7 +4,7 @@ set -euo pipefail
|
|
|
4
4
|
# Roll — AI Agent Convention Manager
|
|
5
5
|
# Single source of truth for how all AI coding agents behave.
|
|
6
6
|
|
|
7
|
-
VERSION="2.602.
|
|
7
|
+
VERSION="2.602.4"
|
|
8
8
|
ROLL_HOME="${ROLL_HOME:-${HOME}/.roll}"
|
|
9
9
|
ROLL_CONFIG="${ROLL_HOME}/config.yaml"
|
|
10
10
|
ROLL_GLOBAL="${ROLL_HOME}/conventions/global"
|
|
@@ -1998,6 +1998,10 @@ cmd_update() {
|
|
|
1998
1998
|
_check_installed_version_or_retry
|
|
1999
1999
|
fi
|
|
2000
2000
|
|
|
2001
|
+
# FIX-166: the running version just changed — invalidate the stale update-check
|
|
2002
|
+
# cache so we don't reverse-nag the new version to "upgrade" to the old latest.
|
|
2003
|
+
_invalidate_update_cache
|
|
2004
|
+
|
|
2001
2005
|
echo ""
|
|
2002
2006
|
info "$(msg update.re_syncing_to_ai_tools)"
|
|
2003
2007
|
echo ""
|
|
@@ -9022,14 +9026,21 @@ fi
|
|
|
9022
9026
|
# first, shared fallback) so the emitter appends to the same file the reader
|
|
9023
9027
|
# consumes. Dispatch by agent so each emitter reads the right session format
|
|
9024
9028
|
# (pi.usage_from_session vs kimi.usage_from_session).
|
|
9025
|
-
|
|
9029
|
+
# FIX-164: dispatch on the per-cycle ROUTED agent (CYCLE_AGENT), not the project
|
|
9030
|
+
# default (_project_agent). With the project default, a kimi-default project ran
|
|
9031
|
+
# kimi_emit for EVERY cycle — so deepseek/pi cycles emitted no usage event at all
|
|
9032
|
+
# (kimi_emit finds no kimi session for a pi cycle), and the dashboard showed them
|
|
9033
|
+
# with empty token/cost. CYCLE_AGENT (set above by the router) is the agent that
|
|
9034
|
+
# actually ran this cycle, so the right emitter reads the right session format.
|
|
9035
|
+
_emit_agent="\${CYCLE_AGENT:-\$(_project_agent)}"
|
|
9036
|
+
if [ "\$_emit_agent" != "claude" ]; then
|
|
9026
9037
|
_pi_rt=\$(_loop_runtime_dir "${slug}" 2>/dev/null || echo "")
|
|
9027
9038
|
if [ -n "\$_pi_rt" ]; then
|
|
9028
9039
|
_pi_evfile="\${_pi_rt}/events.ndjson"
|
|
9029
9040
|
else
|
|
9030
9041
|
_pi_evfile="\${_SHARED_ROOT:-\$HOME/.shared/roll}/loop/events-${slug}.ndjson"
|
|
9031
9042
|
fi
|
|
9032
|
-
case "\$
|
|
9043
|
+
case "\$_emit_agent" in
|
|
9033
9044
|
kimi)
|
|
9034
9045
|
if [ -f "${kimi_emit_script}" ]; then
|
|
9035
9046
|
python3 "${kimi_emit_script}" --cwd "\$WT" --cycle "\${CYCLE_ID}" \\
|
|
@@ -11500,7 +11511,12 @@ _loop_check_depends_on() {
|
|
|
11500
11511
|
[ -n "$row" ] || return 1
|
|
11501
11512
|
|
|
11502
11513
|
local deps
|
|
11503
|
-
|
|
11514
|
+
# FIX-167: include lowercase letters so lettered sub-story ids (the a/b/c
|
|
11515
|
+
# split pattern, e.g. US-LOOP-062c) aren't truncated to their numeric base
|
|
11516
|
+
# (US-LOOP-062). The old class [A-Z0-9,-] stopped at the lowercase suffix,
|
|
11517
|
+
# dropping the suffix AND every dep after it — so a story depending on a Done
|
|
11518
|
+
# sub-story was matched against its (often Hold) parent and wrongly blocked.
|
|
11519
|
+
deps=$(echo "$row" | grep -oE 'depends-on:[A-Za-z][A-Za-z0-9,-]+' | head -1 | sed 's/depends-on://' || true)
|
|
11504
11520
|
[ -n "$deps" ] || return 0
|
|
11505
11521
|
|
|
11506
11522
|
local unsatisfied=""
|
|
@@ -15551,6 +15567,15 @@ _show_changelog() {
|
|
|
15551
15567
|
}
|
|
15552
15568
|
|
|
15553
15569
|
# ─── Version check (background, non-blocking, 24h cache) ─────────────────────
|
|
15570
|
+
# FIX-166: drop the cached `latest` so the next run refetches it. Called after a
|
|
15571
|
+
# successful `roll update`: without this, the 24h cache TTL keeps the pre-upgrade
|
|
15572
|
+
# `latest` around, and _notify_update reverse-nags the freshly-installed (newer)
|
|
15573
|
+
# version to "upgrade" to the older cached one for up to a day. With the file
|
|
15574
|
+
# gone, _notify_update stays silent until the async refetch repopulates it.
|
|
15575
|
+
_invalidate_update_cache() {
|
|
15576
|
+
rm -f "${ROLL_HOME}/.update-check"
|
|
15577
|
+
}
|
|
15578
|
+
|
|
15554
15579
|
_check_update_async() {
|
|
15555
15580
|
local cache="${ROLL_HOME}/.update-check"
|
|
15556
15581
|
local now; now=$(date +%s)
|
|
Binary file
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
"vendor": "deepseek",
|
|
6
6
|
"currency": "CNY",
|
|
7
7
|
"default_model": "deepseek-chat",
|
|
8
|
-
"notes": "Rates per million tokens in CNY (¥) — DeepSeek's native billing currency; we never convert to USD (the dashboard already shows the currency symbol). deepseek-chat and deepseek-reasoner are both deepseek-v4-flash with different thinking modes — same pricing. deepseek-v4-pro is
|
|
8
|
+
"notes": "Rates per million tokens in CNY (¥) — DeepSeek's native billing currency; we never convert to USD (the dashboard already shows the currency symbol). deepseek-chat and deepseek-reasoner are both deepseek-v4-flash with different thinking modes — same pricing. deepseek-v4-pro is priced at in 3 / out 6 — the earlier 2.5折 launch promo became permanent (confirmed 2026-06-02 against the official page), so these are the standing rates, not a temporary discount. cache_read is the official cache-hit input price (reduced to 1/10 of launch price since 2026-04-26). cache_create = cache-miss input rate: DeepSeek levies no separate cache-write surcharge, and pi reports cacheWrite cost as 0, so this rate only ever applies to (near-zero) cacheWrite tokens. pi's own per-message cost.total is computed in USD and is kept as cost_reported_usd for audit, NOT used for the authoritative cost.",
|
|
9
9
|
"prices": {
|
|
10
10
|
"deepseek-chat": {"in": 1, "out": 2, "cache_create": 1, "cache_read": 0.02},
|
|
11
11
|
"deepseek-reasoner": {"in": 1, "out": 2, "cache_create": 1, "cache_read": 0.02},
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": "2026-06-02",
|
|
3
|
+
"effective_at": "2026-06-02",
|
|
4
|
+
"source_url": "https://platform.kimi.com/docs/pricing/chat",
|
|
5
|
+
"vendor": "kimi",
|
|
6
|
+
"currency": "CNY",
|
|
7
|
+
"default_model": "kimi-k2.6",
|
|
8
|
+
"notes": "Rates per million tokens (CNY), verified 2026-06-02 against the official Kimi platform pricing pages (pricing/chat-k25 + pricing/chat-k26). Corrects the 2026-05-23 snapshot, which had copied the original-K2 rate (1/4) onto EVERY kimi model — real K2.5 is 4/21, K2.6 is 6.5/27, so the current models' cost was under-reported ~5-7x on output. Field convention: `in` = standard (cache-miss) input price; `cache_read` = cache-hit input price; `cache_create` = cache-miss input rate (Kimi documents no separate cache-write surcharge, mirroring DeepSeek). kimi-for-coding is the kimi-code CLI's model id; the CLI config pins it to K2.6 (display_name Kimi-k2.6, default_thinking=true, base_url api.kimi.com/coding/v1), so it is priced at K2.6 rates. NOTE: kimi-code is a coding *subscription*; these per-token rates are the published K2.6 API rates used as a usage-cost estimate, not the flat subscription fee. kimi-k2 is the prior-gen original K2, retained at its launch rate (1/4) for currency resolution of legacy name variants; it is no longer on the public pricing page and is not actually billed — only kimi-for-coding (K2.6) is.",
|
|
9
|
+
"prices": {
|
|
10
|
+
"kimi-k2": {"in": 1.00, "out": 4.00, "cache_create": 1.00, "cache_read": 0.25},
|
|
11
|
+
"kimi-k2.5": {"in": 4.00, "out": 21.00, "cache_create": 4.00, "cache_read": 0.70},
|
|
12
|
+
"kimi-k2.6": {"in": 6.50, "out": 27.00, "cache_create": 6.50, "cache_read": 1.10},
|
|
13
|
+
"kimi-for-coding": {"in": 6.50, "out": 27.00, "cache_create": 6.50, "cache_read": 1.10}
|
|
14
|
+
}
|
|
15
|
+
}
|
package/package.json
CHANGED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": "2026-05-23",
|
|
3
|
-
"effective_at": "2026-05-23",
|
|
4
|
-
"source_url": "https://platform.kimi.com/docs/pricing/chat",
|
|
5
|
-
"vendor": "kimi",
|
|
6
|
-
"currency": "CNY",
|
|
7
|
-
"default_model": "kimi-k2.5",
|
|
8
|
-
"notes": "Rates per million tokens (CNY). cache_create estimated at 1.25x input. Prices from public Kimi API platform docs — verify with `roll prices refresh` if page layout changes. Model names: kimi-k2 (prior gen), kimi-k2.5 (current), kimi-k2.6 (latest). kimi-for-coding is the kimi-code CLI's model id (alias of the current K2 line) — FIX-162 so usage events tagged `kimi-code/kimi-for-coding` resolve to a real CNY entry instead of falling back to USD.",
|
|
9
|
-
"prices": {
|
|
10
|
-
"kimi-k2": {"in": 1.00, "out": 4.00, "cache_create": 1.25, "cache_read": 0.25},
|
|
11
|
-
"kimi-k2.5": {"in": 1.00, "out": 4.00, "cache_create": 1.25, "cache_read": 0.25},
|
|
12
|
-
"kimi-k2.6": {"in": 1.00, "out": 4.00, "cache_create": 1.25, "cache_read": 0.25},
|
|
13
|
-
"kimi-for-coding": {"in": 1.00, "out": 4.00, "cache_create": 1.25, "cache_read": 0.25}
|
|
14
|
-
}
|
|
15
|
-
}
|