|
@@ -1677,7 +1677,7 @@ unix(
|
|
|
|
|
|
|
|
yield* llm.tool("bash", {
|
|
yield* llm.tool("bash", {
|
|
|
command:
|
|
command:
|
|
|
- 'i=0; while [ "$i" -lt 4000 ]; do printf "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx %05d\\n" "$i"; i=$((i + 1)); done; sleep 30',
|
|
|
|
|
|
|
+ 'i=0; while [ "$i" -lt 4000 ]; do printf "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx %05d\\n" "$i"; i=$((i + 1)); done; printf truncation-ready; sleep 30',
|
|
|
description: "Print many lines",
|
|
description: "Print many lines",
|
|
|
timeout: 30_000,
|
|
timeout: 30_000,
|
|
|
workdir: path.resolve(dir),
|
|
workdir: path.resolve(dir),
|
|
@@ -1685,7 +1685,15 @@ unix(
|
|
|
|
|
|
|
|
const run = yield* prompt.loop({ sessionID: chat.id }).pipe(Effect.forkChild)
|
|
const run = yield* prompt.loop({ sessionID: chat.id }).pipe(Effect.forkChild)
|
|
|
yield* llm.wait(1)
|
|
yield* llm.wait(1)
|
|
|
- yield* Effect.sleep(150)
|
|
|
|
|
|
|
+ yield* pollWithTimeout(
|
|
|
|
|
+ Effect.gen(function* () {
|
|
|
|
|
+ const msgs = yield* MessageV2.filterCompactedEffect(chat.id)
|
|
|
|
|
+ const assistant = msgs.findLast((item) => item.info.role === "assistant")
|
|
|
|
|
+ const tool = assistant ? toolPart(assistant.parts) : undefined
|
|
|
|
|
+ if (tool?.state.status === "running" && tool.state.metadata?.output.includes("truncation-ready")) return true
|
|
|
|
|
+ }),
|
|
|
|
|
+ "timed out waiting for truncated shell output",
|
|
|
|
|
+ )
|
|
|
yield* prompt.cancel(chat.id)
|
|
yield* prompt.cancel(chat.id)
|
|
|
|
|
|
|
|
const exit = yield* Fiber.await(run)
|
|
const exit = yield* Fiber.await(run)
|