Spaces:
Running
Running
π¨ MEMORY ERROR FIX - Windows Paging File Too Small
Error You're Seeing
OSError: [WinError 1455] The paging file is too small for this operation to complete
This happens when Windows virtual memory (paging file) is too small to load PyTorch and all AI models.
π§ QUICK FIX: Increase Windows Virtual Memory
Step 1: Open System Properties
- Press
Win + Pause/BreakOR - Right-click "This PC" β Properties
- Click "Advanced system settings" (left sidebar)
- Click "Settings" under Performance section
Step 2: Increase Virtual Memory
- Go to "Advanced" tab
- Click "Change" under Virtual Memory
- Uncheck "Automatically manage paging file size"
- Select your system drive (usually C:)
- Choose "Custom size"
- Set both values:
- Initial size:
16000 MB(16 GB) - Maximum size:
32000 MB(32 GB)
- Initial size:
- Click "Set"
- Click "OK" on all windows
- RESTART YOUR COMPUTER
Step 3: After Restart
cd D:\mis_2\LinkScout
python combined_server.py
Server should now start successfully!
β What I Fixed in Code
I implemented lazy loading so models only load when actually needed:
- β NER model: Loads on first entity extraction
- β Hate Speech: Loads on first hate speech detection
- β Clickbait: Loads on first clickbait check
- β Bias: Loads on first bias analysis
Before: All 8 models loaded at startup (crashed)
After: Only RoBERTa + Emotion load at startup, others load on-demand
π― Expected Startup After Fix
π± Using device: cpu
π Loading AI models...
Loading RoBERTa fake news detector...
β
RoBERTa loaded
Loading emotion classifier...
β
Emotion model loaded
β³ NER model: lazy loading (loads on first use)
β³ Hate Speech detector: lazy loading (loads on first use)
β³ Clickbait detector: lazy loading (loads on first use)
β³ Bias detector: lazy loading (loads on first use)
β
Core models loaded (RoBERTa, Emotion)
π§ Initializing Reinforcement Learning...
πΎ [RL] No saved model found, starting fresh
π§ RL Agent: READY (Episodes: 0)
β
Server running on http://localhost:5000
π If You Can't Increase Virtual Memory
Alternative 1: Use Lighter Server (MIS Directory)
The MIS server has better memory management:
cd D:\mis_2\mis
python agentic_server.py
Alternative 2: Disable Some Models
Edit combined_server.py and comment out models you don't need.
Alternative 3: Add More RAM
If your PC has <8GB RAM, consider upgrading to 16GB+.
π Current System Requirements
Minimum:
- RAM: 8GB
- Virtual Memory: 16GB
- Disk Space: 10GB (for models cache)
Recommended:
- RAM: 16GB+
- Virtual Memory: 32GB
- Disk Space: 20GB
β After Server Starts
- Reload LinkScout extension (chrome://extensions/)
- Visit any news article
- Click LinkScout icon
- Click "Scan Page"
- RL system works with feedback buttons!
Last Updated: October 21, 2025
Issue: Windows paging file too small for PyTorch + 8 AI models
Solution: Increase virtual memory to 16-32GB + Lazy loading implemented