dsh-codex-subscription 2.5.4 → 2.5.6

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/README.en.md CHANGED
@@ -61,16 +61,16 @@ Subscription access, model controls, quota management, and image creation in one
61
61
 
62
62
  | Feature | What you can do | Availability / setup |
63
63
  | --- | --- | --- |
64
- | **Image generation** | Generate through your subscription and adjust available request model / quality options | Beta; on by default, can be disabled |
64
+ | **Image generation** | Generate through your subscription and adjust available request model / quality options; ask for a transparent-background PNG when needed | Beta; on by default, can be disabled |
65
65
  | **Reference image editing** | Continue refining an image with references | Beta; on by default, can be disabled |
66
- | **Image viewing and download** | Zoom, pan, fit to window, and download verified originals | Built-in viewer; older images may only have previews |
66
+ | **Image viewing and download** | Completed images appear after the answer without expanding tool activity; zoom, pan, fit to window, and download verified originals | Built-in viewer; older images may only have previews |
67
67
  | **Region-based editing** | Mark regions, add notes, and continue editing with location references | Fills the composer for you to review and send |
68
68
  | **Manual canvas** | Choose an aspect ratio and draw with pen, pencil, marker, and erasers | Beta; canvas off by default |
69
69
  | **Shapes and text** | Draw lines, arrows, shapes, native curves, and editable text / objects | Available in the sketch canvas |
70
70
  | **Layers and image import** | Work in layers and bring images into the canvas | Images are managed as layers |
71
71
  | **Smoothing and navigation** | Smooth complete strokes after release; pan, zoom, undo, and redo | Shortcuts can be customized or disabled |
72
72
  | **Multiple drafts** | Save and reopen up to 20 local drafts | Stored in the current browser |
73
- | **Import and export** | Export PNG, layered PSD, or native drafts that preserve editable strokes | PSD import supports a limited set of ordinary pixel layers |
73
+ | **Import and export** | Export PNG, or native drafts that preserve editable strokes | Drafts can be imported again to keep editing |
74
74
  | **Agent drawing** | Ask the agent to draw with `@sketch`, follow progress, and stop it; the agent can draw whole stages in SVG, imported as editable native strokes | Beta; off by default, requires the canvas |
75
75
  | **Result preview for the model** | Return a canvas image after drawing for subsequent review | Beta; off by default, adds image input usage |
76
76
 
@@ -82,6 +82,7 @@ Subscription access, model controls, quota management, and image creation in one
82
82
  | **Subtask component management** | Install, disable, or uninstall the official Codex subtask component from settings | Managed by supported DSH hosts; no extra login |
83
83
  | **Cloud context compaction** | Continue long conversations using Codex compaction while retaining DSH history and native compaction | Beta / experimental; off by default, enabled requests use SSE |
84
84
  | **WebSocket transport** | Experimentally reuse connections and context transfers, with SSE fallback on connection failure | Beta / experimental; SSE by default, no speed guarantee |
85
+ | **Codex reviewer for Auto review** | DSH Auto review judges tool calls with Codex's own review model; DSH keeps its review policy and allow/deny flow | Beta; off by default, applies when your account catalog offers the model |
85
86
  | **Support diagnostics** | Inspect prerequisites and recent operation results, and copy a short report (about 1 KB; the full one can be copied separately) without credentials or conversation text | Settings → Maintenance; unverified does not mean broken |
86
87
  | **Forecast cache cleanup** | Inspect and clear local quota forecast history | Keeps sign-in, drafts, originals, and shared dependencies |
87
88
 
@@ -105,7 +106,7 @@ This plugin supports the latest DeepSeek Harness release recorded in its package
105
106
  2. Paste this package name, with its version, into the **Package name or address** field:
106
107
 
107
108
  ```text
108
- dsh-codex-subscription@2.5.4
109
+ dsh-codex-subscription@2.5.6
109
110
  ```
110
111
 
111
112
  3. Click **Install** and wait for completion. Follow the page instructions; save your work before restarting if requested.
@@ -239,9 +240,9 @@ Settings shown directly as cropped screenshots from the actual DSH interface.
239
240
 
240
241
  </details>
241
242
 
242
- Layers, native curves, brushes, undo/redo, and shortcuts are supported. Save multiple drafts, export PNG or layered PSD, and annotate generated images before continuing an edit.
243
+ Layers, native curves, brushes, undo/redo, and shortcuts are supported. Save multiple drafts, export PNG or editable drafts, and annotate generated images before continuing an edit.
243
244
 
