Sign inSign up

swarmscorp/swarms

By swarmscorp

•Updated 1 day ago

https://github.com/kyegomez/swarms

Image
Languages & frameworks
Integration & delivery
Machine learning & AI
0

476

swarmscorp/swarms repository overview

⁠Swarms

The official image for Swarms⁠, a framework for building and orchestrating multi-agent LLM systems. It has the swarms package and CLI installed on Python 3.13, ready to run agents, workflows and swarms with any model provider that LiteLLM supports.

⁠Tags

TagContents
latestThe most recent release
16.0.1swarms 16.0.1

Version tags match the swarms version inside the image. Pin one in production. Every tag is built for linux/amd64 and linux/arm64.

⁠Quick start

docker pull swarmscorp/swarms:latest
docker run --rm swarmscorp/swarms python -c "import swarms; print('Swarms is ready')"

⁠Run your own script

Save this as agent.py:

from swarms import Agent

agent = Agent(
    agent_name="Analyst",
    model_name="gpt-5.4-mini",
    max_loops=1,
)

print(agent.run("Summarise the current state of LLM research in three bullets."))

Mount the folder into /app and pass your API key:

docker run --rm -e OPENAI_API_KEY -v "$PWD:/app" swarmscorp/swarms python agent.py

-e OPENAI_API_KEY with no value passes the key from your shell, so it never appears in your command history.

⁠Interactive use

# Python shell with swarms installed
docker run -it --rm -e OPENAI_API_KEY swarmscorp/swarms

# Bash shell
docker run -it --rm -e OPENAI_API_KEY -v "$PWD:/app" swarmscorp/swarms bash

# The swarms CLI
docker run --rm -e OPENAI_API_KEY swarmscorp/swarms swarms --help

⁠Build your own image on top

FROM swarmscorp/swarms:16.0.1

# The image has no pip; ensurepip adds it to the environment swarms is installed in.
USER root
RUN python -m ensurepip && python -m pip install --no-cache-dir yfinance
USER swarms

COPY agent.py .
CMD ["python", "agent.py"]

⁠Configuration

VariablePurpose
OPENAI_API_KEYOpenAI models, such as gpt-5.4
ANTHROPIC_API_KEYAnthropic models, such as claude-sonnet-4-6
GROQ_API_KEYGroq models, such as groq/llama-3.3-70b-versatile
GEMINI_API_KEYGoogle models, such as gemini/gemini-2.5-pro
SWARMS_TELEMETRY_ONTelemetry is on by default. Set this to false to turn it off.

Any other provider supported by LiteLLM⁠ works with its own key variable.

Using --env-file: Docker doesn't strip quotes, so OPENAI_API_KEY="sk-..." reaches the provider with the quotes included and fails to authenticate. Write OPENAI_API_KEY=sk-... instead.

⁠Image details

  • Base: python:3.13-slim
  • Packages: installed in /opt/venv, which is already on PATH
  • User: runs as the non-root user swarms (UID 1000)
  • Working directory: /app, which is writable. Agents save their agent_workspace there.
  • Default command: python

Mounting a folder on Linux: if the container can't write to it, run as your own user with --user "$(id -u):$(id -g)".

Licensed under Apache-2.0.

Tag summary

Content type

Image

Digest

sha256:d7269b5e1…

Size

106.7 MB

Last updated

1 day ago

docker pull swarmscorp/swarms