Papers
Topics
Authors
Recent
Search
2000 character limit reached

Detecting out-of-distribution text using topological features of transformer-based language models

Published 22 Nov 2023 in cs.CL, cs.LG, and math.AT | (2311.13102v2)

Abstract: To safeguard machine learning systems that operate on textual data against out-of-distribution (OOD) inputs that could cause unpredictable behaviour, we explore the use of topological features of self-attention maps from transformer-based LLMs to detect when input text is out of distribution. Self-attention forms the core of transformer-based LLMs, dynamically assigning vectors to words based on context, thus in theory our methodology is applicable to any transformer-based LLM with multihead self-attention. We evaluate our approach on BERT and compare it to a traditional OOD approach using CLS embeddings. Our results show that our approach outperforms CLS embeddings in distinguishing in-distribution samples from far-out-of-domain samples, but struggles with near or same-domain datasets.

Summary

No one has generated a summary of this paper yet.

Paper to Video (Beta)

No one has generated a video about this paper yet.

Whiteboard

No one has generated a whiteboard explanation for this paper yet.

Open Problems

We haven't generated a list of open problems mentioned in this paper yet.

Continue Learning

We haven't generated follow-up questions for this paper yet.