From tpu
Open an IAP-tunnelled SSH session to a TPU VM, optionally with port-forward for Jupyter (8888) and TensorBoard (6006). Knows the alpha-track command + zone + project flags; can also launch the SSH command for the user to paste into their own terminal (interactive sessions don't survive an MCP tool invocation).
How this skill is triggered — by the user, by Claude, or both
Slash command
/tpu:connect <tpu-name> [--zone=europe-west4-a] [--jupyter] [--tensorboard]<tpu-name> [--zone=europe-west4-a] [--jupyter] [--tensorboard]This skill is limited to the following tools:
The summary Claude sees in its skill listing — used to decide when to auto-load this skill
Generate the right `gcloud alpha compute tpus tpu-vm ssh` command
Generate the right gcloud alpha compute tpus tpu-vm ssh command
for the given VM, with optional -L 8888 / -L 6006 port-forwards
for Jupyter + TensorBoard. Interactive SSH itself runs in the user's
terminal — this skill prepares the command and prints it.
Arguments in $ARGUMENTS:
$0 — TPU VM name (required).--zone=ZONE — default europe-west4-a.--project=PROJECT_ID — default tpu-2026.--jupyter — add -L 8888:localhost:8888.--tensorboard — add -L 6006:localhost:6006.--detach — append -N so the tunnel stays open without a shell
(use for the port-forward-only terminal pattern).Verify the VM exists + is reachable:
gcloud compute tpus tpu-vm describe $TPU_NAME --zone=$ZONE \
--project=$PROJECT_ID --format="value(state,acceleratorType,health)"
If state is not READY, abort with an explanation.
Build the SSH command:
CMD="gcloud alpha compute tpus tpu-vm ssh $TPU_NAME \
--project=$PROJECT_ID --zone=$ZONE --tunnel-through-iap"
if --jupyter or --tensorboard:
CMD="$CMD --"
[[ $JUP ]] && CMD="$CMD -L 8888:localhost:8888"
[[ $TB ]] && CMD="$CMD -L 6006:localhost:6006"
[[ $DETACH ]] && CMD="$CMD -N"
Tell the user what to do next:
--detach: open a SECOND terminal and run
the plain SSH command to actually get a shell. The detached
terminal is just the tunnel.# If Jupyter:
source ~/venvs/tunix/bin/activate
jupyter lab --no-browser --port=8888 --ip=127.0.0.1
# then open http://127.0.0.1:8888/lab?token=... in your laptop browser
# If TensorBoard:
source ~/venvs/tunix/bin/activate
tensorboard --logdir <your-log-dir> --port=6006 --host=127.0.0.1
# then open http://localhost:6006
gcloud compute tpus tpu-vm ssh (non-alpha) does NOT support
--tunnel-through-iap. Always use the alpha channel for
tpu-vm SSH.?token=... query string that
changes each launch. Always copy the full URL from the Jupyter
startup log, not just the hostname.-L 8889:localhost:8888 and open localhost:8889.-L flags over two separate tunnels.npx claudepluginhub borisbolliet/tpu-claude-plugin --plugin tpuCreates, edits, and optimizes skills for Claude Code, including drafting, evaluating with test prompts, iterating on performance, and improving skill descriptions for better triggering accuracy.