All docs

Docs › MTS Lab

Servers and workspaces

Keep the research on a powerful server and open it from your laptop, run experiments on servers and clusters, and manage the app from the command line.

Open a server's workspace from your laptop

  1. Install MTS Lab on the server and run mtslab start (it listens on 127.0.0.1 only).
  2. On your laptop, in MTS Lab: workspace menu (top right) → + add a server workspace…: a name and the ssh host you already use (from ~/.ssh/config). The port can stay empty: MTS Lab finds it.
  3. Pick it in the workspace menu. MTS Lab keeps an ssh port-forward up by itself (and starts MTS Lab on the server when it is not running), and the window moves to the server's workspace; ← back to this computer's workspace returns.

Everything runs on the server — the steps, the engine, the agent (the server's Claude Code), JupyterLab — while you work in the window on your laptop. VS Code buttons open the server's files through Remote-SSH. Nothing secret is stored: ssh uses your own keys.

Computes: where an experiment runs

Run on → servers… adds one:

kindwhat you givehow it runs
sshhost, a work folder, the data folder, Pythonthe engine and the code are copied there once per version; the steps run in the background; small result files come back, per-day outputs are read there on demand
Slurmas ssh, plus partition, CPUs, memory, time, account, a command prefixan sbatch job; queued and running states shown; Stop cancels it
Kubernetes / OpenShiftkubectl or oc, namespace, image, CPU, memory, a PVC or host patha Job per experiment on the shared work folder

Test checks the server: ssh, Python, a worker's compiler. The worker image needs Python 3, g++ and the research packages (a Dockerfile is in the source tree). Experiments started from a server workspace use that server's computes.

The mtslab command

mtslabstart (if needed) and open the window
mtslab startstart in the background, no window (servers)
mtslab serverun in the foreground (systemd, or to watch the log)
mtslab stop · status · version
--port N · --workspace DIRdefault 8920 and ~/MTS Lab (or MTSLAB_PORT, MTS_LAB_HOME)

In a project or notebook: python -m mtslab describe (the engine's classes), python -m mtslab data check FILE, python -m mtslab lib build|test|describe (in a library), python -m mtslab nb run NOTEBOOK.

Where things are

~/MTS Lab/projects/<name>projects (git repositories); out/exp/<id>/ their experiments
~/MTS Lab/libs/<name>libraries
~/MTS Lab/data/, instruments.jsonmarket data and instruments
~/MTS Lab/settings.jsonthe Python, server workspaces, computes, JupyterLab's port
~/MTS Lab/mtslab.code-workspace, .vscode/the VS Code workspace, kept current
~/.local/share/mtslab/currentthe app: lab/bin the engine, lab/sdk the SDK, pylib the Python library, docs/data_format.md
~/.local/state/mtslab/the server's log

With PriorStates Studio

MTS Lab also runs as an app in PriorStates Studio, in Desk and Chrome's side panel — the same app and workspace. The standalone install needs neither.