mirror of
https://github.com/openclaw/openclaw.git
synced 2026-03-30 11:21:07 +00:00
fix(agents): pass replay transcript policy
Regeneration-Prompt: | After fixing the replay sanitizer helper itself, a follow-up review comment pointed out that runEmbeddedAttempt was still installing wrapStreamFnSanitizeMalformedToolCalls without the active transcriptPolicy. That meant the new Anthropic and Gemini replay recovery paths only ran in direct helper tests, not in the live embedded runner. Update the stream wrapper installation site to pass transcriptPolicy through unchanged so the already-tested replay cleanup, pairing repair, and turn revalidation logic actually executes in production replays. Keep the change scoped to the call site and verify the replay sanitizer test file still passes after the edit.
This commit is contained in:
@@ -2334,6 +2334,7 @@ export async function runEmbeddedAttempt(
|
||||
activeSession.agent.streamFn = wrapStreamFnSanitizeMalformedToolCalls(
|
||||
activeSession.agent.streamFn,
|
||||
allowedToolNames,
|
||||
transcriptPolicy,
|
||||
);
|
||||
activeSession.agent.streamFn = wrapStreamFnTrimToolCallNames(
|
||||
activeSession.agent.streamFn,
|
||||
|
||||
Reference in New Issue
Block a user