Guide · Agent skill
How to use the Experiment Queue for GPU Batches agent skill
Updated · written with AI from the project's own documentation and checked against our catalogue data
The experiment-queue skill is an agent skill that lets an AI coding agent such as Claude Code manage a large batch of machine learning training jobs on a remote SSH GPU server. It is meant for multi-seed sweeps and hyperparameter grids of 10 or more jobs, where running experiments one at a time with the single-experiment workflow becomes slow. After reading this guide you will know what the skill does, how to install it, how to trigger it with a natural request, and what it needs on your server.
Quick start
- 1Install the skill. Download the ZIP from this page and unzip it into ~/.claude/skills/ or the project's .claude/skills/ folder, or upload it under Settings → Capabilities → Skills in the Claude apps.
- 2Prepare the remote server. Confirm SSH access, screen, Python 3, and a conda environment with your project's dependencies on the GPU host.
- 3Describe your batch. Ask the agent in plain language, or provide a YAML manifest or grid spec listing your jobs and their arguments.
- 4Set the run variables. Set PROJECT_DIR to your local project root so the agent can create a timestamped run folder and save the manifest there.
- 5Let pre-flight checks run. The agent checks the SSH connection, conda environment, working directory, preconditions, and free GPUs before launching.
- 6Launch the scheduler. The agent starts the detached scheduler, which launches jobs on free GPUs and moves through waves automatically.
- 7Check progress. Review the done, running, and pending counts from the status output, and inspect any jobs marked stuck.
What is an agent skill and what does this one do?
An agent skill is a folder with a SKILL.md file and optional scripts that an agent loads when a request matches its description. This skill, named experiment-queue, is an SSH job queue for multi-seed and multi-config ML experiments.
Once active, the agent can take a set of jobs, start them on free GPUs on your remote server, retry jobs that run out of GPU memory after a delay, clean up leftover terminal sessions, and launch the next group of jobs only after the previous group has finished. It also keeps a state file so you can check progress overnight, showing how many jobs are done, running, and pending.
- Starts jobs on GPUs that are free, up to a configured max_parallel limit.
- Retries jobs that fail with out-of-memory (OOM) errors after a delay, up to a set number of attempts.
- Parks jobs that fail for other reasons as stuck, for a human to review.
- Cleans up stale screen sessions whose Python process has already exited.
- Starts the next wave only after the current wave has exited and GPU memory has dropped below a threshold.
- Starts a student job only after its teacher checkpoint exists (preconditions).
What do you need before you start?
The skill assumes your remote environment is already set up. It does not install your project for you.
- SSH access to a remote GPU server, with screen installed.
- Python 3 on the remote host.
- A conda environment on the remote host with your project's dependencies.
- Claude Code or another agent that can run Bash commands.
- The related skills run-experiment and monitor-experiment, which the skill references in its allowed tools.
- Your project's jobs described either as a YAML manifest, a grid specification, or a plain-language description the agent turns into a manifest.
How do you install the experiment-queue skill?
Download the ZIP for this skill from our page and unzip it. Put the resulting experiment-queue folder in one of two places. For a personal install available in all projects, use ~/.claude/skills/. For a single project, use the .claude/skills/ folder inside that project.
If you use the Claude apps instead of Claude Code, you can upload the skill under Settings → Capabilities → Skills.
- Personal install: unzip into ~/.claude/skills/
- Project install: unzip into the project's .claude/skills/ folder
- Claude apps: upload under Settings → Capabilities → Skills
How do you trigger the skill with a natural request?
You do not need to type a command. The skill's description lists phrases that activate it, so you can ask in plain language. Mention a batch, a grid, a multi-seed sweep, or chaining experiments automatically.
Also mention the number of jobs. The skill is meant for cases where /run-experiment is not enough, which the description puts at 10 or more jobs needing orchestration.
- "Run a batch of experiments for seeds 200 to 220 across the four model sizes on my GPU server."
- "Set up a grid: N = 64, 128, 256 and n = 50K, 150K, 500K, then run it on gpu-server."
- "Auto-chain the student training after the teacher checkpoints finish."
- "Run this multi-seed sweep and tell me overnight how many jobs are done."
How does a job manifest work?
A manifest is a YAML file that lists the project, the working directory, the conda environment, the SSH host, a default command, the GPUs to use, the parallel limit, the OOM retry policy, and each job with its arguments. The agent builds or reads this file and saves a copy so the run can be reproduced.
Key fields include gpus, max_parallel, gpu_free_threshold_mib (default 500), and oom_retry with a delay and max_attempts. Each job has an id and args. Preconditions such as checkpoint_exists stop a job from starting until its required file is present.
- project, cwd, conda, and ssh identify where and how jobs run.
- default_cmd is the command each job runs, with per-job args added.
- gpus and max_parallel control how many jobs run at once.
- oom_retry sets the delay in seconds and the number of attempts after an out-of-memory failure.
- preconditions block a job until a checkpoint file exists.
project: my_grid_experiment
cwd: /home/user/your_project
conda: my_env
ssh: gpu-server
gpus: [0, 1, 2, 3, 4, 5, 6, 7]
max_parallel: 8
oom_retry:
delay: 120
max_attempts: 3What are the safety notes for running scripts and network access?
This skill runs scripts and uses the network. Its scripts are build_manifest.py, queue_manager.py, and SKILL.md. The scheduler runs detached on the server and polls GPU state on a fixed interval, so it keeps working after your terminal session closes.
Do not wrap the skill in a second loop or scheduled poll. The skill already runs its own scheduler, and an extra poll would race its wave-transition logic. Use its status output to check progress instead.
- Review the scripts before installing, since they run commands on your remote server over SSH.
- The skill uses Bash, so it needs permission to run commands.
- Do not add an external /loop or cron-style poll on top of the built-in scheduler.
- Expect failed jobs to be marked stuck rather than retried, so check them yourself.
What tips help the queue run smoothly?
Set the GPU free threshold to match your server. The default is 500 MiB. Raise it on a shared server where other users hold memory, and lower it for tight packing on a dedicated machine.
Make sure the conda environment is built and tested on the remote host before you queue jobs. If a whole wave dies at import time, the environment is usually the cause, not the queue.
- Check the status output in the morning rather than polling the server manually.
- Use a grid spec for regular combinations and a manifest for irregular job lists.
- Keep the saved manifest in the run folder so you can rerun the exact same batch.
What people use it for
- Running a multi-seed sweep of 21 seeds across 12 configuration cells overnight.
- Training a teacher model and automatically starting the student distillation once the teacher checkpoint exists.
- Retrying out-of-memory jobs with a delay on a shared GPU server.
- Running a hyperparameter grid across N and sample-size values and collecting results in one run folder.
Frequently asked questions
How do I install the experiment-queue skill?
Download the ZIP for this skill from this page and unzip it into ~/.claude/skills/ for a personal install or into a project's .claude/skills/ folder for one project. In the Claude apps, upload it under Settings → Capabilities → Skills.
Is the experiment-queue skill free?
The skill is released under the MIT licence, as stated on this page. Check the licence file in the source repository for the full terms.
What do I need to use the experiment-queue skill?
You need SSH access to a remote GPU server with screen installed, Python 3 on that host, and a conda environment with your project's dependencies. You also need an agent that can run Bash commands, such as Claude Code.
When should I use experiment-queue instead of run-experiment?
Use experiment-queue for batches of 10 or more jobs that need orchestration, such as multi-seed sweeps or teacher-student chains. For a single ad-hoc experiment, the simpler run-experiment workflow is enough.
Does experiment-queue work with Modal or Vast.ai?
No. The skill says Modal and Vast.ai deployments have their own orchestration, so this skill is meant for SSH remote GPU servers.
What happens when a job fails?
Jobs that run out of GPU memory are retried after the configured delay, up to max_attempts. Jobs that fail for other reasons are parked as stuck for a human to review, so this skill is not suited to experiments that need manual inspection between runs.
New agent skills, repos and AI tools — every week
The best new skills and open-source projects, the fastest-growing repos, and one free prompt. Five minutes to read. Unsubscribe anytime.
Our verdict
Choose experiment-queue if you run 10 or more ML jobs on a shared or dedicated SSH GPU server and want an agent to handle GPU placement, OOM retries and wave transitions overnight. Skip it for single experiments, for Modal or Vast.ai deployments, or for work where you need to inspect each run before the next one starts.
Download the skill