Skip to content

fix(reply): steer active embedded Pi runs between streams - #75226

Closed
howardclaw26 wants to merge 1 commit into
openclaw:mainfrom
howardclaw26:howard/ddx-steer-active-not-streaming
Closed

howardclaw26 wants to merge 1 commit into
openclaw:mainfrom
howardclaw26:howard/ddx-steer-active-not-streaming

Conversation

@howardclaw26

Copy link
Copy Markdown

Summary

  • steer active embedded Pi runs while the run is active even when it is between stream chunks
  • classify normal active-run steering as toolCallSteeringBehavior: "inject"
  • classify stop-like/abort steering through isAbortRequestText(...) as "interrupt"
  • enable Pi tool-boundary interrupt checkpoints up front, with a typed forward-compat seam until the paired @mariozechner/pi-agent-core API is published
  • fall back to follow-up queue if active-run steering cannot be delivered

Related issues

Verification

  • node scripts/run-vitest.mjs run src/agents/pi-embedded-runner/runs.test.ts src/auto-reply/reply/agent-runner.media-paths.test.ts — 33 tests passed
  • PATH=/tmp/openclaw-realbin:/etc/profiles/per-user/openclaw/bin:/run/current-system/sw/bin:/usr/bin:/bin /etc/profiles/per-user/openclaw/bin/corepack pnpm check:changed — passed
  • clawctl verify raw via OpenCode — PASS: /home/openclaw/.openclaw/workspace/tmp/steering-verifiers-20260430/current/openclaw.opencode.final.md
  • clawctl verify raw via Cursor — PASS: /home/openclaw/.openclaw/workspace/tmp/steering-verifiers-20260430/current/openclaw.cursor.final.md

Dependency note

This is paired with a local badlogic/pi-mono branch openclaw-steering-tool-boundary that adds toolCallSteeringBehavior support to @mariozechner/pi-agent-core. The current published SDK is 0.70.6, so this PR keeps the OpenClaw side as an explicit typed forward-compat seam until the Pi change is available.

@openclaw-barnacle openclaw-barnacle Bot added agents Agent runtime and tooling size: S labels Apr 30, 2026
@clawsweeper

clawsweeper Bot commented Apr 30, 2026 •

Copy link
Copy Markdown
Contributor

Thanks for the context here. I swept through the related work, and this is now duplicate or superseded.

Close as superseded: the active non-streaming steer fix is already covered by the open maintainer-labeled replacement PR, while this branch is conflicting and still has a merge-blocking behavior issue in its forward-compatible Pi steering setter default.

So I’m closing this here and keeping the remaining discussion on the canonical linked item.

Review details

Best possible solution:

Review and land or replace the focused maintainer PR for active non-streaming steering, and keep broader stop/tool-boundary interrupt behavior in the canonical interruptibility tracker.

Do we have a high-confidence way to reproduce the issue?

Yes. The current-main failure is source-reproducible through runReplyAgent requiring isStreaming for steering and queueEmbeddedPiMessage rejecting non-streaming embedded handles; the PR's introduced regression is source-reproducible by following callers that omit toolCallSteeringBehavior into the session-wide interrupt default.

Is this the best way to solve the issue?

No, not as this PR. The safer path is the open lifecycle-aware maintainer PR for the active non-streaming fix, with any new Pi tool-boundary interrupt contract handled through the broader interruptibility tracker after upstream API validation.

Security review:

Security review cleared: The diff changes runtime steering behavior and tests only; I found no dependency, workflow, secret, download, permission, or publishing change.

What I checked:

Likely related people:

  • vincentkoc: Authored the open maintainer-labeled replacement PR covering active non-streaming steer delivery in the same reply and embedded-run files, and recent GitHub file history shows adjacent gateway/active-run work. (role: likely follow-up owner; confidence: high; commits: b29ea4e33486, 4a30ae182b6a, ec1f72b6c58f; files: src/auto-reply/reply/agent-runner.ts, src/agents/pi-embedded-runner/runs.ts, src/agents/pi-embedded-runner/run/attempt.ts)
  • fuller-stack-dev: GitHub file history shows commit 70df2b8 changed default mid-turn steering, active-run queueing, and subagent steering around the same runtime path. (role: recent active-run steering contributor; confidence: high; commits: 70df2b8fe28d; files: src/auto-reply/reply/agent-runner.ts, src/agents/pi-embedded-runner/runs.ts)
  • obviyus: Current-line blame for the reply steering gate, embedded queue preparation, and queue handle setup points to commit 2d3f3de, which refactored the gateway/session bootstrap around this surface. (role: recent area contributor; confidence: medium; commits: 2d3f3de23549; files: src/auto-reply/reply/agent-runner.ts, src/agents/pi-embedded-runner/runs.ts, src/agents/pi-embedded-runner/run/attempt.ts)
  • steipete: Recent GitHub file history shows active-run queue failure reason, batched steering default, stale lane recovery, and reply lifecycle changes in the same files and neighboring registry paths. (role: recent adjacent owner; confidence: medium; commits: 1ed50b0ced62, 30a2b3049ae0, c500e8704f4e; files: src/auto-reply/reply/agent-runner.ts, src/agents/pi-embedded-runner/runs.ts, src/auto-reply/reply/reply-run-registry.ts)

Codex review notes: model gpt-5.5, reasoning high; reviewed against a504cd0190b9.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agents Agent runtime and tooling size: S

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant