Metadata-Version: 2.4
Name: spotwarp
Version: 3.0.0
Summary: Zero-Downtime Spot GPU Failover Guard & AI Acceleration Utility for Vast.ai & RunPod
Home-page: https://spotwarp.com
Author: SpotWarp Team
Author-email: info@spotwarp.com
Project-URL: Documentation, https://spotwarp.com
Project-URL: Source, https://github.com/enplabs/spotwarp
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Topic :: System :: Monitoring
Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
Requires-Python: >=3.8
Description-Content-Type: text/markdown
Requires-Dist: requests>=2.25.0
Dynamic: author
Dynamic: author-email
Dynamic: classifier
Dynamic: description
Dynamic: description-content-type
Dynamic: home-page
Dynamic: project-url
Dynamic: requires-dist
Dynamic: requires-python
Dynamic: summary

# SpotWarp: Zero-Downtime Spot GPU Failover Guard v3.0

[![PyPI Version](https://img.shields.io/badge/pypi-v3.0.0-blue.svg)](https://pypi.org/project/spotwarp/)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
[![Security: Audited](https://img.shields.io/badge/Security-Zero--Key--Leakage-green.svg)](https://spotwarp.com)

**SpotWarp** is a lightweight, 100% local Python daemon that protects your AI inference & PyTorch training workloads on cheap Spot GPUs (Vast.ai, RunPod, AWS Spot) with zero downtime and automatic data restoration.

## 🔒 100% Local Security Guarantee
- **Zero-Key Leakage**: Your `VAST_API_KEY` and `RUNPOD_API_KEY` stay 100% local on your host machine.
- **Zero Admin Rights Needed**: Runs entirely in unprivileged user space.
- **Auditable Open Source**: 100% open-source Python code.

## 🚀 Quick Start

### 1. Installation
```bash
pip install spotwarp
```

### 2. Run Guard Daemon (With Auto-Sync and Stateful Resume)
```bash
export VAST_API_KEY="your_vast_api_key_here"
spotwarp start --license-key YOUR_LICENSE_KEY --resume-cmd "python /workspace/train.py --resume"
```

## ⚡ How It Works
1. **0.05s Eviction Detection**: Monitors local/remote instance health 24/7.
2. **Instant Failover**: Automatically selects the cheapest alternative Spot GPU on Vast.ai or RunPod upon eviction warning.
3. **High-Speed Rsync Delta Sync**: Periodically backs up remote workspace files locally and automatically restores them to the replacement container before connection verification.
4. **Stateful Workload Resume**: Launches the training command in the background (`nohup`) on the new node automatically.
