Template-assisted Contrastive Learning of Task-oriented Dialogue Sentence Embeddings

Minsik Oh, Jiwei Li, Guoyin Wang
5/23/2023
cs.CLcs.AI

Official code: minsik-ai/Template-Contrastive-Embedding (1 star, Apache-2.0, last commit 2026-04-08).

Abstract

Learning high quality sentence embeddings from dialogues has drawn increasing attentions as it is essential to solve a variety of dialogue-oriented tasks with low annotation cost. Annotating and gathering utterance relationships in conversations are difficult, while token-level annotations, \eg, entities, slots and templates, are much easier to obtain. Other sentence embedding methods are usually sentence-level self-supervised frameworks and cannot utilize token-level extra knowledge. We introduce Template-aware Dialogue Sentence Embedding (TaDSE), a novel augmentation method that utilizes template information to learn utterance embeddings via self-supervised contrastive learning framework. We further enhance the effect with a synthetically augmented dataset that diversifies utterance-template association, in which slot-filling is a preliminary step. We evaluate TaDSE performance on five downstream benchmark dialogue datasets. The experiment results show that TaDSE achieves significant improvements over previous SOTA methods for dialogue. We further introduce a novel analytic instrument of semantic compression test, for which we discover a correlation with uniformity and alignment. Our code is available at https://github.com/minsik-ai/Template-Contrastive-Embedding

View on arXivView PDF

Code Implementations(1)

Apache-2.0

TaDSE: Template-assisted Contrastive Learning of Task-oriented Dialogue Sentence Embeddings (ACL 2026)

10PythonApr 8, 20266 months agoApache-2.0

Similar Papers

Cite this paper

@article{oh2023templateassisted,
  title  = {Template-assisted Contrastive Learning of Task-oriented Dialogue Sentence Embeddings},
  author = {Minsik Oh and Jiwei Li and Guoyin Wang},
  year   = {2023},
  eprint = {2305.14299},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2305.14299v3}
}

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

Discussion