Small language models (SLMs) have emerged as efficient alternatives to large language models for task-specific applications. However, they are often employed in high-volume, low-latency settings, where efficiency is crucial. We propose TASC, Task-Adaptive Sequence Compression, a framework for SLM acceleration comprising two use-cases: When performing SLM fine-tuning, we propose TASC-ft, which iteratively enriches the tokenizer vocabulary with high-frequency output n-grams and then fine-tunes the model to utilize the expanded vocabulary. Next, we propose an inference-time method, termed TASC-spec. TASC-spec is a lightweight, training-free speculative decoding method that constructs an n-gram draft model from the task's output corpus, mixing task and context n-gram information.TASC-spec avoids any additional training, while bypassing draft-target vocabulary alignment constraints. We demonstrate the effectiveness of both methods across multiple low output-variability generation tasks. Our methods show consistent improvements in inference efficiency while maintaining task performance.


翻译:小型语言模型已成为面向特定任务应用时,相较于大型语言模型的高效替代方案。然而,它们通常被部署在高吞吐量、低延迟的场景中,此时效率至关重要。我们提出了TASC(任务自适应序列压缩)框架,这是一个用于加速小型语言模型的框架,包含两个应用场景:在进行小型语言模型微调时,我们提出了TASC-ft方法,该方法迭代地将高频输出n-gram加入分词器词汇表,然后微调模型以利用扩展后的词汇表。其次,我们提出了一种推理时方法,称为TASC-spec。TASC-spec是一种轻量级、无需训练的推测解码方法,它从任务的输出语料库中构建一个n-gram草稿模型,混合了任务和上下文的n-gram信息。TASC-spec避免了任何额外的训练,同时绕过了草稿模型与目标模型词汇对齐的限制。我们在多个低输出可变性的生成任务上验证了两种方法的有效性。我们的方法在保持任务性能的同时,持续提升了推理效率。

0
下载
关闭预览

相关内容

运用小型语言模型解锁战术边缘人工智能优势
专知会员服务
30+阅读 · 2025年9月7日
大语言模型与小语言模型协同机制综述
专知会员服务
40+阅读 · 2025年5月15日
小型语言模型综述
专知会员服务
55+阅读 · 2024年10月29日
《大型语言模型加速生成技术》最新综述
专知会员服务
50+阅读 · 2024年5月25日
一文速览大语言模型提示最新进展
专知会员服务
80+阅读 · 2023年12月24日
自然语言处理中的语言模型预训练方法
PaperWeekly
14+阅读 · 2018年10月21日
NLP通用模型诞生?一个模型搞定十大自然语言常见任务
人工智能头条
10+阅读 · 2018年6月29日
超全总结:神经网络加速之量化模型 | 附带代码
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
3+阅读 · 2014年12月31日
VIP会员
最新内容
面向具身智能与机器人仿真的三维生成:综述
专知会员服务
1+阅读 · 今天14:22
《新兴技术武器化及其对全球风险的影响》
专知会员服务
8+阅读 · 4月29日
《帕兰泰尔平台介绍:信息分析平台》
专知会员服务
21+阅读 · 4月29日
相关VIP内容
运用小型语言模型解锁战术边缘人工智能优势
专知会员服务
30+阅读 · 2025年9月7日
大语言模型与小语言模型协同机制综述
专知会员服务
40+阅读 · 2025年5月15日
小型语言模型综述
专知会员服务
55+阅读 · 2024年10月29日
《大型语言模型加速生成技术》最新综述
专知会员服务
50+阅读 · 2024年5月25日
一文速览大语言模型提示最新进展
专知会员服务
80+阅读 · 2023年12月24日
相关基金
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
3+阅读 · 2014年12月31日
Top
微信扫码咨询专知VIP会员