fix(acp): deliver final_response after streaming — transform_llm_output hook now visible
When streaming is active, streamed_message=True skipped the final_response update, causing plugin hooks like transform_llm_output to be silently invisible. Remove the `not streamed_message` guard so the final response (possibly transformed by plugins) is always delivered to the ACP client.
This commit is contained in:
@@ -1534,7 +1534,9 @@ class HermesACPAgent(acp.Agent):
|
|||||||
)
|
)
|
||||||
except Exception:
|
except Exception:
|
||||||
logger.debug("Failed to auto-title ACP session %s", session_id, exc_info=True)
|
logger.debug("Failed to auto-title ACP session %s", session_id, exc_info=True)
|
||||||
if final_response and conn and not streamed_message:
|
if final_response and conn:
|
||||||
|
# Always deliver the final response — plugins may have transformed
|
||||||
|
# it after streaming finished (e.g. transform_llm_output hook).
|
||||||
update = acp.update_agent_message_text(final_response)
|
update = acp.update_agent_message_text(final_response)
|
||||||
await conn.session_update(session_id, update)
|
await conn.session_update(session_id, update)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user