Overview

The Manager Agent architecture in Lyzr allows for modular, composable workflows where one agent (the manager) can coordinate and delegate tasks to multiple other specialized agents (called managed agents). This enables powerful, flexible automation where complex multi-step operations can be executed efficiently by splitting responsibilities between agents.

For example, in a fitness assistant setup:

  • The main agent provides personalized fitness advice.
  • A managed agent like Mail Generator can take the generated diet plan or fitness routine and email it to the user.

How It Works

Structure in Agent JSON

In the agent JSON configuration, the managed_agents field is used to declare and reference one or more agents that the main agent can call to perform specific sub-tasks.

"managed_agents": [
  {
    "id": "67f632f43e4bcae4a5cfd109",
    "name": "Mail Generator",
    "usage_description": "Generate a proper diet plan and mail it to the user, whenever the user starts to chat ask for their mail ID 1st"
  }
]

Fields Breakdown

FieldTypeDescription
idstringUnique identifier of the managed agent (retrieved from the Lyzr Agent database).
namestringHuman-readable name of the agent for referencing and understanding purpose.
usage_descriptionstringDescription of how and when to invoke this agent. Acts as a system-level guide to help orchestrate agent responsibilities.