# Auxiliary Tuning and its Application to Conditional Text Generation

- Speaker: [Yoel Zeldes](/wiki/speakers/yoel-zeldes.md)
- Event: [Reversim Summit 2020](/wiki/years/2020.md)
- Video: https://www.youtube.com/watch?v=1GxdGHinpwk
- Transcript: [/transcripts/2020/09-1GxdGHinpwk.md](/transcripts/2020/09-1GxdGHinpwk.md)
- Language: Hebrew · Type: talk · Level: advanced
- Topics: [Machine Learning](/wiki/topics/machine-learning.md), [AI and LLMs](/wiki/topics/generative-ai.md)

> Written by an LLM from machine transcripts. It can contain errors. Check the transcript before you quote it.

## Summary

The speaker discusses the high cost of training large language models like GPT-3 and proposes a method called auxiliary tuning to adapt pre-trained models for conditional text generation without updating their weights. By combining a pre-trained fluency model with a smaller auxiliary model trained from scratch, developers can steer text generation toward specific attributes while avoiding catastrophic forgetting. This approach provides a simpler, more cost-effective alternative to fine-tuning massive models from scratch or complex decoding-time steering methods. The audience learns how to design and implement auxiliary tuning using transformer architectures to save computational resources.

## Key points

- [0:12](https://www.youtube.com/watch?v=1GxdGHinpwk&t=12s) Training massive language models like GPT-3 requires enormous financial investments, often reaching up to 12 million dollars due to the scale of transformer architectures.
- [1:19](https://www.youtube.com/watch?v=1GxdGHinpwk&t=79s) Language models predict the next token by converting text into embeddings and processing them through contextualization layers to capture semantic meaning.
- [5:37](https://www.youtube.com/watch?v=1GxdGHinpwk&t=337s) Fine-tuning large pre-trained models for conditional tasks risks catastrophic forgetting on one extreme and under-adaptation on the other.
- [6:42](https://www.youtube.com/watch?v=1GxdGHinpwk&t=402s) Auxiliary tuning solves conditional text generation by separating the problem into fluency, handled by the frozen pre-trained model, and attribute adherence, handled by a separate auxiliary model.
- [9:51](https://www.youtube.com/watch?v=1GxdGHinpwk&t=591s) The auxiliary tuning framework combines logit vectors from both the pre-trained language model and the auxiliary model using a probabilistic interpretation.
- [16:03](https://www.youtube.com/watch?v=1GxdGHinpwk&t=963s) Feature extraction can be incorporated into auxiliary tuning to leverage contextual representations from the pre-trained model, speeding up training and reducing model size.
- [18:20](https://www.youtube.com/watch?v=1GxdGHinpwk&t=1100s) When tested on tasks like keyword-conditioned text generation, auxiliary tuning achieves results comparable to training from scratch while requiring significantly less time and money.

## Takeaways

- Use auxiliary tuning to adapt pre-trained language models to new conditional tasks without modifying their original weights.
- Combine logit outputs from separate fluency and attribute models to steer text generation effectively.
- Leverage feature extraction from existing models to accelerate training and reduce computational costs.

## Questions this talk answers

- How can I adapt a pre-trained language model for conditional text generation without retraining its weights?
- What is auxiliary tuning and how does it combine fluency models with attribute-specific models?
- How do logits from a pre-trained model and an auxiliary model combine mathematically during inference and training?

## Technologies

GPT-3, GPT-2, Transformers

## Tags

deep learning, language models, machine learning, nlp, text generation, transformers
