devez-vibe 1.9.49 → 1.9.51

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/bin/dvz.exe CHANGED
Binary file
@@ -5,7 +5,7 @@ import { execFile, spawn } from "node:child_process";
5
5
  import { createReadStream, existsSync, readFileSync, readdirSync } from "node:fs";
6
6
  import { mkdir, readdir, readFile, stat, writeFile } from "node:fs/promises";
7
7
  import { createRequire } from "node:module";
8
- import { homedir } from "node:os";
8
+ import { homedir, tmpdir } from "node:os";
9
9
  import { dirname, join, resolve as resolvePath, sep } from "node:path";
10
10
  import { createInterface } from "node:readline";
11
11
  import { fileURLToPath } from "node:url";
@@ -17,6 +17,7 @@ import {
17
17
  getSessionMessages,
18
18
  filterEscalatingDefaultMode,
19
19
  listSessions,
20
+ renameSession,
20
21
  resolveSettings,
21
22
  startup,
22
23
  tool,
@@ -221,9 +222,13 @@ function applyClaudeExecutable(options, params) {
221
222
 
222
223
  // The SDK model list carries no window size, so the status line would stay
223
224
  // blank until a turn reports one — and a fresh session has no turn yet. Claude
224
- // ships a 200k window, and the `[1m]` variants a 1M one.
225
+ // defaults here stay unchanged; Haiku 5.5 has a native 1M window.
225
226
  function claudeContextWindow(...names) {
226
- const oneMillion = names.some((name) => String(name || "").includes("[1m]"));
227
+ if (["1", "true"].includes(String(process.env.CLAUDE_CODE_DISABLE_1M_CONTEXT || "").toLowerCase())) {
228
+ return 200_000;
229
+ }
230
+ const oneMillion = names.some((name) => String(name || "").includes("[1m]")
231
+ || /claude-haiku-5-5(?:$|[-\[])/i.test(String(name || "")));
227
232
  return oneMillion ? 1_000_000 : 200_000;
228
233
  }
229
234
 
@@ -3339,6 +3344,8 @@ const STARTUP_FAILURE_GUIDES = {
3339
3344
  org_pin_mismatch: "조직 설정이 허용하지 않는 계정으로 로그인되어 있습니다. 허용된 조직 계정으로 다시 로그인하세요.",
3340
3345
  managed_settings_invalid: "조직 관리 설정을 읽지 못했습니다. 관리자에게 설정 확인을 요청하세요.",
3341
3346
  remote_settings_required_unavailable: "조직이 요구하는 관리 설정을 불러오지 못했습니다. 네트워크를 확인한 뒤 다시 시작하세요.",
3347
+ org_config_required_unavailable: "조직이 요구하는 정책 한도와 관리 설정을 불러오지 못했습니다. 네트워크·프록시를 확인한 뒤 다시 시작하세요.",
3348
+ org_config_refused: "조직이 요구하는 정책 한도와 관리 설정의 조회가 거부되었습니다. 다시 로그인하거나 관리자에게 Claude Code 사용 권한을 문의하세요.",
3342
3349
  gateway_signin_required: "게이트웨이가 이 로그인을 종료했습니다. 다시 로그인하세요.",
3343
3350
  gateway_access_denied: "게이트웨이가 이 계정의 관리 설정을 거부했습니다. 관리자에게 권한을 요청하세요.",
3344
3351
  proxy_invalid: "프록시 설정이 올바른 주소 형식이 아닙니다. 프록시 환경 변수를 확인하세요.",
@@ -4478,6 +4485,40 @@ async function dispatch(method, params = {}) {
4478
4485
  if (method === "session/compact") {
4479
4486
  return startPrompt({ ...params, input: [{ type: "text", text: "/compact" }] });
4480
4487
  }
4488
+ // The running CLI re-reads the transcript's last custom title before it
4489
+ // re-stamps session metadata, so a rename from here survives a live session.
4490
+ if (method === "session/rename") {
4491
+ const id = liveSessionId(params.sessionId);
4492
+ const dir = await readableCwd(id, params.cwd);
4493
+ // An automatic title never replaces a name given in the meantime.
4494
+ if (params.unnamedOnly && (await getSessionInfo(id, { dir }))?.customTitle) return {};
4495
+ await renameSession(id, String(params.name ?? ""), { dir });
4496
+ return {};
4497
+ }
4498
+ // One Haiku reply that dvz titles a new session with. It reads no settings,
4499
+ // hooks or project files, runs no tools, keeps no transcript, and leaves the
4500
+ // DevezCode room out so the host never takes it for the room's session.
4501
+ if (method === "session/title") {
4502
+ await ensureClaudeExecutableChoice(params);
4503
+ const env = sanitizedEnvironment();
4504
+ delete env.DEVEZCODE_ROOM_ID;
4505
+ const options = {
4506
+ cwd: tmpdir(),
4507
+ model: "haiku",
4508
+ effort: "low",
4509
+ maxTurns: 1,
4510
+ persistSession: false,
4511
+ settingSources: [],
4512
+ tools: [],
4513
+ env,
4514
+ };
4515
+ applyClaudeExecutable(options, params);
4516
+ let reply = "";
4517
+ for await (const message of await startAgentQuery(String(params.prompt ?? ""), options)) {
4518
+ if (message.type === "result") reply = message.result || "";
4519
+ }
4520
+ return { reply };
4521
+ }
4481
4522
  if (method === "session/fork") {
4482
4523
  const source = liveSessionId(params.sessionId);
4483
4524
  const forked = await forkSession(source, { dir: await readableCwd(source, params.cwd) });
@@ -5280,13 +5321,31 @@ async function runSelfTest() {
5280
5321
  if (usage.totalTokens !== 68_802 || usage.inputTokens !== 68_502) {
5281
5322
  throw new Error(`Claude usage self-test failed: ${JSON.stringify(usage)}`);
5282
5323
  }
5283
- const windows = [
5284
- catalogEntry({ value: "opus[1m]", resolvedModel: "claude-opus-5[1m]" }, "").contextWindow,
5285
- catalogEntry({ value: "sonnet", resolvedModel: "claude-sonnet-5" }, "").contextWindow,
5286
- catalogEntry({ value: "haiku", resolvedModel: "x", contextWindow: 300_000 }, "").contextWindow,
5287
- ];
5288
- if (windows.join(",") !== "1000000,200000,300000") {
5289
- throw new Error(`Claude context window self-test failed: ${windows.join(",")}`);
5324
+ const savedDisable1M = process.env.CLAUDE_CODE_DISABLE_1M_CONTEXT;
5325
+ try {
5326
+ delete process.env.CLAUDE_CODE_DISABLE_1M_CONTEXT;
5327
+ const windows = [
5328
+ catalogEntry({ value: "opus[1m]", resolvedModel: "claude-opus-5[1m]" }, "").contextWindow,
5329
+ catalogEntry({ value: "sonnet", resolvedModel: "claude-sonnet-5" }, "").contextWindow,
5330
+ catalogEntry({ value: "haiku", resolvedModel: "x", contextWindow: 300_000 }, "").contextWindow,
5331
+ catalogEntry({ value: "haiku", resolvedModel: "claude-haiku-5-5" }, "").contextWindow,
5332
+ catalogEntry({ value: "claude-haiku-5-5-20261007" }, "").contextWindow,
5333
+ catalogEntry({ value: "claude-haiku-4-5-20251001" }, "").contextWindow,
5334
+ ];
5335
+ if (windows.join(",") !== "1000000,200000,300000,1000000,1000000,200000") {
5336
+ throw new Error(`Claude context window self-test failed: ${windows.join(",")}`);
5337
+ }
5338
+ for (const disabled of ["1", "true"]) {
5339
+ process.env.CLAUDE_CODE_DISABLE_1M_CONTEXT = disabled;
5340
+ if (catalogEntry({ value: "haiku", resolvedModel: "claude-haiku-5-5" }, "").contextWindow !== 200_000
5341
+ || catalogEntry({ value: "haiku", resolvedModel: "claude-haiku-5-5", contextWindow: 300_000 }, "").contextWindow !== 300_000
5342
+ || catalogEntry({ value: "haiku", resolvedModel: "claude-haiku-5-5", contextWindowSize: 400_000 }, "").contextWindow !== 400_000) {
5343
+ throw new Error("Claude disabled 1M context self-test failed");
5344
+ }
5345
+ }
5346
+ } finally {
5347
+ if (savedDisable1M === undefined) delete process.env.CLAUDE_CODE_DISABLE_1M_CONTEXT;
5348
+ else process.env.CLAUDE_CODE_DISABLE_1M_CONTEXT = savedDisable1M;
5290
5349
  }
5291
5350
  const catalogModels = [
5292
5351
  {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "devez-vibe",
3
- "version": "1.9.49",
3
+ "version": "1.9.51",
4
4
  "type": "module",
5
5
  "description": "Stable terminal UI for Codex and Claude Agent SDK",
6
6
  "keywords": [
@@ -45,6 +45,6 @@
45
45
  "postinstall": "node install-skills.mjs && node prepare-search-deps.mjs"
46
46
  },
47
47
  "dependencies": {
48
- "@anthropic-ai/claude-agent-sdk": "0.3.292"
48
+ "@anthropic-ai/claude-agent-sdk": "0.3.296"
49
49
  }
50
50
  }