ChatPaper.aiChatPaper

Échantillonnage prioritaire des grands modèles de langage pour les compilateurs

Priority Sampling of Large Language Models for Compilers

February 28, 2024
Auteurs: Dejan Grubisic, Chris Cummins, Volker Seeker, Hugh Leather
cs.AI

Résumé

Les grands modèles de langage démontrent un potentiel considérable dans la génération et l'optimisation de code. Les méthodes d'échantillonnage couramment utilisées, telles que le Nucleus Sampling, augmentent la diversité de la génération mais produisent souvent des échantillons répétés pour les basses températures et des échantillons incohérents pour les hautes températures. De plus, le coefficient de température doit être ajusté pour chaque tâche, limitant ainsi son utilité. Nous présentons le Priority Sampling, une technique d'échantillonnage simple et déterministe qui produit des échantillons uniques ordonnés par la confiance du modèle. Chaque nouvel échantillon développe le token non développé ayant la probabilité la plus élevée dans l'arbre de recherche augmenté. Par ailleurs, le Priority Sampling prend en charge la génération basée sur des expressions régulières, offrant ainsi un processus d'exploration contrôlé et structuré. Le Priority Sampling surpasse le Nucleus Sampling pour tout nombre d'échantillons, améliorant les performances du modèle original de 2,87 % à 5 % par rapport à -Oz. De plus, il surpasse l'autotuneur utilisé pour la génération des étiquettes pour l'entraînement du modèle original en seulement 30 échantillons.
English
Large language models show great potential in generating and optimizing code. Widely used sampling methods such as Nucleus Sampling increase the diversity of generation but often produce repeated samples for low temperatures and incoherent samples for high temperatures. Furthermore, the temperature coefficient has to be tuned for each task, limiting its usability. We present Priority Sampling, a simple and deterministic sampling technique that produces unique samples ordered by the model's confidence. Each new sample expands the unexpanded token with the highest probability in the augmented search tree. Additionally, Priority Sampling supports generation based on regular expression that provides a controllable and structured exploration process. Priority Sampling outperforms Nucleus Sampling for any number of samples, boosting the performance of the original model from 2.87% to 5% improvement over -Oz. Moreover, it outperforms the autotuner used for the generation of labels for the training of the original model in just 30 samples.
PDF181December 15, 2024