Skip to content

feat(install): add express install prompt for DGX Spark and Station#3317

Merged
ericksoa merged 6 commits into
mainfrom
feat/install-express-spark-station
May 11, 2026
Merged

feat(install): add express install prompt for DGX Spark and Station#3317
ericksoa merged 6 commits into
mainfrom
feat/install-express-spark-station

Conversation

@zyang-dev

@zyang-dev zyang-dev commented May 10, 2026

Copy link
Copy Markdown
Contributor

Summary

On DGX Spark and DGX Station, install.sh now offers an "express install" that auto-configures local inference and applies the suggested security policy after the user has accepted the third-party software notice. The license prompt is unbundled from express — the user is shown the third-party notice first, types yes to accept it, and only then sees the express prompt. Skipped silently on other platforms; users who already set --non-interactive or NEMOCLAW_PROVIDER are unaffected.

Changes

  • scripts/install.sh:
    • New detect_express_platform() reads /sys/class/dmi/id/product_name (DMI) with a /sys/firmware/devicetree/base/model fallback. Echoes "DGX Spark", "DGX Station", or empty.
    • New maybe_offer_express_install() skips silently when not on a supported platform. On Spark/Station, prints the skip reason if --non-interactive, NEMOCLAW_PROVIDER, or no TTY would block the prompt; otherwise asks: Run express install (auto-configures inference and applies suggested security policy)? [Y/n].
    • On Y, exports NEMOCLAW_NON_INTERACTIVE=1, NEMOCLAW_YES=1, NEMOCLAW_POLICY_MODE=suggested, plus NEMOCLAW_PROVIDER=install-ollama + NEMOCLAW_MODEL=qwen3.6:35b for Spark, or NEMOCLAW_PROVIDER=install-vllm for Station. Does not auto-accept the third-party notice; that's handled by the existing preflight prompt.
    • Reordered main() so preflight_usage_notice_prompt runs before maybe_offer_express_install. The user always sees and explicitly accepts the third-party notice (or pre-accepts via env var) before the express question.
  • test/install-preflight.test.ts:
    • runInstallerWithTty (and its piped/interactive wrappers) now sets NEMOCLAW_NO_EXPRESS=1 in the test env so the existing license-flow tests stay focused on what they're verifying when run on real Spark/Station hardware.

Type of Change

  • Code change (feature, bug fix, or refactor)
  • Code change with doc updates
  • Doc only (prose changes, no code sample modifications)
  • Doc only (includes code sample changes)

Verification

  • npx prek run --all-files passes
  • npm test passes
  • Tests added or updated for new or changed behavior
  • No secrets, API keys, or credentials committed
  • Docs updated for user-facing behavior changes
  • make docs builds without warnings (doc changes only)
  • Doc pages follow the style guide (doc changes only)
  • New doc pages include SPDX header and frontmatter (new pages only)

Signed-off-by: zyang-dev 267119621+zyang-dev@users.noreply.github.com

Summary by CodeRabbit

  • New Features

    • Installer detects DGX Spark and DGX Station and offers an optional "express install" after third‑party license acceptance.
    • Express install applies platform-specific defaults (provider/model) and is skipped when non‑interactive, when explicit overrides exist, or when no TTY is present.
  • Tests

    • Preflight tests disable the express prompt for deterministic license/atomic flows and add tests verifying prompt behavior (offer when interactive, skip without a TTY).

Review Change Stack

zyang-dev added 3 commits May 9, 2026 09:05
Signed-off-by: zyang-dev <267119621+zyang-dev@users.noreply.github.com>
Signed-off-by: zyang-dev <267119621+zyang-dev@users.noreply.github.com>
Signed-off-by: zyang-dev <267119621+zyang-dev@users.noreply.github.com>
@coderabbitai

coderabbitai Bot commented May 10, 2026

Copy link
Copy Markdown
Contributor
📝 Walkthrough

Walkthrough

