gpu4agents 0.9.1__tar.gz → 0.10.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (154) hide show
  1. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/.claude-plugin/plugin.json +1 -1
  2. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/.cursor-plugin/plugin.json +1 -1
  3. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/CHANGELOG.md +25 -0
  4. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/INSTALL.md +11 -8
  5. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/PKG-INFO +7 -7
  6. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/PROVIDERS.md +2 -2
  7. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/README.md +6 -6
  8. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/docs/ADDING_A_PROVIDER.md +17 -13
  9. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/docs/AGENTS.md +9 -3
  10. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/docs/CONFIG.md +36 -2
  11. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/__init__.py +1 -1
  12. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/agent/mcp.py +1 -1
  13. {gpu4agents-0.9.1/skills/gpu4agents → gpu4agents-0.10.0/gpu4agents/agent/skill}/SKILL.md +7 -5
  14. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/cli/account.py +78 -9
  15. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/cli/providers.py +2 -2
  16. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/cli/setup.py +10 -4
  17. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/core/engine.py +3 -1
  18. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/core/models.py +4 -0
  19. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/providers/base.py +6 -0
  20. gpu4agents-0.10.0/gpu4agents/providers/gpus.py +70 -0
  21. gpu4agents-0.10.0/gpu4agents/providers/http.py +103 -0
  22. gpu4agents-0.10.0/gpu4agents/providers/lambdacloud/__init__.py +3 -0
  23. gpu4agents-0.10.0/gpu4agents/providers/lambdacloud/client.py +107 -0
  24. gpu4agents-0.10.0/gpu4agents/providers/lambdacloud/config.py +55 -0
  25. gpu4agents-0.10.0/gpu4agents/providers/lambdacloud/mapper.py +230 -0
  26. gpu4agents-0.10.0/gpu4agents/providers/lambdacloud/provider.py +471 -0
  27. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/providers/registry.py +6 -3
  28. gpu4agents-0.10.0/gpu4agents/providers/runpod/__init__.py +3 -0
  29. gpu4agents-0.10.0/gpu4agents/providers/runpod/client.py +183 -0
  30. gpu4agents-0.10.0/gpu4agents/providers/runpod/config.py +61 -0
  31. gpu4agents-0.10.0/gpu4agents/providers/runpod/mapper.py +200 -0
  32. gpu4agents-0.10.0/gpu4agents/providers/runpod/provider.py +412 -0
  33. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/providers/scaffold.py +6 -2
  34. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/providers/vast/config.py +7 -0
  35. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/providers/vast/provider.py +20 -1
  36. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/install.sh +63 -9
  37. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/pyproject.toml +3 -1
  38. {gpu4agents-0.9.1/gpu4agents/agent/skill → gpu4agents-0.10.0/skills/gpu4agents}/SKILL.md +7 -5
  39. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/tests/fakes.py +1 -0
  40. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/tests/test_cli.py +79 -2
  41. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/tests/test_engine.py +17 -0
  42. gpu4agents-0.10.0/tests/test_lambda_provider.py +295 -0
  43. gpu4agents-0.10.0/tests/test_runpod_provider.py +324 -0
  44. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/.claude-plugin/marketplace.json +0 -0
  45. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/.env.example +0 -0
  46. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/.github/ISSUE_TEMPLATE/bug_report.yml +0 -0
  47. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/.github/ISSUE_TEMPLATE/config.yml +0 -0
  48. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/.github/ISSUE_TEMPLATE/feature_request.yml +0 -0
  49. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/.github/dependabot.yml +0 -0
  50. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/.github/pull_request_template.md +0 -0
  51. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/.github/workflows/ci.yml +0 -0
  52. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/.github/workflows/release.yml +0 -0
  53. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/.gitignore +0 -0
  54. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/CODE_OF_CONDUCT.md +0 -0
  55. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/CONTRIBUTING.md +0 -0
  56. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/JOBS.md +0 -0
  57. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/LICENSE +0 -0
  58. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/SECURITY.md +0 -0
  59. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/SERVING.md +0 -0
  60. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/docs/ACCEPTANCE.md +0 -0
  61. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/docs/CHOOSING_A_MODEL.md +0 -0
  62. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/docs/INTEGRATION.md +0 -0
  63. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/docs/LIFECYCLE.md +0 -0
  64. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/docs/USAGE.md +0 -0
  65. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/docs/assets/banner.png +0 -0
  66. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/docs/assets/jambu-logo.jpg +0 -0
  67. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/examples/experiment.py +0 -0
  68. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/examples/gpu.yaml +0 -0
  69. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/examples/mastra-agent/README.md +0 -0
  70. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/examples/mastra-agent/package-lock.json +0 -0
  71. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/examples/mastra-agent/package.json +0 -0
  72. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/examples/mastra-agent/src/agent.ts +0 -0
  73. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/examples/mastra-agent/src/index.ts +0 -0
  74. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/examples/mastra-agent/src/tools/weather-tool.ts +0 -0
  75. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/examples/mastra-agent/tsconfig.json +0 -0
  76. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/examples/typescript-client/README.md +0 -0
  77. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/examples/typescript-client/package-lock.json +0 -0
  78. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/examples/typescript-client/package.json +0 -0
  79. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/examples/typescript-client/src/gpu.ts +0 -0
  80. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/examples/typescript-client/src/index.ts +0 -0
  81. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/examples/typescript-client/tsconfig.json +0 -0
  82. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu.example.yaml +0 -0
  83. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu.models.yaml +0 -0
  84. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu.yaml +0 -0
  85. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/__main__.py +0 -0
  86. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/agent/__init__.py +0 -0
  87. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/agent/install.py +0 -0
  88. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/agent/jobs.py +0 -0
  89. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/cli/__init__.py +0 -0
  90. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/cli/_common.py +0 -0
  91. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/cli/agent.py +0 -0
  92. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/cli/inspect.py +0 -0
  93. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/cli/job.py +0 -0
  94. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/cli/lifecycle.py +0 -0
  95. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/cli/main.py +0 -0
  96. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/cli/run.py +0 -0
  97. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/cli/status.py +0 -0
  98. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/cli/timer.py +0 -0
  99. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/cli/validate.py +0 -0
  100. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/core/__init__.py +0 -0
  101. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/core/beacon.py +0 -0
  102. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/core/config.py +0 -0
  103. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/core/credentials.py +0 -0
  104. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/core/durations.py +0 -0
  105. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/core/errors.py +0 -0
  106. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/core/events.py +0 -0
  107. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/core/execution.py +0 -0
  108. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/core/health.py +0 -0
  109. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/core/hosts.py +0 -0
  110. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/core/job.py +0 -0
  111. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/core/model_inspect.py +0 -0
  112. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/core/paths.py +0 -0
  113. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/core/policy.py +0 -0
  114. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/core/state.py +0 -0
  115. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/core/sweep.py +0 -0
  116. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/core/tool_parsers.py +0 -0
  117. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/providers/__init__.py +0 -0
  118. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/providers/vast/__init__.py +0 -0
  119. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/providers/vast/client.py +0 -0
  120. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/providers/vast/mapper.py +0 -0
  121. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/runtime/__init__.py +0 -0
  122. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/runtime/base.py +0 -0
  123. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/runtime/service.py +0 -0
  124. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/runtime/vllm.py +0 -0
  125. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/serve/__init__.py +0 -0
  126. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/serve/hf/__init__.py +0 -0
  127. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/serve/hf/install.sh +0 -0
  128. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/serve/hf/server.py +0 -0
  129. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/serve/template/__init__.py +0 -0
  130. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/serve/template/gpujob.yaml +0 -0
  131. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/serve/template/server.py +0 -0
  132. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/watchdog/__init__.py +0 -0
  133. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/watchdog/agent_body.py +0 -0
  134. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/watchdog/builder.py +0 -0
  135. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/gpu4agents/watchdog/jobs_ext.py +0 -0
  136. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/jambu_gpu/__init__.py +0 -0
  137. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/jambu_gpu/__main__.py +0 -0
  138. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/skills/gpu4agents/agents/openai.yaml +0 -0
  139. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/tests/conftest.py +0 -0
  140. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/tests/test_agent.py +0 -0
  141. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/tests/test_config.py +0 -0
  142. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/tests/test_engine_sessions.py +0 -0
  143. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/tests/test_integration.py +0 -0
  144. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/tests/test_jobs.py +0 -0
  145. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/tests/test_model_inspect.py +0 -0
  146. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/tests/test_paths.py +0 -0
  147. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/tests/test_policy.py +0 -0
  148. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/tests/test_runtime_vllm.py +0 -0
  149. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/tests/test_serve.py +0 -0
  150. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/tests/test_state.py +0 -0
  151. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/tests/test_sweep.py +0 -0
  152. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/tests/test_vast_mapper.py +0 -0
  153. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/tests/test_vast_provider.py +0 -0
  154. {gpu4agents-0.9.1 → gpu4agents-0.10.0}/tests/test_watchdog.py +0 -0
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "gpu4agents",
3
3
  "description": "Your agent rents the GPU it needs, serves a model on it and runs the experiment. You pay only while it works.",
