Skip to main content

swm

License PyPI Python

One CLI to rule all GPU clouds.
Search pricing across 10 providers, spin up a GPU in seconds, sync your workspace, and track every dollar.


$ swm gpus -g h200 --max-price 4

  Live GPU Availability
┏━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━┳━━━━━━━━┳━━━━━━━━━━┳━━━━━━━━━┓
┃ Provider ┃ GPU              ┃ VRAM   ┃ $/hr     ┃ Stock   ┃
┡━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━╇━━━━━━━━╇━━━━━━━━━━╇━━━━━━━━━┩
│ vastai   │ NVIDIA H200      │ 141 GB │ $2.89/hr │ 12 avl  │
│ runpod   │ NVIDIA H200      │ 141 GB │ $3.49/hr │ High    │
│ lambda   │ NVIDIA H200      │ 141 GB │ $3.99/hr │ 4 avl   │
│ vultr    │ NVIDIA H200      │ 141 GB │ $3.88/hr │ 8 avl   │
└──────────┴──────────────────┴────────┴──────────┴─────────┘

Install

# macOS (Homebrew)
brew tap swm-gpu/swm && brew install swm

# Python (3.11+)
pipx install swm-gpu

# From source
git clone https://github.com/swm-gpu/swm.git && cd swm && pip install -e .

Quick Start

# 1. Add your API key
swm config set runpod.api_key <your-key>

# 2. Find a GPU (the table tells you each GPU's minimum CUDA)
swm gpus -g h200

# 3. Create a pod (auto-picks a CUDA-compatible image; auto-saves to storage)
swm pod create -p runpod -g h200 -n my-session --cuda 12.8

# 4. Install a framework
swm setup install vllm runpod:<id>

# 5. Done — pushes workspace to storage and terminates
swm pod down runpod:<id>

Or just ask your agent

Don't want to learn the CLI? Install the SKILL.md and your AI agent manages GPUs for you:

# Universal (works with Cursor, Copilot, Windsurf, Amp, Devin)
mkdir -p .agents/skills/swm-gpu-workflow
curl -sL https://raw.githubusercontent.com/swm-gpu/swm/main/.agents/skills/swm-gpu-workflow/SKILL.md \
  -o .agents/skills/swm-gpu-workflow/SKILL.md

Works with Cursor, Claude Code, Codex, Copilot, Windsurf, Amp, Devin, and any agent that can run shell commands.

Supported Providers

Provider GPU Search Provision Stop/Resume Billing API
RunPod Live Yes Yes Full
Vast.ai Live Yes Yes Full
Lambda Labs Live Yes — —
Vultr Live Yes Yes —
TensorDock Live Yes Yes —
FluidStack Live Yes Yes —
AWS (EC2) Live Yes Yes —
GCP (Compute) Live Yes Yes —
Azure Live Yes Yes —
CoreWeave Live Yes Yes —

Key Features

GPU Search & Provisioning

swm gpus                            # all GPUs, all providers
swm gpus -g h200 -c 4              # 4×H200 configs
swm gpus --max-price 4 --secure    # under $4/hr, certified clouds
swm images list -p runpod --cuda 12.8  # see compatible Docker images
swm pod create -p runpod -g h200 -n train --cuda 12.8
swm pod down runpod:<id>            # sync + terminate

swm gpus reports each GPU's minimum CUDA toolkit. Pass --cuda <major.minor> to swm pod create to auto-pick the newest provider image that satisfies it.

Workspace Sync

Your /workspace directory follows you across clouds via S3-compatible storage (Backblaze B2, Amazon S3, Google GCS).

swm sync pull runpod:<id>           # storage → pod
swm sync push runpod:<id>           # pod → storage (incremental)
swm sync push runpod:<id> --delete  # also remove files deleted locally
swm sync watch runpod:<id>          # filesystem change watcher
swm sync auto runpod:<id>           # background daemon: push every 60s

Three-tier smart sync: inotify watcher tracks changes, incremental push uploads only what changed, tar mode packs 600k small files into one S3 object.

Continuous auto-sync. swm pod create starts an auto-sync daemon by default — it tails the watcher log and pushes every 60s with no manual intervention. Adopt an existing pod with swm setup workspace <pod> if you created it with --no-storage or the bootstrap was interrupted.

Frameworks

swm setup install vllm runpod:<id>       # vLLM inference server
swm setup install open-webui runpod:<id> # Open WebUI chat interface
swm setup install comfyui runpod:<id>    # ComfyUI image generation
swm setup install axolotl runpod:<id>    # Axolotl fine-tuning
swm setup install ollama runpod:<id>     # Ollama model runner
swm setup install swarmui runpod:<id>    # SwarmUI
swm setup install llm-studio runpod:<id> # H2O LLM Studio

Auto-detects GPU count for tensor parallelism, opens SSH tunnels for unexposed ports, probes health endpoints.

Lifecycle Guard

Monitors SSH sessions, GPU utilization, filesystem writes, and active processes. If nothing's happening, it saves your workspace and terminates the pod.

swm pod create -p runpod -g h200 -n train \
  --lifecycle auto-down --idle-timeout 30   # bake the policy into create
swm guard set runpod:<id> --mode auto-down --idle-timeout 30
swm guard list

No more $96 overnight H100 bills.

Cost Tracking

swm costs live                      # running cost right now
swm costs summary                   # spending breakdown
swm costs reconcile                 # verify against provider billing APIs
swm costs budget set 100            # $100/month alert

Model Management

