Distilled Large Language Model-Driven Dynamic Sparse Expert Activation Mechanism
Authors: Qinghui Chen, Zekai Zhang, Zaigui Zhang, Kai Zhang, Dagang Li, Wenmin Wang, Jinglin Zhang, Cong Liu
Organizations: School of Control Science and Engineering, Shandong University, Jinan, China · Laoshan Laboratory, Qingdao, China · Jinan Inspur Data Technology Co., Ltd, Jinan, China · School of Computer Science and Engineering, Macau University of Science and Technology, Macau SAR, China · NOVA Information Management School, Nova University of Lisbon, Lisbon, Portugal
High inter-class similarity, extreme scale variation, and limited computational budgets hinder reliable visual recognition across diverse real-world data. Existing vision-centric and cross-modal approaches often rely on rigid fusion mechanisms and heavy annotation pipelines, leading to sub-optimal generalization. We propose the Distilled Large Language Model (LLM)-Driven Sparse Mixture-of-Experts (DS-MoE) framework, which integrates text-guided dynamic routing and lightweight multi-scale comprehension. The DS-MoE framework dynamically aligns textual semantics with defect-specific visual patterns through a sparse MoE architecture, where task-relevant experts are adaptively activated based on semantic relevance, resolving inter-class ambiguity. A lightweight MobileSAM encoder enables real-time inference while preserving multi-scale defect details. Extensive experiments on PCB, aluminum foil, and mold defect datasets demonstrate that our framework achieves superior performance compared to existing pure vision models. DS-MoE surpasses YOLOv8/YOLOX with gains of +13.9, +1.4, and +2.0 pp mAP@ 0.5:0.95 on BBMP, aluminum, and PCB, respectively, while also improving precision and recall.
Figures & tables
Figure 1: Example of dataset for industrial detection. The first line and second line serve as the bottle-bottom mold point image and PCB defects image respectively. The aluminium defects image is shown in the third line. According to that, it is necessary to design an object detection in the industrial quality detection, especially for those with higher similarities and greater ranges of size.
Figure 2: DS-MoE Framework. DeepSeek-R1 generates defect-specific text prompts. MobileSAM encoder extracts multi-scale visual features. Hyperbolic manifold alignment fuses text and vision in curvature-aware space. Dynamic sparse MoE gates (top-k experts) activate task-relevant visual experts for fine-grained defect analysis. Dual-branch head outputs simultaneous classification and localization.
Figure 3: Hyperbolic Manifold Alignment. In the Poincaré ball, visual features are first lifted onto the manifold via the exponential map, while distilled text embeddings are anchored in the same space. Their logarithmic mappings are then fused with a learnable weight, preserving both the global defect taxonomy and local semantic nuances. The resulting geometrically aligned features enable downstream curvature-aware convolutional sampling.
Figure 4: A concise flowchart of Stages 8–10. Sparse MoE dynamically routes each input to only ⌊log2Ne⌋ experts: two task-specific modules (anisotropic local patterns and global structure) and selected cross-modal experts that fuse vision with replicated text embeddings. Their outputs are ensembled via dilated convolutions and reweighted by channel-wise attention, yielding a compact feature map.
Figure 5: The glass bottle bottom detection device collects images. During this process, the glass bottle will be suspended by the conveyor belts on both sides and sent to the photographing. The photoelectric gate receives the signal to trigger the light source and the camera at the bottom to take pictures.
Figure 6: Mold point images of different batches. Representative mold-point images from different production batches, illustrating the subtle height variations that make classification challenging.
Table 1: Contrast experiment on the BBMP dataset. Bold indicates best mean performance. DS-MoE statistics are reported as mean ± 95 % CI over five independent runs; p refers to a paired t -test against YOLOv8.
Figure 7: Real-time inspection interface on the glass-bottle production line. In the test system interface, the red box shows the detection accuracy and the time of reasoning a picture, and the blue box shows some detection results. After 30 samples, both precision and recall reach 100 %.
Table 2: Ablation study on BBMP. Incremental gains confirm the necessity of text guidance, MobileSAM backbone, hyperbolic alignment, dynamic experts and the QFocal+CIoU loss.
Figure 8: Sample aluminum-surface defect image. The small defect (zhen kong) and large defect (zang wu) co-exist, demonstrating extreme scale variation.
Table 3: Contrast experiment on the aluminum-defect dataset. Bold indicates best mean performance. DS-MoE statistics are reported as mean ± 95 % CI over five independent runs; p refers to a paired t -test versus YOLOv8.
Figure 9: Qualitative detection results on 16 aluminum-defect images. Bounding boxes and class labels are overlayed to show the model’s ability to localize multi-scale defects accurately.
Table 4: Ablation study on aluminum defects. Each component systematically improves robust detection of pinholes, scratches, contamination and creases.
Table 6: Experiments without tiny object detector. Class-wise results on aluminum defects without the tiny-object head, revealing recall deficits on sub-millimetre pinholes.
Table 7: Experiments with tiny object detector. Class-wise results on aluminum defects with the tiny-object head, showing consistent gains for pinhole detection.
Figure 10: Example PCB defects: (left) missing hole, (right) mouse bite. Both are sub-millimeter anomalies that require high-resolution feature preservation for reliable detection.
Table 8: Contrast experiment on the PCB surface-defect dataset. Bold indicates best mean performance. DS-MoE statistics are reported as mean ± 95 % CI over five independent runs; p refers to a paired t -test versus YOLOv8.
Large-scale vision-language mixture-of-experts (VL-MoE) models provide strong multimodal capability, but efficient deployment on memory-constrained platforms remains difficult. Existing MoE offloading systems are largely designed for text-centric workloads and become much less effective for visual-heavy inputs, where large numbers of visual tokens induce broader and less predictable expert accesses. We present VisMMoE, a VL-MoE offloading system built on a single systems insight: pruning redundant visual tokens can improve offloading not only by reducing computation, but also by reshaping expert demand. We refer to this effect as visual-expert affinity: token pruning makes expert accesses more concentrated within layers and more stable across layers, producing a smaller and more predictable expert working set. Guided by this insight, VisMMoE combines affinity-aware token compression, lookahead expert prediction, and cache/pipeline orchestration to improve expert locality and prefetch effectiveness under tight memory budgets. We implement VisMMoE on multiple frameworks and evaluate it on representative VL-MoE models and benchmarks. VisMMoE improves end-to-end inference performance by up to 2.68x and 1.61x, respectively, over strong baselines for today's VL-MoE deployments while maintaining competitive accuracy.
Cheng Xu, Xiaofeng Hou, Jiacheng Liu +1
Shanghai Jiao Tong University Minhang Qu, Shanghai, China
Unifying the complementary strengths of diverse Vision Foundation Models (VFMs) into a single efficient model is highly desirable but challenged by the negative transfer inherent in monolithic distillation. To address these feature conflicts, we introduce PRISM, a novel dual-stream Mixture-of-Experts (MoE) framework that synergizes VFMs via modular specialization. We propose a two-stage paradigm: (1) expertise deconstruction, where a teacher-conditional router guides experts to specialize in distinct representational subspaces to mitigate interference, followed by (2) dynamic recomposition, where the router learns to assemble these experts into tailored computational pathways for downstream tasks. Experiments on PASCAL-Context and NYUD-v2 show that PRISM establishes a new state of the art, validating that sparse, emergent specialization is a scalable approach for integrating diverse visual knowledge.
Ying Tang, Dong Li, Youjia Zhang +3
School of Computer Science and Technology, Huazhong University of Science and Technology, Wuhan, China.
Mixture-of-Experts (MoE) architectures enable conditional computation by activating only a subset of model parameters for each input. Although sparse routing has been highly effective in language models and has also shown promise in vision, most vision MoE methods operate at the image or patch level. This granularity is poorly aligned with object detection, where the fundamental unit of reasoning is an object query corresponding to a candidate instance. We propose Hierarchical Instance-Conditioned Mixture-of-Experts (HI-MoE), a DETR-style detection architecture that performs routing in two stages: a lightweight scene router first selects a scene-consistent expert subset, and an instance router then assigns each object query to a small number of experts within that subset. This design aims to preserve sparse computation while better matching the heterogeneous, instance-centric structure of detection. In the current draft, experiments are concentrated on COCO with preliminary specialization analysis on LVIS. Under these settings, HI-MoE improves over a dense DINO baseline and over simpler token-level or instance-only routing variants, with especially strong gains on small objects. We also provide an initial visualization of expert specialization patterns. We present the method, ablations, and current limitations in a form intended to support further experimental validation.