より小さな言語モデルのためのテキスト埋め込みを対照的ファインチューニングによって改善する
Improving Text Embeddings for Smaller Language Models Using Contrastive Fine-tuning
August 1, 2024
著者: Trapoom Ukarapol, Zhicheng Lee, Amy Xin
cs.AI
要旨
大規模言語モデルは自然言語理解において顕著な性能を示すが、そのリソース集約的な性質からアクセスしにくいという課題がある。一方で、MiniCPMのような小規模言語モデルは持続可能なスケーラビリティを提供するが、専門的な最適化なしでは性能が劣ることが多い。本論文では、テキスト埋め込みの改善を通じて小規模言語モデルの性能向上を探求する。MiniCPM、Phi-2、Gemmaの3つの言語モデルを選び、NLIデータセット上で対照的ファインチューニングを実施した。その結果、このファインチューニング手法が全てのモデルにおいて様々なベンチマークでテキスト埋め込みの品質を向上させることが示され、特にMiniCPMは平均56.33%の性能向上という最も顕著な改善を示した。対照的ファインチューニングのコードはhttps://github.com/trapoom555/Language-Model-STS-CFTで公開されている。
English
While Large Language Models show remarkable performance in natural language
understanding, their resource-intensive nature makes them less accessible. In
contrast, smaller language models such as MiniCPM offer more sustainable
scalability, but often underperform without specialized optimization. In this
paper, we explore the enhancement of smaller language models through the
improvement of their text embeddings. We select three language models, MiniCPM,
Phi-2, and Gemma, to conduct contrastive fine-tuning on the NLI dataset. Our
results demonstrate that this fine-tuning method enhances the quality of text
embeddings for all three models across various benchmarks, with MiniCPM showing
the most significant improvements of an average 56.33\% performance gain. The
contrastive fine-tuning code is publicly available at
https://github.com/trapoom555/Language-Model-STS-CFT.Summary
AI-Generated Summary