AdaptiVocab: 경량 어휘 적응을 통해 특정 도메인에서의 대형 언어 모델 효율성 향상
AdaptiVocab: Enhancing LLM Efficiency in Focused Domains through Lightweight Vocabulary Adaptation
March 25, 2025
저자: Itay Nakash, Nitay Calderon, Eyal Ben David, Elad Hoffer, Roi Reichart
cs.AI
초록
대규모 언어 모델(LLMs)은 범용 모델로서 인상적인 다재다능성을 보여주고 있습니다. 그러나 이러한 광범위한 적용 가능성은 높은 계산 비용, 특히 자동회귀 디코딩 과정에서 각 단계마다 순방향 전달이 필요한 경우에 큰 부담으로 작용합니다. 도메인 특화 환경에서는 범용 기능이 불필요하며, 이를 효율성과 교환할 수 있습니다. 본 연구에서는 도메인 적응에 대한 새로운 관점을 제시하며, 관심 도메인에 맞춰 어휘를 조정함으로써 지연 시간과 계산 비용을 줄이는 방법을 탐구합니다. 우리는 AdaptiVocab이라는 종단 간 어휘 적응 접근법을 소개합니다. 이는 저자원 도메인에서 LLM의 효율성을 향상시키기 위해 설계되었습니다. AdaptiVocab은 어떤 토크나이저와 아키텍처에도 적용 가능하며, 도메인 특화 n-gram 기반 토큰으로 기존 토큰을 대체함으로써 입력 처리와 출력 생성에 필요한 토큰 수를 줄입니다. AdaptiVocab은 기존 임베딩의 지수 가중치 조합을 사용하여 새로운 n-토큰 임베딩을 초기화하고, 단일 GPU에서 효율적으로 수행할 수 있는 경량 미세 조정 단계를 사용합니다. 우리는 두 개의 7B LLM을 세 개의 특수 도메인에서 평가하며, 효율성, 생성 품질 및 최종 작업 성능을 측정했습니다. 그 결과, AdaptiVocab은 성능 저하 없이 토큰 사용량을 25% 이상 줄이는 것으로 나타났습니다.
English
Large Language Models (LLMs) have shown impressive versatility as general
purpose models. However, their broad applicability comes at a high-cost
computational overhead, particularly in auto-regressive decoding where each
step requires a forward pass. In domain-specific settings, general-purpose
capabilities are unnecessary and can be exchanged for efficiency. In this work,
we take a novel perspective on domain adaptation, reducing latency and
computational costs by adapting the vocabulary to focused domains of interest.
We introduce AdaptiVocab, an end-to-end approach for vocabulary adaptation,
designed to enhance LLM efficiency in low-resource domains. AdaptiVocab can be
applied to any tokenizer and architecture, modifying the vocabulary by
replacing tokens with domain-specific n-gram-based tokens, thereby reducing the
number of tokens required for both input processing and output generation.
AdaptiVocab initializes new n-token embeddings using an exponentially weighted
combination of existing embeddings and employs a lightweight fine-tuning phase
that can be efficiently performed on a single GPU. We evaluate two 7B LLMs
across three niche domains, assessing efficiency, generation quality, and
end-task performance. Our results show that AdaptiVocab reduces token usage by
over 25% without compromising performanceSummary
AI-Generated Summary