Skip to main content Switch to mobile version kaggle-shell-mcp 1.0.1 Turn free 12h Kaggle Dual-T4 GPUs into live remote terminals & detached job runners for AI Agents via MCP.
pip install kaggle-shell-mcp==1.0.1 Copy PIP instructions
Turn free 12h Kaggle GPUs into multi-slot live remote terminals, dual-panel file workbenches, and offline competition runners for AI Agents via MCP.
Tiếng Việt (Vietnamese Guide) · Architecture · Changelog · Contributing
Live Screenshots (Native Rust 60-FPS TUI — kgsh ui)
F1 Cockpit — Real-Time Shell, Live Script Output, MCP Activity & Job Logs
Watch every [mcp] tool call from your AI Agent alongside your own [tui] commands, live GPU/VRAM/RAM/Disk telemetry, running foreground loop tailing, and live training logs side by side.
F2 Dual-Panel File Manager & Code Preview Drawer
Browse local files (Left) and Kaggle /kaggle/working, /kaggle/input, /tmp (Right) with Yazi-style ← / → navigation, DU% disk micro-bars, multi-select, cross-panel clipboard (c/x/p), t push/pull transfers, and v syntax preview drawer.
Remote File Editor (Enter / → 2x) — Clean Shift / Ctrl+Shift & Drag Selection
Drag with the mouse or hold Shift / Ctrl+Shift + arrow keys to select and copy only clean code — never capturing the Path : header or 1 │ line-number gutters.
Workers, Cluster & Quota (Ctrl+W / F5)
Inspect weekly GPU (30h) & TPU (20h) quota, switch or stop parallel slots (slot="1", "2"), and boot from saved profiles (~/.kaggle_mcp/profiles.json).
Zero-Black-Box MCP + 60-FPS Rust TUI (kgsh ui): Watch every command your AI Agent sends in real time, interrupt hung loops (Ctrl+C) on an isolated TUI shell without killing Agent sessions, browse/edit/preview remote files safely (256 KB cap with automatic Read-Only lock on truncated/binary files & unsaved-edit guard), inspect .parquet/.csv/.safetensors/.pt/.zip files, and monitor Multi-GPU VRAM & °C telemetry (GPU0, GPU1, ...).
Zero-Setup Prebuilt Binary Auto-Download (x86_64 & ARM64): Running kgsh ui after pip install kaggle-shell-mcp automatically downloads the matching prebuilt kgsh-tui binary for Windows (x86_64), Linux (x86_64 & aarch64 static musl), or macOS (arm64 & x86_64) from GitHub Releases with Fail-Closed SHA256SUMS.txt verification into ~/.kaggle_mcp/bin/ — no Rust toolchain required.
SSH-Ready Clipboard (OSC 52 + Internal Yank Buffer): Ctrl+C, Ctrl+X, Ctrl+V, mouse drag, and Bracketed Paste work seamlessly even over headless SSH servers without X11/Wayland.
One-Line Credentials & Secret-Safe Sync: Works out of the box with KAGGLE_USERNAME and KAGGLE_KEY (KGAT_... token, legacy key, or ~/.kaggle/kaggle.json, requiring kaggle>=2.2.0). fs_sync and TUI Push automatically exclude .env* (keeping .env.example), kaggle.json, SSH/TLS keys, and local pull directories.
Dual Concurrent GPU VMs (4 × Tesla T4 = 60 GB VRAM) & Verified Shutdown: Run up to 2 parallel live Kaggle GPU VMs (slot="1,2"), pin individual background jobs (gpu_ids="0" / "1"), and stop slots via 3-tier verified shutdown (kgsh down [-f]) that never wipes sessions.json while a GPU VM is still running.
Full Hardware & Kaggle Hub Support: Target NvidiaTeslaT4 (2×15 GB), NvidiaL4, NvidiaL4x4 (96 GB), NvidiaRtxPro6000 (96 GB), NvidiaH100, TpuV5E8 / TpuV6E8, or cpu, with native competition_sources and Kaggle Hub model_sources mounts.
Offline Competition Mode + Auto-Harvest + Host SSE Live Logs: When L4x4 / RTX Pro 6000 enforces enable_internet=False, kaggle_wheelhouse + kaggle_batch_run use isolated per-run slugs (kgsh-batch- - ), automatically harvest relative outputs (submission.csv, checkpoints/) from /tmp into /kaggle/working on exit, and stream live stdout via Kaggle's Host SSE endpoint (kaggle_batch_logs).
11h40m (8h40m TPU) Safe-Drain Watchdog: Sends SIGTERM at 11h35m (8h35m on TPU) to flush checkpoints and exits cleanly (exit 0) at 11h40m so /kaggle/working (19.5 GB) snapshots persist.
Option A: Zero-Install MCP Server for AI Agents (uvx)
Add directly to Claude Desktop / Cursor / Windsurf / Antigravity (mcp_config.json):
{ "mcpServers": { "kgsh": { "command": "uvx", "args": ["--from", "kaggle-shell-mcp", "kgsh"], "env": { "KAGGLE_USERNAME": "your_kaggle_username", "KAGGLE_KEY": "KGAT_your_api_token_here" } } } } Or add to Claude Code CLI in one line:
claude mcp add kgsh -e KAGGLE_USERNAME=your_user -e KAGGLE_KEY=KGAT_your_token -- uvx --from kaggle-shell-mcp kgsh Option B: Install kgsh CLI + Native TUI (pip / uv)
pip install kaggle-shell-mcp # or isolated CLI install: uv tool install kaggle-shell-mcp Configure credentials via any of:
KAGGLE_USERNAME + KAGGLE_KEY environment variables,
.env in your project directory or ~/.kaggle_mcp/.env, or
Existing ~/.kaggle/kaggle.json.
Then launch the TUI or CLI:
# Launch Dual-Panel Rust TUI (auto-downloads prebuilt kgsh-tui binary on first run) kgsh ui # Or manage workers directly from CLI kgsh quota kgsh up -s 1 kgsh shell -s 1 Option C: Install from Source (Developers)
git clone https://github.com/NguyenQuocDat06-AI/kaggle-shell-mcp.git cd kaggle-shell-mcp python -m venv .venv .\.venv\Scripts\pip install -e ".[dev]" # Linux/macOS: ./.venv/bin/pip install -e ".[dev]" cargo build --release --manifest-path tui/Cargo.toml .\.venv\Scripts\kgsh ui MCP Tools Reference (13 Tools)
TUI Keyboard & Mouse Cheatsheet (kgsh ui)
1. Parallel Multi-Slot Interactive GPUs (4 × T4 = 60 GB VRAM)
kgsh up -s 1,2 # Boot 2 Dual-T4 VMs in parallel kgsh push ./my_project /kaggle/working -s 1 kgsh push ./my_project /kaggle/working -s 2 kgsh spawn -s 1 --gpus 0 "python my_project/train.py --lr 1e-4" --name exp1 kgsh spawn -s 1 --gpus 1 "python my_project/train.py --lr 3e-4" --name exp2 kgsh spawn -s 2 --gpus 0 "python my_project/train.py --lr 5e-4" --name exp3 kgsh spawn -s 2 --gpus 1 "python my_project/train.py --lr 1e-3" --name exp4 kgsh logs -s 1 -f # Live tail -f log follower kgsh down -s all # Clean shutdown when done 2. Offline Competition Batch Runner (L4x4 / RTX Pro 6000)
kgsh wheels peft accelerate bitsandbytes --slug lora-deps --py 312 kgsh batch-run "torchrun --nproc_per_node=4 solve.py" \ --path ./comp_solution -a l4x4 --comp arc-prize-2026 \ --wheels your_username/kgsh-wheels-lora-deps \ --model qwen-lm/qwen2.5/transformers/7b-instruct/1 kgsh batch-logs -s batch-1 --tail 80 Architecture & Responsible Use
See ARCHITECTURE.md for system internals (multi-slot file locking, echo-immune PTY sentinel framing, Host SSE log streaming, and prebuilt TUI binary distribution).
kaggle-shell-mcp is built for legitimate ML experimentation, model training, and competition workflows on your own Kaggle account. Respect Kaggle's Terms of Service and shut down active slots (kgsh down -s all) when finished.
Released under the MIT License.
Both files in this release have provenance metadata.
MIT View SPDX License List
mcp model-context-protocol kaggle gpu ai-agent remote-terminal claude-code cursor pytorch
Development Status 5 - Production/Stable
Intended Audience Developers
Operating System OS Independent
Programming Language Python :: 3
Topic Scientific/Engineering :: Artificial Intelligence
Software Development :: Libraries :: Python Modules
Release files for kaggle-shell-mcp 1.0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
Built distribution (wheel)
Total release size: 178.0 kB
Release files / kaggle_shell_mcp-1.0.1.tar.gz
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 27, 2026.
Release files / kaggle_shell_mcp-1.0.1-py3-none-any.whl
Security for kaggle-shell-mcp 1.0.1
Both files in this release have been uploaded with provenance metadata.
With provenance kaggle_shell_mcp-1.0.1.tar.gz Nov 27, 2026
Attestation for kaggle_shell_mcp-1.0.1.tar.gz
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.
Release history Release notifications | RSS feed
Nov 27, 2026 2 release files Full provenance
Nov 24, 2026 2 release files Full provenance
"PyPI", "Python Package Index", and the blocks logos are registered trademarks of the Python Software Foundation.
© 2026 Python Software Foundation