4
- "version": "0.9.1",
4
+ "version": "0.10.0",
5
5
  "author": {
6
6
  "name": "João Gabriel Lima",
7
7
  "url": "https://www.linkedin.com/in/joaogabriellima"
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "gpu4agents",
3
3
  "description": "Your agent rents the GPU it needs, serves a model on it and runs the experiment. You pay only while it works.",
4
- "version": "0.9.1",
4
+ "version": "0.10.0",
5
5
  "author": {
6
6
  "name": "João Gabriel Lima"
7
7
  },
@@ -2,6 +2,31 @@
2
2
 
3
3
  All notable changes to this project. The format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/) and the project uses [Semantic Versioning](https://semver.org/).
4
4
 
5
+ ## [0.10.0] - 2026-11-06
6
+
7
+ ### Added
8
+ - **RunPod and Lambda are built in**, next to Vast.ai. `gpu login` lists all three, with the steps for each in plain words, and saves the one you pick; `gpu init` then writes it into `gpu.yaml` (`--provider` still overrides). The watchdog, budgets, `gpu ls`, `gpu sweep` and the MCP tools work the same on each.
9
+ - RunPod (`RUNPOD_API_KEY`) uses the REST API v2. A pod runs the model image with gpu's boot script; the model and watchdog are reached through RunPod's HTTPS proxy. Without a volume (`provider.options.volume_gb`, default 0) a stopped pod costs nothing. RunPod's API has no spot pods, and gpu does not SSH into pods: run code on the GPU with `gpu job`.
10
+ - Lambda (`LAMBDA_API_KEY`) rents whole VMs. gpu runs the model image on the VM with Docker, registers its own SSH key (kept in `$GPU_HOME/ssh/`) and creates a firewall ruleset per region for the model and watchdog ports. Lambda cannot stop a machine, so where another provider would stop, gpu and the watchdog terminate it. Instance types have a fixed GPU count (1, 2, 4 or 8).
11
+ - RunPod and Lambda report a GPU's model but not its architecture, so gpu looks it up (`providers/gpus.py`) and skips cards too old for the model image, as it already did on Vast.ai.
12
+
13
+ ### Changed
14
+ - `gpu init` without `--provider` uses the provider `gpu login` connected, instead of always Vast.ai.
15
+ - `health.pull_stall_timeout` applies only to providers that report the image pull moving while a machine boots (the new `boot_progress` capability; Vast.ai does). On the others, a long pull is waited out until `health.boot_timeout`, instead of being taken for a stall after ten quiet minutes.
16
+ - The website and docs: a table of how the three providers differ, at `/docs#providers`, and the adapter examples now use a provider that is not built in.
17
+
18
+ ## [0.9.2] - 2026-11-06
19
+
20
+ ### Changed
21
+ - `gpu login` starts by showing the providers you can use: Vast.ai, ready out of the box, or "another provider I already use", which hands the job to your agent (it writes the adapter). For Vast.ai it then lists the steps in plain words, from creating the account and adding credit to copying the key, before the hidden prompt. `--provider`, `--stdin` and a project's `gpu.yaml` skip the menu, as before.
22
+ - The messages a user sees when no account is connected, from `gpu login --check`, the installer, the skill and `install.md`, no longer assume a technical reader.
23
+
24
+ ### Fixed
25
+ - Oh My Zsh's git plugin, on by default, defines `gpu` as an alias for `git push upstream`, and an alias wins over the command, in a terminal and in an agent's shell. The installer now detects a `gpu` alias in zsh and bash and removes it for new shells, in a marked block at the end of `~/.zshrc` or `~/.bashrc` (`--keep-gpu-alias` leaves it). The command is also installed as `gpu4agents`, which no alias takes, and the skill tells the agent to check `type gpu` first and use `command gpu` when it is an alias.
26
+
27
+ ### Added
28
+ - Provider adapters can describe their own first-time walk-through for `gpu login`: `tagline`, `signup_url` and `setup_steps`.
29
+
5
30
  ## [0.9.1] - 2026-11-04
6
31
 
7
32
  ### Changed
@@ -20,21 +20,24 @@ curl -fsSL https://raw.githubusercontent.com/jambuai/gpu4agents/main/install.sh
20
20
 
21
21
  The script needs only `curl` (Linux or macOS; on Windows, run it inside WSL). It installs [uv](https://docs.astral.sh/uv/) if missing, uses it to install the `gpu4agents` package with a Python it downloads by itself, and then installs the skill and registers the `gpu` MCP server for your runtime. It does not ask for or read any key.
22
22
 
23
- Check: `~/.local/bin/gpu --version` prints 0.9.1 or later. Use `~/.local/bin/gpu` for the rest of this session if plain `gpu` is not found.
23
+ Check: `~/.local/bin/gpu --version` prints 0.10.0 or later.
24
+
25
+ For the rest of this session, call the command by its full path, `~/.local/bin/gpu`. Your shell may define `gpu` as an alias: Oh My Zsh's git plugin, on by default, makes `gpu` mean `git push upstream`, and an alias wins over the command, so plain `gpu setup` could run git instead. The installer removes that alias for new shells and says so; tell the user if it did. The same command is also installed as `gpu4agents`.
24
26
 
25
27
  ## 2. Connect a GPU provider account
26
28
 
27
- Run `gpu login --check`.
29
+ Run `~/.local/bin/gpu login --check`.
28
30
 
29
31
  - Exit code 0: an account is connected. Go to step 3.
30
- - Exit code 5: no working key yet. Ask the user which GPU provider they want to use.
31
- - Vast.ai, or no preference: tell the user, in these words or close:
32
+ - Exit code 5: no account is connected yet. Tell the user, in plain words and without technical terms, something close to this:
33
+
34
+ > One last step, about two minutes: connect the account that pays for the GPUs. Open your terminal app (not this chat) and type `gpu login`. It shows the providers you can use and walks you through it: Vast.ai works right away, and if you already use another one (RunPod, Lambda, your company's servers), pick "Another provider" and I'll add it. Your key stays on your computer; I never see it.
32
35
 
33
- > Create an API key at https://cloud.vast.ai/manage-keys/ and add a few dollars of credit. Then open your own terminal, run `gpu login`, and paste the key into the hidden prompt.
36
+ If the installer said it kept a `gpu` alias, tell them to type `gpu4agents login` instead.
34
37
 
35
- - Another provider (RunPod, Lambda, their company's cluster, ...): `gpu` needs an adapter for it first. Tell the user you can write one, and do it after this installation by following https://gpu4agents.jambu.ai/providers.md. The user then runs `gpu login --provider <name>`.
38
+ If the user picks another provider, write its adapter after this installation by following https://gpu4agents.jambu.ai/providers.md. The user then runs `gpu login --provider <name>`.
36
39
 
37
- Wait until the user says it is done, then run `gpu login --check` again. If the user wants to connect later, go on to step 3.
40
+ Wait until the user says it is done, then run `~/.local/bin/gpu login --check` again. If the user wants to connect later, go on to step 3.
38
41
 
39
42
  Never ask the user to paste a key into this conversation, never read `~/.gpu/credentials` or `.env` files, and never print a key.
40
43
 
@@ -49,7 +52,7 @@ The MCP tools (`gpu_setup`, `gpu_status`, ...) appear after the user restarts th
49
52
  Summarize in a few lines:
50
53
 
51
54
  - what was installed (the `gpu` command, the skill, the MCP server for this runtime);
52
- - whether a provider account is connected, or what they still need to do (`gpu login`, or an adapter for their provider);
55
+ - whether a provider account is connected, or what they still need to do (`gpu login` in their terminal, or an adapter for their provider), in plain words;
53
56
  - that they should restart the agent to get the tools;
54
57
  - an example request: "Compare Qwen 7B and Llama 8B on 50 prompts", and that you will show the price and ask before renting anything.
55
58
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.5
2
2
  Name: gpu4agents
3
- Version: 0.9.1
3
+ Version: 0.10.0
4
4
  Summary: GPU for Agents: your coding agent rents the GPU it needs, on its own. You pay only while it works.
5
5
  Project-URL: Homepage, https://gpu4agents.jambu.ai
6
6
  Project-URL: Documentation, https://github.com/jambuai/gpu4agents/tree/main/docs
@@ -69,7 +69,7 @@ Ask Claude Code, Codex, Gemini CLI or Cursor to "compare Qwen 7B and Llama 8B on
69
69
 
70
70
  The agent installs it from one pasted line. A skill and local MCP tools (`gpu_offers`, `gpu_setup`, `gpu_run`, `gpu_status`, `gpu_destroy`, ...) cover the whole lifecycle, and the skill tells the agent to show you the price and ask before renting. Budgets, a maximum lifetime and an account-wide sweep catch anything left behind. Apps in any language get the endpoint from `gpu --json setup`.
71
71
 
72
- Vast.ai is built in. Any other GPU provider takes one adapter file, and your agent can write it: see [Use any GPU provider](#use-any-gpu-provider).
72
+ Vast.ai, RunPod and Lambda are built in. Any other GPU provider takes one adapter file, and your agent can write it: see [Use any GPU provider](#use-any-gpu-provider).
73
73
 
74
74
  ## Installation
75
75
 
@@ -122,8 +122,8 @@ uv tool install gpu4agents && gpu agent install -t auto --global # the same,
122
122
  Run this in your own terminal, so the agent never sees the key:
123
123
 
124
124
  ```bash
125
- gpu login # Vast.ai: paste a key from https://cloud.vast.ai/manage-keys/
126
- gpu login --provider runpod # a provider you added an adapter for
125
+ gpu login # pick Vast.ai, RunPod or Lambda; it walks you through the account and the key
126
+ gpu login --provider lambda # go straight to one provider (also one you added an adapter for)
127
127
  gpu login --check # which account gpu finds, and its balance
128
128
  ```
129
129
 
@@ -164,7 +164,7 @@ Requests count as activity, so the machine stays up while clients call it and st
164
164
 
165
165
  ## Use any GPU provider
166
166
 
167
- `gpu` talks to providers through a small contract: find offers, rent, report status, stop, destroy, and two calls the watchdog makes from the machine to shut itself down. Vast.ai ships with it. For anything else, such as RunPod, Lambda or your company's cluster, paste this into your agent:
167
+ `gpu` talks to providers through a small contract: find offers, rent, report status, stop, destroy, and two calls the watchdog makes from the machine to shut itself down. Vast.ai, RunPod and Lambda ship with it. For anything else, such as CoreWeave, Paperspace or your company's cluster, paste this into your agent:
168
168
 
169
169
  ```text
170
170
  Add <provider> to GPU for Agents. Fetch https://gpu4agents.jambu.ai/providers.md with curl and follow its steps.
@@ -175,8 +175,8 @@ The agent runs `gpu providers new <name>`, fills in the adapter from the provide
175
175
  ```yaml
176
176
  gpu_runtime:
177
177
  provider:
178
- name: runpod
179
- plugin: ./gpu_providers/runpod.py:RunpodProvider
178
+ name: acme
179
+ plugin: ./gpu_providers/acme.py:AcmeProvider
180
180
  ```
181
181
 
182
182
  To reuse an adapter across projects, publish it as a package with a `gpu4agents.providers` entry point. The watchdog, budgets, CLI and MCP tools work the same with every provider. See [PROVIDERS.md](PROVIDERS.md) and [Adding a provider](docs/ADDING_A_PROVIDER.md).
@@ -1,6 +1,6 @@
1
1
  # Add a GPU provider to GPU for Agents (instructions for the agent)
2
2
 
3
- You are a coding agent, and the user wants GPU for Agents (`gpu`) to rent from a provider it does not ship with, such as RunPod, Lambda, Paperspace, a company cluster or their own servers. Vast.ai is built in. Any other provider is one Python file that implements the provider contract. The core, the watchdog that stops idle machines, the CLI and the MCP tools stay the same.
3
+ You are a coding agent, and the user wants GPU for Agents (`gpu`) to rent from a provider it does not ship with, such as CoreWeave, Paperspace, a company cluster or their own servers. Vast.ai, RunPod and Lambda are built in (`gpu login` offers them; nothing to write). Any other provider is one Python file that implements the provider contract. The core, the watchdog that stops idle machines, the CLI and the MCP tools stay the same.
4
4
 
5
5
  Follow these steps in the user's project directory. Do not rent anything until step 6, and ask first.
6
6
 
@@ -28,7 +28,7 @@ In an existing `gpu.yaml`, add those two lines under `gpu_runtime.provider` your
28
28
 
29
29
  ## 3. Read the provider's API docs, then fill in the file
30
30
 
31
- Every `todo(...)` call marks a part that needs the provider's API; until you write it, that part fails with a clear error (exit 9). Read the contract in `gpu4agents/providers/base.py` (run `python -c "import gpu4agents.providers.base as b; print(b.__file__)"` to find it) and the guide at https://github.com/jambuai/gpu4agents/blob/main/docs/ADDING_A_PROVIDER.md. The Vast.ai adapter in `gpu4agents/providers/vast/` is a full working example.
31
+ Every `todo(...)` call marks a part that needs the provider's API; until you write it, that part fails with a clear error (exit 9). Read the contract in `gpu4agents/providers/base.py` (run `python -c "import gpu4agents.providers.base as b; print(b.__file__)"` to find it) and the guide at https://github.com/jambuai/gpu4agents/blob/main/docs/ADDING_A_PROVIDER.md. The built-in adapters are full working examples: `gpu4agents/providers/vast/` (a marketplace of containers), `runpod/` (containers behind an HTTPS proxy) and `lambdacloud/` (whole VMs, where the image runs under Docker and the machine can only be terminated).
32
32
 
33
33
  What each part must do:
34
34
 
@@ -28,7 +28,7 @@ Ask Claude Code, Codex, Gemini CLI or Cursor to "compare Qwen 7B and Llama 8B on
28
28
 
29
29
  The agent installs it from one pasted line. A skill and local MCP tools (`gpu_offers`, `gpu_setup`, `gpu_run`, `gpu_status`, `gpu_destroy`, ...) cover the whole lifecycle, and the skill tells the agent to show you the price and ask before renting. Budgets, a maximum lifetime and an account-wide sweep catch anything left behind. Apps in any language get the endpoint from `gpu --json setup`.
30
30
 
31
- Vast.ai is built in. Any other GPU provider takes one adapter file, and your agent can write it: see [Use any GPU provider](#use-any-gpu-provider).
31
+ Vast.ai, RunPod and Lambda are built in. Any other GPU provider takes one adapter file, and your agent can write it: see [Use any GPU provider](#use-any-gpu-provider).
32
32
 
33
33
  ## Installation
34
34
 
@@ -81,8 +81,8 @@ uv tool install gpu4agents && gpu agent install -t auto --global # the same,
81
81
  Run this in your own terminal, so the agent never sees the key:
82
82
 
83
83
  ```bash
84
- gpu login # Vast.ai: paste a key from https://cloud.vast.ai/manage-keys/
85
- gpu login --provider runpod # a provider you added an adapter for
84
+ gpu login # pick Vast.ai, RunPod or Lambda; it walks you through the account and the key
85
+ gpu login --provider lambda # go straight to one provider (also one you added an adapter for)
86
86
  gpu login --check # which account gpu finds, and its balance
87
87
  ```
88
88
 
@@ -123,7 +123,7 @@ Requests count as activity, so the machine stays up while clients call it and st
123
123
 
124
124
  ## Use any GPU provider
125
125
 
126
- `gpu` talks to providers through a small contract: find offers, rent, report status, stop, destroy, and two calls the watchdog makes from the machine to shut itself down. Vast.ai ships with it. For anything else, such as RunPod, Lambda or your company's cluster, paste this into your agent:
126
+ `gpu` talks to providers through a small contract: find offers, rent, report status, stop, destroy, and two calls the watchdog makes from the machine to shut itself down. Vast.ai, RunPod and Lambda ship with it. For anything else, such as CoreWeave, Paperspace or your company's cluster, paste this into your agent:
127
127
 
128
128
  ```text
129
129
  Add <provider> to GPU for Agents. Fetch https://gpu4agents.jambu.ai/providers.md with curl and follow its steps.
@@ -134,8 +134,8 @@ The agent runs `gpu providers new <name>`, fills in the adapter from the provide
134
134
  ```yaml
135
135
  gpu_runtime:
136
136
  provider:
137
- name: runpod
138
- plugin: ./gpu_providers/runpod.py:RunpodProvider
137
+ name: acme
138
+ plugin: ./gpu_providers/acme.py:AcmeProvider
139
139
  ```
140
140
 
141
141
  To reuse an adapter across projects, publish it as a package with a `gpu4agents.providers` entry point. The watchdog, budgets, CLI and MCP tools work the same with every provider. See [PROVIDERS.md](PROVIDERS.md) and [Adding a provider](docs/ADDING_A_PROVIDER.md).
@@ -1,6 +1,6 @@
1
1
  # Adding a provider
2
2
 
3
- Vast.ai is the built-in provider. Any other provider is a class that implements
3
+ Vast.ai, RunPod and Lambda are built in. Any other provider is a class that implements
4
4
  the contract in `gpu4agents/providers/base.py`. Lifecycle, execution and CLI code
5
5
  stay the same; if you find yourself editing `core/`, the contract is leaking.
6
6
 
@@ -30,16 +30,16 @@ The rest of this guide applies to all three routes.
30
30
  ## 1. Implement the contract
31
31
 
32
32
  ```python
33
- # gpu4agents/providers/runpod/provider.py
33
+ # gpu4agents/providers/acme/provider.py
34
34
  from ...core.models import ProviderCapabilities
35
35
  from ..base import GPUProvider, WatchdogSpec
36
36
 
37
37
 
38
- class RunpodProvider(GPUProvider):
39
- name = "runpod"
40
- display_name = "RunPod"
41
- required_credentials = ["RUNPOD_API_KEY"]
42
- credentials_url = "https://www.runpod.io/console/user/settings"
38
+ class AcmeProvider(GPUProvider):
39
+ name = "acme"
40
+ display_name = "Acme GPU"
41
+ required_credentials = ["ACME_API_KEY"]
42
+ credentials_url = "https://console.acme.example/api-keys"
43
43
  capabilities = ProviderCapabilities(
44
44
  stop=True,
45
45
  destroy=True,
@@ -64,16 +64,16 @@ class RunpodProvider(GPUProvider):
64
64
  def logs(self, instance): ...
65
65
  ```
66
66
 
67
- `gpu login --provider runpod` prompts for each name in `required_credentials`,
67
+ `gpu login --provider acme` prompts for each name in `required_credentials`,
68
68
  passes the values to `verify_credentials`, and saves them in
69
69
  `~/.gpu/credentials` only if it returns. Raise `AuthenticationError` for a
70
70
  rejected key, and return only fields that are safe to print, such as
71
71
  `{"balance_usd": 12.5}`.
72
72
 
73
- For an adapter that ships in this repository, mirror the Vast layout:
73
+ For an adapter that ships in this repository, mirror the layout of `vast/`, `runpod/` or `lambdacloud/`:
74
74
 
75
75
  ```
76
- providers/runpod/
76
+ providers/acme/
77
77
  ├── provider.py the contract implementation
78
78
  ├── client.py raw HTTP; the ONLY place that knows the wire format
79
79
  ├── mapper.py payloads <-> normalized models, state mapping
@@ -86,6 +86,10 @@ The core branches on `provider.capabilities`, never on `provider.name`. Set
86
86
  `stop_eliminates_billing=False` if a stopped instance still costs money; the policy
87
87
  then knows it may need to escalate to destroy, and `lifecycle.stopped_ttl` applies.
88
88
 
89
+ Set `boot_progress=True` only if, while the machine boots, `status().message` shows the image
90
+ pull moving (a new line per layer, as Vast.ai does). The core then gives up on a pull that
91
+ stops moving for `health.pull_stall_timeout`; without it, only `health.boot_timeout` applies.
92
+
89
93
  Set `list_instances=True` and implement `list_instances()` if the API can enumerate
90
94
  the account. Return only instances whose label starts with `JAMBU_LABEL_PREFIX`
91
95
  (`core/models.py`); `gpu ls` and `gpu sweep` are built on it and stay unavailable
@@ -123,7 +127,7 @@ def provider_destroy(ctx):
123
127
  def watchdog_spec(self, spec_or_instance=None):
124
128
  return WatchdogSpec(
125
129
  actions_source=WATCHDOG_ACTIONS,
126
- env={"RUNPOD_API_KEY": self.credentials.get("RUNPOD_API_KEY") or ""},
130
+ env={"ACME_API_KEY": self.credentials.get("ACME_API_KEY") or ""},
127
131
  context={"provider": self.name},
128
132
  )
129
133
  ```
@@ -151,10 +155,10 @@ ships in this repository is added here:
151
155
  # providers/registry.py
152
156
  def load_builtin_providers():
153
157
  from .vast.provider import VastProvider
154
- from .runpod.provider import RunpodProvider
158
+ from .acme.provider import AcmeProvider
155
159
 
156
160
  registry.register(VastProvider)
157
- registry.register(RunpodProvider)
161
+ registry.register(AcmeProvider)
158
162
  return registry
159
163
  ```
160
164
 
@@ -34,13 +34,19 @@ The repository is a Claude Code plugin marketplace (`.claude-plugin/`) and a Cur
34
34
  The user, in their own terminal:
35
35
 
36
36
  ```bash
37
- gpu login # hidden prompt; checks the key with the provider, then saves it
38
- gpu login --provider runpod # a provider added with an adapter
37
+ gpu login # the first time: pick a provider, follow the steps, paste the key (hidden)
38
+ gpu login --provider runpod # straight to one provider (built in, or one added with an adapter)
39
39
  gpu login --check # exit 0, the provider and where the key was found; or exit 5
40
40
  echo "$KEY" | gpu login --stdin
41
41
  ```
42
42
 
43
- The provider is the one `--provider` names, else the project's `gpu.yaml`, else `GPU_PROVIDER`, else Vast.ai. `gpu login --provider NAME` also saves `GPU_PROVIDER=NAME`, so `gpu ls` and `gpu sweep` outside a project use that provider. The key goes to `~/.gpu/credentials` (mode 600, directory 700); other lines in the file are kept. A key in the environment or a project `.env` still works and wins over the file. The skill tells the agent never to ask for the key in chat, read those files, or print it.
43
+ Run with no project and no saved provider, `gpu login` first lists the providers it can use: Vast.ai, RunPod and Lambda, ready out of the box, and "another provider I already use", which tells the user to ask their agent to add it ([`PROVIDERS.md`](../PROVIDERS.md)). For the chosen provider it then shows the steps in plain words (create the account, add credit or a card, copy the key) before the hidden prompt. An adapter supplies its own steps with `tagline`, `signup_url` and `setup_steps`.
44
+
45
+ Otherwise the provider is the one `--provider` names, else the project's `gpu.yaml`, else `GPU_PROVIDER`, else Vast.ai. `gpu login --provider NAME` also saves `GPU_PROVIDER=NAME`, so `gpu ls` and `gpu sweep` outside a project use that provider, and `gpu init` writes it into a new `gpu.yaml`. The key goes to `~/.gpu/credentials` (mode 600, directory 700); other lines in the file are kept. A key in the environment or a project `.env` still works and wins over the file. The skill tells the agent never to ask for the key in chat, read those files, or print it.
46
+
47
+ ## When `gpu` is a shell alias
48
+
49
+ Oh My Zsh's git plugin, on by default, defines `gpu` as `git push upstream`. An alias wins over the command, in a terminal and in the agent's shell, so `gpu login` runs git instead (and in a repository with an `upstream` remote, it pushes). The installer looks for a `gpu` alias in zsh and bash and adds a marked block at the end of `~/.zshrc` or `~/.bashrc` that removes it for new shells; `--keep-gpu-alias` leaves it. The same command is always installed as `gpu4agents` too, and the skill tells the agent to run `type gpu` first and use `command gpu` when it is an alias. The MCP server is unaffected: clients start it without a shell.
44
50
 
45
51
  ## Install by hand
46
52
 
@@ -52,8 +52,8 @@ for why this exists and `gpu profiles` / `gpu inspect-model
52
52
 
53
53
  | Field | Default | Meaning |
54
54
  | --- | --- | --- |
55
- | `name` | `vast` | Adapter to use. `gpu providers` lists what is available. |
56
- | `profile` | `default` | Credential profile. Looks up `VAST_API_KEY__<profile>` before `VAST_API_KEY`. |
55
+ | `name` | `vast` | Adapter to use: `vast`, `runpod`, `lambda`, or one you added. `gpu providers` lists what is available. `gpu init` writes the one `gpu login` connected. |
56
+ | `profile` | `default` | Credential profile. Looks up `VAST_API_KEY__<profile>` (or `RUNPOD_API_KEY__<profile>`, ...) before the plain name. |
57
57
  | `options` | `{}` | Provider-specific tuning, validated by the adapter (see below). |
58
58
 
59
59
  ### `provider.options` for vast
@@ -71,6 +71,40 @@ for why this exists and `gpu profiles` / `gpu inspect-model
71
71
  | `image_login` | – | `-u user -p pass docker.io` for a private image. |
72
72
  | `search_filters` | – | Raw extra filters merged into the offer query. |
73
73
 
74
+ ### `provider.options` for runpod
75
+
76
+ A pod is a container. Its model and watchdog ports are reached through RunPod's
77
+ HTTPS proxy (`https://POD-PORT.proxy.runpod.net`), which ends a single request after
78
+ 100 seconds; streamed answers are not cut. RunPod's API has no spot pods, and `gpu`
79
+ does not SSH into pods, so `workload.mode: remote` is refused (use `gpu job`).
80
+
81
+ | Field | Default | Meaning |
82
+ | --- | --- | --- |
83
+ | `api_base` | `https://api.runpod.io` | REST API v2 endpoint. |
84
+ | `cloud` | `any` | `secure` (RunPod's own data centers), `community` (vetted hosts) or `any` (the cheaper of the two). |
85
+ | `volume_gb` | `0` | Persistent volume at `/workspace`. With none, a stopped pod costs nothing but downloads the model again when it starts. With one, a stopped pod bills the volume, so `lifecycle.stopped_ttl` applies. |
86
+ | `skip_low_availability` | `false` | Leave out GPU types RunPod reports as scarce. |
87
+
88
+ `compute.region` picks data centers by prefix: `US`, `EU-RO-1`, `US-TX,CA`.
89
+
90
+ ### `provider.options` for lambda
91
+
92
+ A Lambda machine is a whole VM. `gpu` runs the model image on it with Docker, and
93
+ opens the model and watchdog ports with a firewall ruleset it creates per region
94
+ (`gpu4agents-PORT-PORT`). Lambda cannot stop a machine, only terminate it, so where
95
+ another provider would stop, `gpu` and the watchdog terminate. Instance types have a
96
+ fixed GPU count (1, 2, 4 or 8) and a fixed disk; `compute.gpu.count` must match one.
97
+ `gpu` keeps the SSH key it registers with Lambda in `$GPU_HOME/ssh/lambda_ed25519`.
98
+
99
+ | Field | Default | Meaning |
100
+ | --- | --- | --- |
101
+ | `api_base` | `https://cloud.lambda.com/api/v1` | API endpoint. |
102
+ | `image_family` | – | VM image, e.g. `lambda-stack-22-04`. Unset: Lambda's default, which has Docker and the NVIDIA container toolkit. |
103
+ | `allow_arm64` | `false` | Also rent Arm machines (GH200). The usual model images are x86 only. |
104
+ | `source_network` | `0.0.0.0/0` | Who may reach the model and watchdog ports. The model still demands its API key and the watchdog its token. |
105
+
106
+ `compute.region` picks regions by prefix: `us-east`, `europe-central-1`.
107
+
74
108
  ## `compute`
75
109
 
76
110
  `gpu inspect-model <repo>` reads a model's HuggingFace metadata and suggests
@@ -1,5 +1,5 @@
1
1
  """GPU for Agents: GPUs your agent rents on its own, billed only while they work."""
2
2
 
3
- __version__ = "0.9.1"
3
+ __version__ = "0.10.0"
4
4
 
5
5
  __all__ = ["__version__"]
@@ -59,7 +59,7 @@ EXIT_MEANINGS = {
59
59
  }
60
60
 
61
61
  INSTRUCTIONS = """\
62
- gpu rents a cloud GPU (Vast.ai built in; other providers through an adapter),
62
+ gpu rents a cloud GPU (Vast.ai, RunPod and Lambda built in; other providers through an adapter),
63
63
  serves a model on it behind an OpenAI-compatible API, and stops it by itself
64
64
  when nobody uses it. Any Hugging Face model: chat models on vLLM; image,
65
65
  speech, transcription, embeddings and other pipeline models on gpu's own
@@ -7,7 +7,7 @@ description: GPU for Agents. Rent a cloud GPU on your own, serve an open-weights
7
7
 
8
8
  `gpu` (the `gpu4agents` package) rents a machine from a GPU provider, serves a model on it with vLLM behind an OpenAI-compatible API or runs your own code on it as a job, and installs a watchdog on the machine. The watchdog shuts the machine down once nothing has used it for `idle_timeout` (15 min by default), so billing ends even if this conversation does.
9
9
 
10
- Vast.ai is built in. Any other provider (RunPod, Lambda, a company cluster) plugs in through an adapter: one Python file that implements the provider contract. See "Another provider" below.
10
+ Vast.ai, RunPod and Lambda are built in. Any other provider (CoreWeave, Paperspace, a company cluster) plugs in through an adapter: one Python file that implements the provider contract. See "Another provider" below.
11
11
 
12
12
  Each project directory has a `gpu.yaml` (what to rent and serve, and from which provider) and a `.gpu/` directory (what was rented). One project, one machine.
13
13
 
@@ -17,7 +17,7 @@ Do these in order. Skip a step whose check already passes.
17
17
 
18
18
  ### 1. Install the `gpu` command
19
19
 
20
- Check: `gpu --version` prints 0.9.1 or later. If the command is missing or older, install it (Linux and macOS; on Windows, use WSL):
20
+ Check: `gpu --version` prints 0.10.0 or later. First run `type gpu`: if it says `gpu` is an alias or a function (Oh My Zsh's git plugin makes it `git push upstream`), plain `gpu` runs that instead, so use `command gpu`, `~/.local/bin/gpu` or `gpu4agents` for every command in this session. In a git repository the alias would really push. If the command is missing or older, install it (Linux and macOS; on Windows, use WSL):
21
21
 
22
22
  ```bash
23
23
  curl -fsSL https://gpu4agents.jambu.ai/install.sh | sh -s -- --agent <runtime>
@@ -31,10 +31,11 @@ To install by hand: `uv tool install --python 3.12 gpu4agents`, or `pipx install
31
31
 
32
32
  Check: `gpu login --check` exits 0. It prints the provider, where the key was found, and the balance when the provider reports one.
33
33
 
34
- If it exits 5, there is no working key yet. Ask the user which provider they want, then tell them, in these words or close:
34
+ If it exits 5, no account is connected yet. The user may not be technical, so skip jargon like "API key" and tell them, in these words or close:
35
35
 
36
- - Vast.ai (built in): "Create an API key at https://cloud.vast.ai/manage-keys/ and add a few dollars of credit. Then open your own terminal, run `gpu login`, and paste the key into the hidden prompt."
37
- - Any other provider: write its adapter first ("Another provider" below), then ask the user to run `gpu login --provider <name>` in their own terminal.
36
+ > One step left, about two minutes: connect the account that pays for the GPUs. Open your terminal app (not this chat) and type `gpu login`. It shows the providers you can use and walks you through it: Vast.ai, RunPod and Lambda work right away, and if you already use another one (your company's servers, for example), pick "Another provider" and I'll add it. Your key stays on your computer; I never see it.
37
+
38
+ If they pick another provider, write its adapter ("Another provider" below), then ask them to run `gpu login --provider <name>` in their terminal.
38
39
 
39
40
  Wait for them to say it is done, then run `gpu login --check` again.
40
41
 
@@ -150,6 +151,7 @@ Exit codes are the same for the CLI and the MCP tools (`exit_code` in the error)
150
151
  | 12 | another gpu command (a setup) holds the project | follow it with `gpu_setup`; `gpu_stop` / `gpu_destroy` cancel it |
151
152
 
152
153
  - `gpu: command not found` right after installing: use `~/.local/bin/gpu`, or open a new shell.
154
+ - `gpu` prints a git error (`fatal: not a git repository`, or it pushed): `gpu` is a shell alias (Oh My Zsh). Use `command gpu` or `gpu4agents`, and tell the user the installer can remove the alias for new terminals.
153
155
  - Requests fail with connection refused or a timeout: the machine was stopped for being idle. Call `gpu_setup` again (about a minute), take the new `base_url` from its output, and retry once.
154
156
  - `401`: a new machine was rented and the key changed; take it from `gpu_connection`.
155
157
  - A long job with quiet stretches longer than `idle_timeout`: `gpu_lock(duration="2h")`, then `gpu_unlock`.
@@ -390,14 +390,14 @@ def login_command(
390
390
  try:
391
391
  cls, credentials = _login_target(context, provider)
392
392
  names = list(cls.required_credentials)
393
- where_to_get = f" (create one at {cls.credentials_url})" if cls.credentials_url else ""
394
393
  if check:
395
394
  missing = [name for name in names if not credentials.get(name)]
396
395
  if missing:
397
396
  raise AuthenticationError(
398
- f"no {cls.display_name} credentials found ({', '.join(missing)}); "
399
- f"run `gpu login{'' if provider is None else ' --provider ' + cls.name}` "
400
- f"in a terminal{where_to_get}"
397
+ f"no GPU provider account is connected yet ({cls.display_name}: "
398
+ f"{', '.join(missing)} not found). In your own terminal, run "
399
+ f"`gpu login{'' if provider is None else ' --provider ' + cls.name}`: "
400
+ "it walks you through it in about two minutes"
401
401
  )
402
402
  values = {name: credentials.get(name) or "" for name in names}
403
403
  source = (credentials.file_source(names[0]) or "environment") if names else "none needed"
@@ -420,11 +420,17 @@ def login_command(
420
420
  "gpu login needs a terminal for the hidden prompt; "
421
421
  "run it in your own terminal, or pipe the key with --stdin"
422
422
  )
423
- if cls.credentials_url:
424
- typer.echo(f"Create a key at {cls.credentials_url}", err=True)
423
+ if provider is None and _choose_freely(context):
424
+ cls = _choose_provider(registry_classes(), cls)
425
+ if cls is None:
426
+ return
427
+ names = list(cls.required_credentials)
428
+ provider = cls.name
429
+ _walk_through(cls)
425
430
  for name in names:
431
+ label = "your key" if len(names) == 1 else name
426
432
  values[name] = getpass.getpass(
427
- f"{cls.display_name} {name} (input hidden): "
433
+ f"Paste {label} here and press Enter (it stays hidden): "
428
434
  ).strip()
429
435
  empty = [name for name, value in values.items() if not value]
430
436
  if empty:
@@ -443,6 +449,69 @@ def login_command(
443
449
  return
444
450
  where = summary.get("saved") or summary.get("source")
445
451
  balance = summary.get("balance_usd")
446
- console.print(Text(f"{cls.display_name} credentials work ({where})", style="green"))
452
+ console.print(Text(f"{cls.display_name} is connected ({where}).", style="green"))
447
453
  if balance is not None:
448
- console.print(Text(f"balance: ${balance:.2f}", style="dim"))
454
+ console.print(Text(f"Credit: ${balance:.2f}", style="dim"))
455
+ if balance <= 0:
456
+ console.print(Text("Add some credit before your agent rents a GPU.", style="yellow"))
457
+ if not check:
458
+ console.print("Go back to your agent and tell it you're done.")
459
+
460
+
461
+ def registry_classes() -> list:
462
+ return list(load_builtin_providers().classes())
463
+
464
+
465
+ def _choose_freely(context: Context) -> bool:
466
+ """No project and no saved default: the user picks the provider."""
467
+ if context.config_path is not None or find_config() is not None:
468
+ return False
469
+ return not account_credentials(Path.cwd()).get(PROVIDER_SETTING)
470
+
471
+
472
+ def _choose_provider(classes: list, default):
473
+ """Show what is available and return the chosen adapter, or None for "another one"."""
474
+ classes = sorted(classes, key=lambda c: (c is not default, c.display_name))
475
+ console.print("[bold]Connect a GPU provider[/bold], so your agent can rent GPUs on its own.")
476
+ console.print("Your key stays on this computer; the agent never sees it.\n")
477
+ for i, item in enumerate(classes, 1):
478
+ note = f" [dim]{item.tagline}[/dim]" if item.tagline else ""
479
+ console.print(f" {i}) {item.display_name}{note}", highlight=False)
480
+ other = len(classes) + 1
481
+ console.print(
482
+ f" {other}) Another provider I already use "
483
+ "[dim]CoreWeave, Paperspace, my company's servers, ...: your agent adds it[/dim]\n",
484
+ highlight=False,
485
+ )
486
+ choice = typer.prompt("Choose", default="1", err=True).strip()
487
+ try:
488
+ index = int(choice)
489
+ except ValueError:
490
+ index = 0
491
+ if 1 <= index <= len(classes):
492
+ return classes[index - 1]
493
+ if index != other:
494
+ raise ConfigError(f"choose a number from 1 to {other}")
495
+ console.print(
496
+ "\nAsk your agent, naming the provider:\n"
497
+ " [cyan]Add PROVIDER as a GPU provider to GPU for Agents. Fetch "
498
+ "https://gpu4agents.jambu.ai/providers.md with curl and follow its steps.[/cyan]\n"
499
+ "It writes the connection for you, then asks you to run "
500
+ "[bold]gpu login --provider NAME[/bold] here to paste that provider's key.",
501
+ highlight=False,
502
+ )
503
+ return None
504
+
505
+
506
+ def _walk_through(cls) -> None:
507
+ """The steps from no account to a key, in plain words."""
508
+ steps = list(cls.setup_steps)
509
+ if not steps and cls.credentials_url:
510
+ steps = ["Create a key at {credentials_url} and copy it."]
511
+ if not steps:
512
+ return
513
+ console.print(f"\n[bold]{cls.display_name}[/bold], in {len(steps)} steps:", highlight=False)
514
+ for i, step in enumerate(steps, 1):
515
+ text = step.format(signup_url=cls.signup_url or cls.credentials_url, credentials_url=cls.credentials_url)
516
+ console.print(f" {i}. {text}", soft_wrap=True, highlight=False)
517
+ console.print("[dim]Already have an account? Skip to the key.[/dim]\n")
@@ -155,8 +155,8 @@ def providers_command(ctx: typer.Context) -> None:
155
155
  if row["missing_credentials"]:
156
156
  console.print(
157
157
  Text(
158
- f" {row['provider']}: set "
159
- + ", ".join(row["missing_credentials"]),
158
+ f" {row['provider']}: not connected; run `gpu login --provider {row['provider']}` "
159
+ "in your terminal",
160
160
  style="yellow",
161
161
  )
162
162
  )
@@ -28,10 +28,13 @@ from ._common import console, fmt_money, get_context, handle, print_json, regist
28
28
  def init_command(
29
29
  ctx: typer.Context,
30
30
  model: str = typer.Option("empero-ai/Qwythos-9B-v2", "--model", help="HuggingFace model id."),
31
- provider: str = typer.Option(
32
- "vast",
31
+ provider: Optional[str] = typer.Option(
32
+ None,
33
33
  "--provider",
34
- help="GPU provider. One gpu does not ship is loaded from gpu_providers/NAME.py (gpu providers new NAME).",
34
+ help=(
35
+ "GPU provider: vast, runpod or lambda (default: the one `gpu login` connected, else vast). "
36
+ "One gpu does not ship is loaded from gpu_providers/NAME.py (gpu providers new NAME)."
37
+ ),
35
38
  ),
36
39
  jobs: bool = typer.Option(
37
40
  False,
@@ -78,6 +81,9 @@ def init_command(
78
81
  from ..providers import scaffold
79
82
  from ..providers.registry import load_builtin_providers
80
83
 
84
+ from .account import default_provider_name
85
+
86
+ provider = provider or default_provider_name()
81
87
  try:
82
88
  credential_names = list(load_builtin_providers().get_class(provider).required_credentials)
83
89
  plugin = None
@@ -182,7 +188,7 @@ def init_command(
182
188
  console.print(
183
189
  Text(f"! {provider} is not built in: run `gpu providers new {provider}` and fill in the adapter", style="yellow")
184
190
  )
185
- login = "gpu login" if provider == "vast" else f"gpu login --provider {provider}"
191
+ login = f"gpu login --provider {provider}"
186
192
  console.print(f"next: {login} && gpu validate")
187
193
  if engine == "none":
188
194
  console.print("then: gpu job run -- python your_script.py (see `gpu job --help`)")
@@ -823,7 +823,9 @@ class Engine:
823
823
  instance = state.instance
824
824
  assert instance is not None
825
825
  boot_timeout = self.config.boot_timeout_s
826
- stall_timeout = self.config.pull_stall_timeout_s
826
+ stall_timeout = (
827
+ self.config.pull_stall_timeout_s if self.provider.capabilities.boot_progress else None
828
+ )
827
829
  deadline = time.time() + boot_timeout
828
830
  announced = False
829
831
  # Live, healthy pulls printed a new line every 1-8 minutes; stalled ones
@@ -80,6 +80,10 @@ class ProviderCapabilities:
80
80
  stop_eliminates_billing: bool = True
81
81
  # Can enumerate this tool's instances account-wide (`gpu ls`, `gpu sweep`).
82
82
  list_instances: bool = False
83
+ # While booting, the status message shows the image pull moving (a new
84
+ # line per layer). Only then can a stalled pull be told from a slow one
85
+ # (health.pull_stall_timeout); otherwise boot_timeout alone applies.
86
+ boot_progress: bool = False
83
87
 
84
88
  def as_row(self) -> dict[str, str]:
85
89
  return {k: ("yes" if v else "no") for k, v in self.__dict__.items()}