Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions docs/user_guide/quick_start.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,20 @@ We will walk through you the easiest way to quickly set up your own AI cluster.

If you have not installed Parallax yet, please refer to the [installation guide](./install.md) and follow the instructions.

### Verify Your Setup

Before running Parallax, you can verify your environment is correctly configured:

```sh
parallax doctor
```

This checks Python version, CUDA/Metal availability, dependencies, and common path issues. Use `-v` for detailed output:

```sh
parallax doctor -v
```

### With Frontend

#### Step 1: Launch scheduler
Expand Down
17 changes: 17 additions & 0 deletions src/parallax/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -295,6 +295,14 @@ def chat_command(args, passthrough_args: list[str] | None = None):
_execute_with_graceful_shutdown(cmd)


def doctor_command(args, passthrough_args: list[str] | None = None):
"""Run environment diagnostics to validate Parallax setup."""
from parallax.doctor import run_all_checks

results, success = run_all_checks(verbose=args.verbose)
sys.exit(0 if success else 1)


def update_package_info():
"""Update package information."""
version = get_current_version()
Expand Down Expand Up @@ -364,6 +372,7 @@ def main():
parallax join # Join cluster in local network
parallax join -s {scheduler-address} # Join cluster in public network
parallax join -s 12D3KooWLX7MWuzi1Txa5LyZS4eTQ2tPaJijheH8faHggB9SxnBu # example
parallax doctor # Validate environment setup
""",
)

Expand Down Expand Up @@ -415,6 +424,12 @@ def main():
"-r", "--use-relay", action="store_true", help="Use public relay servers"
)

# Add 'doctor' command parser
doctor_parser = subparsers.add_parser(
"doctor", help="Run environment diagnostics to validate setup"
)
doctor_parser.add_argument("-v", "--verbose", action="store_true", help="Show detailed output")

# Accept unknown args and pass them through to the underlying python command
args, passthrough_args = parser.parse_known_args()

Expand All @@ -428,6 +443,8 @@ def main():
join_command(args, passthrough_args)
elif args.command == "chat":
chat_command(args, passthrough_args)
elif args.command == "doctor":
doctor_command(args, passthrough_args)
else:
parser.print_help()
sys.exit(1)
Expand Down
15 changes: 15 additions & 0 deletions src/parallax/doctor/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
"""
Parallax Doctor - Environment diagnostic module.

This module provides diagnostic checks for validating the Parallax environment
before running the application. It checks Python version, hardware availability,
dependencies, and WSL path issues.

Usage:
parallax doctor # Run all diagnostic checks
parallax doctor -v # Run with verbose output
"""

from parallax.doctor.checks import run_all_checks

__all__ = ["run_all_checks"]
Loading