Introduction
Standard Natural Language Processing (NLP) models typically operate under a "universal language" assumption, treating linguistic meaning as invariant across different speakers. However, language is inherently personal; individual styles, vocabularies, and sentiments vary significantly. PerPLM addresses this by personalizing Pretrained Language Models (PLMs) using only a writer's historical text, avoiding the need for external metadata like user graphs or demographic information.
Methodology
PerPLM introduces a two-pronged strategy for personalization:
1. Personalized Prompts
The framework utilizes two types of prompts to capture individual style:
- Soft Prompts: Continuous learnable vectors inserted into every layer of the Transformer architecture. These act as "style adjusters" tailored to specific writers.
- Hard Prompts: Input text is augmented with actual snippets from the writer's history. These can be Static (randomly selected) or Dynamic (semantically similar to the current input).
2. Personalized Intermediate Learning ("Inter")
The core innovation is an intermediate phase of Masked Language Modeling (MLM). Before fine-tuning on the target task, the model uses writer-specific prompts to predict missing words in the writer's historical text. This step establishes a stylistic "prior," allowing the model to associate specific prompts with a writer's unique linguistic "vibe."
Experimental Results
The researchers evaluated PerPLM on three datasets: Yelp (restaurant reviews), Amazon (movie/TV reviews), and Twitter (hashtag recommendation).
Sentiment Analysis (Yelp & Amazon)
As shown in the results for Yelp and Amazon, the inclusion of the "Inter" step consistently improves performance across various model architectures, including BERT, RoBERTa, and ELECTRA. For instance, on the Yelp dataset using BERT-base, Soft Prompts combined with Intermediate Learning achieved a macro-F1 of 78.76, significantly outperforming standard fine-tuning (76.31).
Hashtag Recommendation (Twitter)
The benefits of personalization were even more pronounced on the Twitter dataset, where brevity and idiosyncratic style are prevalent.
On Twitter, standard fine-tuning reached an nDCG@5 of 60.83. In contrast, the PerPLM configuration using Static Hard Prompts with Intermediate Learning reached 73.11, demonstrating the power of capturing stylistic priors in short-form text.
Key Insights
- Prompt Depth: Inserting prompts into all layers, particularly those closer to the output, is more effective than input-only personalization.
- Stylistic Priors: The intermediate MLM phase is a critical component, effectively "teaching" the model a writer's style before task-specific training.
- Generalization: For unknown writers, using "approximate" prompts from semantically similar known writers still provides a performance boost over non-personalized baselines.
Conclusion
PerPLM demonstrates that writer-specific intermediate learning and prompts can significantly enhance the personalization of PLMs using only historical text. While challenges remain regarding scaling to millions of users and ensuring data privacy, this approach provides a robust framework for more nuanced, individual-aware NLP.
Summary updated