Skip to content

Resolve Pull Request Blockers#12

Merged
skyelaird merged 1 commit intomainfrom
claude/resolve-pr-issues-01KsREzzLyoFtQhiN38RnRBv
Nov 13, 2025
Merged

Resolve Pull Request Blockers#12
skyelaird merged 1 commit intomainfrom
claude/resolve-pr-issues-01KsREzzLyoFtQhiN38RnRBv

Conversation

@skyelaird
Copy link
Copy Markdown
Owner

Implements Option 1: Simple web server with refresh button for convenient on-demand prediction generation from the dashboard UI.

New Files

  • server.py - Flask server with API endpoints:

    • /api/generate - POST endpoint to trigger prediction generation
    • /api/status - GET endpoint to check generation progress
    • /api/data - GET endpoint to fetch prediction data
    • Serves static dashboard files
    • Background thread for prediction generation
  • requirements.txt - Server dependencies (Flask, flask-cors)

  • ISSUE_MULTI_USER_WEB_APP.md - GitHub issue template for future Option 3 (full multi-user web application)

Modified Files

  • dashboard.html:

    • Added "⚡ Refresh Predictions" button (fixed position, top-right)
    • Added progress modal with spinner and status updates
    • JavaScript functions for API calls and status polling
    • Auto-reloads dashboard when generation completes
    • Graceful error handling
  • README.md:

    • Added "Option A: Web Server" as recommended quick start
    • Kept "Option B: Static Files" for manual workflow
    • Clear instructions for both approaches

Usage

Option 1 (with server):

cd Dashboard
pip install -r requirements.txt
python3 server.py
# Visit http://localhost:8000
# Click "⚡ Refresh Predictions" button

Option 2 (static files):

cd Dashboard
python3 generate_predictions.py
open dashboard.html

Features

✅ One-click prediction refresh from dashboard
✅ Real-time progress indicator with status messages ✅ Background processing (non-blocking)
✅ Auto-reload when complete
✅ Error handling and timeout protection
✅ Works locally or can be deployed to VPS

Future Work

See ISSUE_MULTI_USER_WEB_APP.md for comprehensive multi-user service proposal (authentication, per-user configs, database, scheduled jobs, API, mobile app, etc.)

Implements Option 1: Simple web server with refresh button for
convenient on-demand prediction generation from the dashboard UI.

## New Files

- **server.py** - Flask server with API endpoints:
  - `/api/generate` - POST endpoint to trigger prediction generation
  - `/api/status` - GET endpoint to check generation progress
  - `/api/data` - GET endpoint to fetch prediction data
  - Serves static dashboard files
  - Background thread for prediction generation

- **requirements.txt** - Server dependencies (Flask, flask-cors)

- **ISSUE_MULTI_USER_WEB_APP.md** - GitHub issue template for
  future Option 3 (full multi-user web application)

## Modified Files

- **dashboard.html**:
  - Added "⚡ Refresh Predictions" button (fixed position, top-right)
  - Added progress modal with spinner and status updates
  - JavaScript functions for API calls and status polling
  - Auto-reloads dashboard when generation completes
  - Graceful error handling

- **README.md**:
  - Added "Option A: Web Server" as recommended quick start
  - Kept "Option B: Static Files" for manual workflow
  - Clear instructions for both approaches

## Usage

**Option 1 (with server):**
```bash
cd Dashboard
pip install -r requirements.txt
python3 server.py
# Visit http://localhost:8000
# Click "⚡ Refresh Predictions" button
```

**Option 2 (static files):**
```bash
cd Dashboard
python3 generate_predictions.py
open dashboard.html
```

## Features

✅ One-click prediction refresh from dashboard
✅ Real-time progress indicator with status messages
✅ Background processing (non-blocking)
✅ Auto-reload when complete
✅ Error handling and timeout protection
✅ Works locally or can be deployed to VPS

## Future Work

See ISSUE_MULTI_USER_WEB_APP.md for comprehensive multi-user
service proposal (authentication, per-user configs, database,
scheduled jobs, API, mobile app, etc.)
@skyelaird skyelaird merged commit b4fe313 into main Nov 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants