openclaw - 💡(How to fix) Fix /steer command doesn't actually inject into active run — queues for next turn instead

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…

The /steer command is documented in the Control UI and help text as:

"Inject a message into the active run" / "Send guidance to the active run in this session"

But in practice, /steer does not inject into the currently streaming turn. It queues the message via turn/steer protocol, and the message only takes effect when the current turn completes — i.e., the next turn. By the time the current turn finishes naturally, the user could just send a normal message, making /steer useless for its intended purpose.

Root Cause

The steering flow is:

  1. handleSteerCommand()queueEmbeddedPiMessageWithOutcomeAsync()
  2. handle.queueMessage(text)activeSteeringQueue.queue(text)
  3. client.request("turn/steer", { threadId, expectedTurnId, input })

The turn/steer protocol message is sent to Codex App Server, but the LLM API does not support mid-stream prompt injection. The handle registered at run-attempt line ~4000 shows:

const handle = {
    queueMessage: async (text, options) => activeSteeringQueue.queue(text, options),
    isStreaming: () => !completed,
};

queueMessage merely batches and sends turn/steer, which the app-server can only apply to the next turn. There is no abort-and-restart logic in this path.

By contrast, /subagents steer does properly abort the subagent run and restart with the new message (via abortEmbeddedPiRun + agent.wait + new agent message). But /steer for the current session lacks this abort-restart behavior.

Code Example

const handle = {
    queueMessage: async (text, options) => activeSteeringQueue.queue(text, options),
    isStreaming: () => !completed,
};
RAW_BUFFERClick to expand / collapse

Description

The /steer command is documented in the Control UI and help text as:

"Inject a message into the active run" / "Send guidance to the active run in this session"

But in practice, /steer does not inject into the currently streaming turn. It queues the message via turn/steer protocol, and the message only takes effect when the current turn completes — i.e., the next turn. By the time the current turn finishes naturally, the user could just send a normal message, making /steer useless for its intended purpose.

Expected Behavior

/steer "focus on X" should interrupt the current LLM streaming and restart the turn with the steer message injected, so the model responds to the guidance immediately without waiting for the current (potentially long) generation to finish.

Actual Behavior

/steer "focus on X" queues the message and waits until the current turn completes. The steer message only appears in the next turn context. If the current run is generating a long response, the steer is delayed until generation naturally ends.

Root Cause Analysis

The steering flow is:

  1. handleSteerCommand()queueEmbeddedPiMessageWithOutcomeAsync()
  2. handle.queueMessage(text)activeSteeringQueue.queue(text)
  3. client.request("turn/steer", { threadId, expectedTurnId, input })

The turn/steer protocol message is sent to Codex App Server, but the LLM API does not support mid-stream prompt injection. The handle registered at run-attempt line ~4000 shows:

const handle = {
    queueMessage: async (text, options) => activeSteeringQueue.queue(text, options),
    isStreaming: () => !completed,
};

queueMessage merely batches and sends turn/steer, which the app-server can only apply to the next turn. There is no abort-and-restart logic in this path.

By contrast, /subagents steer does properly abort the subagent run and restart with the new message (via abortEmbeddedPiRun + agent.wait + new agent message). But /steer for the current session lacks this abort-restart behavior.

Suggested Fix

For native Pi embedded runs, /steer should abort the current LLM streaming and restart with the steer message injected into the context, similar to how /subagents steer works. Specifically:

  1. Abort the current turn (call runAbortController.abort("steered"))
  2. Wait for abort to settle
  3. Re-send the original prompt + steer message as a new turn
  4. Or alternatively, implement turn/steer handling in the app-server that actually aborts and restarts

Version

OpenClaw 2026.5.18

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

openclaw - 💡(How to fix) Fix /steer command doesn't actually inject into active run — queues for next turn instead