mirror of https://github.com/langgenius/dify.git
Merge 67c0ec030f into 2c919efa69
This commit is contained in:
commit
c5eef62ac4
|
|
@ -35,6 +35,7 @@ from core.workflow.node_events import (
|
|||
AgentLogEvent,
|
||||
NodeEventBase,
|
||||
NodeRunResult,
|
||||
RunRetrieverResourceEvent,
|
||||
StreamChunkEvent,
|
||||
StreamCompletedEvent,
|
||||
)
|
||||
|
|
@ -670,6 +671,11 @@ class AgentNode(Node[AgentNodeData]):
|
|||
agent_logs.append(agent_log)
|
||||
|
||||
yield agent_log
|
||||
elif message.type == ToolInvokeMessage.MessageType.RETRIEVER_RESOURCES:
|
||||
assert isinstance(message.message, ToolInvokeMessage.RetrieverResourceMessage)
|
||||
retriever_resources = message.message.retriever_resources
|
||||
context_str = message.message.context
|
||||
yield RunRetrieverResourceEvent(retriever_resources=retriever_resources, context=context_str)
|
||||
|
||||
# Add agent_logs to outputs['json'] to ensure frontend can access thinking process
|
||||
json_output: list[dict[str, Any]] = []
|
||||
|
|
|
|||
Loading…
Reference in New Issue