Notebooks and runtimes
A notebook is an ordinary .ipynb file in your workspace. Open one from the
Files page (or create one with New Notebook), and the notebook editor
loads with a runtime bar at the top. The bar is where you pick a machine,
start it, and stop it. Nothing runs until you do.
The runtime bar
Stopped. The bar shows a summary of the current settings and a Start Runtime button. Click the summary to open Runtime settings; Start is disabled, with a hint, when your account is at its concurrent-runtime limit.
Starting. The bar shows Finding a machine… while the cloud allocates an instance and Setting up machine… while the runtime boots and mounts your workspace. Cancel abandons the launch. Provisioning time is never charged. A launch that takes more than 10 minutes (25 on Lambda Cloud) is abandoned and reported.
Running. The bar shows the connection state, the time left when a duration is set, and three controls:
- Connect opens a popover with Web Ports (every port the runtime is
listening on, plus a field to type one) and SSH Access (the
sshcommand and config block for this runtime). See Web apps on runtime ports and SSH. - Restart restarts the kernel in place (shortcut
0 0). The machine, the image, the workspace mount and anything you installed survive. - Stop terminates the machine. If you installed packages outside the image during the session, Stop first asks Save installed packages? with Save as Environment or Stop anyway.
While a runtime is running, every setting is locked except Idle stop.
Runtime settings
| Row | What you choose |
|---|---|
| Environment | The container image the runtime boots from: a template or one of your own. Manage environments… opens the Environments page. See Environments. |
| Provider | The cloud. The GPU classes on offer differ per cloud, and each class launches in a fixed region of that cloud. |
| Machine | CPU Only with a vCPU count, or a GPU class, how many GPUs, and, where the family sells more than one shape, the vCPU/RAM/NVMe size. |
| Pricing | On-Demand, or Spot where the provider sells it. Spot is cheaper and can be reclaimed by the cloud, so keep checkpoints in your workspace. |
| Duration | A hard stop: 30 minutes, 1, 2, 4, 8, 12 or 24 hours, or Infinite (shown as ∞ in the bar). The picker preselects 30 minutes. |
| Idle stop | 15, 30, 60, 120 or 240 minutes, or Never. The default is 120 minutes. A runtime is idle only when there is no user interaction and no cell is executing. |
| Cost | The credit burn rate of the configuration, in credits per hour ($1 = 100 credits). |
Each machine row carries an availability badge with the time it was last checked. A stale badge may warn you; it never promises capacity.
Menus
- File: Save (⌘S), Rename, Notebook info, Share…, Save
a copy as Environment (bakes the session's installed packages into a new
environment), and Download as
.ipynb,.pyor.html. - Edit: Cut cell (X), Copy cell (C), Paste cell below (V), Clear all outputs, Find and replace (⌘F).
- View: Show terminal (⌃`), Show selections panel (named groups of cells you can re-run together), Show table of contents (⌘⇧O), and collapse or expand all inputs or outputs.
- Runtime: Run all cells, Interrupt execution (I I), Restart kernel (0 0), Restart runtime (new VM), Disconnect.
Single-key shortcuts work in command mode, with no cell being edited.
Running cells and saving
- Run a cell with Shift+Enter. Output streams into the cell as it is produced.
- Closing the tab does not kill a running cell. Come back and the outputs produced while you were away replay into the cell.
- Autosave writes the notebook 2 seconds after you stop typing, and at least every 5 seconds while you keep typing; the bar shows Saving… and Saved. Leaving the page saves at once. ⌘S saves on demand.
- The kernel runs as an ordinary user in
/home/user/workspace, your durable workspace filesystem. Everything else on the machine is discarded when the runtime stops; see Packages in your runtime.
The terminal
Show terminal in the View menu, the terminal button in the bar, or
Ctrl+ (⌘ on a Mac) opens a shell at the bottom of the notebook. It runs on
the same machine, as the same user, starting in ~/workspace, and it is the
quickest way to pip install, inspect a GPU with nvidia-smi, or start a
web server to open from Web Ports.
Why a runtime stopped
When a runtime ends for a reason other than your Stop, the bar says which:
| Message | Meaning |
|---|---|
| Stopped after the idle timeout | No interaction and no running cell for the idle period. |
| Reached the session time limit | The Duration you chose ran out. |
| Spot capacity was reclaimed by the cloud | A spot machine was taken back. Relaunch, or pick On-Demand. |
| Out of compute credits | Your balance reached zero. Add credits in Settings. |
| Stopped: monthly spend cap reached | Your spend cap in Settings was hit. |
| Stopped because a member was removed from the workspace | The owner removed a member who could reach this runtime. |
| Stopped because the Pro subscription of the account that launched it ended | The launcher's Pro lapsed. |
| Connection to the runtime was lost | The runtime's tunnel to the platform dropped and did not recover. |
| The runtime crashed, The runtime agent went offline | The machine failed. Retry launches a fresh one; Report this problem sends the details to the team. |
Two notices can appear while a runtime runs: a reminder that a secret your environment references is not defined in this workspace (with a link to Settings, Secrets), and a warning when the machine's CUDA driver is older than your environment expects.
Viewers
A workspace viewer opens notebooks read-only: cells render with their saved outputs, and Start, the terminal and SSH are disabled with a hint. Viewers can still open a running runtime's web ports.
Related
- Quickstart: from sign-in to a first GPU cell.
- Environments: building the image a runtime boots from.
- Limits: runtime, idle and connection bounds.