JoLT: Jointly Learned Representations of Language and Time-Series

Yifu Cai, Mononito Goswami, Arjun Choudhry, Arvind Srinivasan, Artur DubrawskiDGM4H @ NeurIPS 2023

TL;DR

This paper introduces JoLT, a novel neural model that jointly learns representations from time-series data (like ECGs) and text. By directly modeling time-series alongside text, JoLT significantly improves clinical text summarization and shows promise for question answering, outperforming existing methods that treat these modalities independently or convert time-series into images.

What Problem Does This Paper Address?

In healthcare, time-series data (e.g., ECGs, EEGs) and accompanying textual reports are often generated together. However, current approaches tend to model these data types in isolation. Even when joint modeling is attempted, it often involves converting time-series into images or graphs, losing some of the inherent temporal information. This paper tackles the challenge of effectively integrating time-series and text data, hypothesizing that explicitly modeling them together can lead to better performance on tasks like summarizing clinical findings and answering questions about time-series data, areas that have been underexplored.

Methods

JoLT is a neural model composed of three main components: a time-series encoder, a text decoder, and a "Querying Transformer" (Q-Former) that bridges the two.

  • Time-Series Encoder: A Transformer-based model is pre-trained on time-series data using a masked time-series reconstruction objective. This encoder learns to represent segments of the time-series.
  • Text Decoder: A pre-trained language model (like OPT) is used as the decoder to generate textual output.
  • Querying Transformer (Q-Former): This novel component is crucial for aligning the representations from the time-series encoder and the text decoder. It uses learnable query tokens to extract relevant time-series features, conditioned on textual prompts. The Q-Former is trained with three objectives:
  • Contrastive Loss: To maximize mutual information between time-series and text representations.
  • Text Generation Loss: To train the Q-Former to generate text based on time-series input.
  • Time-Series Text Matching Loss: For finer alignment between the modalities.

During the final "Generative Learning" stage, the encoder and Q-Former are connected to the frozen decoder, and the entire model is trained end-to-end using a causal language modeling loss, with the query embeddings acting as soft prompts for the decoder.

Datasets

The primary dataset used for evaluation is the PTB-XL dataset. This is a large, publicly available dataset of 12-lead, 10-second ECG recordings from 18,885 patients. The authors used a subset of this data, paired with gold-standard clinical interpretations, for training and fine-tuning their model. They split the data into training (11,319 samples), validation (1,636 samples), and test (1,650 samples) sets.

Key Insights and Ideas

  • Direct Time-Series Modeling is Key: The paper strongly suggests that explicitly modeling time-series data, rather than converting it to images, leads to better performance in tasks like clinical summarization. This is because direct modeling preserves the rich temporal dynamics inherent in the signals.
  • Q-Former for Modality Alignment: The Q-Former is a critical innovation, enabling effective alignment between the distinct representations of time-series and text. This bridging mechanism is essential for the joint learning process.
  • Domain-Specific Fine-Tuning Matters: The experiments highlight that off-the-shelf general-purpose models (like BLIP-2) perform poorly on clinical data without domain-specific fine-tuning, underscoring the need for specialized models and datasets in healthcare.
  • Surprising Decoder Performance: Contrary to expectations, larger language models or those pre-trained on clinical data did not necessarily outperform models trained on general text for this specific task. This suggests that the nature of clinical interpretations (often terse) might not require massive, specialized language models.

Key Results

  • Summarization Performance: JoLT, when evaluated on the PTB-XL dataset for ECG interpretation, significantly outperformed a fine-tuned state-of-the-art image captioning model (BLIP-2). For instance, in Table 2, JoLT achieved a Rouge-L F1 score of 0.435, compared to BLIP-2's 0.225. Qualitative examples showed JoLT generating more accurate and comprehensive summaries.
  • Question Answering: JoLT also showed promise in time-series conditioned multiple-choice question answering, outperforming BiomedCLIP (Table 4), though both models performed poorly overall, often defaulting to the majority class.
  • Decoder Ablation: JoLT's performance was sensitive to the choice of decoder architecture, size, and pre-training data, with OPT-2.7B proving to be a strong choice.

Limitations and Future Work

  • Limited Pre-training Data: The authors note that JoLT's time-series encoder was pre-trained on a relatively small subset of the PTB-XL dataset. They believe that extending this pre-training with a larger, diverse set of time-series data could further boost performance.
  • Evaluation Challenges: The paper acknowledges that evaluating models for clinical applications is inherently challenging, and robust assessment methods are still an area of active research.
  • Question Answering Performance: While JoLT showed promise in question answering, its performance was still low, indicating a need for further research to improve accuracy and reduce overconfidence in predictions.
  • Broken Assumptions: The authors' hypotheses regarding the superiority of larger or clinically pre-trained decoders were not fully supported by their experiments, suggesting that further investigation is needed to understand these dynamics. Future work should focus on comprehensive evaluation and exploring more advanced architectures and pre-training strategies.

Summary updated

BibTeX
@inproceedings{cai2023jolt,
  author = {Yifu Cai and Mononito Goswami and Arjun Choudhry and Arvind Srinivasan and Artur Dubrawski},
  title = {{JoLT: Jointly Learned Representations of Language and Time-Series}},
  booktitle = {DGM4H @ NeurIPS},
  year = {2023},
  url = {https://openreview.net/forum?id=UVF1AMBj9u},
}
Figure