Beam is a free, open source machine learning infrastructure project written in Go and released under AGPL-3.0. It has 1,780 GitHub stars, 165 forks and 21 open issues, and was last pushed 27 hours ago. On this registry it ranks #46 of 57 tracked projects in Machine Learning Infrastructure, with 5 head-to-head comparisons available. It gained 10 stars over the last 6 tracked days.

What is Beam?

What it is

Beam is an open-source runtime for serverless AI workloads, released under AGPL-3.0 and implemented in Go. It lives in the Python AI infrastructure ecosystem, where it gives developers a Pythonic interface for deploying and scaling GPU inference, sandboxes, and background jobs without managing infrastructure. The open-source engine is Beta9, which powers the managed Beam cloud platform.

The concrete problem it addresses is running AI workloads on GPUs without managing infrastructure, while keeping cold starts low and autoscaling workloads. Beam targets those needs with sub-second container launch, scale-to-zero behavior, distributed volume mounting, and decorators for endpoints, tasks, and sandboxes.

Key capabilities

  • Launches containers in under one second by using a custom container runtime, a scheduler, and embedded caching.
  • Fans out workloads across hundreds of containers for parallelization and concurrency.
  • Provides a Pythonic developer experience with hot reloading, webhooks, and scheduled jobs.
  • Runs workloads serverless by default, including scale-to-zero behavior for idle functions.
  • Mounts distributed storage volumes for workloads that need shared or persistent data access.
  • Supports GPU execution on managed cloud hardware such as 4090s and H100s, and also supports bring-your-own GPUs.
  • Creates isolated sandboxes that can run LLM-generated code remotely.

Who uses it and how

  • Application developers spin up isolated containers to execute LLM-generated code in a sandbox, then read the remote result from Python.
  • Machine learning teams deploy custom inference endpoints with explicit GPU, CPU, memory, Python version, and queue-depth autoscaling settings.
  • Backend teams add background jobs through task queues with input schemas, retry policies, and direct invocation from an application.
  • Teams replace a Celery-style queue by scheduling resilient tasks or deploying them behind versioned endpoints.
  • Organizations can use the managed Beam cloud or self-host Beta9 for free.

Getting started

Install the client with pip install beam-client, create an account, and follow the Getting Started Guide. The README shows Python decorators for endpoints, tasks, and sandboxes, plus a beam deploy command for background tasks.

When to use it — and when not to

Use Beam when a Python team needs serverless GPU inference, isolated sandboxes, and background jobs with scale-to-zero behavior, especially if cold-start latency and autoscaling are primary concerns. Avoid it if your organization cannot accept AGPL-3.0, needs a mature production track record, or cannot operate the custom runtime, scheduler, caching, storage volumes, and GPU capacity required for self-hosted deployments. The repository facts indicate a young project with 0 contributors and 21 open issues, so teams with strict stability requirements should evaluate it carefully.

project readme (upstream, from github) — read inline

Run AI Workloads at Scale

Colab ⭐ Star the Repo Documentation Join Slack Twitter AGPL

Beam is a fast, open-source runtime for serverless AI workloads. It gives you a Pythonic interface to deploy and scale AI applications with zero infrastructure overhead.

Watch the demo

✨ Features

  • Fast Cold Starts: Launch containers in under a second using a custom container runtime, scheduler, and embedded caching
  • Parallelization and Concurrency: Fan out workloads to 100s of containers
  • First-Class Developer Experience: Hot-reloading, webhooks, and scheduled jobs
  • Scale-to-Zero: Workloads are serverless by default
  • Volume Storage: Mount distributed storage volumes
  • GPU Support: Run on our cloud (4090s, H100s, and more) or bring your own GPUs

📦 Installation

pip install beam-client

⚡️ Quickstart

  1. Create an account here
  2. Follow our Getting Started Guide

Creating a sandbox

Spin up isolated containers to run LLM-generated code:

from beam import Image, Sandbox


sandbox = Sandbox(image=Image()).create()
response = sandbox.process.run_code("print('I am running remotely')")

print(response.result)

Deploy a serverless inference endpoint

Create an autoscaling endpoint for your custom model:

from beam import Image, endpoint
from beam import QueueDepthAutoscaler

@endpoint(
    image=Image(python_version="python3.11"),
    gpu="A10G",
    cpu=2,
    memory="16Gi",
    autoscaler=QueueDepthAutoscaler(max_containers=5, tasks_per_container=30)
)
def handler():
    return {"label": "cat", "confidence": 0.97}

Run background tasks

Schedule resilient background tasks (or replace your Celery queue) by adding a simple decorator:

from beam import Image, TaskPolicy, schema, task_queue


class Input(schema.Schema):
    image_url = schema.String()


@task_queue(
    name="image-processor",
    image=Image(python_version="python3.11"),
    cpu=1,
    memory=1024,
    inputs=Input,
    task_policy=TaskPolicy(max_retries=3),
)
def my_background_task(input: Input, *, context):
    image_url = input.image_url
    print(f"Processing image: {image_url}")
    return {"image_url": image_url}


if __name__ == "__main__":
    # Invoke a background task from your app (without deploying it)
    my_background_task.put(image_url="https://example.com/image.jpg")

    # You can also deploy this behind a versioned endpoint with:
    # beam deploy app.py:my_background_task --name image-processor

Self-Hosting vs Cloud

Beta9 is the open-source engine powering Beam, our fully-managed cloud platform. You can self-host Beta9 for free or choose managed cloud hosting through Beam.

👋 Contributing

We welcome contributions big or small. These are the most helpful things for us:

❤️ Thanks to Our Contributors

Frequently asked questions

Is Beam free to use?

Beam is open source under the AGPL-3.0 licence. There is no licence fee and no seat count — you can self-host it or, where the project offers one, pay a vendor for a managed version instead.

What does Beam do?

Serverless GPU compute with sub-second cold starts

What is Beam written in?

Beam is primarily written in Go. Its source is publicly available at https://github.com/beam-cloud/beta9, and it has 1,780 GitHub stars.