Using Knowledge Graphs to harvest datasets for efficient CLIP model training
Simon Ging, Sebastian Walter, Jelena Bratulić, Johannes Dienert, Hannah Bast, Thomas Brox
TL;DR
This work tackles the data-hungry nature of CLIP by presenting a knowledge-graph–guided dataset harvesting pipeline that enables effective pretraining with far less data. By linking Wikidata and WordNet to an LLM-driven search process, the authors create EntityNet, a 33M-image, 45M-alt-text vision-language dataset with a 10M-organism subset, enabling from-scratch CLIP training on modest hardware in under a day. Across generic and expert domains, EntityNet-based CLIP models achieve state-of-the-art or competitive results with substantially reduced compute compared to conventional large-scale datasets, and finetuning on expert data can further boost performance. The approach demonstrates that structured knowledge graphs can automate high-quality data assembly for domain-specific CLIP models, offering a scalable path to controlled, efficient vision-language pretraining and broader applicability beyond natural images.
Abstract
Training high-quality CLIP models typically requires enormous datasets, which limits the development of domain-specific models -- especially in areas that even the largest CLIP models do not cover well -- and drives up training costs. This poses challenges for scientific research that needs fine-grained control over the training procedure of CLIP models. In this work, we show that by employing smart web search strategies enhanced with knowledge graphs, a robust CLIP model can be trained from scratch with considerably less data. Specifically, we demonstrate that an expert foundation model for living organisms can be built using just 10M images. Moreover, we introduce EntityNet, a dataset comprising 33M images paired with 46M text descriptions, which enables the training of a generic CLIP model in significantly reduced time.
