Abstract
Multi-attribute controllable text generation (CTG) faces significant challenges due to the complex and shifting relationships between target attributes. We present TARA (Token-level Attribute Relation Adaptation), a framework that explicitly models these relationships at the token level. By identifying whether attributes are "promotive" or "inhibitory" during the generation process, TARA achieves significantly higher control accuracy than previous methods while maintaining high text quality and fluency.
Introduction
Controllable Text Generation (CTG) aims to produce text that satisfies specific constraints, such as a "positive" sentiment or a specific topic like "Mexican food." The challenge escalates when trying to satisfy multiple attributes simultaneously. Most existing research treats attributes as independent or focuses solely on static "interference," where one attribute's signal washes out another.
However, attribute relations are dynamic and token-dependent. For example, in a restaurant review, the word "fries" might be promotive for both "Positive" and "American" attributes, but inhibitory if the goal is "Negative" and "American." Failing to account for these shifting relationships leads to "attribute control degeneration," where the model ignores one attribute to satisfy another or produces incoherent text.
Methods
TARA introduces three key components to handle these dynamic relations within a unified framework:
- Attribute-Adaptive Prefix Tuning: The model fine-tunes attribute-specific prefixes using a novel loss function ($L_{adapt}$) incorporating L2 normalization and variance. This forces the model to ignore tokens with weak attribute expressions and focus on "vital" attribute properties, reducing the noise that causes inhibitory interference.
- Token-level Attribute Representation ($r_{att}$): To isolate the "pure" control signal, TARA subtracts the logits of a base language model from the logits of the attribute-specific model. This removes common "quality" tokens (like "the," "is," "a") from the control signal, ensuring the model focuses strictly on tokens that convey the desired attributes.
- Dynamic Text Generation Strategy: During inference, the model calculates dynamic weights for each attribute based on how well the current sequence already satisfies them. This "tug-of-war" balance ensures that promotive relations are exploited and inhibitory ones are mitigated in real-time.
Experimental Evaluation
The researchers evaluated TARA using the YELP restaurant review dataset, testing combinations of Sentiment (Positive, Negative) and Topic (Asian, American, Mexican).
Key Results
- Superior Accuracy: TARA achieved an average correctness of 85.25%, outperforming the best comparative baseline (PromptGating) by 5.34%.
- Balanced Performance: Unlike baselines that achieve high accuracy at the cost of fluency (e.g., GeDi, which had a massive perplexity of 616), TARA maintained a competitive perplexity of 40.16, indicating fluent, human-like text.
- Scalability: In triple-attribute tests (Sentiment + Topic + Dessert), TARA maintained robust performance (78.12% average correctness), proving it can handle increasingly complex constraints better than traditional prefix-tuning methods.
Discussion and Limitations
The core insight of TARA is that attribute relations are not global properties but exist at the token level. By subtracting the base model's influence, the authors achieved a "pure" signal that significantly improved control correctness. Furthermore, the use of L2 normalization acts as a "forgetting mechanism," forcing the model to identify only the most essential tokens for a given attribute.
While TARA excels at control, its results in text diversity and perplexity are slightly inferior to some specialized models that prioritize fluency over strict control. Additionally, the model may inherit biases present in the YELP training data. Future work could involve integrating "safety" attributes—like detoxification or politeness—as default constraints to mitigate the generation of harmful content.
Summary updated