浏览代码

Fix: set output for Message template (#8064)

### What problem does this PR solve?
now Streamning logic is not match with none streaming logic, which may
introduce down stream can not find upstream components.

### Type of change

- [x] Bug Fix (non-breaking change which fixes an issue)
tags/v0.19.1
Stephen Hu 4 个月前
父节点
当前提交
640fca7dc9
没有帐户链接到提交者的电子邮件
共有 1 个文件被更改,包括 3 次插入1 次删除
  1. 3
    1
      agent/component/message.py

+ 3
- 1
agent/component/message.py 查看文件

@@ -40,7 +40,9 @@ class Message(ComponentBase, ABC):
if kwargs.get("stream"):
return partial(self.stream_output)

return Message.be_output(random.choice(self._param.messages))
res = Message.be_output(random.choice(self._param.messages))
self.set_output(res)
return res

def stream_output(self):
res = None

正在加载...
取消
保存