Adds DGX platform detection and an interactive express-install offer for DGX Spark/Station after the third‑party notice; accepting sets non-interactive/yes/policy env and platform-specific provider/model defaults. Tests opt out of the express prompt during preflight runs.

Changes

Express Install Platform Detection

Layer / File(s) Summary
Platform Detection
scripts/install.sh
detect_express_platform() reads DMI product_name and falls back to devicetree model to classify DGX Spark or DGX Station.
Express Install Prompt and Configuration
scripts/install.sh
maybe_offer_express_install() conditionally prompts on supported platforms (TTY present, interactive, no pre-set provider, NEMOCLAW_NO_EXPRESS not 1); on acceptance exports NEMOCLAW_NON_INTERACTIVE=1, NEMOCLAW_YES=1, NEMOCLAW_POLICY_MODE=suggested, and sets platform defaults (Spark: install-ollama + qwen3.6:35b; Station: install-vllm).
Main Function Integration
scripts/install.sh
main() invokes maybe_offer_express_install immediately after preflight_usage_notice_prompt.
Tests / Express Prompt Suite
test/install-preflight.test.ts
Adds PTY-based tests that simulate TTY vs no-TTY to verify express offer/accept behavior and printed env-like outputs; test helper runInstallerWithTty sets NEMOCLAW_NO_EXPRESS="1" to prevent express prompts from consuming test input during license/atomicity tests.

Sequence Diagram(s)

sequenceDiagram
  participant main
  participant preflight_usage_notice_prompt
  participant maybe_offer_express_install
  main->>preflight_usage_notice_prompt: show third-party notice
  preflight_usage_notice_prompt-->>main: return after acceptance
  main->>maybe_offer_express_install: attempt express offer (if platform & TTY & no overrides)
  maybe_offer_express_install-->>main: return (may export env and set provider/model)
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Poem

A rabbit hops where DGX lights gleam,
It peeks the model, plans a scheme,
Offers quick install, gentle and spry,
Defaults set with a blink of its eye,
🐇✨

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 50.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The PR title clearly and concisely describes the main feature addition: an express install prompt for DGX Spark and Station platforms, which is the primary objective of the changeset.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/install-express-spark-station

Tip

💬 Introducing Slack Agent: The best way for teams to turn conversations into code.

Slack Agent is built on CodeRabbit's deep understanding of your code, so your team can collaborate across the entire SDLC without losing context.

  • Generate code and open pull requests
  • Plan features and break down work
  • Investigate incidents and troubleshoot customer tickets together
  • Automate recurring tasks and respond to alerts with triggers
  • Summarize progress and report instantly

Built for teams:

  • Shared memory across your entire org—no repeating context
  • Per-thread sandboxes to safely plan and execute work
  • Governance built-in—scoped access, auditability, and budget controls

One agent for your entire SDLC. Right inside Slack.

👉 Get started


Comment @coderabbitai help to get the list of available commands and usage tips.

