Python
gui: complete Chinese translations and enforce locale contracts
malin1997671b321f661b
diff --git a/surfaces/gui/src/components/ManageTabs.tsx b/surfaces/gui/src/components/ManageTabs.tsxindex 49ebb19d..a124ac39 100644--- a/surfaces/gui/src/components/ManageTabs.tsx+++ b/surfaces/gui/src/components/ManageTabs.tsx@@ -758,7 +758,7 @@ export function ConnectorTools({ c, onChanged }: { c: Connector; onChanged: () =<span className="min-w-0"><span className="block text-[13px]">{tool.label}</span><span className="block text-[11.5px] text-faint">- {tool.name} · {tool.kind} · {t("manage.tool_asks_approval")}+ {t("manage.tool_asks_approval", { name: tool.name, kind: tool.kind })}</span><span className="block text-[11.5px] text-faint">{tool.description}</span></span>diff --git a/surfaces/gui/src/components/PersonasTab.tsx b/surfaces/gui/src/components/PersonasTab.tsxindex 3f28e450..4733d9f2 100644--- a/surfaces/gui/src/components/PersonasTab.tsx+++ b/surfaces/gui/src/components/PersonasTab.tsx@@ -232,9 +232,11 @@ export function PersonasTab({ onOpenPersona }: { onOpenPersona?: (id: string) =><div key={c.id} className={CARD + " p-3.5"}><div className="text-[13.5px] font-medium">{c.name}</div><div className="text-[12px] text-muted mt-0.5 mb-2">{c.description}</div>- <div className="text-[12px] text-ink">{t("personas.tools_label")} {c.tools.join(", ") || "—"}</div><div className="text-[12px] text-ink">- {t("personas.risk_label")} {c.risk.join(", ") || "read"}+ {t("personas.tools_label", { tools: c.tools.join(", ") || "—" })}+ </div>+ <div className="text-[12px] text-ink">+ {t("personas.risk_label", { risk: c.risk.join(", ") || "read" })}{c.connectors ? ` · ${t("personas.connectors_tag")}` : ""}{c.messaging ? ` · ${t("personas.messaging_tag")}` : ""}{c.mcp.length ? ` · ${t("personas.mcp_tag")}: ${c.mcp.join(", ")}` : ""}diff --git a/surfaces/gui/src/components/ScheduledView.test.tsx b/surfaces/gui/src/components/ScheduledView.test.tsxnew file mode 100644index 00000000..3891c95f--- /dev/null+++ b/surfaces/gui/src/components/ScheduledView.test.tsx@@ -0,0 +1,41 @@+import { afterEach, describe, expect, it, vi } from "vitest";+import { cleanup, render, screen } from "@testing-library/react";+import { ScheduledView } from "./ScheduledView";++vi.mock("../api", () => ({+ announceAutomationsChanged: vi.fn(),+ createAutomation: vi.fn(),+ deleteAutomation: vi.fn(),+ getAutomation: vi.fn(),+ getAutomations: vi.fn().mockResolvedValue([]),+ markAutomationSeen: vi.fn(),+ updateAutomation: vi.fn(),+}));++vi.mock("./AutomationQuickstart", () => ({+ AutomationQuickstart: () => <div data-testid="automation-quickstart" />,+}));++vi.mock("./IntegrationsView", () => ({+ PanelHead: ({ title, sub }: { title: string; sub: string }) => (+ <header>+ <h1>{title}</h1>+ <p>{sub}</p>+ </header>+ ),+}));++afterEach(cleanup);++describe("ScheduledView empty state", () => {+ it("renders translated emphasis as a strong element, not literal markup", () => {+ const { container } = render(+ <ScheduledView onOpenRun={vi.fn()} onRunNow={vi.fn()} />,+ );++ expect(+ screen.getByText("+ New automation", { selector: "strong" }),+ ).toBeTruthy();+ expect(container.textContent).not.toContain("<strong>");+ });+});diff --git a/surfaces/gui/src/components/ScheduledView.tsx b/surfaces/gui/src/components/ScheduledView.tsxindex a96abc65..dd80ecfa 100644--- a/surfaces/gui/src/components/ScheduledView.tsx+++ b/surfaces/gui/src/components/ScheduledView.tsx@@ -1,5 +1,5 @@import { useEffect, useState } from "react";-import { useTranslation } from "react-i18next";+import { Trans, useTranslation } from "react-i18next";import {createAutomation,deleteAutomation,@@ -155,7 +155,10 @@ export function ScheduledView({ onOpenRun, onRunNow, initialOpenId }: Props) {{empty ? (!showForm && (<div className={CARD + " p-4 text-[12.5px] text-muted"}>- {t("automations.empty_state")}+ <Trans+ i18nKey="automations.empty_state"+ components={{ strong: <strong /> }}+ /></div>)) : (diff --git a/surfaces/gui/src/components/Transcript.tsx b/surfaces/gui/src/components/Transcript.tsxindex 4c6fbd27..27f55b6a 100644--- a/surfaces/gui/src/components/Transcript.tsx+++ b/surfaces/gui/src/components/Transcript.tsx@@ -176,7 +176,7 @@ function StepRow({ tool, approval }: { tool: ToolItem; approval?: ApprovalItem }<spanclassName="text-[10.5px] px-1.5 rounded-full bg-tealSoft text-tealInk shrink-0"data-testid="tool-standing-rule"- title={t("transcript.step.auto_allowed_tip", { rule: tool.standingRule })}+ title={t("transcript.step.auto_allowed_tip", { name: tool.standingRule })}>{t("transcript.step.auto_allowed")}</span>diff --git a/surfaces/gui/src/i18n.test.ts b/surfaces/gui/src/i18n.test.tsnew file mode 100644index 00000000..ea375661--- /dev/null+++ b/surfaces/gui/src/i18n.test.ts@@ -0,0 +1,92 @@+import { createInstance } from "i18next";+import { describe, expect, it } from "vitest";+import en from "./locales/en.json";+import zh from "./locales/zh.json";++interface LocaleTree {+ [key: string]: string | LocaleTree;+}++const IMPORTANT_KEYS = [+ "settings.voice_dl_progress",+ "settings.voice_installed",+ "settings.voice_not_installed",+ "personas.installed",+ "personas.disable_warning",+ "personas.tools_label",+ "personas.risk_label",+ "transcript.step.auto_allowed_tip",+ "manage.tool_asks_approval",+ "manage.id_title",+ "automations.empty_state",+ "composer.pdf_too_big",+ "composer.pdf_too_many_pages",+ "composer.pdf_unreadable",+ "composer.listening_sr",+] as const;++const values: Record<string, Record<string, string | number>> = {+ "settings.voice_dl_progress": { done: "1 MiB", total: "2 MiB" },+ "settings.voice_installed": { size: "141 MiB" },+ "settings.voice_not_installed": { size: "141 MiB" },+ "personas.installed": { count: 2 },+ "personas.disable_warning": { count: 2 },+ "personas.tools_label": { tools: "read_file" },+ "personas.risk_label": { risk: "read" },+ "transcript.step.auto_allowed_tip": { name: "read_file" },+ "manage.tool_asks_approval": { name: "send_message", kind: "write" },+ "manage.id_title": { id: "U123" },+ "composer.pdf_too_big": { name: "report.pdf", mb: "12.5", limit: 10 },+ "composer.pdf_too_many_pages": { name: "report.pdf", pages: 24, limit: 20 },+ "composer.pdf_unreadable": { name: "report.pdf", error: "invalid PDF" },+ "composer.listening_sr": { time: "0:12" },+};++function flatten(tree: LocaleTree, prefix = "", result: Record<string, string> = {}) {+ for (const [key, value] of Object.entries(tree)) {+ const path = prefix ? `${prefix}.${key}` : key;+ if (typeof value === "string") result[path] = value;+ else flatten(value, path, result);+ }+ return result;+}++function placeholders(value: string) {+ return [...value.matchAll(/{{\s*([\w.]+)(?:\s*,[^}]*)?\s*}}/g)]+ .map((match) => match[1])+ .sort();+}++const flatEn = flatten(en);+const flatZh = flatten(zh);++describe("locale contracts", () => {+ it("keeps interpolation placeholders aligned between English and Chinese", () => {+ for (const key of Object.keys(flatEn)) {+ if (!(key in flatZh)) continue;+ expect(placeholders(flatZh[key]), key).toEqual(placeholders(flatEn[key]));+ }+ });++ it("defines every important runtime key in both locales", () => {+ for (const key of IMPORTANT_KEYS) {+ expect(flatEn[key], `missing English key: ${key}`).toBeTypeOf("string");+ expect(flatZh[key], `missing Chinese key: ${key}`).toBeTypeOf("string");+ }+ });++ it("fully interpolates important Chinese runtime strings", async () => {+ const instance = createInstance();+ await instance.init({+ resources: { zh: { translation: zh } },+ lng: "zh",+ fallbackLng: false,+ interpolation: { escapeValue: false },+ });++ for (const key of IMPORTANT_KEYS) {+ const rendered = instance.t(key, values[key] ?? {});+ expect(rendered, key).not.toMatch(/{{\s*[\w.]+(?:\s*,[^}]*)?\s*}}/);+ }+ });+});diff --git a/surfaces/gui/src/locales/en.json b/surfaces/gui/src/locales/en.jsonindex 4880693c..79c2ebf5 100644--- a/surfaces/gui/src/locales/en.json+++ b/surfaces/gui/src/locales/en.json@@ -127,11 +127,11 @@"err_mic_start": "Could not start the microphone.","starting_mic": "Starting microphone…","approvals_to_inbox_help": "When a run is unattended, approval asks go to the Inbox.",- "listening_sr": "Listening…",+ "listening_sr": "Listening, {{time}}","pdf_could_not_read": "Couldn't read that PDF.",- "pdf_too_big": "That PDF is over the size limit and wasn't attached.",- "pdf_too_many_pages": "That PDF is over the page limit and wasn't attached.",- "pdf_unreadable": "Couldn't read that PDF.",+ "pdf_too_big": "{{name}} skipped — {{mb}} MB is over your {{limit}} MB limit (Settings → Token savings)",+ "pdf_too_many_pages": "{{name}} skipped — {{pages}} pages is over your {{limit}}-page limit (Settings → Token savings)",+ "pdf_unreadable": "{{name}} skipped — {{error}}","send_approvals_to_inbox": "Send approvals to the Inbox","starting_transcribe": "Transcribing…","model": {@@ -259,9 +259,9 @@"voice_delete": "Delete","voice_delete_confirm": "Delete this model?","voice_device_title": "Device",- "voice_dl_progress": "Downloading… {{pct}}%",+ "voice_dl_progress": "{{done}} of {{total}}","voice_download": "Download",- "voice_installed": "Installed",+ "voice_installed": "Installed and verified · {{size}}","voice_intro": "Speak naturally in the composer. Recordings and transcripts stay on this device.","voice_listening": "Listening…","voice_mac": "macOS",@@ -272,7 +272,7 @@"voice_mic_test_ready": "Test the microphone","voice_mic_test_title": "Microphone test","voice_no_speech": "No speech detected — try again.",- "voice_not_installed": "Not installed",+ "voice_not_installed": "Local voice model · {{size}}","voice_private_body": "The voice model runs entirely on this machine — recordings never leave this device.","voice_private_title": "Fully private","voice_processor": "Processor",@@ -1021,7 +1021,7 @@"could_not_connect": "could not connect","could_not_start_connect": "could not start the connect","could_not_start_managed": "could not start the connect",- "id_title": "ID",+ "id_title": "ID: {{id}}","included_models": "Included models","included_models_help": "Curated, agent-capable models this provider serves — add your key above to enable them.","listening_empty": "None yet — open a session's Sources ▸ Channels to subscribe it to a channel.",@@ -1170,13 +1170,13 @@"delete_title": "Delete {{name}}","delete_tooltip": "Delete this persona","disable": "Disable",- "disable_warning": "Disabling archives its {{n}} conversation(s) — they stay available under \"Show archived\".",+ "disable_warning": "Disabling archives its {{count}} conversation(s) — they stay available under \"Show archived\".","enable_intro": "Enable a coworker, then choose whether it appears in the new-session picker. The starred persona is the default for new sessions.","enabled": "Enabled","in_picker": "In picker","install": "Install","install_failed": "Install failed",- "installed": "Installed {{n}} persona(s) — review and enable below.",+ "installed": "Installed {{count}} persona(s) — review and enable below.","installing": "Installing…","keep": "Keep","keep_enabled": "Keep enabled",diff --git a/surfaces/gui/src/locales/zh.json b/surfaces/gui/src/locales/zh.jsonindex 9a7218c0..1dbdc487 100644--- a/surfaces/gui/src/locales/zh.json+++ b/surfaces/gui/src/locales/zh.json@@ -127,11 +127,11 @@"err_mic_start": "无法启动麦克风。","starting_mic": "正在启动麦克风…","approvals_to_inbox_help": "无人值守运行时,审批请求会进入收件箱。",- "listening_sr": "正在聆听…",+ "listening_sr": "正在聆听,{{time}}","pdf_could_not_read": "无法读取该 PDF。",- "pdf_too_big": "PDF 超过大小限制,未附加。",- "pdf_too_many_pages": "PDF 超过页数限制,未附加。",- "pdf_unreadable": "无法读取该 PDF。",+ "pdf_too_big": "已跳过 {{name}} —— {{mb}} MB 超过 {{limit}} MB 上限(设置 → Token 节省)",+ "pdf_too_many_pages": "已跳过 {{name}} —— {{pages}} 页超过 {{limit}} 页上限(设置 → Token 节省)",+ "pdf_unreadable": "已跳过 {{name}} —— {{error}}","send_approvals_to_inbox": "将审批请求发送到收件箱","starting_transcribe": "正在转写…","model": {@@ -152,14 +152,14 @@"approval": {"approved": "✓ 已批准","declined": "✕ 已拒绝",- "approved_scope": "approved · {{scope}}"+ "approved_scope": "已批准 · {{scope}}"},"step": {"raw": "原始",- "auto_allowed": "auto-allowed",- "auto_allowed_tip": "Auto-allowed by this automation's standing approvals: {{name}}",- "hidden_count_label": "{{n}} hidden",- "hidden_tip": "Removed by your privacy filters before the agent saw the results — agents get no trace of these."+ "auto_allowed": "已自动允许",+ "auto_allowed_tip": "已根据此自动化的常驻授权自动允许:{{name}}",+ "hidden_count_label": "{{n}} 项已隐藏",+ "hidden_tip": "在 agent 看到结果前已被你的隐私过滤器移除 —— agent 不会获知任何痕迹。"},"turn": {"running": "运行 {{label}}…",@@ -167,11 +167,11 @@"hidden": "{{count}} 已被你的过滤器隐藏","steps_label": "{{count}} 步"},- "dir_declined": "Declined folder access",- "dir_granted": "Granted folder access",- "plan_approved": "Plan approved",- "plan_proposed": "proposed plan",- "plan_rejected": "Sent back with feedback"+ "dir_declined": "已拒绝文件夹访问",+ "dir_granted": "已授予文件夹访问权限",+ "plan_approved": "计划已批准",+ "plan_proposed": "已提出计划",+ "plan_rejected": "已退回并附上反馈"},"rail": {"progress_title": "进度",@@ -258,9 +258,9 @@"voice_delete": "删除","voice_delete_confirm": "删除此模型?","voice_device_title": "设备",- "voice_dl_progress": "下载中… {{pct}}%",+ "voice_dl_progress": "{{done}} / {{total}}","voice_download": "下载",- "voice_installed": "已安装",+ "voice_installed": "已安装并验证 · {{size}}","voice_intro": "在输入框自然说话。录音和转写都保留在本设备。","voice_listening": "聆听中…","voice_mac": "macOS",@@ -271,7 +271,7 @@"voice_mic_test_ready": "测试麦克风","voice_mic_test_title": "麦克风测试","voice_no_speech": "未检测到语音 —— 请再试一次。",- "voice_not_installed": "未安装",+ "voice_not_installed": "本地语音模型 · {{size}}","voice_private_body": "语音模型完全在本机运行 —— 录音永不离开此设备。","voice_private_title": "完全私密","voice_processor": "处理器",@@ -834,7 +834,7 @@"hiw_recent": "最近","hiw_summarize_room": "总结 #launch-room","hiw_via_slack": "通过 Slack",- "hiw_jira_linear": "Jira vs Linear",+ "hiw_jira_linear": "Jira 与 Linear 对比","hiw_coworker": "同事","hiw_via_slack_same": "通过 Slack —— 同一会话","hiw_signups_referrer": "…注册量提升 3.4×,首要来源是 press 页面。",@@ -1006,82 +1006,82 @@},"manage": {"add_btn": "添加",- "allowed_empty": "nobody yet — Allow a recent sender →",- "allowed_to_message": "Allowed to message",- "cancel": "cancel",- "check_browser": "Check your browser…",- "coming_soon": "Coming soon",- "composer_picker_help": "The models offered when starting a session; the black badge marks the default. Add more from a provider's card above.",- "composer_picker_title": "In the composer's picker",- "connect": "Connect",- "connect_one_click": "Connect {{title}} with one click",- "connector_no_tools": "No tools for this connector yet.",- "could_not_connect": "could not connect",- "could_not_start_connect": "could not start the connect",- "could_not_start_managed": "could not start the connect",- "id_title": "ID",- "included_models": "Included models",- "included_models_help": "Curated, agent-capable models this provider serves — add your key above to enable them.",- "listening_empty": "None yet — open a session's Sources ▸ Channels to subscribe it to a channel.",- "listening_title": "Sessions listening to {{title}} channels · {{n}}",- "listening_unsub_tip": "Unsubscribe",- "loading": "Loading…",- "mcp_add_btn": "+ Add server",- "mcp_add_server": "Add a server",- "mcp_asks": "asks",- "mcp_connect_failed": "failed to connect",- "mcp_enable": "Enable this server",- "mcp_help": "External tool servers (stdio or HTTP), shared across all agents. Reload the app after editing mcp.json — or reload now.",- "mcp_hide_tools": "hide tools",- "mcp_invalid_json": "Invalid JSON: {{msg}}",- "mcp_no_tools": "No tools.",- "mcp_none": "No MCP servers configured.",+ "allowed_empty": "暂无 —— 允许一位近期发送者 →",+ "allowed_to_message": "允许发送消息",+ "cancel": "取消",+ "check_browser": "请查看你的浏览器…",+ "coming_soon": "即将推出",+ "composer_picker_help": "新建会话时可选的模型;黑色徽标表示默认模型。可从上方提供方卡片添加更多模型。",+ "composer_picker_title": "输入框的模型选择器",+ "connect": "连接",+ "connect_one_click": "一键连接 {{title}}",+ "connector_no_tools": "此连接器暂无工具。",+ "could_not_connect": "无法连接",+ "could_not_start_connect": "无法启动连接",+ "could_not_start_managed": "无法启动连接",+ "id_title": "ID:{{id}}",+ "included_models": "内置模型",+ "included_models_help": "此提供方精选的 agent 模型 —— 在上方添加密钥即可启用。",+ "listening_empty": "暂无 —— 打开会话的「来源 ▸ 频道」即可订阅频道。",+ "listening_title": "正在监听 {{title}} 频道的会话 · {{n}}",+ "listening_unsub_tip": "取消订阅",+ "loading": "加载中…",+ "mcp_add_btn": "+ 添加服务器",+ "mcp_add_server": "添加服务器",+ "mcp_asks": "需询问",+ "mcp_connect_failed": "连接失败",+ "mcp_enable": "启用此服务器",+ "mcp_help": "外部工具服务器(stdio 或 HTTP),由所有 agent 共享。编辑 mcp.json 后请重新加载应用,或立即重新加载。",+ "mcp_hide_tools": "隐藏工具",+ "mcp_invalid_json": "JSON 无效:{{msg}}",+ "mcp_no_tools": "无工具。",+ "mcp_none": "未配置 MCP 服务器。","mcp_oauth": "oauth",- "mcp_paste_help": "Paste a '{ \"<name>\": { … } }' object (or a full mcpServers block).",- "mcp_paste_label": "Paste server JSON (name → config):",- "mcp_sign_in": "Sign in",- "mcp_sign_out": "sign out",- "mcp_signing_in": "signing in…",- "mcp_tool_count": "{{n}} tools",- "mcp_tools": "tools",- "mcp_waiting_browser": "waiting for browser…",- "models": "Models",- "models_help": "Ticked models show in the composer's picker; the black badge marks the default for new sessions.",- "one_click_coming": "One-click sign-in is coming soon — connect manually below for now:",- "openai_env_help": "A key is set via OPENAI_API_KEY in this server's environment. Add a different key here to override it for this computer.",- "optional": "(optional)",- "or_connect_manually": "or connect manually:",- "parked_allow_deliver": "Allow & deliver",- "parked_allow_deliver_tip": "Allow the sender and deliver this message now",- "parked_allow_only": "Allow only",- "parked_allow_tip": "Allow the sender; this message is discarded",- "parked_dismiss": "Dismiss",- "parked_dismiss_tip": "Discard this message without allowing the sender",- "parked_in": "in {{chat}}",- "parked_title": "Messages from senders you haven't allowed · {{n}}",- "recent_empty": "None yet. Message the bot once and it'll show here.",- "recent_senders": "Recent senders",- "reload_now": "reload now",- "reltime_day": "{{n}}d ago",- "reltime_hour": "{{n}}h ago",- "reltime_just_now": "just now",- "reltime_min": "{{n}}m ago",- "remove_from_picker": "Remove from the picker",- "remove_key": "Remove key…",- "remove_key_confirm": "Remove the {{title}} key from this computer?",- "signin_unlocks": "Sign-in unlocks the one-click {{title}} connect — or connect manually below.",- "tool_asks_approval": "{{name}} · {{kind}} · asks approval",- "tools_exposed": "Tools exposed to OpenWorker",- "unknown": "unknown",- "validating": "Validating…"+ "mcp_paste_help": "粘贴一个“{ \"<name>\": { … } }”对象(或完整的 mcpServers 块)。",+ "mcp_paste_label": "粘贴服务器 JSON(名称 → 配置):",+ "mcp_sign_in": "登录",+ "mcp_sign_out": "退出登录",+ "mcp_signing_in": "登录中…",+ "mcp_tool_count": "{{n}} 个工具",+ "mcp_tools": "工具",+ "mcp_waiting_browser": "正在等待浏览器…",+ "models": "模型",+ "models_help": "已勾选的模型会显示在输入框的选择器中;黑色徽标表示新会话的默认模型。",+ "one_click_coming": "一键登录即将推出 —— 目前请在下方手动连接:",+ "openai_env_help": "此服务器的环境中已通过 OPENAI_API_KEY 设置密钥。在此添加其他密钥可覆盖本机设置。",+ "optional": "(可选)",+ "or_connect_manually": "或手动连接:",+ "parked_allow_deliver": "允许并送达",+ "parked_allow_deliver_tip": "允许该发送者并立即送达此消息",+ "parked_allow_only": "仅允许",+ "parked_allow_tip": "允许该发送者;此消息将被丢弃",+ "parked_dismiss": "忽略",+ "parked_dismiss_tip": "丢弃此消息,但不允许该发送者",+ "parked_in": "在 {{chat}} 中",+ "parked_title": "来自未允许发送者的消息 · {{n}}",+ "recent_empty": "暂无。给机器人发一次消息后会显示在这里。",+ "recent_senders": "近期发送者",+ "reload_now": "立即重新加载",+ "reltime_day": "{{n}} 天前",+ "reltime_hour": "{{n}} 小时前",+ "reltime_just_now": "刚刚",+ "reltime_min": "{{n}} 分钟前",+ "remove_from_picker": "从选择器中移除",+ "remove_key": "移除密钥…",+ "remove_key_confirm": "从本机移除 {{title}} 密钥?",+ "signin_unlocks": "登录即可解锁 {{title}} 一键连接 —— 或在下方手动连接。",+ "tool_asks_approval": "{{name}} · {{kind}} · 需审批",+ "tools_exposed": "向 OpenWorker 提供的工具",+ "unknown": "未知",+ "validating": "验证中…"},"models": {- "add_btn": "Add",- "add_placeholder": "Add another model…",- "default_badge": "default",- "default_locked": "The default model is always shown — make another model default first",- "key_set": "Key set",- "make_default": "Make default"+ "add_btn": "添加",+ "add_placeholder": "添加其他模型…",+ "default_badge": "默认",+ "default_locked": "默认模型始终显示 —— 请先将其他模型设为默认",+ "key_set": "已设置密钥",+ "make_default": "设为默认"},"onboarding": {"cancel": "取消",@@ -1157,37 +1157,37 @@"workspace_label": "工作区"},"personas": {- "add_help": "Load from a local directory or a public GitHub repo. Files are copied into a managed area (a snapshot), so the source can change without affecting the install.",- "add_section": "Add personas",- "builtin": "· built-in",- "configure_title": "Configure {{name}}",- "connectors_tag": "connectors",- "default_for_new": "Default for new sessions",- "delete": "Delete",- "delete_failed": "Couldn't delete — it may be in a session.",- "delete_title": "Delete {{name}}",- "delete_tooltip": "Delete this persona",- "disable": "Disable",- "disable_warning": "Disabling archives its {{n}} conversation(s) — they stay available under \"Show archived\".",- "enable_intro": "Enable a coworker, then choose whether it appears in the new-session picker. The starred persona is the default for new sessions.",- "enabled": "Enabled",- "in_picker": "In picker",- "install": "Install",- "install_failed": "Install failed",- "installed": "Installed {{n}} persona(s) — review and enable below.",- "installing": "Installing…",- "keep": "Keep",- "keep_enabled": "Keep enabled",+ "add_help": "从本地目录或公开 GitHub 仓库加载。文件会复制到托管区域(快照),因此源文件变更不会影响已安装版本。",+ "add_section": "添加角色",+ "builtin": "· 内置",+ "configure_title": "配置 {{name}}",+ "connectors_tag": "连接器",+ "default_for_new": "新会话默认角色",+ "delete": "删除",+ "delete_failed": "无法删除 —— 该角色可能正在会话中使用。",+ "delete_title": "删除 {{name}}",+ "delete_tooltip": "删除此角色",+ "disable": "禁用",+ "disable_warning": "禁用后会归档其 {{count}} 个会话 —— 仍可在「显示已归档」中查看。",+ "enable_intro": "启用一位同事,然后选择是否显示在新会话选择器中。带星标的角色是新会话的默认角色。",+ "enabled": "已启用",+ "in_picker": "在选择器中",+ "install": "安装",+ "install_failed": "安装失败",+ "installed": "已安装 {{count}} 个角色 —— 请在下方审核并启用。",+ "installing": "安装中…",+ "keep": "保留",+ "keep_enabled": "保持启用","mcp_tag": "mcp",- "messaging_tag": "messaging",+ "messaging_tag": "消息","mode_github": "GitHub URL",- "mode_local": "Local directory",+ "mode_local": "本地目录","placeholder_github": "https://github.com/org/repo","placeholder_local": "/path/to/persona/dir",- "recommended_mode": "Recommended mode: {{mode}}. Enable it above to use it.",- "risk_label": "Risk: {{risk}}",- "set_default": "Set default",- "tools_label": "Tools: {{tools}}"+ "recommended_mode": "推荐模式:{{mode}}。请在上方启用后使用。",+ "risk_label": "风险:{{risk}}",+ "set_default": "设为默认",+ "tools_label": "工具:{{tools}}"},"provider": {"all_providers": "‹ 全部 provider",