| ... | ... | @@ -9,11 +9,7 @@ import * as CodexErrors from "effect-codex-app-server/errors"; |
| 9 | 9 | import * as CodexRpc from "effect-codex-app-server/rpc"; |
| 10 | 10 | import * as EffectCodexSchema from "effect-codex-app-server/schema"; |
| 11 | 11 | |
| 12 | | import { |
| 13 | | buildCodexDeveloperInstructions, |
| 14 | | codexDefaultModeDeveloperInstructions, |
| 15 | | codexPlanModeDeveloperInstructions, |
| 16 | | } from "../CodexDeveloperInstructions.ts"; |
| 12 | import { buildCodexDeveloperInstructions } from "../CodexDeveloperInstructions.ts"; |
| 17 | 13 | import { codexSessionAppServerArgs } from "./codexLaunchArgs.ts"; |
| 18 | 14 | import { |
| 19 | 15 | buildTurnStartParams, |
| ... | ... | @@ -459,7 +455,7 @@ describe("buildCodexDeveloperInstructions", () => { |
| 459 | 455 | reasoningEffort: "high", |
| 460 | 456 | }); |
| 461 | 457 | |
| 462 | | NodeAssert.ok(instructions.startsWith(codexDefaultModeDeveloperInstructions(true))); |
| 458 | NodeAssert.match(instructions, /^<collaboration_mode># Collaboration Mode: Default/); |
| 463 | 459 | NodeAssert.match(instructions, /T3 Code/); |
| 464 | 460 | NodeAssert.match(instructions, /Codex harness/); |
| 465 | 461 | NodeAssert.match(instructions, /as gpt-5\.3-codex with high reasoning effort/); |
| ... | ... | @@ -484,7 +480,7 @@ describe("buildCodexDeveloperInstructions", () => { |
| 484 | 480 | reasoningEffort: "medium", |
| 485 | 481 | }); |
| 486 | 482 | |
| 487 | | NodeAssert.ok(instructions.startsWith(codexPlanModeDeveloperInstructions(true))); |
| 483 | NodeAssert.match(instructions, /^<collaboration_mode># Plan Mode/); |
| 488 | 484 | NodeAssert.match(instructions, /as gpt-5\.3-codex with medium reasoning effort/); |
| 489 | 485 | }); |
| 490 | 486 | |
| ... | ... | @@ -513,11 +509,11 @@ describe("buildCodexDeveloperInstructions", () => { |
| 513 | 509 | }); |
| 514 | 510 | |
| 515 | 511 | describe("T3 browser developer instructions", () => { |
| 512 | const runtime = { model: "gpt-5.3-codex", reasoningEffort: "high" }; |
| 513 | |
| 516 | 514 | it("prefers the product-native preview tools in both collaboration modes", () => { |
| 517 | | for (const instructions of [ |
| 518 | | codexDefaultModeDeveloperInstructions(true), |
| 519 | | codexPlanModeDeveloperInstructions(true), |
| 520 | | ]) { |
| 515 | for (const mode of ["default", "plan"] as const) { |
| 516 | const instructions = buildCodexDeveloperInstructions(mode, runtime, true); |
| 521 | 517 | NodeAssert.match(instructions, /t3-code/); |
| 522 | 518 | NodeAssert.match(instructions, /preview_status/); |
| 523 | 519 | NodeAssert.match(instructions, /preview_open/); |
| ... | ... | @@ -526,10 +522,8 @@ describe("T3 browser developer instructions", () => { |
| 526 | 522 | }); |
| 527 | 523 | |
| 528 | 524 | it("omits the browser block entirely when the preview tools are not attached", () => { |
| 529 | | for (const instructions of [ |
| 530 | | codexDefaultModeDeveloperInstructions(false), |
| 531 | | codexPlanModeDeveloperInstructions(false), |
| 532 | | ]) { |
| 525 | for (const mode of ["default", "plan"] as const) { |
| 526 | const instructions = buildCodexDeveloperInstructions(mode, runtime, false); |
| 533 | 527 | NodeAssert.doesNotMatch(instructions, /preview_status/); |
| 534 | 528 | NodeAssert.doesNotMatch(instructions, /preview_open/); |
| 535 | 529 | NodeAssert.doesNotMatch(instructions, /T3 Code collaborative browser/); |
| ... | ... | @@ -543,7 +537,6 @@ describe("T3 browser developer instructions", () => { |
| 543 | 537 | }); |
| 544 | 538 | |
| 545 | 539 | it("tracks the turn's MCP configuration rather than defaulting to on", () => { |
| 546 | | const runtime = { model: "gpt-5.3-codex", reasoningEffort: "high" }; |
| 547 | 540 | NodeAssert.match(buildCodexDeveloperInstructions("default", runtime, true), /preview_open/); |
| 548 | 541 | NodeAssert.doesNotMatch( |
| 549 | 542 | buildCodexDeveloperInstructions("default", runtime, false), |