@junghanacs/entwurf 0.35.0 → 0.35.1

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.
Files changed (59) hide show
  1. package/CHANGELOG.md +129 -0
  2. package/VERIFY.md +5 -4
  3. package/docs/acp-backend-rail.md +28 -2
  4. package/docs/setup-clean-host.md +1 -1
  5. package/mcp/entwurf-bridge/dist/pi-extensions/lib/acp/backend-adapter.js +46 -2
  6. package/mcp/entwurf-bridge/dist/pi-extensions/lib/acp/model-ids.js +67 -0
  7. package/mcp/entwurf-bridge/dist/pi-extensions/lib/acp/models.js +9 -20
  8. package/mcp/entwurf-bridge/dist/pi-extensions/lib/entwurf-v2-visible-resume.js +11 -0
  9. package/mcp/entwurf-bridge/dist/pi-extensions/lib/fresh-call-dispatch.js +27 -1
  10. package/mcp/entwurf-bridge/dist/pi-extensions/lib/herdr-fresh-call.js +3 -0
  11. package/mcp/entwurf-bridge/dist/pi-extensions/lib/mux-fresh-call.js +2 -0
  12. package/mcp/entwurf-bridge/dist/pi-extensions/lib/resume-launch-identity.js +13 -4
  13. package/mcp/entwurf-bridge/dist/pi-extensions/meta-bridge-pi-durable.js +119 -11
  14. package/package.json +2 -2
  15. package/pi-extensions/lib/acp/backend-adapter.ts +52 -2
  16. package/pi-extensions/lib/acp/model-ids.js +77 -0
  17. package/pi-extensions/lib/acp/models.ts +15 -22
  18. package/pi-extensions/lib/entwurf-v2-visible-resume.ts +12 -0
  19. package/pi-extensions/lib/fresh-call-dispatch.ts +25 -1
  20. package/pi-extensions/lib/herdr-fresh-call.ts +5 -0
  21. package/pi-extensions/lib/mux-fresh-call.ts +3 -0
  22. package/pi-extensions/lib/resume-launch-identity.ts +12 -4
  23. package/pi-extensions/meta-bridge-pi-durable.ts +153 -13
  24. package/run.sh +81 -20
  25. package/scripts/check-acp-backend-preflight.ts +10 -2
  26. package/scripts/check-acp-cortex.ts +7 -6
  27. package/scripts/check-acp-prompt-lifecycle.ts +2 -2
  28. package/scripts/check-acp-provider-surface.ts +1 -1
  29. package/scripts/check-acp-session-reuse.ts +5 -5
  30. package/scripts/check-acp-stop-reason.ts +2 -2
  31. package/scripts/check-acp-stream-hooks.ts +2 -2
  32. package/scripts/check-acp-usage-accounting.ts +2 -2
  33. package/scripts/check-fresh-call-dispatch.ts +47 -4
  34. package/scripts/check-gate-qualification.ts +6 -4
  35. package/scripts/check-probe-ordering.ts +13 -6
  36. package/scripts/check-resume-launch-identity.ts +38 -0
  37. package/scripts/mutants/acp-cortex.json +17 -8
  38. package/scripts/mutants/acp-set-model-readback.json +28 -0
  39. package/scripts/mutants/fresh-call-dispatch.json +11 -0
  40. package/scripts/mutants/herdr-dev-checkout.json +70 -0
  41. package/scripts/mutants/pi-durable.json +117 -0
  42. package/scripts/mutants/resume-launch-identity.json +15 -0
  43. package/scripts/mutants/v2-visible-resume.json +11 -0
  44. package/scripts/resolve-acp-bridge.ts +1 -1
  45. package/scripts/smoke-acp-bundled-mcp-live.ts +1 -1
  46. package/scripts/smoke-acp-carrier-augment-live.ts +1 -1
  47. package/scripts/smoke-acp-long-turn-live.ts +1 -1
  48. package/scripts/smoke-acp-mcp-live.ts +1 -1
  49. package/scripts/smoke-acp-memory-containment-live.ts +1 -1
  50. package/scripts/smoke-acp-ordering-probe-live.ts +1 -1
  51. package/scripts/smoke-acp-overlay-live.ts +1 -1
  52. package/scripts/smoke-acp-provider-live.ts +1 -1
  53. package/scripts/smoke-acp-raw-turn-live.ts +1 -1
  54. package/scripts/smoke-acp-session-reuse-live.ts +1 -1
  55. package/scripts/smoke-acp-skill-live.ts +1 -1
  56. package/scripts/smoke-acp-socket-citizen-live.ts +2 -2
  57. package/scripts/smoke-acp-v2-send-live.ts +1 -1
  58. package/scripts/smoke-entwurf-chain-live.ts +1 -1
  59. package/scripts/smoke-mux-lifecycle-live.ts +1 -1