@zyang-dev zyang-dev self-assigned this May 10, 2026

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@scripts/install.sh`:
- Around line 1698-1704: maybe_offer_express_install currently never respects a
hard opt-out env var; update the function to honor NEMOCLAW_NO_EXPRESS by
checking it at the start of maybe_offer_express_install and returning
immediately when set (e.g., when NEMOCLAW_NO_EXPRESS equals "1" or a truthy
value) before calling detect_express_platform; this ensures automation/tests can
skip the express prompt path by setting NEMOCLAW_NO_EXPRESS and leaves the rest
of the function (including the call to detect_express_platform) unchanged.
- Around line 1720-1725: The current read call `read -r reply </dev/tty || true`
silences TTY read failures and leaves `reply` empty, which matches the
default-accept branch; change this so a failed read sets a negative/decline
value instead of empty. Replace the `read -r reply </dev/tty || true` with logic
that checks the read exit status (e.g., `if ! read -r reply </dev/tty; then
reply="n"; fi`) so that on read failure `reply` is explicitly "n" (or "no") and
will not fall through to the `"" | y | yes)` accept case; keep the subsequent
normalization `reply="$(printf "%s" "$reply" | tr '[:upper:]' '[:lower:]')"` and
existing case handling.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: f48d0ab5-471a-4447-88d4-36e8389d05c2

📥 Commits

Reviewing files that changed from the base of the PR and between 34d9f61 and dcb98cd.

📒 Files selected for processing (1)
  • scripts/install.sh

Comment thread scripts/install.sh
Comment thread scripts/install.sh Outdated
Signed-off-by: zyang-dev <267119621+zyang-dev@users.noreply.github.com>

@ericksoa ericksoa left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for splitting the license notice from the express prompt and addressing the CodeRabbit items. I think this still needs one installer-flow fix before approval.

The express prompt is gated on if [ ! -t 0 ]; then ... skip, but the canonical installer path is curl -fsSL https://www.nvidia.com/nemoclaw.sh | bash, where stdin is the script pipe even in a real interactive terminal. The existing preflight_usage_notice_prompt handles this correctly by opening /dev/tty; after the user accepts that notice, maybe_offer_express_install immediately sees non-TTY stdin and skips express mode with Skipping express prompt (no TTY). That means the main Spark/Station install path never offers the new express install.

I reproduced the final helper behavior by sourcing the PR head, stubbing detect_express_platform to return DGX Spark, and running under a controlling TTY with stdin redirected away, matching the curl-pipe shape:

[INFO] Detected DGX Spark. Skipping express prompt (no TTY).
NON_INTERACTIVE= PROVIDER= MODEL= POLICY=

Please make maybe_offer_express_install use the same /dev/tty prompt path as the license/onboard prompts instead of treating non-TTY stdin as no prompt capability. This should also get a focused regression test for the piped-stdin-with-controlling-TTY case, plus the no-TTY skip case, so the express path is covered directly rather than only disabled via NEMOCLAW_NO_EXPRESS in existing license tests.

Signed-off-by: Aaron Erickson <aerickson@nvidia.com>

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick comments (1)
test/install-preflight.test.ts (1)

2844-2854: ⚡ Quick win

Cover the DGX Station express branch too.

This new suite only locks down the Spark defaults, but the feature also has a Station-specific path with different env output. Adding a sibling case here for "DGX Station" would protect the install-vllm branch from silently drifting.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@test/install-preflight.test.ts` around lines 2844 - 2854, Add a sibling test
to cover the DGX Station express branch by copying the existing "offers express
install when curl-piped stdin still has a controlling TTY" case and modifying it
to simulate the Station variant (e.g., call runExpressPromptWithTty with the
input/environment that triggers "DGX Station"); assert exit status is 0, that
output matches /Detected DGX Station/, that it suggests running express install,
and that the environment/result line matches the Station-specific expected
string (e.g., includes PROVIDER=install-vllm and the corresponding
MODEL/POLICY/YES values) so the install-vllm branch is exercised.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Nitpick comments:
In `@test/install-preflight.test.ts`:
- Around line 2844-2854: Add a sibling test to cover the DGX Station express
branch by copying the existing "offers express install when curl-piped stdin
still has a controlling TTY" case and modifying it to simulate the Station
variant (e.g., call runExpressPromptWithTty with the input/environment that
triggers "DGX Station"); assert exit status is 0, that output matches /Detected
DGX Station/, that it suggests running express install, and that the
environment/result line matches the Station-specific expected string (e.g.,
includes PROVIDER=install-vllm and the corresponding MODEL/POLICY/YES values) so
the install-vllm branch is exercised.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: 3cba91be-7cf2-443a-abf2-633d2ab9c12d

📥 Commits

Reviewing files that changed from the base of the PR and between dca0660 and b42c817.

📒 Files selected for processing (2)
  • scripts/install.sh
  • test/install-preflight.test.ts
🚧 Files skipped from review as they are similar to previous changes (1)
  • scripts/install.sh

