DLab AI Forward CLI
Command-line interface for AI Forward - expose your local LLM services (Ollama, LM Studio) to the cloud via secure WebSocket tunnel.
Features
- 🔌 Easy Tunneling - Connect local LLM services to cloud infrastructure
- 🤖 Multi-Service Support - Works with Ollama and LM Studio
- 📊 System Monitoring - Reports CPU, RAM, and GPU metrics
- 🔄 Auto-Discovery - Automatically detects available models
- 🔒 Secure - Token-based authentication
- 🖥️ Cross-Platform - Works on macOS, Linux, and Windows
Installation
pip install dlab-ai-forward
For NVIDIA GPU monitoring support:
pip install dlab-ai-forward[nvidia]
Or using pipx (recommended for CLI tools):
pipx install dlab-ai-forward
pipx install dlab-ai-forward[nvidia] # With NVIDIA support
Usage
# Basic usage
dlab-ai-forward --name demo --server https://ai.example.com --token YOUR_TOKEN
# With custom ports
dlab-ai-forward --name my-node --server https://ai.example.com --token YOUR_TOKEN \
--ollama-port 11434 --lmstudio-port 1234
# Expose only specific services
dlab-ai-forward --name ollama-only --server https://ai.example.com --token YOUR_TOKEN \
--services ollama
# Verbose mode (debug logging)
dlab-ai-forward --name demo --server https://ai.example.com --token YOUR_TOKEN --verbose
Options
| Option | Description | Default |
|---|---|---|
--name |
Tunnel name (unique identifier) | Required |
--server |
Backend server URL | Required |
--token |
Authentication token (32 chars) | Required |
--ollama-port |
Ollama local port | 11434 |
--lmstudio-port |
LM Studio local port | 1234 |
--services |
Services to expose | ollama lmstudio |
--verbose, -v |
Enable debug logging | False |
System Requirements
- Python 3.8+
- Ollama (optional) - running on localhost:11434
- LM Studio (optional) - running on localhost:1234
GPU Monitoring
GPU metrics are automatically detected and reported:
- NVIDIA GPUs: Install with
pip install dlab-ai-forward[nvidia] - AMD GPUs (Windows): Install with
pip install dlab-ai-forward[amd] - Apple Silicon (M1/M2/M3): Automatically supported on macOS
- Other GPUs: Not currently supported
AMD GPU on Windows
For AMD GPU monitoring on Windows, you have two options:
-
Using WMI (built-in, no extra install):
- Works with most AMD GPUs
- Uses Windows Performance Counters
- May require running as Administrator for full metrics
-
Using pyadl (optional):
pip install dlab-ai-forward[amd]
- Uses AMD Display Library (ADL)
- More accurate metrics
- Requires AMD drivers installed
How It Works
- CLI connects to backend via WebSocket with authentication token
- CLI detects local LLM services and available models
- CLI reports system metrics (CPU, RAM, GPU)
- Cloud services can proxy requests through the backend to your local models
Example: Call Local Model from Cloud
# Cloud service makes request to backend
curl https://ai.example.com/api/demo/ollama/api/tags \
-H "Authorization: Bearer YOUR_TOKEN"
# Or for LM Studio
curl https://ai.example.com/api/demo/lmstudio/v1/models \
-H "Authorization: Bearer YOUR_TOKEN"
License
MIT License
Metadata
Release files for dlab-ai-forward 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| dlab_ai_forward-0.1.0.tar.gz | 14.3 kB | Without provenance | Details for dlab_ai_forward-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| dlab_ai_forward-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for dlab_ai_forward-0.1.0-py3-none-any.whl |
Total release size: 27.6 kB
Release files / dlab_ai_forward-0.1.0.tar.gz
| Download URL | dlab_ai_forward-0.1.0.tar.gz |
|---|---|
| Size | 14.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ee6b35a1f323419dfce3323bc300df865011e22864abcfe6bcb3d6431dc77f24
|
|
BLAKE2b-256 checksum How to use checksums |
492e6decfdf4df8b84ce65cabbca60a8cf7437cf6b5f7736c54924f7fe3f5a39
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.0
|
Release files / dlab_ai_forward-0.1.0-py3-none-any.whl
| Download URL | dlab_ai_forward-0.1.0-py3-none-any.whl |
|---|---|
| Size | 13.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f23432a68b36d75bd363f4ca655826e1090cf6a353b9e561d8c5b7951f658bfe
|
|
BLAKE2b-256 checksum How to use checksums |
fe50335b2553aaf77d0711cf94634b391795d8278ce57277dd070c1302bba1f5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.0
|
Security for dlab-ai-forward 0.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.