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
- Install MTS Lab on the server and run
mtslab start(it listens on 127.0.0.1 only). - 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. - 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:
| kind | what you give | how it runs |
|---|---|---|
| ssh | host, a work folder, the data folder, Python | the 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 |
| Slurm | as ssh, plus partition, CPUs, memory, time, account, a command prefix | an sbatch job; queued and running states shown; Stop cancels it |
| Kubernetes / OpenShift | kubectl or oc, namespace, image, CPU, memory, a PVC or host path | a 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
mtslab | start (if needed) and open the window |
mtslab start | start in the background, no window (servers) |
mtslab serve | run in the foreground (systemd, or to watch the log) |
mtslab stop · status · version | |
--port N · --workspace DIR | default 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.json | market data and instruments |
~/MTS Lab/settings.json | the Python, server workspaces, computes, JupyterLab's port |
~/MTS Lab/mtslab.code-workspace, .vscode/ | the VS Code workspace, kept current |
~/.local/share/mtslab/current | the 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.