@@ -16,7 +16,7 @@ import type { ResolvedTarget } from "../pi-extensions/lib/entwurf-core.ts";
16
16
  import { getRegistryRouting } from "../pi-extensions/lib/entwurf-core.ts";
17
17
 
18
18
  const isRemote = process.argv[2] === "remote";
19
- const target: ResolvedTarget = { provider: "entwurf", model: "claude-sonnet-5", explicitOnly: false };
19
+ const target: ResolvedTarget = { provider: "entwurf", model: "claude-sonnet-5-5", explicitOnly: false };
20
20
 
21
21
  // Throws EntwurfRoutingError (non-zero exit) when the bridge cannot be resolved —
22
22
  // exactly the fail-fast the smoke wants to observe as a failure, not a pass.
@@ -56,7 +56,7 @@ import { skipLive } from "./lib/live-skip.ts";
56
56
  import { PI_BOOT_TIMEOUT_MS, waitForPiRecord } from "./lib/pi-record-discovery.ts";
57
57
 
58
58
  const ACP_PROVIDER = "entwurf";
59
- const ACP_MODEL = process.env.ENTWURF_ACP_PROVIDER_MODEL?.trim() || "claude-sonnet-5";
59
+ const ACP_MODEL = process.env.ENTWURF_ACP_PROVIDER_MODEL?.trim() || "claude-sonnet-5-5";
60
60
 
61
61
  const REAL_CONTROL_DIR = path.join(os.homedir(), ".pi", "entwurf-control");
62
62
  const SOCKET_SUFFIX = ".sock";
@@ -48,7 +48,7 @@ import { fileURLToPath } from "node:url";
48
48
  import { skipLive } from "./lib/live-skip.ts";
49
49
 
50
50
  const REPO_ROOT = resolve(dirname(fileURLToPath(import.meta.url)), "..");
51
- const MODEL = process.env.ENTWURF_ACP_PROVIDER_MODEL?.trim() || "claude-sonnet-5";
51
+ const MODEL = process.env.ENTWURF_ACP_PROVIDER_MODEL?.trim() || "claude-sonnet-5-5";
52
52
  const PROVIDER = "entwurf";
53
53
  const TURN_TIMEOUT_MS = Number(process.env.ENTWURF_ACP_PROVIDER_TIMEOUT_MS) || 240_000;
54
54
 
@@ -44,7 +44,7 @@ import { fileURLToPath } from "node:url";
44
44
  import { skipLive } from "./lib/live-skip.ts";
45
45
 
46
46
  const REPO_ROOT = resolve(dirname(fileURLToPath(import.meta.url)), "..");
47
- const MODEL = process.env.ENTWURF_ACP_LONG_TURN_MODEL?.trim() || "claude-sonnet-5";
47
+ const MODEL = process.env.ENTWURF_ACP_LONG_TURN_MODEL?.trim() || "claude-sonnet-5-5";
48
48
  const PROVIDER = "entwurf";
49
49
 
50
50
  /** The cutoff this cut removed. The turn must outlive it. */
@@ -30,7 +30,7 @@ import { skipLive } from "./lib/live-skip.ts";
30
30
 
31
31
  const REPO_ROOT = resolve(dirname(fileURLToPath(import.meta.url)), "..");
32
32
  const PROBE_SERVER = join(REPO_ROOT, "scripts", "fixtures", "probe-mcp-server.ts");
33
- const MODEL = process.env.ENTWURF_ACP_PROVIDER_MODEL?.trim() || "claude-sonnet-5";
33
+ const MODEL = process.env.ENTWURF_ACP_PROVIDER_MODEL?.trim() || "claude-sonnet-5-5";
34
34
  const PROVIDER = "entwurf";
35
35
  const TURN_TIMEOUT_MS = Number(process.env.ENTWURF_ACP_PROVIDER_TIMEOUT_MS) || 240_000;
36
36
 
