Template Techniques
Subagents
Explains how to split work between a main conversational agent and specialised subagents on their own chats on the same stub.
In some more complex use cases it becomes necessary to split functions between two or even more agents on the same stub.
There would be the main conversational agent running on the stub under the chat name main and then named Subagents on their own chat names.
Key functionality
- each subagent has its own defined chat name on the gpt chat task
- each subagent has its own custom feedback action defined under
assistant_response_action_name, which is set on its gpt task params, this action is defined and added to the_allstate - the custom feedback action injects the responses from the subagent into the main chat as a system message relaying the response
- all AI enabled actions have explicit availability for chat names so that each agent has access to defined actions
- each subagent has its own specialized system prompt
- subagents have access to specialized tool actions (via chat name availability) for carrying out their area of specialization
- the main conversational agent has an action to chat to the subagent, which appends the message to the subagent
- the chat to subagent action has a checkbox field that allows starting a new conversation