FlowiseAI / Flowise

Drag & drop UI to build your customized LLM flow
https://flowiseai.com
Apache License 2.0
31.71k stars 16.54k forks source link

[BUG] Multi-agent Workers don't access Supervisor instructions #3512

Open taras-svystun opened 1 week ago

taras-svystun commented 1 week ago

Describe the bug

In a multi-agent setup using agentflow, the workers rely solely on chat history and do not access Supervisor instructions.

To Reproduce

Refer to the attached agentflow, which consists of a simple multi-agent system: one worker (dishes_browser_agent) displays dishes, while another (make_order_agent) handles orders. image

Expected behavior

When a user enters a query such as "I want something Jamaican/Canadian/etc.," the Supervisor directs the dishes_browser worker, which generates three relevant dishes.

For a specific case: If the user input is "I want something Italian," it should be interpreted as a request for Japanese dishes. The Supervisor’s instruction correctly specifies "Retrieve Japanese dishes ...," but the dishes_browser worker outputs Italian dishes instead. It seems that Supervisor instructions are not accessible to the workers.

Screenshots

Ordinary flow:

image

Special case with "I want something Italian."

image

Flow

Refer to the attached agentflow.

Setup

I would appreciate any support. Thanks!

simple-multi-agent Agents.json

HenryHengZJ commented 1 week ago

This is the behaviour by design, workers are the lowest level, and they do not have context about supervisor instruction, this is because workers are designed to only execute the task given by supervisor: https://docs.flowiseai.com/using-flowise/agentflows/multi-agents#id-1.-system-architecture

taras-svystun commented 4 days ago

Thanks for the answer, @HenryHengZJ.

"workers are designed to only execute the task given by supervisor". How (if the workers do not have context about supervisor instruction)?

From my example the worker doesn't seem to execute the task given by supervisor.