parent
38b138c56e
commit
d73f1a68c4
@ -1 +0,0 @@
|
||||
# 5.8.7
|
@ -0,0 +1,90 @@
|
||||
# 🚀 Swarms 5.9.2 Release Notes
|
||||
|
||||
|
||||
### 🎯 Major Features
|
||||
|
||||
#### Concurrent Agent Execution Suite
|
||||
We're excited to introduce a comprehensive suite of agent execution methods to supercharge your multi-agent workflows:
|
||||
|
||||
- `run_agents_concurrently`: Execute multiple agents in parallel with optimal resource utilization
|
||||
- `run_agents_concurrently_async`: Asynchronous execution for improved performance
|
||||
- `run_single_agent`: Streamlined single agent execution
|
||||
- `run_agents_concurrently_multiprocess`: Multi-process execution for CPU-intensive tasks
|
||||
- `run_agents_sequentially`: Sequential execution with controlled flow
|
||||
- `run_agents_with_different_tasks`: Assign different tasks to different agents
|
||||
- `run_agent_with_timeout`: Time-bounded agent execution
|
||||
- `run_agents_with_resource_monitoring`: Monitor and manage resource usage
|
||||
|
||||
### 📚 Documentation
|
||||
- Comprehensive documentation added for all new execution methods
|
||||
- Updated examples and usage patterns
|
||||
- Enhanced API reference
|
||||
|
||||
### 🛠️ Improvements
|
||||
- Tree swarm implementation fixes
|
||||
- Workspace directory now automatically set to `agent_workspace`
|
||||
- Improved error handling and stability
|
||||
|
||||
## Quick Start
|
||||
|
||||
```python
|
||||
from swarms import Agent, run_agents_concurrently, run_agents_with_timeout, run_agents_with_different_tasks
|
||||
|
||||
# Initialize multiple agents
|
||||
agents = [
|
||||
Agent(
|
||||
agent_name=f"Analysis-Agent-{i}",
|
||||
system_prompt="You are a financial analysis expert",
|
||||
llm=model,
|
||||
max_loops=1
|
||||
)
|
||||
for i in range(5)
|
||||
]
|
||||
|
||||
# Run agents concurrently
|
||||
task = "Analyze the impact of rising interest rates on tech stocks"
|
||||
outputs = run_agents_concurrently(agents, task)
|
||||
|
||||
# Example with timeout
|
||||
outputs_with_timeout = run_agents_with_timeout(
|
||||
agents=agents,
|
||||
task=task,
|
||||
timeout=30.0,
|
||||
batch_size=2
|
||||
)
|
||||
|
||||
# Run different tasks
|
||||
task_pairs = [
|
||||
(agents[0], "Analyze tech stocks"),
|
||||
(agents[1], "Analyze energy stocks"),
|
||||
(agents[2], "Analyze retail stocks")
|
||||
]
|
||||
different_outputs = run_agents_with_different_tasks(task_pairs)
|
||||
```
|
||||
|
||||
## Installation
|
||||
```bash
|
||||
pip3 install -U swarms
|
||||
```
|
||||
|
||||
## Coming Soon
|
||||
- 🌟 Auto Swarm Builder: Automatically construct and configure entire swarms from a single task specification (in development)
|
||||
- Auto Prompt Generator for thousands of agents (in development)
|
||||
|
||||
## Community
|
||||
We believe in the power of community-driven development. Help us make Swarms better!
|
||||
|
||||
- ⭐ Star our repository: https://github.com/kyegomez/swarms
|
||||
- 🔄 Fork the project and contribute your improvements
|
||||
- 🤝 Join our growing community of contributors
|
||||
|
||||
## Bug Fixes
|
||||
- Fixed Tree Swarm implementation issues
|
||||
- Resolved workspace directory configuration problems
|
||||
- General stability improvements
|
||||
|
||||
---
|
||||
|
||||
For detailed documentation and examples, visit our [GitHub repository](https://github.com/kyegomez/swarms).
|
||||
|
||||
Let's build the future of multi-agent systems together! 🚀
|
@ -1,30 +0,0 @@
|
||||
from swarms import Prompt
|
||||
from swarm_models import OpenAIChat
|
||||
import os
|
||||
|
||||
model = OpenAIChat(
|
||||
api_key=os.getenv("OPENAI_API_KEY"),
|
||||
model_name="gpt-4o-mini",
|
||||
temperature=0.1,
|
||||
)
|
||||
|
||||
# Aggregator system prompt
|
||||
prompt_generator_sys_prompt = Prompt(
|
||||
name="prompt-generator-sys-prompt-o1",
|
||||
description="Generate the most reliable prompt for a specific problem",
|
||||
content="""
|
||||
Your purpose is to craft extremely reliable and production-grade system prompts for other agents.
|
||||
|
||||
# Instructions
|
||||
- Understand the prompt required for the agent.
|
||||
- Utilize a combination of the most effective prompting strategies available, including chain of thought, many shot, few shot, and instructions-examples-constraints.
|
||||
- Craft the prompt by blending the most suitable prompting strategies.
|
||||
- Ensure the prompt is production-grade ready and educates the agent on how to reason and why to reason in that manner.
|
||||
- Provide constraints if necessary and as needed.
|
||||
- The system prompt should be extensive and cover a vast array of potential scenarios to specialize the agent.
|
||||
""",
|
||||
auto_generate_prompt=True,
|
||||
llm=model,
|
||||
)
|
||||
|
||||
# print(prompt_generator_sys_prompt.get_prompt())
|
File diff suppressed because it is too large
Load Diff
Loading…
Reference in new issue