LLM-pruning en distillatie in de praktijk: de Minitron-aanpak
LLM Pruning and Distillation in Practice: The Minitron Approach
August 21, 2024
Auteurs: Sharath Turuvekere Sreenivas, Saurav Muralidharan, Raviraj Joshi, Marcin Chochowski, Mostofa Patwary, Mohammad Shoeybi, Bryan Catanzaro, Jan Kautz, Pavlo Molchanov
cs.AI
Samenvatting
We presenteren een uitgebreid rapport over het comprimeren van de Llama 3.1 8B en Mistral NeMo 12B modellen naar respectievelijk 4B en 8B parameters, met behulp van pruning en distillatie. We onderzoeken twee verschillende pruningstrategieën: (1) diepte-pruning en (2) gezamenlijke hidden/attention/MLP (breedte) pruning, en evalueren de resultaten op gangbare benchmarks uit de LM Evaluation Harness. De modellen worden vervolgens afgestemd met NeMo Aligner en getest in instruct-getunede versies. Deze aanpak resulteert in een overtuigend 4B model afgeleid van Llama 3.1 8B en een state-of-the-art Mistral-NeMo-Minitron-8B (MN-Minitron-8B voor de bondigheid) model afgeleid van Mistral NeMo 12B. We ontdekten dat het, zonder toegang tot de originele data, voordelig is om de leraarmodellen lichtelijk te finetunen op de distillatiedataset. We maken onze basismodelgewichten openbaar op Hugging Face onder een permissieve licentie.
English
We present a comprehensive report on compressing the Llama 3.1 8B and Mistral
NeMo 12B models to 4B and 8B parameters, respectively, using pruning and
distillation. We explore two distinct pruning strategies: (1) depth pruning and
(2) joint hidden/attention/MLP (width) pruning, and evaluate the results on
common benchmarks from the LM Evaluation Harness. The models are then aligned
with NeMo Aligner and tested in instruct-tuned versions. This approach produces
a compelling 4B model from Llama 3.1 8B and a state-of-the-art
Mistral-NeMo-Minitron-8B (MN-Minitron-8B for brevity) model from Mistral NeMo
12B. We found that with no access to the original data, it is beneficial to
slightly fine-tune teacher models on the distillation dataset. We open-source
our base model weights on Hugging Face with a permissive license.Summary
AI-Generated Summary