Efficiently Exploring Large Language Models for Document-Level Machine Translation with In-context Learning

Menglong Cui, Jiangcun Du, Shaolin Zhu, Deyi Xiong
6/11/2024
cs.CL

No confident code implementation found for this paper.

Abstract

Large language models (LLMs) exhibit outstanding performance in machine translation via in-context learning. In contrast to sentence-level translation, document-level translation (DOCMT) by LLMs based on in-context learning faces two major challenges: firstly, document translations generated by LLMs are often incoherent; secondly, the length of demonstration for in-context learning is usually limited. To address these issues, we propose a Context-Aware Prompting method (CAP), which enables LLMs to generate more accurate, cohesive, and coherent translations via in-context learning. CAP takes into account multi-level attention, selects the most relevant sentences to the current one as context, and then generates a summary from these collected sentences. Subsequently, sentences most similar to the summary are retrieved from the datastore as demonstrations, which effectively guide LLMs in generating cohesive and coherent translations. We conduct extensive experiments across various DOCMT tasks, and the results demonstrate the effectiveness of our approach, particularly in zero pronoun translation (ZPT) and literary translation tasks.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. Any repos shown below are weak matches — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{cui2024efficiently,
  title  = {Efficiently Exploring Large Language Models for Document-Level Machine Translation with In-context Learning},
  author = {Menglong Cui and Jiangcun Du and Shaolin Zhu and Deyi Xiong},
  year   = {2024},
  eprint = {2406.07081},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2406.07081v1}
}

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/2406.07081.svg)](https://codeofpaper.com/paper/2406.07081)

Discussion