swm models search qwen3                         # search HuggingFace Hub
swm models info civitai:101055                  # inspect HF / Civitai refs
swm models pull runpod:<id> Qwen/Qwen3-8B       # HuggingFace repo
swm models pull runpod:<id> deepseek-r1:14b     # Ollama ref
swm models pull runpod:<id> civitai:101055 --as checkpoint
swm models pull runpod:<id> https://example.com/style.safetensors --as lora
swm models list runpod:<id> --all               # tracked + untracked files
swm models link runpod:<id> /workspace/foo.safetensors --as lora
swm setup start vllm runpod:<id> --model Qwen/Qwen3-8B

Downloads land in a unified on-pod model store at /workspace/models/. Framework installs wire their expected paths into that store: ComfyUI and SwarmUI get bucket-style directories (checkpoints/, loras/, vae/, diffusion_models/, text_encoders/, ...), vLLM uses the shared HF cache, and Ollama uses the shared Ollama store. Every pull/link is recorded in /workspace/models/.manifest.json, so swm models list can show tracked, missing, and unmanaged files.

For gated repos or restricted Civitai models:

swm config set hf.api_key <huggingface-token>
swm config set civitai.api_key <civitai-token>

How It Works

Everything happens over SSH. No agents on the pod. No custom images. No webhooks.

┌──────────┐       SSH        ┌─────────────┐       S3 API      ┌───────────┐
│ Your Mac │ ───────────────> │  GPU Pod    │ ────────────────> │ B2 / S3   │
│   swm    │  exec, scp      │  (any       │  s5cmd sync       │ / GCS     │
│          │ <─────────────── │   provider) │ <──────────────── │(workspace)│
└──────────┘                  └─────────────┘                   └───────────┘

Credentials are never stored on the pod. Storage keys are passed as transient environment variables per command.

Security

  • SSH key authentication only — no passwords stored anywhere
  • No credentials on pods — storage keys passed transiently, never written to disk
  • Non-destructive by default — sync push, sync pull, and pod down never remove files from your storage bucket. Deletions are opt-in (sync push --delete) and the auto-sync daemon refuses to start unless a prior pull/push has confirmed pod ↔ bucket are in sync
  • Secure cloud default — swm pod create defaults to SOC 2 / HIPAA certified data centers

Documentation

Full docs at swmgpu.com.

Page Description
Getting Started (CLI) Install and create your first pod in 5 minutes
Getting Started (Agent) Let your AI agent manage GPUs for you
Configuration All config keys for providers and storage
Command Reference Full reference for every swm command
Core Concepts Providers, workspaces, frameworks, lifecycle guard

Requirements

  • macOS or Linux
  • Python 3.11+ (if not using Homebrew binary)
  • SSH client (ssh, scp)
  • An account with at least one GPU provider

Contributing

Bug reports, feature requests, and pull requests welcome. See CONTRIBUTING.md for scope, code style, and the PR workflow. The community is governed by our Code of Conduct.

Open-ended questions and design discussions belong in GitHub Discussions. Security reports go through private vulnerability reporting — see SECURITY.md.

License

Licensed under the Apache License, Version 2.0.

Release files for swm-gpu 0.3.8

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for swm-gpu 0.3.8
File Size Uploaded
swm_gpu-0.3.8.tar.gz 283.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for swm-gpu 0.3.8
File Interpreter ABI Platform
swm_gpu-0.3.8-py3-none-any.whl Python 3 none any Details

Total release size: 509.5 kB

Release files / swm_gpu-0.3.8.tar.gz

Download URL swm_gpu-0.3.8.tar.gz
Size 283.2 kB
Tags Source
SHA-256 checksum
How to use checksums
9a33ae277516f31c8ce45811731ae8f89193867218ab700ee32a98116fc3152c
BLAKE2b-256 checksum
How to use checksums
749d9c9f751147d87706d7c99fb096cb57d2db5941ae898f7a58b207683f1029
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 27, 2026.

Transparency log

Release files / swm_gpu-0.3.8-py3-none-any.whl

Download URL swm_gpu-0.3.8-py3-none-any.whl
Size 226.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
db1d8231181713c45d6657d0a56f879f61b5bd322d3e16635bf12b9671ccdd41
BLAKE2b-256 checksum
How to use checksums
c060b9ed8257cfed0b369713d984695c21ccf1c2de3835a259a1b85d04c7a4dc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 27, 2026.

Transparency log

Release history Release notifications | RSS feed

0.3.10

2 release files

0.3.9

2 release files

This release

0.3.8 This release

2 release files

0.3.7

2 release files

0.3.6

2 release files

0.3.5

2 release files

0.3.4

2 release files

0.3.3

2 release files

0.3.2

2 release files

0.3.1

2 release files

0.3.0

2 release files

0.2.16

2 release files

0.2.15

2 release files

0.2.14

2 release files

0.2.13

2 release files

0.2.12

2 release files

0.2.11

2 release files

0.2.10

2 release files

0.2.9

2 release files

0.2.8

2 release files

0.2.7

2 release files

0.2.6

2 release files

0.2.5

2 release files

0.2.4

2 release files

0.2.3

2 release files

0.2.2

2 release files

0.2.1

2 release files

0.2.0

2 release files

0.1.13

2 release files

0.1.12

2 release files

0.1.11

2 release files

0.1.10

2 release files

0.1.9

2 release files

0.1.8

2 release files

0.1.7

2 release files

0.1.6

2 release files

0.1.5

2 release files

0.1.4

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page