SmythOS Agents Integration
Want to build complex, multi-layered agents without reinventing the wheel? Connect SmythOS Agents to each other to create powerful, modular, and scalable automations.
List of SmythOS Agent Componentsβ
The integration provides one powerful component for connecting agents together.
Component | Action | What it Does | Inputs | Key Outputs | Use Case |
---|---|---|---|---|---|
SmythOS Agent | Execute Agent | Runs another SmythOS agent as a sub-task and returns its result. | required prompt | Response | Creating a "manager" agent that delegates tasks. |
Prerequisitesβ
Before you begin, please ensure you have the following:
- An active SmythOS account. (Sign up here).
- At least one existing SmythOS agent that can be used as a subagent (the agent being called).
- A second SmythOS agent to act as the parent agent (the agent that will do the calling).
Getting Started With Subagentsβ
The process involves configuring a parent agent to call a subagent.
Step 1: Create Your Specialized Subagentβ
First, build and test an agent that performs a specific, reusable task. For example, create an agent named "Sentiment Analyzer" that takes a piece of text as input and outputs "Positive," "Negative," or "Neutral."
Step 2: Create Your Parent Agentβ
Next, create the agent that will orchestrate the work. For example, an agent named "Customer Feedback Processor."
Step 3: Add and Configure the SmythOS Agent Componentβ
- In your parent agent's graph ("Customer Feedback Processor"), drag and drop the SmythOS Agent component from the component library.
- Click the component to open its Settings panel.
- From the dropdown list, select the subagent you want to call (e.g., "Sentiment Analyzer").
- Configure the
Version
settings to determine if you want to call theDev
orProd
version of the subagent.
Which Component Should I Use?β
If you need to⦠| Use this Component | Why? |
---|---|---|
Make one agent perform the task of another agent | SmythOS Agent | This is the dedicated component for creating parent-child relationships between agents. |
Component Detailsβ
This section provides detailed information for the SmythOS Agent component.
SmythOS Agentβ
Executes a specified "subagent" as part of the current agent's workflow, passing a prompt to it and receiving its final response.
Component-Specific Settingsβ
- Model: Choose the AI model the parent agent will use to reason about how and when to call the subagent.
- Version:
Same As Parent
: If the parent is inDev
, it calls theDev
subagent. IfProd
, it callsProd
.Dev
: Always calls theDev
version of the subagent, useful for testing.Prod Latest
: Always calls the latestProd
version of the subagent, ensuring stability.
- Description for Model: A description of what the subagent does. This is pre-filled from the subagent's
Behavior
field but can be edited. This text helps the parent agent's AI understand the subagent's capabilities.
Inputsβ
Field | Type | Required | Notes |
---|---|---|---|
prompt | string | Yes | The instruction or data passed from the parent agent to the subagent. |
Outputsβ
Field | Type | Description |
---|---|---|
Response | any | The final output returned by the subagent. The data type depends on what the subagent is designed to produce. |
{
"component": "smythos.agent",
"prompt": "Please analyze the sentiment of the following customer feedback: 'The new feature is incredible and so easy to use!'"
}
Best Practices & Advanced Tipsβ
- Design for Modularity: Build subagents that are highly specialized and do one thing exceptionally well. A good subagent is like a good function in programming: reliable, predictable, and reusable.
- Write Clear Descriptions: The "Description for Model" setting is vital. Write a clear, concise description of the subagent's purpose, inputs, and outputs. This helps the parent agent's AI make better decisions about when and how to use the subagent.
- Manage Versions: Thoroughly test your subagents in their
Dev
environment. Only promote a subagent toProd
when it is stable. In your parent agent, use theDev
version setting for testing and switch toProd Latest
for your live workflows. - Standardize Inputs/Outputs: For easier interoperability, design your subagents to accept and return data in a consistent format, such as JSON.
Troubleshooting Common Issuesβ
-
Subagent Fails to Execute
- Cause: The subagent itself might have an error, or the parent agent might be passing an improperly formatted prompt.
- Solution: Check the execution history of the subagent directly. Its logs will contain the specific error message. Verify that the data being passed in the
prompt
from the parent matches what the subagent expects.
-
Incorrect Output from Subagent
- Cause: The
prompt
from the parent agent may be ambiguous, or the logic within the subagent may be flawed. You might also be calling the wrong version (Dev
vs.Prod
). - Solution: First, check the
Version
setting in the parent component. Ensure you are targeting the correct subagent version. Then, simplify theprompt
to be as clear as possible. If the issue persists, debug the subagent's internal logic.
- Cause: The
-
Infinite Loops
- Cause: Agent A calls Agent B, and Agent B calls Agent A, creating a recursive loop.
- Solution: Carefully map out your agent architecture. Avoid circular dependencies where agents call each other in a way that could lead to an infinite loop.
What's Next?β
You are now ready to build sophisticated, multi-agent systems with the SmythOS Agents Integration!
Consider these ideas:
-
Build an Agent That...
- Acts as a "Project Manager." It receives a high-level goal, breaks it down into tasks, and then calls different specialized subagents (a "Research Agent," a "Writing Agent," a "Publishing Agent") to complete each task in sequence.
- Functions as a customer service dispatcher. It receives all incoming messages, uses a "Language Detection Subagent," a "Sentiment Analysis Subagent," and a "Topic Classification Subagent" to triage the message, and finally routes it to the correct human department.
-
Explore Other Integrations:
- A parent agent can fetch data from a Google Sheet, then use a
Loop
component to pass each row to a subagent for individual processing. - A subagent could be dedicated to a specific integration, like Ahrefs. This "Ahrefs Specialist" agent could be called by any parent agent that needs to perform SEO analysis.
- A parent agent can fetch data from a Google Sheet, then use a