244
- [Image editing, draft storage, and PSD limitations →](docs/GUIDE.en.md#image-generation-and-editing-beta)
245
+ [Image editing and draft storage →](docs/GUIDE.en.md#image-generation-and-editing-beta)
245
246
 
246
247
  <a id="codex-subtask-runtime"></a>
247
248
 
package/README.md CHANGED
@@ -61,16 +61,16 @@
61
61
 
62
62
  | 功能 | 你可以做什么 | 使用方式 / 条件 |
63
63
  | --- | --- | --- |
64
- | **图片生成** | 通过订阅生成图片,调整可用的请求型号与质量 | Beta;默认开启,可关闭 |
64
+ | **图片生成** | 通过订阅生成图片,调整可用的请求型号与质量;需要时可生成透明背景 PNG | Beta;默认开启,可关闭 |
65
65
  | **参考图编辑** | 带上参考图继续修改作品 | Beta;默认开启,可关闭 |
66
- | **图片查看与下载** | 缩放、拖动、适合窗口,下载校验后的原图 | 内置查看器,无需另装;旧图可能只有预览 |
66
+ | **图片查看与下载** | 完成的出图结果直接显示在回答后,无需展开工具过程;可缩放、拖动、适合窗口、下载校验后的原图 | 内置查看器,无需另装;旧图可能只有预览 |
67
67
  | **区域标注编辑** | 在图上圈定区域、填写备注,带定位参考继续编辑 | 回填输入框后由你确认发送 |
68
68
  | **手绘画板** | 选择画布比例,使用钢笔、铅笔、荧光笔及橡皮 | Beta;画板默认关闭 |
69
69
  | **形状与文字** | 绘制直线、箭头、形状、原生曲线,选中修改对象和文字 | 在草图画板中使用 |
70
70
  | **图层与图片导入** | 分层创作,将图片加入草图继续画 | 图片作为图层管理 |
71
71
  | **笔画平滑与导航** | 抬笔后平滑整条路径;拖动、缩放、撤销重做 | 快捷键可自定义和关闭 |
72
72
  | **多份草稿** | 保存并重新编辑最多 20 份本地草稿 | 保存在当前浏览器 |
73
- | **导入与导出** | 导出 PNG、分层 PSD,或交换保留原生笔画的草稿文件 | PSD 导入仅支持有限的普通像素图层 |
73
+ | **导入与导出** | 导出 PNG,或交换保留原生笔画的草稿文件 | 草稿文件可重新导入继续编辑 |
74
74
  | **Agent 绘图** | 用 `@sketch` 让 Agent 绘制,查看进度并随时停止;Agent 可用 SVG 整段作画,导入为可编辑原生笔画 | Beta;默认关闭,需同时开启画板 |
75
75
  | **绘图结果回看** | 完成后向模型返回画布预览,帮助后续检查 | Beta;默认关闭,会增加图片输入用量 |
76
76
 
@@ -82,6 +82,7 @@
82
82
  | **子任务组件管理** | 在设置里安装、停用或卸载官方 Codex 子任务组件 | 由支持的 DSH 宿主管理,无需额外登录 |
83
83
  | **云端上下文压缩** | 使用 Codex 云端压缩继续长对话,同时保留 DSH 历史与原生压缩 | Beta / 实验性;默认关闭,开启的请求使用 SSE |
84
84
  | **WebSocket 连接** | 实验性复用连接和上下文传输,连接失败可回退 SSE | Beta / 实验性;默认 SSE,不保证更快 |
85
+ | **Auto review 官方审查模型** | DSH Auto review 改用 Codex 自带的审查模型判断工具调用,审查规则与放行流程仍由 DSH 负责 | Beta;默认关闭,账号目录提供该模型时生效 |
85
86
  | **支持诊断** | 查看功能前置条件和近期操作结果,一键复制约 1 KB 的精简报告(完整报告可另行复制);不含凭据和会话正文 | 设置 → 维护;未验证不代表故障 |
86
87
  | **预测缓存清理** | 查看并清理本地额度预测历史 | 保留登录、草稿、原图和共享依赖 |
87
88
 
@@ -105,7 +106,7 @@
105
106
  2. 在 **包名或地址** 输入框中粘贴下面的包名(已带版本号):
106
107
 
107
108
  ```text
108
- dsh-codex-subscription@2.5.4
109
+ dsh-codex-subscription@2.5.6
109
110
  ```
110
111
 
111
112
  3. 点击 **安装**,等待安装完成;按页面提示操作,需要重启时先保存工作。
@@ -268,9 +269,9 @@ DSH 实机设置截图。
268
269
 
269
270
  </details>
270
271
 
271
- 支持图层、原生曲线、笔刷、撤销重做和快捷键;可保存多份草稿,导出 PNG 或分层 PSD。生成图可标注区域后继续编辑。
272
+ 支持图层、原生曲线、笔刷、撤销重做和快捷键;可保存多份草稿,导出 PNG 或可编辑草稿。生成图可标注区域后继续编辑。
272
273
 
273
- [图片编辑、草稿保存与 PSD 限制 →](docs/GUIDE.zh-CN.md#图片生成与编辑beta)
274
+ [图片编辑与草稿保存 →](docs/GUIDE.zh-CN.md#图片生成与编辑beta)
274
275
 
275
276
  <a id="codex-subtask-runtime"></a>
276
277
 
package/lib/client.js CHANGED
@@ -778,7 +778,7 @@ window.__ModuleLoader__.load({
778
778
  id: context.id,
779
779
  kind: KIND,
780
780
  target: "chat",
781
- location: end.location,
781
+ location: { kind: "session" },
782
782
  anchorSeq,
783
783
  visibility: "visible",
784
784
  data: { blocks }
@@ -1928,59 +1928,6 @@ window.__ModuleLoader__.load({
1928
1928
  });
1929
1929
  }
1930
1930
  //#endregion
1931
- //#region src/sketch-import-confirm.jsx
1932
- function useSketchImportConfirm(t) {
1933
- const [pending, setPending] = (0, react.useState)(false);
1934
- const resolve = (0, react.useRef)(null);
1935
- const dialog = (0, react.useRef)(null);
1936
- const finish = (accepted) => {
1937
- const done = resolve.current;
1938
- resolve.current = null;
1939
- setPending(false);
1940
- done?.(accepted);
1941
- };
1942
- (0, react.useEffect)(() => {
1943
- if (pending) dialog.current?.showModal();
1944
- else dialog.current?.close();
1945
- }, [pending]);
1946
- (0, react.useEffect)(() => () => {
1947
- resolve.current?.(false);
1948
- resolve.current = null;
1949
- }, []);
1950
- return {
1951
- confirmPsd: () => new Promise((done) => {
1952
- resolve.current?.(false);
1953
- resolve.current = done;
1954
- setPending(true);
1955
- }),
1956
- prompt: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("dialog", {
1957
- ref: dialog,
1958
- className: "codexSketchImportConfirm",
1959
- "aria-label": t("sketchPsdConfirmTitle"),
1960
- onKeyDown: (event) => event.stopPropagation(),
1961
- onCancel: (event) => {
1962
- event.preventDefault();
1963
- event.stopPropagation();
1964
- finish(false);
1965
- },
1966
- children: [
1967
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("h3", { children: t("sketchPsdConfirmTitle") }),
1968
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", { children: t("sketchPsdConfirmBody") }),
1969
- /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
1970
- type: "button",
1971
- autoFocus: true,
1972
- onClick: () => finish(false),
1973
- children: t("sketchCancel")
1974
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
1975
- type: "button",
1976
- onClick: () => finish(true),
1977
- children: t("sketchImport")
1978
- })] })
1979
- ]
1980
- })
1981
- };
1982
- }
1983
- //#endregion
1984
1931
  //#region src/sketch-objects.js
