Context-Aware Conversation Thread Detection in Multi-Party Chat

Ming Tan, Dakuo Wang, Yupeng Gao, Haoyu Wang, Saloni Potdar, Xiaoxiao Guo, Shiyu Chang, Mo Yu

Abstract

In multi-party chat platforms like Slack or IRC, multiple conversations often occur simultaneously, leading to interleaved message logs that are difficult for machines to disentangle. We propose CATD (Context-Aware Thread Detection), a framework that moves beyond traditional pairwise message comparisons by modeling the entire history and "flow" of conversation threads. CATD utilizes LSTMs to capture conversational rhythm and attention mechanisms to identify semantic links across non-consecutive messages. Our hybrid model, CATD-COMBINE, uses a dynamic gate to weigh these features, achieving state-of-the-art results on Reddit-based benchmarks, particularly in dense discussion environments.

Introduction

The challenge of "chat disentanglement" involves automatically assigning messages in a multi-party stream to their respective conversation threads. Traditional approaches often rely on pairwise similarity—calculating the relationship between a new message and a single preceding one. However, this ignores the broader context, such as the specific "genre" of the conversation, the set of active participants, and the topical progression over time. Humans naturally use this thread-level context to follow conversations; CATD aims to replicate this capability computationally.

Methodology

The CATD framework consists of two specialized sub-models integrated via a dynamic gating mechanism.

CATD-FLOW and CATD-MATCH

  1. CATD-FLOW: This component treats a thread as a continuous stream. It employs a Long Short-Term Memory (LSTM) network to encode the historical sequence of a thread. When a new message arrives, the model evaluates how well it fits the established conversational "flow."
  2. CATD-MATCH: Utilizing an attention mechanism, this model looks back at all previous messages in a thread to identify those most relevant to the current input. This allows the system to capture semantic dependencies that may span several intervening messages.
Architectural overview of the CATD-FLOW and CATD-MATCH models.

CATD-COMBINE and Inference

The final architecture, CATD-COMBINE, uses a sigmoid-based dynamic gate to decide the relative importance of flow versus matching for each message. To optimize the global thread structure, the system employs Beam Search during inference. This prevents the model from making irreversible errors early in the process by maintaining multiple high-probability threading hypotheses.

Experimental Setup

The models were evaluated on three datasets derived from Reddit: Gadgets, Iphones, and Politics. A key contribution of this work is the implementation of a thread-level split, ensuring that entire threads are kept together in either the training or testing sets to prevent data leakage. Messages were represented using Google’s Universal Sentence Encoder (USE), supplemented by features such as user identity and temporal gaps.

Results and Discussion

CATD models significantly outperformed existing baselines, including GTM and CISIR-USE, across all tested metrics: Normalized Mutual Information (NMI), Adjusted Rand Index (ARI), and F1-score.

Performance comparison of CATD models against state-of-the-art baselines across three Reddit datasets.

The improvement was most pronounced in the Politics dataset, which featured the highest message density and complexity. While baselines struggled significantly (ARI ~0.032), CATD-COMBINE achieved an ARI of 0.461. Ablation studies confirmed that the dynamic gating mechanism in the COMBINE model was superior to simpler methods like concatenation or parameter sharing.

Conclusion

By shifting the focus from message pairs to entire thread contexts, CATD sets a new benchmark for chat disentanglement. The combination of sequence modeling (FLOW) and attention-based relevance (MATCH) provides a robust framework for handling the complexities of multi-party dialogue. Future work may explore Transformer-based architectures and more granular linguistic features to further enhance detection in high-velocity real-time environments.

Summary updated

BibTeX
@inproceedings{tan2019context,
  author = {Ming Tan and Dakuo Wang and Yupeng Gao and Haoyu Wang and Saloni Potdar and Xiaoxiao Guo and Shiyu Chang and Mo Yu},
  title = {{Context-Aware Conversation Thread Detection in Multi-Party Chat}},
  booktitle = {Conference on Empirical Methods in Natural Language Processing},
  year = {2019},
  doi = {10.18653/v1/d19-1682},
}
Figure