WebOverlay: High-Throughput Vision-Only Distillation for Extreme Aspect-Ratio Web Overlay Detection
Organizations: Google USA
Abstract
Web overlays, such as cookie consent banners, newsletter prompts, and age gates, obstruct automated web crawlers and degrade downstream document representations. While proprietary multimodal Large Language Models (MLLMs) can accurately identify overlays, their latency and inference cost preclude web-scale ingestion. Conversely, lightweight vision models struggle with full-page renderings characterized by extreme vertical aspect ratios, where standard isotropic resizing collapses critical text features and causes false positives. In this work, we present WebOverlay, a high-throughput vision-only detector trained via distillation from a frontier vision-language teacher. We establish a dynamic tiling strategy that partitions extreme aspect-ratio web renders into aspect-preserving patches with spatial overlap, coupled with an aspect-ratio-aware boundary adjudication mechanism to eliminate boundary artifacts. To eliminate cross-modal latency overheads, our student model relies purely on visual cues, bypassing DOM tree parsing. WebOverlay significantly outperforms DOM-based heuristics and achieves competitive precision and recall against heavy proprietary MLLM baselines while delivering multiple orders of magnitude higher throughput and substantially reduced deployment costs.
Figures & tables
| Paradigm | Model | F1 | F1 95% CI | Precision | Recall | Acc | ROC-AUC |
|---|---|---|---|---|---|---|---|
| HTML Rules | Regex Rules over Rendered HTML † | 44.44 | [41.0, 47.8] | 33.33 | 66.67 | 70.39 | — |
| Lightweight CNN | MobileNetV4 | 31.47 | [28.9, 34.0] | 19.49 | 81.67 | 36.80 | 62.60 |
| Object Detector | YOLO-style ConvNet Detector § | 39.50 | [36.0, 42.9] | 29.38 | 60.24 | 67.22 | 69.75 |
| Commercial MLLM | Gemini 2.5 Flash (Teacher) ‡ | 89.74 | [87.6, 91.8] | 85.22 | 94.76 | 96.15 | — |
| Ours | SigLIP-27L Distilled, Whole-Page View | 81.57 | [78.4, 84.6] | 94.65 | 71.67 | 94.25 | 91.32 |
| Ours | SigLIP-27L Distilled, 3-Tile Max-OR | 85.98 | [83.4, 88.4] | 85.08 | 86.90 | 94.97 | 94.95 |
| Evaluation Slice | Model | AP (%) | AP 95% CI | ROC-AUC (%) |
|---|---|---|---|---|
| Full-2.4K ( ) | MobileNetV4 | 39.70 | [35.2, 44.3] | 62.60 |
| YOLO ConvNet | 40.46 | [35.6, 45.7] | 69.75 | |
| Ours (3-Tile) | 87.78 | [84.5, 90.7] | 94.95 | |
| Test-Common ( ) | MobileNetV4 | 40.40 | [35.7, 45.0] | 60.87 |
| YOLO ConvNet | 41.86 | [36.7, 47.3] | 68.14 | |
| Ours (3-Tile) | 90.52 | [87.4, 93.2] | 95.18 |
| Slice | Model | P (%) | R (%) | F1 (%) | Acc (%) | AUC (%) |
|---|---|---|---|---|---|---|
| Test-Common ( ) | MobileNetV4 (Vision Only) | 21.55 | 81.17 | 34.06 | 36.73 | 60.87 |
| YOLO-style ConvNet | 31.62 | 60.21 | 41.46 | 65.78 | 68.14 | |
| Commercial MLLM (Teacher) | 85.58 | 97.61 | 91.20 | 96.21 | — | |
| Ours (3-Tile, Max-OR) | 90.30 | 86.47 | 88.35 | 95.41 | 95.18 | |
| Test-Hard ( ) | MobileNetV4 (Vision Only) | 10.88 | 86.05 | 19.32 | 37.07 | 72.55 |
| YOLO-style ConvNet | 18.18 | 60.47 | 27.96 | 72.71 | 74.61 |
| Teacher | Ours, 3-tile | Ours, 1-view | |||||
|---|---|---|---|---|---|---|---|
| Aspect Ratio | Pages | Overlays | R | P | R | P | R |
| 793 | 161 | 99.4 | 82.1 | 83.9 | 93.8 | 80.7 | |
| 804 | 162 | 97.5 | 86.8 | 86.4 | 90.9 | 71.6 | |
| 492 | 75 | 89.3 | 90.5 | 96.0 | 77.4 | 62.7 | |
| 275 | 22 | 59.1 | 81.2 | 81.8 | 47.4 | 36.4 | |
| Slice | Pos. | Teacher F1 | Ours F1 | [95% CI] | ||
|---|---|---|---|---|---|---|
| All | 592 | 133 | 84.4 | 87.9 | [ , ] | 0.200 |
| Val-Common | 475 | 114 | 90.4 | 88.2 | [ , ] | 0.541 |
| Val-Hard | 117 | 19 | 30.8 | 86.5 | [ , ] |
| Group | Model Variant / Ablated Component | Precision (%) | Recall (%) | F1 (%) | Acc (%) | AP (%) | AUC (%) | F1 (pts) |
| (A) Distillation Depth | Full 27-Layer Distillation (3-Tile, Ours) | 85.08 | 86.90 | 85.98 | 94.97 | 87.78 | 94.95 | Ref |
| Top-4 Layers Only (3-Tile) | 85.04 | 81.19 | 83.07 | 94.12 | 86.85 | 94.43 | ||
| Full 27-Layer Distillation (Whole-Page View) | 94.65 | 71.67 | 81.57 | 94.25 | 85.91 | 91.32 | Ref | |
| Top-4 Layers Only (Whole-Page View) | 91.12 | 65.95 | 76.52 | 92.81 | 82.34 | 89.59 | ||
| (B) Tiling Strategy | 3-Tile Viewport Tiling ( , Ours) | 85.08 | 86.90 | 85.98 | 94.97 | 87.78 | 94.95 | Ref |
| Whole-Page View (1 Tile) | 94.65 | 71.67 | 81.57 | 94.25 | 85.91 | 91.32 |
| Execution Stage | Hardware | Per Page (ms) | Share |
|---|---|---|---|
| Image decode + 3-tile tiling | Host CPU (16 threads) | 5.45 | 2.8% |
| SigLIP ViT forward ( ) | TPU v5e | 190.04 | 97.2% |
| MLP classification head | TPU v5e | 0.004 | |
| Serial total | 195.49 | 100.0% |
| Traffic to Tier 2 (%) | Gate Recall (%) | |
|---|---|---|
| — | 100.0 | 100.0 |
| 0.10 | 98.9 | 100.0 |
| 0.20 | 88.6 | 95.0 |
| 0.25 | 74.7 | 86.4 |
| 0.30 | 62.6 | 79.0 |
| 0.40 | 46.7 | 69.0 |
Object Detection
Object detection locates and classifies objects in images or video, balancing localization accuracy, robustness, and inference speed.
See all 673 papers