[논문 리뷰] Qwen2.5-1M Technical Report
Qwen2.5-1M은 컨텍스트 길이를 1M 토큰으로 확장하고, 긴 컨텍스트 사전 학습, 사후 학습, 및 길이 외삽, 희소 어텐션, 시스템 수준 최적화를 갖춘 오픈 소스 추론 프레임워크를 도입하여 ultra-long 입력에 대한 선행 채움(prefill) 속도 향상을 크게 실현합니다.
We introduce Qwen2.5-1M, a series of models that extend the context length to 1 million tokens. Compared to the previous 128K version, the Qwen2.5-1M series have significantly enhanced long-context capabilities through long-context pre-training and post-training. Key techniques such as long data synthesis, progressive pre-training, and multi-stage supervised fine-tuning are employed to effectively enhance long-context performance while reducing training costs. To promote the use of long-context models among a broader user base, we present and open-source our inference framework. This framework includes a length extrapolation method that can expand the model context lengths by at least four times, or even more, without additional training. To reduce inference costs, we implement a sparse attention method along with chunked prefill optimization for deployment scenarios and a sparsity refinement method to improve precision. Additionally, we detail our optimizations in the inference engine, including kernel optimization, pipeline parallelism, and scheduling optimization, which significantly enhance overall inference performance. By leveraging our inference framework, the Qwen2.5-1M models achieve a remarkable 3x to 7x prefill speedup in scenarios with 1 million tokens of context. This framework provides an efficient and powerful solution for developing applications that require long-context processing using open-source models. The Qwen2.5-1M series currently includes the open-source models Qwen2.5-7B-Instruct-1M and Qwen2.5-14B-Instruct-1M, as well as the API-accessed model Qwen2.5-Turbo. Evaluations show that Qwen2.5-1M models have been greatly improved in long-context tasks without compromising performance in short-context scenarios. Specifically, the Qwen2.5-14B-Instruct-1M model significantly outperforms GPT-4o-mini in long-context tasks and supports contexts eight times longer.
연구 동기 및 목표
- LLM에서 128k 토큰을 넘는 롱 컨텍스트 처리의 동기 부여 및 구현.
- 롱-리치 추론을 개선하면서 짧은 컨텍스트 성능을 보존하기 위한 효율적인 롱-컨텍스트 사전 학습 및 사후 학습 전략 개발.
- 비용을 절감하고 배치를 가속화하기 위한 길이 외삽, 희소 어텐션, 엔진 최적화를 갖춘 오픈 소스 추론 프레임워크를 제공.
제안 방법
- 합성 데이터와 장거리 의존성을 개선하기 위한 롱-컨텍스트 사전 학습 및 장거리 학습 단계.
- 합성 롱-인스트럭션 데이터와 두 단계의 감독 미세 조정 및 오프라인 강화 학습을 포함한 사후 학습.
- Dual Chunk Attention 및 YaRN 어텐션 스케일링을 통한 길이 외삽, MInference와 함께하는 희소 어텐션, 청크드 프리필 최적화를 특징으로 하는 오픈 소스 추론 프레임워크; 커널, 파이프라인, 스케줄링 개선을 포함한 엔진 최적화.
실험 결과
연구 질문
- RQ1짧은 컨텍스트 성능을 유지하거나 향상시키면서 LLM 컨텍스트를 1M 토큰까지 효과적으로 확장할 수 있는가?
- RQ2Qwen2.5-1M에서 장거리 의존성을 가장 잘 촉진하는 데이터 및 훈련 전략은 무엇인가?
- RQ3길이 외삽, 희소 어텐션 및 엔진 최적화를 통해 초장 컨텍스트에서 추론을 비용 효율적이고 확장 가능하게 만들 수 있는가?
- RQ4길이 외삽 및 희소성 정제가 롱 컨텍스트 검색 및 질의응답 작업에 미치는 영향은 무엇인가?
- RQ5기존의 1M 컨텍스트 대안들과 비교하여 Qwen2.5-1M 모델은 롱 컨텍스트 벤치마크에서 어떤 차이를 보이는가?
주요 결과
- Qwen2.5-1M 모델은 오픈 소스 추론 프레임워크를 사용할 때 1M 컨텍스트 처리와 함께 prefill에서 상당한 속도 향상(3배에서 7배의 prefill 속도 증가)을 달성합니다.
- 262,144 토큰까지의 점진적 컨텍스트 길이와 합성 롱-데이터 작업을 포함한 롱-컨텍스트 학습은 짧은 컨텍스트 성능을 희생하지 않으면서 롱-컨텍스트 이해를 향상시킵니다.
- 두 단계 사후 학습과 오프라인 RL은 인간 선호도와의 정렬을 개선하고 롱컨텍스트 작업에 일반화되며, RL 후 Longbench-Chat에서 측정 가능한 이점을 보입니다.
- Dual Chunk Attention (DCA) 및 YaRN 어텐션 스케일링을 통한 길이 외삽은 1M 토큰까지의 컨텍스트를 가진 Passkey Retrieval 및 NIAH와 같은 롱 컨텍스트 작업의 성능을 크게 향상시킵니다.
- MInference 기반 희소 어텐션, 청크드 프리필 및 희소성 정제는 1M 토큰 컨텍스트에서 Needle in a Haystack 테스트의 대부분의 검색 정확도를 회복시키면서 상당한 속도 향상을 가능하게 합니다.
더 나은 연구,지금 바로 시작하세요
연구 설계부터 논문 작성까지, 연구 시간을 획기적으로 줄여보세요.
카드 등록 없음 · 무료 플랜 제공
이 리뷰는 AI가 만들고, 인간 에디터가 검토했습니다.