/** * Lever copy: zh-first dictionary with an English counterpart. The zh side is * the key-set source of truth; `packages/dsh-i18n` mirrors the keys into the * centralized ru dictionary and `pnpm i18n:check` enforces the parity. */ /** Lever copy, key source of truth. */ export const zh = { 'lever.a11y': '梁神模式拨杆', 'lever.name': '梁神模式', 'lever.hint.pull': '拨下拨杆:开启「梁神模式」', 'lever.hint.push': '上拨拨杆:返回「{preset}」', 'lever.hint.locked': '会话已开始,模式不可再更改', 'lever.hint.missing': '未找到「梁神模式」预设,请先启用该插件行', 'lever.state.on': '梁神模式', 'lever.state.off': '普通模式', 'lever.busy': '正在切换…', 'lever.failed.locked': '会话已经开始,模式已锁定', 'lever.failed.missing': '没有找到「梁神模式」预设', 'lever.failed.timeout': '切换超时,请重试', 'lever.failed.failed': '切换失败:{reason}', 'burst.line1': '三秒,三辈子的代码', 'burst.line2': '文言文 · 二进制 · 摩斯电码', 'settings.title': '梁神模式', 'settings.description': '控制本插件与工具面呈现方式。', 'settings.enabled': '启用梁神模式', 'settings.enabledHint': '关闭后不声明预设、也不发 agent 公告。', 'settings.announceToAgent': '向 agent 公告本插件', 'settings.announceToAgentHint': '开启后向每一轮 agent 系统提示注入本插件公告;默认关闭以保持提示词干净。', 'settings.presentation': '工具面呈现方式', 'settings.presentationHint': '写入本插件声明的预设的 tool-catalog 行:both(出厂默认)让原生清单与 run_code 同驻(原生直调优先);native 保持原生工具清单;ptc 把 wire 收拢为 run_code。改动立即生效,但已开始的会话保持其已声明的组合。', 'settings.on': '开', 'settings.off': '关', 'settings.inherit': '继承(跟随部署默认)', 'settings.overridden': '已覆盖', 'settings.reset': '重置', 'settings.notExposed': '当前 DSH 版本未向设置页暴露本插件的配置命名空间,表单不可用。可编辑 ~/.dsh/settings.yaml 直接配置,或将本命名空间加入 Host 设置白名单后重启。', 'settings.readOnly': '当前部署的设置只读。', 'settings.expand': '展开设置', 'settings.collapse': '收起设置', 'settings.save': '保存', 'settings.saving': '保存中…', 'settings.discard': '放弃', 'settings.unsaved': '未保存', 'settings.saveFailed': '部署未接受这些值,已保留供你修改。', 'settings.invalidValue': '该取值不被接受', 'presentation.ptc': 'ptc(仅 run_code)', 'presentation.native': 'native(原生工具清单)', 'presentation.both': 'both(两者同驻)', 'settings.guardEnabled': '启用退化熔断器', 'settings.guardEnabledHint': '运行时检测思考退化(连续零产出长思考 / 同参重复失败),触发时注入熔断提示并临时下调推理档位。关闭后不干预任何请求。', 'settings.guardStallChars': '单步暴走字符阈值', 'settings.guardStallCharsHint': '单条推理达到该字符数且零产出即触发熔断(按 V4.1 官方 384K 最大输出校准;默认 8000,约 2-4K 思考 token)。', 'settings.guardGlobalCap': '慢烧连续步数', 'settings.guardGlobalCapHint': '连续多少步有真实推理但零产出触发慢烧熔断(默认 4;步数越小越敏感,真实长调查建议调大)。', 'settings.guardSensitivity': '熔断灵敏度', 'settings.guardSensitivityHint': '整体缩放熔断阈值:保守(更少打断,阈值×1.5)、均衡(出厂校准值)、激进(更早触发,阈值×0.5)。阈值随推理档位自适应:max 档 8000 / high 档 12000 / low 档 20000 字符。', 'sensitivity.conservative': '保守(少打断)', 'sensitivity.balanced': '均衡(默认)', 'sensitivity.aggressive': '激进(早触发)', 'settings.guardEchoFailures': '同参连续失败次数', 'settings.guardEchoFailuresHint': '同一工具以相同参数连续失败多少次触发空转熔断(默认 3)。', } /** English counterpart; the key set mirrors {@link zh} exactly. */ export const en: Record = { 'lever.a11y': 'LiangShen mode lever', 'lever.name': 'LiangShen mode', 'lever.hint.pull': 'Pull the lever down to turn on LiangShen mode', 'lever.hint.push': 'Push the lever up to return to "{preset}"', 'lever.hint.locked': 'The session has started, so its mode can no longer change', 'lever.hint.missing': 'The LiangShen preset is not installed; enable that plugin row first', 'lever.state.on': 'LiangShen', 'lever.state.off': 'Standard', 'lever.busy': 'Switching…', 'lever.failed.locked': 'The session already started, so the mode is locked', 'lever.failed.missing': 'The LiangShen preset was not found', 'lever.failed.timeout': 'The switch timed out; try again', 'lever.failed.failed': 'Switch failed: {reason}', 'burst.line1': 'Three seconds, three lifetimes of code', 'burst.line2': 'Classical Chinese · Binary · Morse code', 'settings.title': 'LiangShen mode', 'settings.description': 'Controls this plugin and the wire presentation.', 'settings.enabled': 'Enable LiangShen mode', 'settings.enabledHint': 'When off, the preset is not declared and the agent announcement does not run.', 'settings.announceToAgent': 'Announce this plugin to agents', 'settings.announceToAgentHint': 'Adds this plugin announcement to every agent system prompt; off by default so prompts stay clean.', 'settings.presentation': 'Wire presentation', 'settings.presentationHint': 'Written into the tool-catalog row of the preset this plugin declares: both (the shipped default) keeps the roster and run_code co-resident (direct native calls first); native keeps the native roster; ptc collapses the wire to run_code. A change re-declares the preset immediately; sessions that already started keep the composition they declared.', 'settings.on': 'On', 'settings.off': 'Off', 'settings.inherit': 'Inherit (deployment default)', 'settings.overridden': 'Overridden', 'settings.reset': 'Reset', 'settings.notExposed': "This DSH version does not expose this plugin's settings namespace to the configuration page, so the form is unavailable. Edit ~/.dsh/settings.yaml directly, or add the namespace to the Host settings allowlist and restart.", 'settings.readOnly': 'This deployment serves settings read-only.', 'settings.expand': 'Show settings', 'settings.collapse': 'Hide settings', 'settings.save': 'Save', 'settings.saving': 'Saving…', 'settings.discard': 'Discard', 'settings.unsaved': 'Unsaved', 'settings.saveFailed': 'The deployment did not accept these values; they were left for you to correct.', 'settings.invalidValue': 'The value is not accepted', 'presentation.ptc': 'ptc (run_code only)', 'presentation.native': 'native (native tool roster)', 'presentation.both': 'both (both co-resident)', 'settings.guardEnabled': 'Degeneration circuit breaker', 'settings.guardEnabledHint': 'Detects reasoning degeneration at runtime (consecutive zero-output long reasoning / repeated identical-argument failures), injecting a breaker message and stepping the reasoning effort down when it fires. Disabled means requests are never touched.', 'settings.guardStallChars': 'Runaway reasoning character floor', 'settings.guardStallCharsHint': 'One reasoning block reaching this many characters with no output fires the breaker (calibrated against V4.1\'s official 384K max output; default 8000, roughly 2-4K thinking tokens).', 'settings.guardGlobalCap': 'Slow-burn step count', 'settings.guardGlobalCapHint': 'Consecutive output-free steps of real reasoning that fire the slow-burn ladder (default 4; lower is more sensitive — raise it for genuinely long investigations).', 'settings.guardSensitivity': 'Breaker sensitivity', 'settings.guardSensitivityHint': 'Scales every breaker threshold: conservative (fewer interruptions, x1.5), balanced (the calibrated defaults), aggressive (fires earlier, x0.5). Thresholds adapt to the reasoning effort: 8000 at max / 12000 at high / 20000 at low.', 'sensitivity.conservative': 'Conservative (fewer interruptions)', 'sensitivity.balanced': 'Balanced (default)', 'sensitivity.aggressive': 'Aggressive (fires earlier)', 'settings.guardEchoFailures': 'Identical-argument failures', 'settings.guardEchoFailuresHint': 'Identical-argument failures of the same tool in a row that fire the echo ladder (default 3).', } /** Every key in the locale catalog. */ export type LiangShenKey = keyof typeof zh