@@ -70,7 +70,7 @@ import {
70
70
  import { terminateChild } from "./lib/acp-child-cleanup.ts";
71
71
  import { skipLive } from "./lib/live-skip.ts";
72
72
 
73
- const REQUESTED_MODEL_ID = process.env.ENTWURF_ACP_MEMORY_MODEL ?? "claude-sonnet-5";
73
+ const REQUESTED_MODEL_ID = process.env.ENTWURF_ACP_MEMORY_MODEL ?? "claude-sonnet-5-5";
74
74
  const ALLOW_PATH_FALLBACK = process.env.ENTWURF_ACP_MEMORY_ALLOW_PATH_FALLBACK === "1";
75
75
  const RAW_TAIL_CAP = 64 * 1024;
76
76
 
@@ -93,7 +93,7 @@ const SHIM_RUNTIME_FILES: readonly string[] = [
93
93
  join(REPO_ROOT, "scripts", "lib", "probe-cli-target.ts"),
94
94
  join(REPO_ROOT, "scripts", "lib", "probe-event-log.ts"),
95
95
  ];
96
- const MODEL_ID = process.env.ENTWURF_ACP_PROBE_MODEL?.trim() || "claude-sonnet-5";
96
+ const MODEL_ID = process.env.ENTWURF_ACP_PROBE_MODEL?.trim() || "claude-sonnet-5-5";
97
97
  const D1_MS = Number(process.env.PROBE_D1_MS ?? "2000") || 2000;
98
98
  const D2_MS = Number(process.env.PROBE_D2_MS ?? "8000") || 8000;
99
99
  const TEXT_TAIL_CAP = 400;
@@ -57,7 +57,7 @@ import {
57
57
  import { terminateChild } from "./lib/acp-child-cleanup.ts";
58
58
  import { skipLive } from "./lib/live-skip.ts";
59
59
 
60
- const REQUESTED_MODEL_ID = process.env.ENTWURF_ACP_OVERLAY_MODEL ?? "claude-sonnet-5";
60
+ const REQUESTED_MODEL_ID = process.env.ENTWURF_ACP_OVERLAY_MODEL ?? "claude-sonnet-5-5";
61
61
  const ALLOW_PATH_FALLBACK = process.env.ENTWURF_ACP_OVERLAY_ALLOW_PATH_FALLBACK === "1";
62
62
  const RAW_TAIL_CAP = 64 * 1024;
63
63
 
@@ -29,7 +29,7 @@ import { fileURLToPath } from "node:url";
29
29
  import { skipLive } from "./lib/live-skip.ts";
30
30
 
31
31
  const REPO_ROOT = resolve(dirname(fileURLToPath(import.meta.url)), "..");
32
- const MODEL = process.env.ENTWURF_ACP_PROVIDER_MODEL?.trim() || "claude-sonnet-5";
32
+ const MODEL = process.env.ENTWURF_ACP_PROVIDER_MODEL?.trim() || "claude-sonnet-5-5";
33
33
  const PROVIDER = "entwurf";
34
34
  const TURN_TIMEOUT_MS = Number(process.env.ENTWURF_ACP_PROVIDER_TIMEOUT_MS) || 240_000;
35
35
 
@@ -36,7 +36,7 @@ import { connectAcpClient } from "../pi-extensions/lib/acp/acp-client.ts";
36
36
  import { terminateChild } from "./lib/acp-child-cleanup.ts";
37
37
  import { skipLive } from "./lib/live-skip.ts";
38
38
 
39
- const REQUESTED_MODEL_ID = process.env.ENTWURF_ACP_RAW_TURN_MODEL ?? "claude-sonnet-5";
39
+ const REQUESTED_MODEL_ID = process.env.ENTWURF_ACP_RAW_TURN_MODEL ?? "claude-sonnet-5-5";
40
40
  const ALLOW_PATH_FALLBACK = process.env.ENTWURF_ACP_RAW_TURN_ALLOW_PATH_FALLBACK === "1";
41
41
  const RAW_TAIL_CAP = 64 * 1024; // cap captured raw NDJSON to 64KB tail on report.
42
42
 
@@ -36,7 +36,7 @@ import { normalizeContext } from "@earendil-works/pi-ai";
36
36
  import { skipLive } from "./lib/live-skip.ts";
37
37
 
38
38
  const REPO_ROOT = resolve(dirname(fileURLToPath(import.meta.url)), "..");
39
- const MODEL = process.env.ENTWURF_ACP_PROVIDER_MODEL?.trim() || "claude-sonnet-5";
39
+ const MODEL = process.env.ENTWURF_ACP_PROVIDER_MODEL?.trim() || "claude-sonnet-5-5";
40
40
  // The pi built-ins the Claude child also exposes natively. pi declares its tool surface on
41
41
  // every turn, and since 0.86 that declaration reaches a provider as the leading system
42
42
  // message's `toolsAdded` (`normalizeContext`), which backend.ts replays for the exclude-tools
@@ -31,7 +31,7 @@ import { fileURLToPath } from "node:url";
31
31
  import { skipLive } from "./lib/live-skip.ts";
32
32
 
33
33
  const REPO_ROOT = resolve(dirname(fileURLToPath(import.meta.url)), "..");
34
- const MODEL = process.env.ENTWURF_ACP_PROVIDER_MODEL?.trim() || "claude-sonnet-5";
34
+ const MODEL = process.env.ENTWURF_ACP_PROVIDER_MODEL?.trim() || "claude-sonnet-5-5";
35
35
  const PROVIDER = "entwurf";
36
36
  const TURN_TIMEOUT_MS = Number(process.env.ENTWURF_ACP_PROVIDER_TIMEOUT_MS) || 240_000;
37
37
 
@@ -20,7 +20,7 @@
20
20
  // LIVE-only (spawns a real pi + opens a real socket) — kept OUT of `pnpm check`;
21
21
  // honest skip when LIVE!=1 (skip = CI safety, NOT an acceptance PASS).
22
22
  // LIVE=1 ./run.sh smoke-acp-socket-citizen-live
23
- // override model via ENTWURF_S1_MODEL (default claude-opus-5).
23
+ // override model via ENTWURF_S1_MODEL (default claude-opus-5-5).
24
24
 
25
25
  import { type ChildProcess, spawn } from "node:child_process";
26
26
  import { existsSync } from "node:fs";
@@ -35,7 +35,7 @@ import { skipLive } from "./lib/live-skip.ts";
35
35
  import { PI_BOOT_TIMEOUT_MS, waitForPiRecord } from "./lib/pi-record-discovery.ts";
36
36
 
37
37
  const ACP_PROVIDER = "entwurf";
38
- const ACP_MODEL = process.env.ENTWURF_S1_MODEL?.trim() || "claude-opus-5";
38
+ const ACP_MODEL = process.env.ENTWURF_S1_MODEL?.trim() || "claude-opus-5-5";
39
39
 
40
40
  const REAL_CONTROL_DIR = path.join(os.homedir(), ".pi", "entwurf-control");
41
41
  const SOCKET_SUFFIX = ".sock";
@@ -89,7 +89,7 @@ import { skipLive } from "./lib/live-skip.ts";
89
89
  import { PI_BOOT_TIMEOUT_MS, waitForPiRecord } from "./lib/pi-record-discovery.ts";
90
90
 
91
91
  const ACP_PROVIDER = "entwurf";
92
- const ACP_MODEL = process.env.ENTWURF_ACP_PROVIDER_MODEL?.trim() || "claude-sonnet-5";
92
+ const ACP_MODEL = process.env.ENTWURF_ACP_PROVIDER_MODEL?.trim() || "claude-sonnet-5-5";
93
93
 
94
94
  const REAL_CONTROL_DIR = path.join(os.homedir(), ".pi", "entwurf-control");
95
95
  const SOCKET_SUFFIX = ".sock";
@@ -74,7 +74,7 @@ const REAL_CONTROL_DIR = path.join(os.homedir(), ".pi", "entwurf-control");
74
74
  const SOCKET_SUFFIX = ".sock";
75
75
 
76
76
  const GPT_TARGET = process.env.ENTWURF_CHAIN_GPT_TARGET?.trim() || "openai-codex/gpt-5.6-luna";
77
- const ACP_TARGET = process.env.ENTWURF_CHAIN_ACP_TARGET?.trim() || "entwurf/claude-sonnet-5";
77
+ const ACP_TARGET = process.env.ENTWURF_CHAIN_ACP_TARGET?.trim() || "entwurf/claude-sonnet-5-5";
78
78
  const BOOT_TIMEOUT_MS = 45_000;
79
79
  const CLAUDE_TURN_TIMEOUT_MS = Number(process.env.ENTWURF_CHAIN_CLAUDE_TIMEOUT_MS) || 240_000;
80
80
  const CHAIN_TIMEOUT_MS = Number(process.env.ENTWURF_CHAIN_TIMEOUT_MS) || 420_000;
@@ -109,7 +109,7 @@ const BRIDGE_LAUNCHER = path.join(REPO, "mcp", "entwurf-bridge", "start.sh");
109
109
  /** The two pi shapes. They differ in exactly one thing that matters here — whether the record
110
110
  * carries `provider=entwurf`, which is what makes the resume argv re-inject the bridge (#29). */
111
111
  const PI_NATIVE_MODEL = "openai-codex/gpt-6-luna";
112
- const PI_ACP_MODEL = "entwurf/claude-sonnet-5";
112
+ const PI_ACP_MODEL = "entwurf/claude-sonnet-5-5";
113
113
  const CLAUDE_MODEL = "claude-sonnet-5";
114
114
 
115
115
  // Bounded waits — harness-side only. Each names what it is waiting FOR, so a red run says which