Skip to content

SYSTEM Cited by 1 source

Livebook

Livebook is an Elixir notebook environment — Elixir's answer to Jupyter Notebooks — but with one architectural difference that matters for this wiki: it can attach its runtime to any Erlang/Elixir cluster and leverage BEAM's native code-distribution primitives to make the notebook feel like local code while running compute on arbitrarily many remote nodes.

Key architectural properties

  • Runtime is clusterable to remote BEAM nodes. A Livebook running on a user's laptop can spin up a runtime on a Fly Machine in the user's Fly.io org and drive compute against it; alternatively the runtime can attach to an already-running Elixir application for introspection/debug. (Source: sources/2024-09-24-flyio-ai-gpu-clusters-from-your-laptop-with-livebook)
  • Notebook-to-cluster code sync is automatic. "Livebook will automatically synchronize your notebook dependencies as well as any module or code defined in your notebook across nodes." User-defined modules are callable from anywhere in the cluster without a build step. Canonical instance of concepts/transparent-cluster-code-distribution. (Source: same)
  • Auto-completion comes from the remote node. When a runtime is attached to a remote cluster, Livebook's completion results come from modules defined on the remote node, not from a local index. The notebook is a thin client over BEAM's introspection primitives.
  • FLAME-driven elastic execution. Code cells can issue Flame.call blocks that spawn additional compute nodes on demand, with the framework managing pool size and lifecycle. Combined with Livebook's code-sync this means a cell can dispatch its own locally-defined function across an ephemeral cluster.
  • Kubernetes-side parity (v0.14.1). Michael Ruoss contributed runtime + FLAME support on K8s, so the same Livebook-driven elastic-compute workflow runs on Kubernetes clusters (Pods instead of Fly Machines).

Seen in

Last updated · 200 distilled / 1,178 read