1985
1932
  const objectId = (stroke, index) => stroke.id ?? `legacy-${index}`;
1986
1933
  const identifyObjects = (doc) => ({
@@ -3418,30 +3365,7 @@ window.__ModuleLoader__.load({
3418
3365
  }
3419
3366
  //#endregion
3420
3367
  //#region src/sketch-formats.js
3421
- const SKETCH_FILE_ACCEPT = ".psd,.dsh-sketch.json,image/png,image/jpeg,image/webp";
3422
- const canvas = (w, h) => {
3423
- const c = document.createElement("canvas");
3424
- c.width = w;
3425
- c.height = h;
3426
- return c;
3427
- };
3428
- function runPsdCodec(action, payload) {
3429
- return new Promise((resolve, reject) => {
3430
- const worker = new Worker("/api/codex-subscription/sketch-psd-worker", { type: "module" });
3431
- const finish = (callback, value) => {
3432
- clearTimeout(timer);
3433
- worker.terminate();
3434
- callback(value);
3435
- };
3436
- const timer = setTimeout(() => finish(reject, Error("PSD operation timed out")), 3e4);
3437
- worker.onerror = () => finish(reject, Error("PSD codec could not be loaded"));
3438
- worker.onmessage = (event) => event.data.ok ? finish(resolve, event.data.value) : finish(reject, Error(event.data.error));
3439
- worker.postMessage({
3440
- action,
3441
- payload
3442
- });
3443
- });
3444
- }
3368
+ const SKETCH_FILE_ACCEPT = ".dsh-sketch.json,image/png,image/jpeg,image/webp";
3445
3369
  function encodeSketchDocument(doc) {
3446
3370
  return JSON.stringify({
3447
3371
  format: "dsh-sketch",
@@ -3521,81 +3445,9 @@ window.__ModuleLoader__.load({
3521
3445
  doc.active = doc.layers[Math.max(0, activeIndex)].id;
3522
3446
  return doc;
3523
3447
  }
3524
- async function exportSketchPsd(doc, images, composite) {
3525
- const width = doc.width ?? 1024, height = doc.height ?? 1024;
3526
- const children = doc.layers.map((layer, i) => {
3527
- const ctx = canvas(width, height).getContext("2d"), ref = layer.image;
3528
- if (ref) ctx.drawImage(images.get(ref.src), ref.x * width, ref.y * height, ref.width * width, ref.height * height);
3529
- paintSketch(ctx, layer.strokes, width, true, height);
3530
- return {
3531
- name: layer.name || `Layer ${i + 1}`,
3532
- hidden: !layer.visible,
3533
- opacity: 1,
3534
- blendMode: "normal",
3535
- imageData: ctx.getImageData(0, 0, width, height)
3536
- };
3537
- });
3538
- const context = canvas(width, height).getContext("2d");
3539
- context.fillStyle = "#fff";
3540
- context.fillRect(0, 0, width, height);
3541
- if (children[0] && !children[0].hidden) {
3542
- const bottom = canvas(width, height);
3543
- bottom.getContext("2d").putImageData(children[0].imageData, 0, 0);
3544
- context.drawImage(bottom, 0, 0);
3545
- children[0].imageData = context.getImageData(0, 0, width, height);
3546
- } else {
3547
- if (children.length >= 8) throw Error("Show the bottom layer before exporting this eight-layer drawing");
3548
- children.unshift({
3549
- name: "Paper",
3550
- opacity: 1,
3551
- blendMode: "normal",
3552
- imageData: context.getImageData(0, 0, width, height)
3553
- });
3554
- }
3555
- return runPsdCodec("write", {
3556
- width,
3557
- height,
3558
- children,
3559
- imageData: composite.getContext("2d").getImageData(0, 0, width, height)
3560
- });
3561
- }
3562
- async function importSketchPsd(file) {
3563
- if (file.size > 32 * 1024 * 1024) throw Error("PSD exceeds 32 MB");
3564
- const psd = await runPsdCodec("read", await file.arrayBuffer());
3565
- const scale = Math.min(1, 1024 / Math.max(psd.width, psd.height)), width = Math.max(1, Math.round(psd.width * scale)), height = Math.max(1, Math.round(psd.height * scale));
3566
- const doc = {
3567
- ...createSketchLayers(),
3568
- width,
3569
- height,
3570
- ratio: Object.keys(SKETCH_RATIOS).find((k) => SKETCH_RATIOS[k][0] === width && SKETCH_RATIOS[k][1] === height) ?? "custom",
3571
- layers: [],
3572
- nextId: psd.layers.length + 1
3573
- };
3574
- for (const [i, layer] of psd.layers.entries()) {
3575
- const src = canvas(layer.imageData.width, layer.imageData.height);
3576
- src.getContext("2d").putImageData(new ImageData(new Uint8ClampedArray(layer.imageData.data), layer.imageData.width, layer.imageData.height), 0, 0);
3577
- const out = canvas(width, height), ctx = out.getContext("2d");
3578
- ctx.globalAlpha = layer.opacity;
3579
- ctx.drawImage(src, layer.left * scale, layer.top * scale, src.width * scale, src.height * scale);
3580
- doc.layers.push({
3581
- id: i + 1,
3582
- name: layer.name,
3583
- visible: !layer.hidden,
3584
- strokes: [],
3585
- image: {
3586
- src: out.toDataURL("image/png"),
3587
- x: 0,
3588
- y: 0,
3589
- width: 1,
3590
- height: 1
3591
- }
3592
- });
3593
- }
3594
- return doc;
3595
- }
3596
3448
  //#endregion
3597
3449
  //#region src/sketch-document-lifecycle.js
3598
- function createSketchDocumentLifecycle(state, { sessionId, t, schedule, checkpoint, cache, setSelection, setTextEdit, setRecovered, confirmPsd = async () => false, store = sketchDrafts, decodeImages = decodeSketchImages, readImage = importSketchImage }) {
3450
+ function createSketchDocumentLifecycle(state, { sessionId, t, schedule, checkpoint, cache, setSelection, setTextEdit, setRecovered, store = sketchDrafts, decodeImages = decodeSketchImages, readImage = importSketchImage }) {
3599
3451
  const { doc, undo, redo, images, saved, dirty, documentId, documentRevision } = state;
3600
3452
  const hasContent = () => doc.current.layers.some((layer) => layer.image || layer.strokes.length);
3601
3453
  const save = async (name) => {
@@ -3665,10 +3517,9 @@ window.__ModuleLoader__.load({
3665
3517
  });
3666
3518
  };
3667
3519
  const importImage = async (file, { visible = true } = {}) => {
3668
- if (file.name?.toLowerCase().endsWith(".psd") || file.name?.toLowerCase().endsWith(".dsh-sketch.json")) {
3520
+ if (file.name?.toLowerCase().endsWith(".dsh-sketch.json")) {
3669
3521
  if (file.size > 32 * 1024 * 1024) throw Error("File exceeds 32 MB");
3670
- if (file.name.toLowerCase().endsWith(".psd") && !await confirmPsd()) return;
3671
- const next = file.name.toLowerCase().endsWith(".psd") ? await importSketchPsd(file) : decodeSketchDocument(await file.text());
3522
+ const next = decodeSketchDocument(await file.text());
3672
3523
  const decoded = /* @__PURE__ */ new Map();
3673
3524
  await decodeImages(next, decoded);
3674
3525
  await saveChanges();
@@ -4054,11 +3905,7 @@ window.__ModuleLoader__.load({
4054
3905
  className: "codexSketchExportFormats codexSketchSegment",
4055
3906
  role: "group",
4056
3907
  "aria-label": t("sketchExportFormat"),
4057
- children: [
4058
- ["png", "PNG"],
4059
- ["psd", "PSD"],
4060
- ["draft", t("sketchEditableFile")]
4061
- ].map(([value, label]) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
3908
+ children: [["png", "PNG"], ["draft", t("sketchEditableFile")]].map(([value, label]) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
4062
3909
  type: "button",
4063
3910
  "aria-pressed": format === value,
4064
3911
  disabled: disabled || working,
@@ -4364,7 +4211,6 @@ window.__ModuleLoader__.load({
4364
4211
  //#region src/sketch-studio.jsx
4365
4212
  function SketchStudio({ open, agentEnabled, onOpen, onClose, attachSketch, enabled, t, incoming, sessionId, rpc, sessionState }) {
4366
4213
  const localSession = (0, react.useRef)(null);
4367
- const psdImport = useSketchImportConfirm(t);
4368
4214
  localSession.current ??= sessionState ?? createSketchSessionState();
4369
4215
  const { doc, undo, redo, images, saved, dirty, documentId, documentRevision, agentAdapter, agentSession, agentRun } = localSession.current;
4370
4216
  const dialog = (0, react.useRef)(null), canvas = (0, react.useRef)(null), cache = (0, react.useRef)(/* @__PURE__ */ new Map());
@@ -4483,7 +4329,6 @@ window.__ModuleLoader__.load({
4483
4329
  cache,
4484
4330
  setSelection,
4485
4331
  setTextEdit,
4486
- confirmPsd: psdImport.confirmPsd,
4487
4332
  setRecovered
4488
4333
  });
4489
4334
  (0, react.useEffect)(() => localSession.current.retain?.(), []);
@@ -4786,10 +4631,6 @@ window.__ModuleLoader__.load({
4786
4631
  blob: new Blob([encodeSketchDocument(doc.current)], { type: "application/json" }),
4787
4632
  extension: "dsh-sketch.json"
4788
4633
  };
4789
- if (format === "psd") return {
4790
- blob: new Blob([await exportSketchPsd(doc.current, images.current, canvas.current)], { type: "image/vnd.adobe.photoshop" }),
4791
- extension: "psd"
4792
- };
4793
4634
  if (format !== "png") throw Error("Unsupported format");
4794
4635
  return {
4795
4636
  blob: await new Promise((resolve, reject) => canvas.current.toBlob((blob) => blob ? resolve(blob) : reject(Error("PNG")), "image/png")),
@@ -5303,15 +5144,14 @@ window.__ModuleLoader__.load({
5303
5144
  onClick: () => retryRestore((value) => value + 1),
5304
5145
  children: t("accountRetry")
5305
5146
  }) : null]
5306
- }) : null,
5307
- psdImport.prompt
5147
+ }) : null
5308
5148
  ]
5309
5149
  })] });
5310
5150
  }
5311
5151
  //#endregion
5312
5152
  //#region src/sketch-styles.js
5313
5153
  const SKETCH_CSS = `
5314
- .codexSketchImportConfirm{width:min(440px,calc(100vw - 32px));box-sizing:border-box;padding:24px;border:1px solid var(--sketch-line);border-radius:20px;background:var(--sketch-bg);color:var(--sketch-fg);box-shadow:0 12px 60px #0005}.codexSketchImportConfirm::backdrop{background:#0007}.codexSketchImportConfirm h3{margin:0 0 12px;font-size:16px}.codexSketchImportConfirm p{font-size:14px;line-height:1.7;color:var(--sketch-muted)}.codexSketchImportConfirm>div{display:flex;justify-content:flex-end;gap:12px}.codexSketchImportConfirm button{padding:8px 16px;border-radius:12px;border:1px solid var(--sketch-line);background:var(--sketch-line);color:var(--sketch-fg)}
5154
+
5315
5155
  .codexSketchSizeModes{display:flex;flex-direction:column;gap:3px}.codexSketchSizeModes button{font-size:11px;padding:4px 6px;border-radius:10px;color:var(--sketch-muted)}.codexSketchSizeModes button[aria-pressed=true]{background:var(--sketch-line);color:var(--sketch-fg)}
5316
5156
 
5317
5157
  .codexSketchSizeControl{position:absolute;left:10px;top:50%;transform:translateY(-50%);z-index:2;display:flex;flex-direction:column;align-items:center;gap:10px;padding:12px 6px;border:1px solid var(--sketch-line);border-radius:24px;background:var(--sketch-glass);backdrop-filter:blur(18px);box-shadow:0 3px 14px #0001}
@@ -5593,8 +5433,6 @@ window.__ModuleLoader__.load({
5593
5433
  storageHint: "仅清理本地预测历史,保留原图、草稿、登录信息和共享依赖。子任务组件可在“模型与运行”中管理。",
5594
5434
  storageConfirm: "清除所有已登录账号的本地预测历史后,需要重新积累采样。服务端额度不变,后续查询会重新生成缓存。",
5595
5435
  storageFailed: "未能读取或清除预测缓存,请重试。",
5596
- sketchPsdConfirmTitle: "导入 PSD 副本",
5597
- sketchPsdConfirmBody: "支持最多 8 层、8 位 RGB 的简单 PSD(32 MB 内,边长不超过 4096)。导入后各层转为图片,最长边缩至 1024;不支持蒙版、调整层和特殊混合效果。原文件不会修改。需要保留草图对象的可编辑性,请使用 DSH 草图格式。继续导入?",
5598
5436
  runtimeIncompatible: "检测到不兼容的 Codex 子任务组件,请卸载后重启,再安装受支持版本。",
5599
5437
  runtimeManagedElsewhere: "此组件由宿主或其他依赖管理,请在 DSH 插件管理中查看;这里不能直接卸载。",
5600
5438
  runtimeLoading: "正在检查组件…",
@@ -5641,6 +5479,10 @@ window.__ModuleLoader__.load({
5641
5479
  subagentBackend_dsh: "DSH",
5642
5480
  subagentBackend_codex: "Codex",
5643
5481
  connectionTitle: "连接方式",
5482
+ reviewModelTitle: "Auto review 审查模型",
5483
+ reviewModel_session: "当前模型",
5484
+ reviewModel_official: "Codex 官方审查模型",
5485
+ reviewModelHint: "实验功能,默认使用当前模型。选择官方后,DSH Auto review 用 Codex 自带的审查模型判断工具调用(账号目录提供时),审查规则与放行、拒绝流程仍由 DSH 负责;不可用时沿用当前模型。",
5644
5486
  connectionHint: "默认 SSE。WebSocket 实验性复用连接与上下文传输;连接失败可回退 SSE。下次请求生效,不扩大上下文容量。",
5645
5487
  streamIdleTimeoutTitle: "流无响应超时",
5646
5488
  streamIdleTimeoutHint: "连续多久没有收到任何流式数据时中断本次请求,不是整体回答时限。调低可能中断较慢但仍在推理的回答,并交由 DSH 重试处理。默认 10 分钟。",
@@ -5681,7 +5523,7 @@ window.__ModuleLoader__.load({
5681
5523
  sketchDownload: "下载",
5682
5524
  sketchExportFormat: "导出格式",
5683
5525
  sketchEditableFile: "可编辑草稿",
5684
- sketchFormatHint: "PNG 为合并图片;PSD 交换像素图层;可编辑草稿保留原生笔画。可导入 PSD 或草稿文件(32 MB 内);PSD 仅支持普通像素图层,长边适配至 1024。",
5526
+ sketchFormatHint: "PNG 为合并图片;可编辑草稿保留原生笔画,可重新导入(32 MB 内)。",
5685
5527
  imageToSketch: "进入草图",
5686
5528
  sketchPictures: "图片",
5687
5529
  sketchPictureAdd: "添加",
@@ -6160,8 +6002,6 @@ window.__ModuleLoader__.load({
6160
6002
  storageHint: "Clears local forecast history only. Original images, drafts, sign-in data and shared dependencies are preserved. Manage subtask components under Models & runtime.",
6161
6003
  storageConfirm: "This clears local forecast samples for all signed-in accounts. Forecasts will need new samples. Server quotas stay unchanged; subsequent checks recreate the cache.",
6162
6004
  storageFailed: "Could not read or clear the forecast cache. Try again.",
6163
- sketchPsdConfirmTitle: "Import a PSD copy",
6164
- sketchPsdConfirmBody: "Supports simple 8-bit RGB PSDs with up to 8 layers, 32 MB and 4096 pixels per side. Layers become images and the longest side is reduced to 1024 pixels. Masks, adjustments and special blending effects are unsupported. The original file stays unchanged. Use the DSH sketch format to preserve editable sketch objects. Continue?",
6165
6005
  runtimeIncompatible: "An incompatible Codex subtask component was found. Uninstall it, restart DSH, then install the supported version.",
6166
6006
  runtimeManagedElsewhere: "This component is managed by the host or another dependency. Check DSH plugin management; it cannot be removed here.",
6167
6007
  runtimeLoading: "Checking component…",
@@ -6208,6 +6048,10 @@ window.__ModuleLoader__.load({
6208
6048
  subagentBackend_dsh: "DSH",
6209
6049
  subagentBackend_codex: "Codex",
6210
6050
  connectionTitle: "Connection",
6051
+ reviewModelTitle: "Auto review model",
6052
+ reviewModel_session: "Current model",
6053
+ reviewModel_official: "Codex reviewer",
6054
+ reviewModelHint: "Experimental; uses the current model by default. With Codex reviewer, DSH Auto review judges tool calls with Codex's own review model when your account catalog offers it. DSH keeps its review policy and allow/deny flow; otherwise the current model is used.",
6211
6055
  connectionHint: "SSE by default. Experimental WebSocket reuses connections and context transfers and can fall back to SSE on connection failure. Applies to the next request; context limits stay the same.",
6212
6056
  streamIdleTimeoutTitle: "Stream inactivity timeout",
6213
6057
  streamIdleTimeoutHint: "How long a request may receive no streamed data before it is aborted. This is not an overall response deadline. Lower values can abort slow but valid reasoning and hand the request to DSH retry handling. Default: 10 minutes.",
@@ -6248,7 +6092,7 @@ window.__ModuleLoader__.load({
6248
6092
  sketchDownload: "Download",
6249
6093
  sketchExportFormat: "Export format",
6250
6094
  sketchEditableFile: "Editable draft",
6251
- sketchFormatHint: "PNG is flattened; PSD exchanges pixel layers; editable drafts retain native strokes. Import PSD or draft files up to 32 MB. PSD supports normal pixel layers, fitted to a 1024 px long edge.",
6095
+ sketchFormatHint: "PNG is flattened; editable drafts retain native strokes and can be imported again (up to 32 MB).",
6252
6096
  imageToSketch: "Open in sketch",
6253
6097
  sketchPictures: "Images",
6254
6098
  sketchPictureAdd: "Add",
@@ -8093,6 +7937,7 @@ window.__ModuleLoader__.load({
8093
7937
  ...capabilities,
8094
7938
  autoQuotaRetry: normalizeAutoQuotaRetry(value?.[AUTO_QUOTA_RETRY_FIELD]),
8095
7939
  connectionMode: value?.connectionMode === "websocket" ? "websocket" : "sse",
7940
+ reviewModel: value?.reviewModel === "official" ? "official" : "session",
8096
7941
  compactionMode: value?.compactionMode === "cloud" ? "cloud" : "dsh",
8097
7942
  subagentBackend: value?.subagentBackend === "codex" ? "codex" : "dsh",
8098
7943
  subagentBackendAvailable,
@@ -8152,6 +7997,7 @@ window.__ModuleLoader__.load({
8152
7997
  [DISABLED_MODELS_FIELD]: normalizeDisabledModels(value?.[DISABLED_MODELS_FIELD]),
8153
7998
  [AUTO_QUOTA_RETRY_FIELD]: normalizeAutoQuotaRetry(value?.[AUTO_QUOTA_RETRY_FIELD]),
8154
7999
  connectionMode: value?.connectionMode === "websocket" ? "websocket" : "sse",
8000
+ reviewModel: value?.reviewModel === "official" ? "official" : "session",
8155
8001
  compactionMode: value?.compactionMode === "cloud" ? "cloud" : "dsh",
8156
8002
  subagentBackend: value?.subagentBackend === "codex" ? "codex" : "dsh",
8157
8003
  ...readCapabilitySettings(value),
@@ -8685,7 +8531,7 @@ window.__ModuleLoader__.load({
8685
8531
  }
8686
8532
  //#endregion
8687
8533
  //#region src/version.js
8688
- const PACKAGE_VERSION = "2.5.4";
8534
+ const PACKAGE_VERSION = "2.5.6";
8689
8535
  //#endregion
8690
8536
  //#region src/client-recovery.js
8691
8537
  async function recoveryCall(rpc, endpoint, payload = {}, timeoutMs = 1e4) {
@@ -10357,6 +10203,44 @@ window.__ModuleLoader__.load({
10357
10203
  })
10358
10204
  ]
10359
10205
  }),
10206
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("section", {
10207
+ className: "codexSubscriptionCard codexSubscriptionPreferencesCard",
10208
+ "aria-label": t("reviewModelTitle"),
10209
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
10210
+ className: "codexSubscriptionPreference",
10211
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
10212
+ className: "codexSubscriptionPreferenceCopy",
10213
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
10214
+ className: "codexSubscriptionPreferenceLabel",
10215
+ children: [
10216
+ t("reviewModelTitle"),
10217
+ " ",
10218
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("small", { children: "Beta" })
10219
+ ]
10220
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
10221
+ className: "codexSubscriptionPreferenceHint",
10222
+ children: t("reviewModelHint")
10223
+ })]
10224
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
10225
+ className: "codexSubscriptionQuotaModes",
10226
+ role: "radiogroup",
10227
+ "aria-label": t("reviewModelTitle"),
10228
+ "aria-busy": snapshot.saving || void 0,
10229
+ children: ["session", "official"].map((value) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("label", {
10230
+ className: "codexSubscriptionQuotaMode",
10231
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("input", {
10232
+ type: "radio",
10233
+ name: "codex-review-model",
10234
+ checked: snapshot.reviewModel === value,
10235
+ disabled: !snapshot.writable,
10236
+ onChange: () => {
10237
+ preference.set({ reviewModel: value });
10238
+ }
10239
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { children: t(`reviewModel_${value}`) })]
10240
+ }, value))
10241
+ })]
10242
+ })
10243
+ }),
10360
10244
  /* @__PURE__ */ (0, react_jsx_runtime.jsx)("section", {
10361
10245
  className: "codexSubscriptionCard codexSubscriptionPreferencesCard",
10362
10246
  "aria-label": t("compactionTitle"),