NeuroLM: A Universal Multi-task Foundation Model for Bridging the Gap between Language and EEG Signals

Weibang Jiang, Yansen Wang, Bao-liang Lu, Dongsheng Li

TL;DR

NeuroLM is the first multi-task foundation model for EEG signals that treats brain activity as a "foreign language." By aligning EEG data with the embedding space of Large Language Models (LLMs) and using instruction tuning, it creates a single, unified model capable of performing diverse tasks—from emotion recognition to seizure detection—without needing task-specific architectures.

What Problem Does This Paper Address?

Electroencephalogram (EEG) signals are the "gold standard" for non-invasive brain-computer interfaces (BCIs), but they are notoriously difficult to work with. They have a low signal-to-noise ratio, vary wildly between individuals, and come in different channel configurations.

While recent "foundation models" for EEG have improved performance through large-scale pre-training, they suffer from a major limitation: versatility. To use these models for a specific task (like classifying sleep stages vs. detecting epilepsy), researchers must fully fine-tune the entire model on a specific dataset. This results in a fragmented ecosystem of single-task models, leading to significant resource wastage and a lack of a universal interface for brain signals. NeuroLM aims to bridge this gap by creating a model that understands EEG and language simultaneously.

Methods

The researchers developed a three-stage training pipeline to transform an LLM into an EEG expert:

  1. Text-Aligned Neural Tokenizer: Continuous EEG signals are "pachified" and passed through a Vector-Quantized (VQ) encoder. Unlike previous models that only look at raw waves, NeuroLM predicts both temporal and frequency domains (Fourier magnitudes). Crucially, they use adversarial training with a domain classifier to force these EEG tokens into the same mathematical space as text embeddings, essentially teaching the model that EEG tokens are just another vocabulary.
Text-Aligned Neural Tokenizer Architecture
  1. Multi-channel Autoregressive Pre-training: The model (based on GPT-2) is pre-trained on 25,000 hours of EEG data. They introduced a stair-stepping mask for the attention mechanism, allowing the model to learn causal relationships across different brain regions (channels) over time.
  2. Multi-task Instruction Tuning: By feeding the model natural language prompts (e.g., [SEP] Question: Is this EEG segment abnormal? Answer:), the model learns to map specific EEG patterns to text-based answers. This allows a single model to switch between six different tasks just by changing the text prompt.

Datasets

  • Pre-training: A massive corpus of ~25,000 hours of EEG data, primarily anchored by the TUEG (Temple University Hospital EEG) dataset, supplemented by several others like the SEED series and BCI Competition data.
  • Evaluation (6 Downstream Tasks):
  • TUAB: Abnormal vs. normal detection.
  • TUEV: Six-class seizure/event classification.
  • SEED: Three-class emotion recognition.
  • HMC: Five-stage sleep classification.
  • Workload: Cognitive load prediction.
  • TUSL: Slowing event classification.

Key Insights and Ideas

  • EEG as a Foreign Language: The core philosophy is that brain signals have a syntax and semantics that an LLM can parse if the input is tokenized correctly.
  • Space-wise Alignment: Because we don't have captions for most EEG data (unlike images), the authors couldn't use CLIP-style pairing. Instead, they used a domain classifier to ensure the distribution of EEG tokens matches the distribution of text tokens.
  • The Frequency Factor: Reconstructing the frequency domain is vital for "cognitive" tasks like emotion and sleep classification, whereas the temporal domain is more important for detecting physical abnormalities.
  • Layer Specialization: Visualization shows that shallow layers of the model focus on understanding the text instruction, while deeper layers focus on the EEG tokens to generate the final answer.

Key Results

Performance comparison of NeuroLM against single-task models
  • Scale: The largest variant, NeuroLM-XL, boasts 1.7 billion parameters, making it the largest EEG-processing model to date.
  • Performance: NeuroLM achieves performance comparable to state-of-the-art (SOTA) single-task models (like LaBraM) but does so within a single multi-task framework.
  • Robustness: The model demonstrates true linguistic understanding; for multiple-choice tasks, it remains accurate even when the order of options in the prompt is shuffled.
  • Zero-Shot Potential: The instruction-tuning paradigm suggests the model could potentially generalize to entirely new EEG tasks described in natural language.

Limitations and Future Work

While NeuroLM is a massive step toward a universal model, it still lags slightly behind specialized, end-to-end trained models on certain specific metrics and is sensitive to hyperparameter tuning.

Future Directions: * Upgrading the Backbone: Moving from GPT-2 to more modern, powerful open-source models like LLaMA 3. * Mixture-of-Experts (MoE): Using specialized expert layers within the LLM to handle the distinct gap between brain signals and human language. * Finer Alignment: Developing methods to describe EEG samples with more detailed text descriptions during the tokenizer training phase to improve the semantic link between the two modalities.

Summary updated

BibTeX
@inproceedings{jiang2025neurolm,
  author = {Weibang Jiang and Yansen Wang and Bao-liang Lu and Dongsheng Li},
  title = {{NeuroLM: A Universal Multi-task Foundation Model for Bridging the Gap between Language and EEG Signals}},
  booktitle = {International Conference on Learning Representations},
  year = {2025},
  url = {https://openreview.net/forum?id=Io9yFt7XH7},
}
Figure