Skip to content

迁移七个插件包 45 件文案进词条层(57 件/575 条,45 迁入/12 不迁) #1229

Closed

Description

@FeatherHunter

目标

把 7 个插件的客户端与宿主侧文本迁到词条:客户端走宿主语言词条席(注册词条+槽位语言选项),宿主侧(工具描述、拒答报文、桥提示)走词条层。
本票范围=「交付物路径(文件清单)」所列 57 件(575 条);清单由 ledger 派生、与其它迁移票不重叠,范围外文件不得顺手改。

7 个插件:plugin-manager、plugin-bill-ilife、plugin-calorie、plugin-chef、plugin-home-ilife、plugin-memo-ilife、plugin-schedule-ilife。

交付物路径(文件清单)

派生源:tooling/i18n-codemod.ledger.json(路径+条数+分类)。开工前把待迁件逐件登记进 tooling/i18n-scope.json 的 files 数组(正斜杠相对路径)。

  • packages/plugin-bill-ilife/src/bridge.ts — 10 条(copy 3/concat 7)
  • packages/plugin-bill-ilife/src/index.ts — 4 条(copy 3/concat 1)
  • packages/plugin-bill-ilife/src/seal-states.generated.ts — 11 条(derived 11)
  • packages/plugin-bill-ilife/src/settings.ts — 13 条(copy 13)
  • packages/plugin-bill-ilife/src/skill-tool.ts — 20 条(copy 4/concat 15/ident 1)
  • packages/plugin-bill-ilife/src/slot.ts — 1 条(copy 1)
  • packages/plugin-calorie/src/bridge.ts — 10 条(copy 3/concat 7)
  • packages/plugin-calorie/src/client.ts — 13 条(copy 6/concat 7)
  • packages/plugin-calorie/src/index.ts — 3 条(copy 2/concat 1)
  • packages/plugin-calorie/src/seal-states.generated.ts — 11 条(derived 11)
  • packages/plugin-calorie/src/settings.ts — 23 条(copy 23)
  • packages/plugin-calorie/src/skill-tool.ts — 20 条(copy 4/concat 15/ident 1)
  • packages/plugin-calorie/src/slot.ts — 1 条(copy 1)
  • packages/plugin-chef/src/bridge.ts — 10 条(copy 3/concat 7)
  • packages/plugin-chef/src/index.ts — 3 条(copy 2/concat 1)
  • packages/plugin-chef/src/seal-states.generated.ts — 11 条(derived 11)
  • packages/plugin-chef/src/settings.ts — 9 条(copy 9)
  • packages/plugin-chef/src/skill-tool.ts — 20 条(copy 4/concat 15/ident 1)
  • packages/plugin-chef/src/slot.ts — 1 条(copy 1)
  • packages/plugin-home-ilife/src/bridge.ts — 10 条(copy 3/concat 7)
  • packages/plugin-home-ilife/src/index.ts — 3 条(copy 2/concat 1)
  • packages/plugin-home-ilife/src/seal-states.generated.ts — 11 条(derived 11)
  • packages/plugin-home-ilife/src/settings.ts — 11 条(copy 11)
  • packages/plugin-home-ilife/src/skill-tool.ts — 20 条(copy 4/concat 15/ident 1)
  • packages/plugin-home-ilife/src/slot.ts — 1 条(copy 1)
  • packages/plugin-manager/src/client.ts — 10 条(copy 8/concat 2)
  • packages/plugin-manager/src/config-panel-contract.ts — 1 条(copy 1)
  • packages/plugin-manager/src/config-panel-value.ts — 11 条(concat 11)
  • packages/plugin-manager/src/config-panel-view.ts — 43 条(copy 38/concat 5)
  • packages/plugin-manager/src/config-panel.ts — 4 条(copy 2/concat 2)
  • packages/plugin-manager/src/directory-browser-contract.ts — 12 条(copy 7/concat 5)
  • packages/plugin-manager/src/directory-browser-parts.ts — 5 条(copy 5)
  • packages/plugin-manager/src/directory-browser-state.ts — 4 条(copy 2/concat 2)
  • packages/plugin-manager/src/health-fetch.ts — 7 条(copy 4/concat 3)
  • packages/plugin-manager/src/health-view.ts — 28 条(copy 15/concat 13)
  • packages/plugin-manager/src/install.ts — 4 条(copy 1/concat 3)
  • packages/plugin-manager/src/nav.ts — 14 条(copy 12/concat 2)
  • packages/plugin-manager/src/seal-paper-schemes.ts — 1 条(concat 1)
  • packages/plugin-manager/src/seal-scroll.ts — 2 条(concat 2)
  • packages/plugin-manager/src/seal-stamp.ts — 2 条(concat 2)
  • packages/plugin-manager/src/seal-vocabulary.generated.ts — 9 条(derived 9)
  • packages/plugin-manager/src/update-contract.ts — 5 条(copy 3/concat 2)
  • packages/plugin-manager/src/update-targets.ts — 1 条(copy 1)
  • packages/plugin-memo-ilife/src/bridge.ts — 10 条(copy 3/concat 7)
  • packages/plugin-memo-ilife/src/client.ts — 34 条(copy 27/concat 7)
  • packages/plugin-memo-ilife/src/index.ts — 3 条(copy 2/concat 1)
  • packages/plugin-memo-ilife/src/seal-states.generated.ts — 11 条(derived 11)
  • packages/plugin-memo-ilife/src/settings.ts — 9 条(copy 9)
  • packages/plugin-memo-ilife/src/skill-tool.ts — 20 条(copy 4/concat 15/ident 1)
  • packages/plugin-memo-ilife/src/slot.ts — 1 条(copy 1)
  • packages/plugin-schedule-ilife/src/bridge.ts — 10 条(copy 3/concat 7)
  • packages/plugin-schedule-ilife/src/client.ts — 22 条(copy 18/concat 2/ident 2)
  • packages/plugin-schedule-ilife/src/index.ts — 3 条(copy 2/concat 1)
  • packages/plugin-schedule-ilife/src/seal-states.generated.ts — 11 条(derived 11)
  • packages/plugin-schedule-ilife/src/settings.ts — 7 条(copy 7)
  • packages/plugin-schedule-ilife/src/skill-tool.ts — 20 条(copy 4/concat 15/ident 1)
  • packages/plugin-schedule-ilife/src/slot.ts — 1 条(copy 1)

