Skip to content
Agentmart
Submit a tool

modal-gpu

Run Python code on cloud GPUs using Modal serverless platform.

Skill by benchflow-ai

IndexedApache-2.0★ 1,870
Write a review

Install

Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.

npx agentmarket install skill/benchflow-ai-modal-gpu

Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.

Get the weekly diff

The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.

We use your email only for this newsletter. Privacy

About

Run Python code on cloud GPUs using Modal serverless platform. Use when you need A100/T4/A10G GPU access for training ML models. Covers Modal app setup, GPU selection, data downloading inside functions, and result handling.

Use cases: cloud, data, ml

No reviews yet. Installed it? Reviews come from verified installers only. How reviews work

Permissions

What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.

Tools
No tools found
Secrets
None asked for
Install scripts
None found

Network hosts it talks to 1

  • codeload.github.com · found in install command

Files it touches

  • ~/.claude/skills/modal-gpu

What's inside

Skill name
modal-gpu
Description
Run Python code on cloud GPUs using Modal serverless platform. Use when you need A100/T4/A10G GPU access for training ML models. Covers Modal app setup, GPU selection, data downloading inside functions, and result handling.
License
Apache-2.0
Instructions
99 lines in SKILL.md · view on GitHub

Files (6)

  • SKILL.md
  • common-issues.md · references/
  • data-download.md · references/
  • getting-started.md · references/
  • gpu-selection.md · references/
  • results.md · references/

SKILL.md (first lines)

# Modal GPU Training

## Overview

Modal is a serverless platform for running Python code on cloud GPUs. It provides:

- **Serverless GPUs**: On-demand access to T4, A10G, A100 GPUs
- **Container Images**: Define dependencies declaratively with pip
- **Remote Execution**: Run functions on cloud infrastructure
- **Result Handling**: Return Python objects from remote functions

Two patterns:
- **Single Function**: Simple script with `@app.function` decorator
- **Multi-Function**: Complex workflows with multiple remote calls

## Quick Reference

| Topic | Reference |
|-------|-----------|
| Basic Structure | [Getting Started](references/getting-started.md) |
| GPU Options | [GPU Selection](references/gpu-selection.md) |
| Data Handling | [Data Download](references/data-download.md) |
| Results & Outputs | [Results](references/results.md) |
| Troubleshooting | [Common Issues](references/common-issues.md) |

## Installation

```bash
pip install modal
modal token set --token-id <id> --token-secret <secret>
```

## Minimal Example

```python
import modal

app = modal.App("my-training-app")

image = modal.Image.debian_slim(python_version="3.11").pip_install(
    "torch",
    "einops",
    "numpy",
)

@app.function(gpu="A100", image=image, timeout=3600)
def train():
    import torch
    device = torch.device("cuda")
    print(f"Using GPU: {torch.cuda.get_device_name(0)}")

    # Training code here
    return {"loss": 0.5}

@app.local_entrypoint()
def main():
    results = train.remote()
    print(results)
```

## Common Imports

```python
import modal
from modal import Image, App

# Inside remote function
import torch
import torch.nn as nn
from huggingface_hub import hf_hub_download
```

## When to Use What

| Scenario | Approach |
|----------|----------|
| Quick GPU experiments | `gpu="T4"` (16GB, cheapest) |
| Medium training jobs | `gpu="A10G"` (24GB) |
| Large-scale training | `gpu="A100"` (40/80GB, fastest) |
| Long-running jobs | Set `timeout=3600` or higher |
| Data from HuggingFace | Download inside function with `hf_hub_download` |
| Return metrics | Return dict from function |

## Running

```bash
# Run script
modal run train_modal.py

# Run in background
modal run --detach train_modal.py
```

## External Resources

- Modal Documentation: https://modal.com/docs
- Modal Examples: https://github.com/modal-labs/modal-examples

From benchflow-ai/skillsbench, Apache-2.0.

More from benchflow-ai/skillsbench

Signals

Stars
1,870
Forks
372
Open issues
50
Last commit (this folder)
May 30, 2026 (5 months ago)
Last release
Jun 14, 2026 (4 months ago)

From GitHub (fetched Oct 24, 2026).

Details

License
Apache-2.0
First seen
Oct 24, 2026
Last checked
Oct 24, 2026

Same skill elsewhere

Copies of this SKILL.md published by others; search shows only one of them.

More from benchflow-ai

Cite this page

modal-gpu skill. Agent Mart. https://agentmart.dev/skills/benchflow-ai-modal-gpu (last updated 2026-10-24)