@aidotnet/nextcowork-device-service 2.8.3 → 2.8.5
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/RUNTIME.json +1 -1
- package/bin.mjs +39 -4
- package/bin.mjs.map +1 -1
- package/package.json +1 -1
package/RUNTIME.json
CHANGED
package/bin.mjs
CHANGED
|
@@ -5455,6 +5455,11 @@ function shellDialect(shell) {
|
|
|
5455
5455
|
if (name === "powershell" || name === "pwsh" || name === "pwsh-preview") return "powershell";
|
|
5456
5456
|
return name === "fish" ? "fish" : "posix";
|
|
5457
5457
|
}
|
|
5458
|
+
function terminalShellArgs(shell, platform = process.platform) {
|
|
5459
|
+
if (platform === "win32") return [];
|
|
5460
|
+
const name = shell.split("/").pop()?.toLowerCase();
|
|
5461
|
+
return name !== void 0 && ["sh", "bash", "zsh", "dash", "ksh", "mksh", "fish"].includes(name) ? ["-l"] : [];
|
|
5462
|
+
}
|
|
5458
5463
|
function quoteShellArg(shell, arg) {
|
|
5459
5464
|
switch (shellDialect(shell)) {
|
|
5460
5465
|
case "cmd":
|
|
@@ -28743,6 +28748,26 @@ const DEEPSEEK_EFFORT_THINKING = {
|
|
|
28743
28748
|
reasoningReplay: "text-required"
|
|
28744
28749
|
};
|
|
28745
28750
|
const DEEPSEEK$1 = [
|
|
28751
|
+
// 1017 版本已在 NextCoWork 渠道上架;官方 API 使用 deepseek-flash 指向同一版本。
|
|
28752
|
+
model("deepseek", "deepseek-v4.1-flash-1017", "DeepSeek V4.1 Flash 1017", {
|
|
28753
|
+
capabilities: visionCapabilities({
|
|
28754
|
+
thinking: true,
|
|
28755
|
+
tools: true,
|
|
28756
|
+
caching: true,
|
|
28757
|
+
structuredOutput: true,
|
|
28758
|
+
streaming: true
|
|
28759
|
+
}),
|
|
28760
|
+
contextWindow: 1e6,
|
|
28761
|
+
maxOutputTokens: 384e3,
|
|
28762
|
+
thinkingConfig: DEEPSEEK_EFFORT_THINKING,
|
|
28763
|
+
reasoningEfforts: ["none", "low", "high", "max"],
|
|
28764
|
+
aliases: ["deepseek-flash"],
|
|
28765
|
+
source: {
|
|
28766
|
+
url: "https://nextco.work/models/deepseek-v4.1-flash-1017",
|
|
28767
|
+
fetchedAt: "2026-10-19"
|
|
28768
|
+
},
|
|
28769
|
+
verificationStatus: "official-api"
|
|
28770
|
+
}),
|
|
28746
28771
|
// DeepSeek announced this as a time-limited preview on 2026-09-08. Its
|
|
28747
28772
|
// public announcement confirms native multimodal input and says billing
|
|
28748
28773
|
// follows V4 Flash, but does not publish independent limits. Keep the
|
|
@@ -31891,6 +31916,10 @@ const PEAK_WINDOWS = [
|
|
|
31891
31916
|
];
|
|
31892
31917
|
const ds = maker(null, "USD", "https://api-docs.deepseek.com/quick_start/pricing/");
|
|
31893
31918
|
const DEEPSEEK = [
|
|
31919
|
+
ds("deepseek-v4.1-flash-1017", "DeepSeek V4.1 Flash 1017", one({ input: 0.15, output: 0.6, cacheRead: 3e-3 }), {
|
|
31920
|
+
windows: PEAK_WINDOWS,
|
|
31921
|
+
fetchedAt: "2026-10-19"
|
|
31922
|
+
}),
|
|
31894
31923
|
ds("deepseek-v4-flash", "DeepSeek V4 Flash", one({ input: 0.22, output: 0.66, cacheRead: 7e-3 }), {
|
|
31895
31924
|
windows: PEAK_WINDOWS
|
|
31896
31925
|
}),
|
|
@@ -33553,7 +33582,7 @@ function localEnvironment(host2, rootPath) {
|
|
|
33553
33582
|
},
|
|
33554
33583
|
openTerminal: async (options) => {
|
|
33555
33584
|
const pty = await import("node-pty");
|
|
33556
|
-
return pty.spawn(terminalShell,
|
|
33585
|
+
return pty.spawn(terminalShell, terminalShellArgs(terminalShell), {
|
|
33557
33586
|
...options,
|
|
33558
33587
|
name: "xterm-256color",
|
|
33559
33588
|
env: { ...process.env, TERM: "xterm-256color", ...options.env ?? {} }
|
|
@@ -33771,15 +33800,21 @@ function seedDefaultWorkspace() {
|
|
|
33771
33800
|
unavailable2 = true;
|
|
33772
33801
|
}
|
|
33773
33802
|
const now2 = getHost().clock.now();
|
|
33774
|
-
|
|
33775
|
-
id,
|
|
33803
|
+
const workspace = {
|
|
33776
33804
|
name: "默认工作区",
|
|
33777
33805
|
rootPath,
|
|
33778
33806
|
...unavailable2 ? { unavailable: true } : {},
|
|
33779
33807
|
settings: structuredClone(DEFAULT_WORKSPACE_SETTINGS),
|
|
33780
33808
|
createdAt: now2,
|
|
33781
33809
|
lastOpenedAt: now2
|
|
33782
|
-
}
|
|
33810
|
+
};
|
|
33811
|
+
try {
|
|
33812
|
+
store.putWorkspace({ id, ...workspace });
|
|
33813
|
+
} catch (err) {
|
|
33814
|
+
if (!(err instanceof ConfigProfileError) || err.code !== "workspaceOwned") throw err;
|
|
33815
|
+
getHost().logger.warn(`[runtime] 默认工作区 id ${id} 属于其他账户,改用新 id`);
|
|
33816
|
+
store.putWorkspace({ id: `${id}-${randomUUID().slice(0, 8)}`, ...workspace });
|
|
33817
|
+
}
|
|
33783
33818
|
}
|
|
33784
33819
|
function ensureSeeded() {
|
|
33785
33820
|
seed();
|