Why Contribute?
By joining us, you have the opportunity to:- Work on the Frontier of Agents: Shape the future of autonomous agent technology and help build a production-grade, open-source framework
- Join a Vibrant Community: Collaborate with a passionate and growing group of agent developers, researchers, and enthusiasts
- Make a Tangible Impact: Whether you’re fixing a bug, adding a new feature, or improving documentation, your work will be used in real-world applications
- Learn and Grow: Gain hands-on experience with advanced AI concepts and strengthen your software engineering skills
Areas Needing Contributions
We have several areas where contributions are particularly welcome:Writing Tests
- Goal: Increase test coverage to ensure the library’s robustness
- Tasks:
- Write unit tests for existing code in
swarms/ - Identify edge cases and potential failure points
- Ensure tests are repeatable and independent
- Add integration tests for swarm orchestration methods
- Write unit tests for existing code in
Improving Documentation
- Goal: Maintain clear and comprehensive documentation for users and developers
- Tasks:
- Update docstrings to reflect any changes
- Add examples and tutorials in the
examples/directory - Improve or expand the content in the swarms-framework-docs repository
- Create video tutorials and walkthroughs
Adding New Swarm Architectures
- Goal: Provide new multi-agent orchestration methods
- Current Architectures:
Enhancing Agent Capabilities
- Goal: Improve existing agents and add new specialized agents
- Areas of Focus:
- Financial analysis agents
- Medical diagnosis agents
- Code generation and review agents
- Research and analysis agents
- Creative content generation agents
Removing Defunct Code
- Goal: Clean up and remove bad code to improve maintainability
- Tasks:
- Identify unused or deprecated code
- Remove duplicate implementations
- Simplify complex functions
- Update outdated dependencies
How to Contribute
Reporting Issues
If you find any bugs, inconsistencies, or have suggestions for enhancements, please open an issue on GitHub:- Search Existing Issues: Before opening a new issue, check if it has already been reported
- Open a New Issue: If it hasn’t been reported, create a new issue and provide detailed information
- Title: A concise summary in the WARP format, for example
[FIX][SwarmRouter.run][Pass output_type to fallback swarms] - Description: Detailed description, steps to reproduce, expected behavior, and any relevant logs or screenshots
- Title: A concise summary in the WARP format, for example
- Label Appropriately: Use labels to categorize the issue (e.g., bug, enhancement, documentation)
Good First Issues
The easiest way to contribute is to pick any issue with thegood first issue tag. These are specifically designed for new contributors:
- Good First Issues
- Contributing Board - Participate in roadmap discussions!
Submitting Pull Requests
We welcome pull requests (PRs) for bug fixes, improvements, and new features. Please follow these guidelines:- Fork the Repository: Create a personal fork of the repository on GitHub
-
Clone Your Fork: Clone your forked repository to your local machine and install it in editable mode
-
Create a New Branch: Use a descriptive branch name
- Make Your Changes: Implement your code, ensuring it adheres to the coding standards
- Add Tests: Write tests to cover your changes
-
Commit Your Changes: Write the commit message in the WARP format
-
Push to Your Fork:
-
Create a Pull Request:
- Go to the original repository on GitHub
- Click on “New Pull Request”
- Select your branch and open the PR against
masterwith a WARP title - Describe the problem it solves and link the issue (
Fixes #1234)
- Respond to Feedback: Be prepared to make changes based on code reviews
Keep PRs small and focused: one bug fix, one feature, or one refactor per PR. Under about 100 changed lines is reviewed fastest. Don’t mix reformatting, renames, or unrelated cleanup into a functional change.
WARP git messages
Every commit message, PR title, and issue title in the Swarms repository must use the WARP (Warp Speed Protocol) shorthand. The rule applies to people and AI agents alike.TYPE: the kind of change, in capitals, for exampleFEAT,FIX,DOCS,REFACTOR,TEST, orCHORE.Function/FileName: the function, class, module, or file the change is about.Short Description: one imperative line saying what changed.
Coding Standards
To maintain code quality and consistency, please adhere to the following standards:Type Annotations
- Mandatory: All functions and methods must have type annotations
-
Example:
-
Benefits:
- Improves code readability
- Helps with static type checking tools
Docstrings and Documentation
- Docstrings: Every public class, function, and method must have a docstring following the Google Python Style Guide or NumPy Docstring Standard
-
Content:
- Description: Briefly describe what the function or class does
- Args: List and describe each parameter
- Returns: Describe the return value(s)
- Raises: List any exceptions that are raised
-
Example:
- Documentation: Update or create documentation pages if your changes affect the public API
Testing
- Required: All new features and bug fixes must include appropriate unit tests
-
Framework: Use
unittest,pytest, or a similar testing framework -
Test Location: Place tests in the
tests/directory, mirroring the structure ofswarms/ - Test Coverage: Aim for high test coverage to ensure code reliability
-
Running Tests:
Code Style
- PEP 8 Compliance: Follow PEP 8 style guidelines
- Linting Tools: The CI lint gate runs
black --checkandruff check .— runblack .andruff check .locally before submitting - Consistency: Maintain consistency with the existing codebase
- No unrelated reformatting: Change only the lines you need to
Comments
Write code that explains itself, and comment only what it can’t. A comment is one line. If it needs a paragraph, it belongs in the docstring.- No multi-line comment blocks: no banners, section dividers, or multi-paragraph explanations
- No commented-out code; git history keeps it
- Don’t restate the code, such as
# loop over agentsabove aforloop
Development Resources
Documentation
- Official Documentation: docs.swarms.world
- Installation Guide: Installation
- Quickstart Guide: Get Started
- Agent Architecture: Agent Internal Mechanisms
- Agent API: Agent API
Examples and Tutorials
- Basic Examples: examples/
- Agent Examples: examples/single_agent/
- Multi-Agent Examples: examples/multi_agent/
- Tool Examples: examples/tools/
API Reference
- Core Classes: swarms/structs/
- Agent Implementations: swarms/agents/
- Tool Implementations: swarms/tools/
- Utility Functions: swarms/utils/
License
By contributing to Swarms, you agree that your contributions will be licensed under the Apache License 2.0.Get Help
If you have any questions or need assistance, please feel free to:- Open an issue on GitHub
- Join our Discord community
- Reach out to the maintainers
- Schedule an onboarding session
Thank You
Thank you for contributing to Swarms! Your efforts help make this project better for everyone.