





















@@ -11,6 +11,7 @@ import {
1111resetRunOverflowCompactionHarnessMocks,
1212} from "./run.overflow-compaction.harness.js";
1313import {
14+ACK_EXECUTION_FAST_PATH_INSTRUCTION,
1415buildAttemptReplayMetadata,
1516DEFAULT_EMPTY_RESPONSE_RETRY_LIMIT,
1617DEFAULT_REASONING_ONLY_RETRY_LIMIT,
@@ -673,6 +674,16 @@ describe("runEmbeddedPiAgent incomplete-turn safety", () => {
673674expect(instruction).toContain("Do not recap or restate the plan");
674675});
675676677+it("applies the ack-turn fast path to Gemini action turns", () => {
678+const instruction = resolveAckExecutionFastPathInstruction({
679+provider: "google",
680+modelId: "gemini-3.1-pro",
681+prompt: "go ahead",
682+});
683+684+expect(instruction).toBe(ACK_EXECUTION_FAST_PATH_INSTRUCTION);
685+});
686+676687it("extracts structured steps from planning-only narration", () => {
677688expect(
678689extractPlanningOnlyPlanDetails(
@@ -1049,6 +1060,21 @@ describe("runEmbeddedPiAgent incomplete-turn safety", () => {
10491060expect(retryInstruction).toContain("Do not restate the plan");
10501061});
105110621063+it("does not enable incomplete-turn recovery for non-Gemini Google models", () => {
1064+const retryInstruction = resolvePlanningOnlyRetryInstruction({
1065+provider: "google",
1066+modelId: "gemma-4-26b-a4b-it",
1067+prompt: "Please inspect the code, make the change, and run the checks.",
1068+aborted: false,
1069+timedOut: false,
1070+attempt: makeAttemptResult({
1071+assistantTexts: ["I'll inspect the code, make the change, and run the checks."],
1072+}),
1073+});
1074+1075+expect(retryInstruction).toBeNull();
1076+});
1077+10521078it("does not misclassify a direct answer that says 'i'm not going to' as planning-only", () => {
10531079const retryInstruction = resolvePlanningOnlyRetryInstruction({
10541080provider: "openai-codex",
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。