-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: resolve merge conflicts in docs workflow
- Loading branch information
Showing
8 changed files
with
297 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
source "https://rubygems.org" | ||
|
||
gem "jekyll" | ||
gem "just-the-docs" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
remote_theme: pmarsceill/just-the-docs | ||
|
||
# Site settings | ||
title: SmolSwarms Docs | ||
description: Documentation that hits different fr fr 🌊 | ||
baseurl: "/smolswarms" | ||
url: "https://ultrainstinct0x.github.io" | ||
|
||
# Theme settings | ||
color_scheme: dark | ||
search_enabled: true | ||
heading_anchors: true | ||
|
||
# Aux links for the upper right navigation | ||
aux_links: | ||
"SmolSwarms on GitHub": | ||
- "//github.com/ultrainstinct0x/smolswarms" | ||
|
||
# Makes Aux links open in a new tab | ||
aux_links_new_tab: true | ||
|
||
# Custom footer content | ||
footer_content: "No cap, just clean docs fr fr 🚀" | ||
|
||
# Back to top link | ||
back_to_top: true | ||
back_to_top_text: "Back to top" | ||
|
||
# Collections for docs structure | ||
collections: | ||
guides: | ||
permalink: "/:collection/:path/" | ||
output: true | ||
reference: | ||
permalink: "/:collection/:path/" | ||
output: true | ||
|
||
# Default YAML frontmatter settings | ||
defaults: | ||
- | ||
scope: | ||
path: "" # an empty string here means all files in the project | ||
values: | ||
layout: "default" | ||
- | ||
scope: | ||
path: "_guides" | ||
values: | ||
layout: "guide" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,121 @@ | ||
--- | ||
layout: default | ||
title: Quick Start Guide | ||
parent: Guides | ||
nav_order: 1 | ||
--- | ||
|
||
# Quick Start Guide | ||
{: .no_toc } | ||
|
||
Getting started with SmolSwarms faster than a speedrunner finding a new glitch fr fr 🏃♂️ | ||
{: .fs-6 .fw-300 } | ||
|
||
## Table of contents | ||
{: .no_toc .text-delta } | ||
|
||
1. TOC | ||
{:toc} | ||
|
||
--- | ||
|
||
## Installation | ||
|
||
First, let's get this bad boy installed faster than npm downloading node_modules: | ||
|
||
```bash | ||
pip install smolswarms | ||
``` | ||
|
||
Want that developer% speedrun strats? | ||
|
||
```bash | ||
git clone https://github.com/ultrainstinct0x/smolswarms.git | ||
cd smolswarms | ||
pip install -e .[dev] # Install that developer DLC | ||
``` | ||
|
||
## Basic Usage | ||
|
||
Creating your first swarm is easier than explaining why you have 47 Chrome tabs open: | ||
|
||
```python | ||
from smolswarms import SwarmFactory | ||
from smolswarms.specs import BusinessUnit | ||
|
||
# Define your swarm requirements (more detailed than my coffee order) | ||
unit_spec = BusinessUnit( | ||
name="growth_team", | ||
core_functions=["user_acquisition", "retention", "analytics"], | ||
budget_constraints="reasonable" # No infinite money glitch... yet | ||
) | ||
|
||
# Let it cook fr fr | ||
factory = SwarmFactory() | ||
swarm = factory.spawn_business_unit(unit_spec) | ||
|
||
# Watch the magic happen | ||
results = swarm.execute_strategy("increase_q4_growth") | ||
print(f"Swarm do be vibing: {results}") | ||
``` | ||
|
||
## Configuration | ||
|
||
Configure your swarm like you're optimizing your Discord server settings: | ||
|
||
```python | ||
from smolswarms.config import SwarmConfig | ||
|
||
config = SwarmConfig( | ||
base_model="claude-3-opus-20240229", # That big brain energy | ||
max_tokens=8192, # More tokens than a CS:GO inventory | ||
temperature=0.7, # Spicier than my GitHub contributions | ||
coordination_protocol="hierarchical" # More organized than my life | ||
) | ||
|
||
# Apply config like it's a texture pack | ||
factory = SwarmFactory(config=config) | ||
``` | ||
|
||
## Advanced Features | ||
|
||
### Agent Communication | ||
|
||
Make your agents talk to each other like they're in a Discord server: | ||
|
||
```python | ||
# Create a communication channel that hits different | ||
channel = swarm.create_channel("strategy_discussion") | ||
|
||
# Let them chat fr fr | ||
swarm.broadcast( | ||
channel=channel, | ||
message="Yo, who's trying to optimize this workflow rn?", | ||
priority="high" | ||
) | ||
``` | ||
|
||
### Memory Management | ||
|
||
Give your agents memory persistence that's more reliable than my promises to fix legacy code: | ||
|
||
```python | ||
# Save that knowledge like it's a game checkpoint | ||
swarm.store_memory( | ||
key="market_insights", | ||
value={"trend": "up only", "confidence": "trust_me_bro"}, | ||
persistence="permanent" | ||
) | ||
|
||
# Retrieve it faster than my excuse generator | ||
insights = swarm.recall_memory("market_insights") | ||
``` | ||
|
||
## What's Next? | ||
|
||
- Check out our [Advanced Guides](advanced.md) for more galaxy brain strats | ||
- Join our [Discord](https://discord.gg/smolswarms) to vibe with the dev team | ||
- Read the [Architecture Guide](architecture.md) to understand how this quantum realm works | ||
- Browse the [API Reference](/reference) for that low-level knowledge | ||
|
||
Remember: With great power comes great API costs - use responsibly fr fr! 💫 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
--- | ||
layout: default | ||
title: Home | ||
nav_order: 1 | ||
description: "SmolSwarms Documentation - Because why spawn one AI when you can spawn them all fr fr 🤖" | ||
permalink: / | ||
--- | ||
|
||
# SmolSwarms Documentation | ||
{: .fs-9 } | ||
|
||
Spawn and orchestrate autonomous AI agent swarms that actually do be hitting different fr fr 🌊 | ||
{: .fs-6 .fw-300 } | ||
|
||
[Get Started](#getting-started){: .btn .btn-primary .fs-5 .mb-4 .mb-md-0 .mr-2 } | ||
[View it on GitHub](https://github.com/ultrainstinct0x/smolswarms){: .btn .fs-5 .mb-4 .mb-md-0 } | ||
|
||
--- | ||
|
||
## Getting Started | ||
|
||
You ever look at an AI agent and think "what if there were more of them?" Well, you've come to the right place fr fr. SmolSwarms is basically Kubernetes but for AI agents (and 100% more cursed). | ||
|
||
```python | ||
from smolswarms import SwarmFactory | ||
|
||
# Spawn your corporate hivemind in 3 lines no cap | ||
factory = SwarmFactory() | ||
swarm = factory.spawn_department({ | ||
"business_unit": "growth_team", | ||
"budget": "infinite_money_glitch", | ||
"vibe": "hypergrowth" | ||
}) | ||
|
||
# Watch the magic happen | ||
swarm.execute_autonomously() | ||
``` | ||
|
||
## Why SmolSwarms Though? | ||
|
||
- 🏭 **Agent Factory System**: Spawning specialized AI agents faster than you can say "recursive automation" | ||
- 🧠 **Big Brain Energy**: Uses Claude-3 as the director agent to design optimal architectures | ||
- 💰 **Token Economic Policy**: Built-in optimization to keep your OpenAI bill from going to the moon | ||
- 🤝 **Agent Communication Protocol**: They're like Discord servers but for AI agents | ||
- 🛡️ **Safety First**: Sandboxed execution environments because we ain't trying to speedrun Skynet | ||
|
||
## Useful Links | ||
|
||
- [Changelog](/changelog) - What's new in these streets | ||
- [Roadmap](/roadmap) - Where we're going (where we're going we don't need roads) | ||
- [Contributing Guide](/contributing) - How to make this project more based | ||
- [API Reference](/reference) - The sacred texts | ||
|
||
## About the project | ||
|
||
SmolSwarms is more open-source than my emotional baggage fr fr. We out here trying to make multi-agent systems more accessible than a Discord server with no verification. | ||
|
||
### License | ||
|
||
SmolSwarms is distributed under the [MIT License](https://github.com/ultrainstinct0x/smolswarms/blob/main/LICENSE). | ||
|
||
### Contributing | ||
|
||
When contributing to this repository, please first discuss the change you wish to make via issue, email, or any other method with the owners of this repository before making a change. Read more about becoming a contributor in our [Contributing Guide](contributing). | ||
|
||
### Code of Conduct | ||
|
||
Just don't be more toxic than a League of Legends lobby fr fr. Read more in our [Code of Conduct](code-of-conduct). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
""" | ||
Agent implementations for smolswarms. | ||
This module contains different types of agents that can be spawned in a swarm: | ||
- BaseAgent: Abstract base class for all agents | ||
- ResearchAgent: For data analysis and research tasks | ||
- ExecutorAgent: For task execution and coordination | ||
- ReviewerAgent: For code and content review | ||
""" | ||
|
||
from typing import Protocol | ||
|
||
|
||
class Agent(Protocol): | ||
"""Base protocol for all agents in the system.""" | ||
|
||
def execute_task(self, task: str) -> None: | ||
"""Execute a given task.""" | ||
... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
""" | ||
Core functionality for smolswarms. | ||
This module contains the core components and utilities: | ||
- SwarmManager: Manages agent swarms and their interactions | ||
- MemoryManager: Handles persistent storage and memory management | ||
- TokenManager: Manages token usage and optimization | ||
- ConfigManager: Handles configuration and settings | ||
""" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
""" | ||
Data models and schemas for smolswarms. | ||
This module contains Pydantic models for: | ||
- AgentConfig: Configuration for individual agents | ||
- SwarmConfig: Configuration for entire swarms | ||
- TaskSpec: Task specification and requirements | ||
- MetricsData: Performance and usage metrics | ||
""" | ||
|
||
from pydantic import BaseModel | ||
|
||
|
||
class BaseConfig(BaseModel): | ||
"""Base configuration model.""" | ||
|
||
name: str | ||
description: str |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
""" | ||
Utility functions and helpers for smolswarms. | ||
This module contains various utility functions: | ||
- logging: Custom logging setup | ||
- metrics: Performance and usage metrics | ||
- validation: Input validation helpers | ||
- formatting: Output formatting utilities | ||
""" |