Felipe Meres commited on
Commit
ce3fde5
Β·
1 Parent(s): 7436980

Remove false GPU advertising and fix misleading claims

Browse files

- Remove false "free GPU acceleration" claims from README and app
- Update messaging to accurately reflect CPU-only processing on free tier
- Add honest performance expectations and upgrade path to GPU tier
- Fix device status messages to show "Free CPU Tier" accurately
- Add note about GPU tier upgrade for faster processing
- Replace misleading GPU benefits with honest CPU optimization claims

Files changed (2) hide show
  1. README.md +6 -5
  2. app.py +10 -9
README.md CHANGED
@@ -14,7 +14,7 @@ models:
14
 
15
  # πŸ”¬ Granite Docling 258M - Online Demo
16
 
17
- Experience IBM's cutting-edge Vision-Language Model for document processing and conversion directly in your browser with **free GPU acceleration** on Hugging Face Spaces!
18
 
19
  > **πŸ€– This Space uses the [IBM Granite Docling 258M](https://huggingface.co/ibm-granite/granite-docling-258M) Vision-Language Model hosted on Hugging Face Hub**
20
 
@@ -59,17 +59,18 @@ The IBM Granite Docling 258M is a state-of-the-art Vision-Language Model (VLM) d
59
  ## ⚑ Performance & Tips
60
 
61
  - **Document Analysis mode** is optimized for speed and works great on the free tier
62
- - **GPU acceleration** automatically enabled when available
63
  - **Processing time varies** based on document size and complexity
64
- - **Free tier** may have timeout limitations for very large documents
 
65
 
66
  ## πŸ› οΈ Technical Details
67
 
68
  - **Model**: [IBM Granite Docling 258M](https://huggingface.co/ibm-granite/granite-docling-258M) Vision-Language Model
69
  - **Model Hub**: Automatically loaded from `ibm-granite/granite-docling-258M` on Hugging Face
70
  - **Backend**: Docling framework with PyMuPDF optimization
71
- - **GPU Support**: CUDA acceleration when available
72
- - **Hosting**: πŸ€— Hugging Face Spaces (Free Tier)
73
 
74
  ## πŸ”— Links & Resources
75
 
 
14
 
15
  # πŸ”¬ Granite Docling 258M - Online Demo
16
 
17
+ Experience IBM's cutting-edge Vision-Language Model for document processing and conversion directly in your browser on Hugging Face Spaces!
18
 
19
  > **πŸ€– This Space uses the [IBM Granite Docling 258M](https://huggingface.co/ibm-granite/granite-docling-258M) Vision-Language Model hosted on Hugging Face Hub**
20
 
 
59
  ## ⚑ Performance & Tips
60
 
61
  - **Document Analysis mode** is optimized for speed and works great on the free tier
62
+ - **CPU processing** optimized for reliable performance
63
  - **Processing time varies** based on document size and complexity
64
+ - **Free CPU tier** provides reliable processing with timeout limitations for very large documents
65
+ - **Upgrade to GPU tier** for faster processing speeds
66
 
67
  ## πŸ› οΈ Technical Details
68
 
69
  - **Model**: [IBM Granite Docling 258M](https://huggingface.co/ibm-granite/granite-docling-258M) Vision-Language Model
70
  - **Model Hub**: Automatically loaded from `ibm-granite/granite-docling-258M` on Hugging Face
71
  - **Backend**: Docling framework with PyMuPDF optimization
72
+ - **Processing**: CPU optimized (GPU available with paid tier upgrade)
73
+ - **Hosting**: πŸ€— Hugging Face Spaces (Free CPU Tier)
74
 
75
  ## πŸ”— Links & Resources
76
 
app.py CHANGED
@@ -242,7 +242,7 @@ No table structures were detected in this document.
242
  ⚑ Mode: {processing_mode}
243
  ⏱️ Processing time: {processing_time:.2f}s
244
  πŸ“„ Content length: {len(markdown_output)} characters
245
- 🌐 Running on Hugging Face Spaces"""
246
 
247
  return markdown_output, json_metadata, processing_info, ""
248
 
@@ -309,26 +309,27 @@ No table structures were detected in this document.
309
  <div class="main-header">
310
  <h1>πŸ”¬ Granite Docling 258M - Online Demo</h1>
311
  <p>Experience IBM's cutting-edge Vision-Language Model for document processing</p>
312
- <p><strong>πŸ†“ Free GPU-Accelerated Processing on Hugging Face Spaces</strong></p>
313
  </div>
314
  """)
315
 
316
  # Demo info
317
- device_status = "πŸ’» CPU Processing"
318
  if self.granite_instance and hasattr(self.granite_instance, 'device'):
319
  device = str(self.granite_instance.device)
320
  if 'CUDA' in device:
321
- device_status = "πŸš€ GPU-Accelerated Processing (CUDA)"
322
  elif 'MPS' in device:
323
- device_status = "🍎 Apple Silicon Acceleration (MPS)"
324
 
325
  demo_info = f"""
326
  <div class="demo-box">
327
  <h3>🌟 Live Demo Status</h3>
328
- <p><strong>Status</strong>: {"βœ… Ready" if DOCLING_AVAILABLE and self.granite_instance else "⚠️ Limited (CPU fallback)"}</p>
329
  <p><strong>Processing</strong>: {device_status}</p>
330
  <p><strong>Model</strong>: <a href="https://huggingface.co/ibm-granite/granite-docling-258M" target="_blank" style="color: white; text-decoration: underline;">IBM Granite Docling 258M</a> Vision-Language Model</p>
331
- <p><strong>Hosting</strong>: πŸ€— Hugging Face Spaces (Free Tier)</p>
 
332
  </div>
333
  """
334
  gr.HTML(demo_info)
@@ -338,7 +339,7 @@ No table structures were detected in this document.
338
  gr.HTML(f"""
339
  <div style="background-color: #ffe6e6; padding: 15px; border-radius: 8px; margin: 10px 0; color: #d00;">
340
  <h3>⚠️ Demo Limitations</h3>
341
- <p>The full model might not be available on the free tier. You can still try the interface, but processing might be limited.</p>
342
  <p>For full functionality, clone the repository: <a href="https://github.com/felipemeres/granite-docling-implementation" target="_blank">GitHub Repository</a></p>
343
  </div>
344
  """)
@@ -422,7 +423,7 @@ No table structures were detected in this document.
422
  <li><strong>Vision-Language Understanding</strong>: Advanced document comprehension</li>
423
  <li><strong>Multi-Format Support</strong>: PDF, DOCX, Images</li>
424
  <li><strong>Fast Analysis</strong>: 19x faster document insights</li>
425
- <li><strong>GPU Acceleration</strong>: Free GPU processing on HF Spaces</li>
426
  </ul>
427
  </div>
428
  """)
 
242
  ⚑ Mode: {processing_mode}
243
  ⏱️ Processing time: {processing_time:.2f}s
244
  πŸ“„ Content length: {len(markdown_output)} characters
245
+ 🌐 Running on Hugging Face Spaces (CPU tier)"""
246
 
247
  return markdown_output, json_metadata, processing_info, ""
248
 
 
309
  <div class="main-header">
310
  <h1>πŸ”¬ Granite Docling 258M - Online Demo</h1>
311
  <p>Experience IBM's cutting-edge Vision-Language Model for document processing</p>
312
+ <p><strong>πŸ†“ Free Document Processing on Hugging Face Spaces</strong></p>
313
  </div>
314
  """)
315
 
316
  # Demo info
317
+ device_status = "πŸ’» CPU Processing (Free Tier)"
318
  if self.granite_instance and hasattr(self.granite_instance, 'device'):
319
  device = str(self.granite_instance.device)
320
  if 'CUDA' in device:
321
+ device_status = "πŸš€ GPU Processing (CUDA) - Paid Tier"
322
  elif 'MPS' in device:
323
+ device_status = "🍎 Apple Silicon Processing (MPS)"
324
 
325
  demo_info = f"""
326
  <div class="demo-box">
327
  <h3>🌟 Live Demo Status</h3>
328
+ <p><strong>Status</strong>: {"βœ… Ready" if DOCLING_AVAILABLE and self.granite_instance else "⚠️ Limited"}</p>
329
  <p><strong>Processing</strong>: {device_status}</p>
330
  <p><strong>Model</strong>: <a href="https://huggingface.co/ibm-granite/granite-docling-258M" target="_blank" style="color: white; text-decoration: underline;">IBM Granite Docling 258M</a> Vision-Language Model</p>
331
+ <p><strong>Hosting</strong>: πŸ€— Hugging Face Spaces (Free CPU Tier)</p>
332
+ <p><strong>Note</strong>: Upgrade to GPU tier for faster processing</p>
333
  </div>
334
  """
335
  gr.HTML(demo_info)
 
339
  gr.HTML(f"""
340
  <div style="background-color: #ffe6e6; padding: 15px; border-radius: 8px; margin: 10px 0; color: #d00;">
341
  <h3>⚠️ Demo Limitations</h3>
342
+ <p>The full model might not be available on the free CPU tier. Processing will be slower than GPU but still functional.</p>
343
  <p>For full functionality, clone the repository: <a href="https://github.com/felipemeres/granite-docling-implementation" target="_blank">GitHub Repository</a></p>
344
  </div>
345
  """)
 
423
  <li><strong>Vision-Language Understanding</strong>: Advanced document comprehension</li>
424
  <li><strong>Multi-Format Support</strong>: PDF, DOCX, Images</li>
425
  <li><strong>Fast Analysis</strong>: 19x faster document insights</li>
426
+ <li><strong>Reliable Processing</strong>: CPU-optimized on HF Spaces free tier</li>
427
  </ul>
428
  </div>
429
  """)