@ericksoa ericksoa left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved after pushing the follow-up fix in b42c817. The express install prompt now uses the controlling TTY for curl-piped installs, while true no-TTY runs still skip. Local validation passed: bash syntax/diff check, installer hash check, focused express prompt Vitest tests, license acceptance Vitest tests, and build:cli. GitHub checks are green on the updated head.

@ericksoa ericksoa merged commit 61134b5 into main May 11, 2026
21 checks passed
@zyang-dev zyang-dev deleted the feat/install-express-spark-station branch May 11, 2026 19:30
@miyoungc miyoungc mentioned this pull request May 12, 2026
12 tasks
miyoungc added a commit that referenced this pull request May 12, 2026
## Summary
Refreshes the release-prep docs for v0.0.39 based on changes merged
since the Friday 4pm doc refresh. Updates the source docs, bumps the
docs version metadata, and regenerates the NemoClaw user skills from the
refreshed docs.

## Changes
- #3314 -> `docs/get-started/prerequisites.md`,
`docs/get-started/quickstart.md`, `docs/reference/troubleshooting.md`:
Documents installer Docker setup, Docker group activation, and retry
guidance.
- #3317 -> `docs/get-started/quickstart.md`,
`docs/reference/commands.md`: Documents the DGX Spark and DGX Station
express install prompt and `NEMOCLAW_NO_EXPRESS`.
- #3328 and #3329 -> `docs/security/best-practices.md`,
`docs/deployment/sandbox-hardening.md`: Updates sandbox capability
hardening docs for the stricter bounding-set and `setpriv` step-down
behavior.
- #3330, #3335, and #3346 -> `docs/inference/use-local-inference.md`:
Documents Windows-host Ollama relaunch behavior, NIM key passthrough,
early health-fail diagnostics, and mixed-GPU preflight detail.
- #2406, #2883, #3001, #3244, #3267, #3318, #3320, and #3354 ->
`docs/about/release-notes.md`: Adds the v0.0.39 release-prep section
while keeping the v0.0.38 release notes intact.
- Advances the release-prep docs metadata from v0.0.38 to v0.0.39.
- Regenerates `.agents/skills/nemoclaw-user-*` from the updated source
docs.

## Type of Change
- [ ] Code change (feature, bug fix, or refactor)
- [ ] Code change with doc updates
- [ ] Doc only (prose changes, no code sample modifications)
- [x] Doc only (includes code sample changes)

## Verification
- [x] `npx prek run --all-files` passes
- [ ] `npm test` passes
- [ ] Tests added or updated for new or changed behavior
- [x] No secrets, API keys, or credentials committed
- [x] Docs updated for user-facing behavior changes
- [x] `make docs` builds without warnings (doc changes only)
- [x] Doc pages follow the [style
guide](https://github.com/NVIDIA/NemoClaw/blob/main/docs/CONTRIBUTING.md)
(doc changes only)
- [ ] New doc pages include SPDX header and frontmatter (new pages only)

---
Signed-off-by: Miyoung Choi <miyoungc@nvidia.com>

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

## Release Notes v0.0.39

* **New Features**
  * Host alias management commands for easier configuration
  * Sandbox GPU control options during onboarding
  * Update command with check and confirmation modes

* **Documentation**
* Enhanced Linux installer guidance with Docker and group membership
handling
  * Expanded troubleshooting for permission and connectivity issues
  * Improved capability-dropping security documentation
  * Updated inference model switching commands
  * Brev environment-specific troubleshooting

* **Improvements**
  * DGX Spark/Station express install flow
  * Windows Ollama relay and health-check enhancements
  * NVIDIA NIM preflight GPU reporting

[![Review Change
Stack](https://storage.googleapis.com/coderabbit_public_assets/review-stack-in-coderabbit-ui.svg)](https://app.coderabbit.ai/change-stack/NVIDIA/NemoClaw/pull/3375)

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
@wscurran wscurran added the feature PR adds or expands user-visible functionality label Jun 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature PR adds or expands user-visible functionality

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants