Adaptive Cross-lingual Text Classification through In-Context One-Shot Demonstrations

Emilio Villa-Cueva, A. Pastor López-Monroy, Fernando Sánchez-Vega, Thamar Solorio
4/3/2024
cs.CL

No official code found. Best implementation: villacu/ic_xlt (0 stars, last commit 2024-06-09).

Abstract

Zero-Shot Cross-lingual Transfer (ZS-XLT) utilizes a model trained in a source language to make predictions in another language, often with a performance loss. To alleviate this, additional improvements can be achieved through subsequent adaptation using examples in the target language. In this paper, we exploit In-Context Tuning (ICT) for One-Shot Cross-lingual transfer in the classification task by introducing In-Context Cross-lingual Transfer (IC-XLT). The novel concept involves training a model to learn from context examples and subsequently adapting it during inference to a target language by prepending a One-Shot context demonstration in that language. Our results show that IC-XLT successfully leverages target-language examples to improve the cross-lingual capabilities of the evaluated mT5 model, outperforming prompt-based models in the Zero and Few-shot scenarios adapted through fine-tuning. Moreover, we show that when source-language data is limited, the fine-tuning framework employed for IC-XLT performs comparably to prompt-based fine-tuning with significantly more training data in the source language.

View on arXivView PDF

Code Implementations(1)

villacu/ic_xltCommunity100%

In-Context Cross-lingual Transfer implementation example

00Python, Jupyter NotebookMar 27, 20242 years ago

Similar Papers

Cite this paper

@article{villacueva2024adaptive,
  title  = {Adaptive Cross-lingual Text Classification through In-Context One-Shot Demonstrations},
  author = {Emilio Villa-Cueva and A. Pastor López-Monroy and Fernando Sánchez-Vega and Thamar Solorio},
  year   = {2024},
  eprint = {2404.02452},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2404.02452v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2404.02452.svg)](https://codeofpaper.com/paper/2404.02452)

Discussion