合计:待迁 57 件/575 条(copy 283/concat 209/payload 0/ident 8/data 0/cmdkey 0/derived 75)。

验收命令(读数)

开工前置(不通过就别开工):pnpm build 绿(测试读 dist/)。

本票读数(逐条贴命令与结果):

  1. 登记范围:把「交付物路径(文件清单)」的待迁件逐件写进 tooling/i18n-scope.json 的 files 数组。规则与口径见 docs/agents/多语言-门禁改造-验收命令.md。
  2. 两道门先红后绿(必须都 exit 0,且 RESULT 行计数覆盖本票范围):
    • node tooling/check-i18n-entries.mjs → RESULT: files=<n> keys=<n> missing=0
    • node tooling/check-i18n-keys.mjs → RESULT: files=<n> literals=<n> residue=0
      ⚠ 登记范围后先跑一次拿到红读数(记进票面),改完再跑拿绿读数;登记即绿=要么范围里没有可迁的件(写清楚),要么门失明(查 blind 行)。
  3. 中文列逐字节不变:pnpm snapshot:html:check 的中文列(tooling/skill-html.snapshot.json)与 node tooling/calorie-html-snapshot.mjs --check(calorie 范围)逐件同值;页面范围另跑 node packages/skill-bill/scripts/gen-page-fingerprints.mjs --check、node packages/base-render/scripts/i18n-pilot-1202.mjs --check。记录法:改前/改后各跑一次 git hash-object <账本>,两个 sha 相同即证。
  4. 英文列新录:英文产物按 docs/agents/多语言-文件名裁决.md 命名(<主体>_en_<TS>.html),偏离中文列的件录进英文列账本(tooling/*.snapshot.en.json,只记偏离项)。
  5. 词条 zh/en 对齐+占位符一致:本范围每个 key 的 zh 与 en 都有值;同一 key 的 {占位符} 集合在 zh/en 中相等;每个新增 key 有 resolve 带参单测(缺参抛 MissingParamError,见 packages/base-entries/src/evaluate.ts:31,48)。缺英文禁止留空串:空串视为缺词条并走回退链(packages/base-entries/src/resolve.ts:69-70,见 [实施] 门禁加固:空串当缺词条+zh/en 占位符一致性 #1306)。
  6. 全仓编译:node node_modules/typescript/bin/tsc -b 退出码 0(含 packages/base-render/test-d/contract-signatures.ts 契约签名;字面量类型换 string 后这里红就是没接线完)。
  7. CLI 端到端:--language en 输出英文;--language zz 走回退链(请求语言→zh→en),不返回空串。
  8. 同票内完成接线:本票迁移的函数,调用方必须传 language;禁止新增 language: string = 'zh' 默认参数裸调(见 [实施] 语言接线补全:默认参数与调用方漏传 #1307)。写模式跑完 ≠ 迁移完成。

边界

只改本票清单内文件与其直接调用方(接线点);不新增依赖;不动命令关键字、用户数据、唤醒词(ADR-0004 三条不译)。拼接串(前缀+变量+后缀)按 docs/agents/多语言-位置四分规则.md 先整句化成一条模板再进词条——每处这样的改动要在票面预先申报(原句 → 模板)并由第二方逐处比对。

不许动的东西

插件的 RPC 通道与设置页键;六个单品的别名内联方式(总管源码被内联进各自产物)。

遗留出口

跨包重复串的派生链另见专门票。

  • 本票范围内出现清单外文件(ledger 未收录或新生成):登记 tooling/i18n-ticket-scope.json 并另开票,不在本票临时扩范围。
  • 半迁移(同页中英混排)必须在收工前清零;未清零写进本票进度并保持 open。

进度

  • 进度:100%(2026-11-02T01:49:34+08:00):45 件迁入、12 件不迁,四门绿,提交 8d6363f
  • 2026-10-09 run-locked 退役清理:开工前置去包装、改直调;判据不变。
  • 2026-11-01 队列重写([实施] 队列重写:28 张迁移票的文件清单与统一票面 #1308):本票文件清单由 tooling/i18n-codemod.ledger.json 派生(剔除 tooling/i18n-scope.json 已迁 12 件),待迁 57 件/575 条;清单与其它迁移票不重叠。开工时把待迁件登记进 tooling/i18n-scope.json 的 files,收工时写验收读数与提交 SHA。

Activity

  1. added
    ready-for-agent
    and removed
    wayfinder:task
    on Nov 1, 2026
  2. changed the title [-]迁移 7 个插件的文本(660 条)[/-] [+]迁移 7 个插件的文本:57 件(575 条)[/+] on Nov 1, 2026
  3. FeatherHunter commented on Nov 1, 2026

    @FeatherHunter
    OwnerAuthor

    完成登记(2026-11-02,提交 8d6363f)

    • 结果:57 件清单中 45 件迁入(353 条,七个插件包 zh/en 各 841 键)、12 件不迁:六包 seal-states.generated.ts 与 manager seal-vocabulary.generated.ts(生成件)、install.ts/seal-scroll.ts/seal-stamp.ts(开发报文)、seal-paper-schemes.ts(0 条中文)、config-panel-contract.ts(冻结契约面,单件内存编译,任何相对 import 会在 require 阶段炸;渲染期取词已落在 config-panel-view.ts)。
    • 英文列:353 条全部人工落笔、无空串,占位符集合一致(params keys=841 pairs=841 mismatch=0);译名 Cookie Accounting/Calories/Memos/Schedule Keeper/Home Keeper/Private Chef/iLife。
    • 术语与结构处置:模块级常量改渲染期函数(slotTitle、configItems、managerTabs、manualEntry、updateTargets、advancedGroupTitle、rootKindText、statusLabel 等),并保留模块加载期的 zh 兼容镜像常量(SLOT_TITLE/CONFIG_ITEMS/MANAGER_TABS/MANUAL_ENTRY/ADVANCED_GROUP_TITLE/LARK_OFFICIAL_LINE)供旧调用方与边界测试;判据位改协议常量(manager health-contract.ts 的 ACTION_PREFIX='去哪修:'、SOURCE_DEFAULT='默认值',health-view.ts 不再比中文字面量)。
    • 门禁读数(集成树,scope 260 件):entries files=260 keys=6097 missing=0 blanks=0 empty=0;keys files=260 literals=25156 residue=0;params keys=6126 pairs=6126 mismatch=0;ticket-scope tickets=29 files=824 literals=29907 excluded=142 problems=0。
    • 构建:pnpm build exit 0(tsc -b + gen-cli --stamp 三件 + pnpm -r build:client)。
    • 测试:七包 node --test 合计 tests=940 pass=917 fail=23;与 master 基线对照(940/919/21)后,差异项均为像素/CDP 并发 flake——把可疑 4 项(manager 施工T1:像素验收缝跑通加按下收缩加焦点双环(承接可施工规格1159) #1160 T1/T5、manager smoke 烟囱、schedule 【实施】作息管家设置页收窄:照记账样板铺开 + 飞书 CLI 状态行 #764)单独重跑,两树均全过;master 独有红([BUG] 配置面板悬停焦点四合一:复制卡顿、高级缺焦点、Tab 焦点弱、星星与 issue 按钮缺 SVG 与反馈 #1174 两条、票 爱生活面板头部与底部:star/反馈/作者其他插件引流卡 #679、票 爱生活面板:页签名补全成产品名(作息管家/居家管家/私家大厨/饼干记账)+ 去掉「总开关」那行静态文本 #738、爱生活配置面板顶部版本显示慢,检查更新与全部更新长时间不可点 #986 两条)在集成树全过因其 dist 为本次全新构建。判定无本票新增确定性红。
    • 同票测试适配 2 件:plugin-memo-ilife/test/config-surface-696.test.mjs(改断言产物含词条键+读 dist/entries/zh.js 断言原文仍在)、plugin-calorie/test/version-dynamic-130.test.mjs(模拟安装补拷 dist/entries+把 base-entries 以 junction 放进模拟 node_modules)。
    • allowlist:本票新增 20 个数据键(backup.dir、backup.stem、db.dir、db.goals、db.name、html.dir、key.file、media.dir、photos.dir、photos.gifs、xunji.catalog、xunji.key、lark.cli、dsh-calorie.version、ilife-manager.roots、package.json、settings.section、config.get、config.save、config.reset)。
    • 迁移器收口:--ticket 1229 files=57 migrated=0 skipped=57 unsupported=0。
    • 遗留出口:生成件印章语仍为 zh(sealStates 的 label/progress/status 与 manager 印章词汇表),需生成器侧另票;模块加载期 zh 兼容镜像若被新调用点误用会漏中文(已在报告 §7 标注)。
  4. changed the title [-]迁移 7 个插件的文本:57 件(575 条)[/-] [+]迁移七个插件包 45 件文案进词条层(57 件/3,355 条,45 迁入/12 不迁)[/+] on Nov 1, 2026
  5. FeatherHunter commented on Nov 1, 2026

    @FeatherHunter
    OwnerAuthor

    词条迁移完成:45 件迁入(353 条)、12 件不迁;entries/keys/params/ticket-scope 四门绿,pnpm build 绿,七包测试与 master 基线同形;票内测试适配 2 件随票提交。

  6. changed the title [-]迁移七个插件包 45 件文案进词条层(57 件/3,355 条,45 迁入/12 不迁)[/-] [+]迁移七个插件包 45 件文案进词条层(57 件/575 条,45 迁入/12 不迁)[/+] on Nov 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    ready-for-agent

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions