AgentStack
Browse Sign in
Browse Why AgentStack Sell Docs
Sign in
SKILL verified MIT Self-run

Colab Remote

skill-broomva-skills-colab-remote · by broomva

>

No reviews yet
0 installs
21 views
0.0% view→install

Install

$ agentstack add skill-broomva-skills-colab-remote

✓ scanned · ✓ verified, works with Claude Code, Cursor, and more.

Security review

✓ Passed

No issues found. Passed automated security review. · v0.1.0 How review works →

  • Prompt-injection patterns
  • Secret / credential exfiltration
  • Dangerous shell & filesystem operations
  • Untrusted network calls
  • Known-malicious package signatures

What it can access

  • Network access No
  • Filesystem access No
  • Shell / process execution No
  • Environment & secrets Used
  • Dynamic code execution No

From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.

View the full security report →

Verified badge

Passed review? Show it. Paste this badge into your README, it links to the public security report.

AgentStack Verified badge Links to your public security report.
[![AgentStack Verified](https://agentstack.voostack.com/badges/verified.svg)](https://agentstack.voostack.com/security/report/skill-broomva-skills-colab-remote)

Reliability & compatibility

Security review passed
0 installs to date
no reviews yet
1mo ago

Declared compatibility

Claude CodeClaude Desktop

Compatibility is declared by the source manifest. End-to-end runtime verification is coming, see below.

Preview Execution monitoring

We're building live execution health for every listing: tool-call success rate, median latency, uptime, and last-checked timestamps, measured, not self-reported. It isn't live yet, so we don't show numbers we can't stand behind.

How agent discovery & health will work →
Are you the author of Colab Remote? Claim this listing to set pricing, connect Stripe payouts, and keep 70% of every sale.
Sign up to claim

About

Colab Remote — SSH-Operated GPU Training

Operate Google Colab Pro/Pro+ instances as headless GPU backends from the local terminal.

Architecture

Local Mac (Claude Code)
  ├── agent-browser → Chrome → colab.research.google.com
  │   └── Opens notebook, runs colab-ssh setup cell
  ├── SSH tunnel → Colab runtime (via ngrok or cloudflared)
  │   └── Run training, monitor GPU, transfer files
  └── /autoany EGRI loop (local)
      └── Proposes mutations → SSH executes on Colab → evaluates results

Phase 1: Launch Colab Session (Browser Automation)

Use /agent-browser to open Colab and set up SSH access.

Step 1: Open Colab and create notebook

agent-browser open "https://colab.research.google.com/#create=true"
agent-browser wait --load networkidle
agent-browser snapshot -i

If login is required, prompt the user to authenticate manually, then re-snapshot.

Step 2: Select GPU runtime

Navigate Runtime > Change runtime type, select GPU (T4/V100/A100 depending on plan), and save.

Step 3: Install colab-ssh and get connection details

Type the SSH setup code into a cell. Two methods supported:

Method A: ngrok (recommended)

!pip install colab-ssh --upgrade
from colab_ssh import launch_ssh
launch_ssh("YOUR_NGROK_TOKEN")

User must provide ngrok authtoken from https://ngrok.com.

Method B: cloudflared (no account needed)

!pip install colab-ssh --upgrade
from colab_ssh import launch_ssh_cloudflared
launch_ssh_cloudflared(password="your-password-here")

Step 4: Extract and save connection details

After the cell runs, snapshot output to extract hostname/port. Save for reuse:

mkdir -p ~/.colab-remote
cat > ~/.colab-remote/session.env  train.log 2>&1 &"
# Monitor
ssh -p $COLAB_PORT root@$COLAB_HOST "tail -f /content/train.log"

Monitor GPU

ssh -p $COLAB_PORT root@$COLAB_HOST "nvidia-smi --query-gpu=utilization.gpu,utilization.memory,memory.used,memory.total,temperature.gpu --format=csv"

Install dependencies

ssh -p $COLAB_PORT root@$COLAB_HOST "pip install torch transformers peft bitsandbytes accelerate datasets"

Phase 3: EGRI Integration (/autoany)

Wire Colab as the execution backend for an EGRI optimization loop. See references/egri-colab.md for the full problem-spec template and harness patterns.

Execution loop (summary)

for each trial:
  1. Upload mutated artifact → scp to Colab
  2. Execute on Colab GPU → ssh python train.py
  3. Evaluate results → ssh python evaluate.py
  4. Download metrics → scp results.json
  5. Score locally (immutable evaluator)
  6. Promote or discard based on policy

Phase 4: Session Lifecycle

| Tier | Max runtime | Idle timeout | GPU | |------|-------------|--------------|-----| | Free | 12h | 90min | T4, limited | | Pro | 24h | 90min | T4, V100, priority | | Pro+ | 24h | 90min | T4, V100, A100 |

Keep-alive

ssh -p $COLAB_PORT root@$COLAB_HOST "while true; do sleep 300; echo keepalive; done &"

Reconnect after timeout

  1. Check: ssh -p $COLAB_PORT root@$COLAB_HOST "echo ok" 2>/dev/null && echo "UP" || echo "DOWN"
  2. If dead, re-launch via Phase 1 (browser automation)
  3. Resume from last checkpoint

Google Drive persistence

Mount Drive to persist across sessions:

ssh -p $COLAB_PORT root@$COLAB_HOST "python -c 'from google.colab import drive; drive.mount(\"/content/drive\")'"
# Checkpoints survive in /content/drive/MyDrive/

Quick Reference

| Task | Command | |------|---------| | Check GPU | ssh -p $COLAB_PORT root@$COLAB_HOST "nvidia-smi" | | Upload | scp -P $COLAB_PORT ./file root@$COLAB_HOST:/content/ | | Download | scp -P $COLAB_PORT root@$COLAB_HOST:/content/file ./ | | Run script | ssh -p $COLAB_PORT root@$COLAB_HOST "python /content/script.py" | | Background job | ssh -p $COLAB_PORT root@$COLAB_HOST "nohup python train.py > log 2>&1 &" | | Tail log | ssh -p $COLAB_PORT root@$COLAB_HOST "tail -20 /content/log" | | Disk space | ssh -p $COLAB_PORT root@$COLAB_HOST "df -h /content" | | Kill job | ssh -p $COLAB_PORT root@$COLAB_HOST "pkill -f train.py" | | Session alive? | ssh -p $COLAB_PORT root@$COLAB_HOST "echo ok" 2>/dev/null |

Prerequisites

  • ngrok account (free): https://ngrok.com — or cloudflared: brew install cloudflared
  • Colab Pro/Pro+ for GPU priority and longer runtimes
  • agent-browser installed and working
  • Google account signed into Chrome

Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

Install and usage instructions live in the source repository linked above.

Reviews

No reviews yet, be the first.

Versions

  • v0.1.0 Imported from the upstream source.