fix(cli): remove tool round limit in ResponsesReplySource

cd28d0ff688e · AtlantisPleb · · parent 6efdb61ceb91

fix(cli): remove tool round limit in ResponsesReplySource

Deploy story

What this commit did to the running system — joined from the forge receipt chain, the part a commit page elsewhere cannot show.

Not deployed through the forge lane

No push, promotion, build, or deploy receipt references this commit (receipts are scanned over a bounded recent window). Changes shipped by full node replacement carry their proof in the release gate receipt instead.

Changed files

  • modified packages/openagents-cli/src/coder-responses.ts

Diff

1 file changed, +1 -12

packages/openagents-cli/src/coder-responses.ts modified +1 -12

@@ -51,12 +51,6 @@ interface Call {

51 51
  readonly args: string;
52 52
}
53 53
54
/**
55
 * Rounds of tool calls one turn may take before it must answer. A backstop
56
 * against a loop, not a budget; the reader can stop a turn at any time.
57
 */
58
const MAX_TOOL_ROUNDS = 24;
59
60 54
export class ResponsesReplySource implements ReplySource {
61 55
  private readonly items: Item[] = [];
62 56
  private tools: ReadonlyArray<CoderTool> = [];

@@ -89,7 +83,7 @@ export class ResponsesReplySource implements ReplySource {

89 83
    this.items.push({ role: "user", content: prompt });
90 84
    let calls = 0;
91 85
92
    for (let round = 0; round < MAX_TOOL_ROUNDS; round += 1) {
86
    for (;;) {
93 87
      calls += 1;
94 88
      const { text, requested } = yield* this.once(signal);
95 89
      if (text !== "") this.items.push({ role: "assistant", content: text });

@@ -121,11 +115,6 @@ export class ResponsesReplySource implements ReplySource {

121 115
      }
122 116
    }
123 117
124
    yield {
125
      type: "text",
126
      value: `\n\nStopped after ${String(MAX_TOOL_ROUNDS)} rounds of tool calls without an answer.`,
127
    };
128
    yield { type: "usage", calls };
129 118
  }
130 119
131 120
  /**

This page updates live while a promote is in flight · changelog