Idefics2 is trained mostly on OBELICS, our open interleaved image-text document dataset.
Training on interleaved data is crucial to reaching high performance on VQA tasks, taking an arbitrary number of images as input, and doing in-context learning.
The Cauldron is a massive collection of 50 high-quality datasets, all converted to the user/assistant format, and ready to use to fine-tune any Vision Language Model.
The Cauldron covers a wide range of tasks, including general visual question answering, counting, captioning, text transcription, document understanding, chart/figure understanding, table understanding, visual reasoning, geometry, spotting differences between 2 images or converting a screenshot to a code.
We release Idefics2-8B, a foundation vision language model with SOTA results for its size on many benchmarks.
For Idefics2, we adopted a simple architecture: -Images are fed to a vision encoder, then to a modality projection to match the input dimension of the LLM, and finally to a perceiver resampler for efficient pooling. -Interleaved image-text data are then passed to the LLM.
During the pre-training: -The modality projection and perceiver resampler weights are newly initialized. -We start with pre-trained models for the vision encoder and the LLM, and continue the training with LoRA. -In total, we see 1.5T images!
We pre-train on 3 types of data, all publicly available: -Interleaved image-text documents: our dataset OBELICS HuggingFaceM4/OBELICS -Image caption pairs: only synthetic captions! -PDF documents: IDL and PDFA
We kept the aspect ratio of the images with the Patch n' Pack strategy, with a resolution of up to 980x980. At inference, it's also more efficient for lower-resolution images.
For the SFT, we build The Cauldron, a collection of 50 high-quality datasets in the user/assistant format. It is a ready-to-use dataset for the fine-tuning of any VLM. HuggingFaceM4/the_cauldron
Most current models, like LLaVA-NeXT, encode images with an excessive number of tokens, like 2880. Instead, we put a focus on being efficient at inference by training on a mix of images encoded with 64 tokens, and 320 tokens. The result is that we perform favorably compared to the best models in our size class, while being efficient at inference.
With the new WebSight dataset, converting the screenshot of a web page to its corresponding HTML code is just one fine-tuning step away
We release a new version of our synthetic dataset: -Real images within web pages 🖼️ -Tailwind CSS 🎨 -2M examples 📈
Our initial release, v0.1, featured web designs in HTML + CSS, using simple colored rectangles as image placeholders. It was a good start to help models grasp the basics of web page structure and coding associations. Yet, it was missing the look of a real website.
Improving visual appeal, we've now embedded actual images in our web designs, ensuring they match the site's content for a more authentic look.
Switching to Tailwind CSS offers a more compact representation of the code.
We've also expanded our dataset to 2 million examples!
After fine-tuning our forthcoming foundation vision-language model on this dataset, we've observed some encouraging capabilities, such as converting sketches directly into functional HTML code.
We're excited to hear your thoughts and suggestions for future versions. What would you like to see next? Feel free to open a discussion on the hub!