혼합형 트랜스포머: 다중 모달 기반 모델을 위한 희소 및 확장 가능한 아키텍처
Mixture-of-Transformers: A Sparse and Scalable Architecture for Multi-Modal Foundation Models
November 7, 2024
저자: Weixin Liang, Lili Yu, Liang Luo, Srinivasan Iyer, Ning Dong, Chunting Zhou, Gargi Ghosh, Mike Lewis, Wen-tau Yih, Luke Zettlemoyer, Xi Victoria Lin
cs.AI
초록
대규모 언어 모델(LLM)의 발전은 텍스트, 이미지, 음성을 통합된 프레임워크 내에서 처리할 수 있는 다중 모달 시스템으로 확장되었습니다. 이러한 모델을 학습시키기 위해서는 텍스트 전용 LLM에 비해 훨씬 더 큰 데이터셋과 계산 자원이 필요합니다. 이러한 확장 문제를 해결하기 위해, 우리는 사전 학습 계산 비용을 크게 줄이는 희소 다중 모달 트랜스포머 아키텍처인 Mixture-of-Transformers(MoT)를 소개합니다. MoT는 피드포워드 네트워크, 어텐션 행렬, 레이어 정규화를 포함한 모델의 비임베딩 파라미터를 모달리티별로 분리하여, 전체 입력 시퀀스에 대한 전역적 자기 어텐션을 통해 모달리티별 처리를 가능하게 합니다. 우리는 MoT를 다양한 설정과 모델 규모에서 평가했습니다. Chameleon 7B 설정(자기회귀적 텍스트 및 이미지 생성)에서 MoT는 FLOPs의 55.8%만 사용하여 밀집 기준 모델의 성능과 동등한 성능을 보였습니다. 음성을 포함하도록 확장했을 때, MoT는 FLOPs의 37.2%만으로 밀집 기준 모델과 비슷한 음성 성능을 달성했습니다. 텍스트와 이미지가 서로 다른 목표로 학습되는 Transfusion 설정에서, 7B MoT 모델은 FLOPs의 1/3만으로 밀집 기준 모델의 이미지 모달리티 성능과 동등한 성능을 보였으며, 760M MoT 모델은 주요 이미지 생성 지표에서 1.4B 밀집 기준 모델을 능가했습니다. 시스템 프로파일링은 MoT의 실질적인 이점을 더욱 강조하며, 밀집 기준 모델의 이미지 품질을 47.2%의 벽시계 시간으로, 텍스트 품질을 75.6%의 벽시계 시간으로 달성했습니다(AWS p4de.24xlarge 인스턴스와 NVIDIA A100 GPU에서 측정).
English
The development of large language models (LLMs) has expanded to multi-modal
systems capable of processing text, images, and speech within a unified
framework. Training these models demands significantly larger datasets and
computational resources compared to text-only LLMs. To address the scaling
challenges, we introduce Mixture-of-Transformers (MoT), a sparse multi-modal
transformer architecture that significantly reduces pretraining computational
costs. MoT decouples non-embedding parameters of the model by modality --
including feed-forward networks, attention matrices, and layer normalization --
enabling modality-specific processing with global self-attention over the full
input sequence. We evaluate MoT across multiple settings and model scales. In
the Chameleon 7B setting (autoregressive text-and-image generation), MoT
matches the dense baseline's performance using only 55.8\% of the FLOPs. When
extended to include speech, MoT reaches speech performance comparable to the
dense baseline with only 37.2\% of the FLOPs. In the Transfusion setting, where
text and image are trained with different objectives, a 7B MoT model matches
the image modality performance of the dense baseline with one third of the
FLOPs, and a 760M MoT model outperforms a 1.4B dense baseline across key image
generation metrics. System profiling further highlights MoT's practical
benefits, achieving dense baseline image quality in 47.2\% of the wall-clock
time and text quality in 75.6\% of the wall-clock time (measured on AWS
p4de.24xlarge instances with NVIDIA A100 GPUs).