ChatPaper.aiChatPaper

Veelvoudige In-Context Leren in Multimodale Fundamentmodellen

Many-Shot In-Context Learning in Multimodal Foundation Models

May 16, 2024
Auteurs: Yixing Jiang, Jeremy Irvin, Ji Hun Wang, Muhammad Ahmed Chaudhry, Jonathan H. Chen, Andrew Y. Ng
cs.AI

Samenvatting

Grote taalmodellen staan bekend om hun effectiviteit bij few-shot in-context learning (ICL). Recente vooruitgang in multimodale foundationmodellen heeft ongekend lange contextvensters mogelijk gemaakt, wat een kans biedt om hun vermogen te onderzoeken om ICL uit te voeren met veel meer demonstratievoorbeelden. In dit werk evalueren we de prestaties van multimodale foundationmodellen bij het schalen van few-shot naar many-shot ICL. We benchmarken GPT-4o en Gemini 1.5 Pro over 10 datasets die meerdere domeinen beslaan (natuurlijke beelden, medische beelden, remote sensing en moleculaire beelden) en taken (multi-class, multi-label en fijnmazige classificatie). We observeren dat many-shot ICL, inclusief tot bijna 2.000 multimodale demonstratievoorbeelden, leidt tot aanzienlijke verbeteringen in vergelijking met few-shot (<100 voorbeelden) ICL over alle datasets. Verder blijft de prestaties van Gemini 1.5 Pro log-lineair verbeteren tot het maximale aantal geteste voorbeelden op veel datasets. Gezien de hoge inferentiekosten die gepaard gaan met de lange prompts die nodig zijn voor many-shot ICL, onderzoeken we ook de impact van het batchgewijs verwerken van meerdere queries in één API-aanroep. We laten zien dat het batchgewijs verwerken van tot 50 queries kan leiden tot prestatieverbeteringen onder zero-shot en many-shot ICL, met aanzienlijke winsten in de zero-shot setting op meerdere datasets, terwijl de kosten en latentie per query drastisch worden verminderd. Ten slotte meten we de ICL-data-efficiëntie van de modellen, oftewel de snelheid waarmee de modellen leren van meer demonstratievoorbeelden. We constateren dat hoewel GPT-4o en Gemini 1.5 Pro vergelijkbare zero-shot prestaties behalen over de datasets, Gemini 1.5 Pro een hogere ICL-data-efficiëntie vertoont dan GPT-4o op de meeste datasets. Onze resultaten suggereren dat many-shot ICL gebruikers in staat zou kunnen stellen om multimodale foundationmodellen efficiënt aan te passen aan nieuwe toepassingen en domeinen. Onze codebase is publiekelijk beschikbaar op https://github.com/stanfordmlgroup/ManyICL.
English
Large language models are well-known to be effective at few-shot in-context learning (ICL). Recent advancements in multimodal foundation models have enabled unprecedentedly long context windows, presenting an opportunity to explore their capability to perform ICL with many more demonstrating examples. In this work, we evaluate the performance of multimodal foundation models scaling from few-shot to many-shot ICL. We benchmark GPT-4o and Gemini 1.5 Pro across 10 datasets spanning multiple domains (natural imagery, medical imagery, remote sensing, and molecular imagery) and tasks (multi-class, multi-label, and fine-grained classification). We observe that many-shot ICL, including up to almost 2,000 multimodal demonstrating examples, leads to substantial improvements compared to few-shot (<100 examples) ICL across all of the datasets. Further, Gemini 1.5 Pro performance continues to improve log-linearly up to the maximum number of tested examples on many datasets. Given the high inference costs associated with the long prompts required for many-shot ICL, we also explore the impact of batching multiple queries in a single API call. We show that batching up to 50 queries can lead to performance improvements under zero-shot and many-shot ICL, with substantial gains in the zero-shot setting on multiple datasets, while drastically reducing per-query cost and latency. Finally, we measure ICL data efficiency of the models, or the rate at which the models learn from more demonstrating examples. We find that while GPT-4o and Gemini 1.5 Pro achieve similar zero-shot performance across the datasets, Gemini 1.5 Pro exhibits higher ICL data efficiency than GPT-4o on most datasets. Our results suggest that many-shot ICL could enable users to efficiently adapt multimodal foundation models to new applications and domains. Our codebase is publicly available at https://github.com/stanfordmlgroup/ManyICL .
PDF323December 15, 2024