Understanding Finetuning for Factual Knowledge Extraction from Language
Models
- URL: http://arxiv.org/abs/2301.11293v1
- Date: Thu, 26 Jan 2023 18:29:50 GMT
- Title: Understanding Finetuning for Factual Knowledge Extraction from Language
Models
- Abstract summary: Language models (LMs) pretrained on large corpora of text from the web have been observed to contain large amounts of various types of knowledge about the world.
We show that finetuning LMs on a set of factual knowledge makes them produce better answers to queries from a different set, thus making finetuned LMs a good candidate for knowledge extraction.
We then consider two solutions to remedy the identified negative effect: 1- model mixing and 2- mixture finetuning with the LM's pre-training task.
- Score: 1.7969777786551426
- License: http://creativecommons.org/licenses/by/4.0/
- Abstract: Language models (LMs) pretrained on large corpora of text from the web have
been observed to contain large amounts of various types of knowledge about the
world. This observation has led to a new and exciting paradigm in knowledge
graph construction where, instead of manual curation or text mining, one
extracts knowledge from the parameters of an LM. Recently, it has been shown
that finetuning LMs on a set of factual knowledge makes them produce better
answers to queries from a different set, thus making finetuned LMs a good
candidate for knowledge extraction and, consequently, knowledge graph
construction. In this paper, we analyze finetuned LMs for factual knowledge
extraction. We show that along with its previously known positive effects,
finetuning also leads to a (potentially harmful) phenomenon which we call
Frequency Shock, where at the test time the model over-predicts rare entities
that appear in the training set and under-predicts common entities that do not
appear in the training set enough times. We show that Frequency Shock leads to
a degradation in the predictions of the model and beyond a point, the harm from
Frequency Shock can even outweigh the positive effects of finetuning, making
finetuning harmful overall. We then consider two solutions to remedy the
identified negative effect: 1- model mixing and 2- mixture finetuning with the
LM's pre-training task. The two solutions combined lead to significant
improvements compared to vanilla finetuning.
Related papers
- Narrow Finetuning Leaves Clearly Readable Traces in Activation Differences [16.09906989518837]
We show that narrow finetuning creates strong biases in LLM activations that can be interpreted to understand the finetuning domain.<n>These biases can be discovered using simple tools from model diffing.<n>We demonstrate that these analyses contain crucial information by creating an LLM-based interpretability agent.
arXiv Detail & Related papers (2025-10-14T19:05:59Z) - How Much Knowledge Can You Pack into a LoRA Adapter without Harming LLM? [55.33467849079774]
Low-rank adaptation (LoRA) is a popular and efficient training technique for updating or domain-specific adaptation of Large Language Models.
We investigate how new facts can be incorporated into the LLM using LoRA without compromising the previously learned knowledge.
arXiv Detail & Related papers (2025-02-20T12:31:03Z) - Gradual Learning: Optimizing Fine-Tuning with Partially Mastered Knowledge in Large Language Models [51.20499954955646]
Large language models (LLMs) acquire vast amounts of knowledge from extensive text corpora during the pretraining phase.
In later stages such as fine-tuning and inference, the model may encounter knowledge not covered in the initial training.
We propose a two-stage fine-tuning strategy to improve the model's overall test accuracy and knowledge retention.
arXiv Detail & Related papers (2024-10-08T08:35:16Z) - Understanding Finetuning for Factual Knowledge Extraction [45.398982602347765]
We show that fine-tuning on lesser-known facts that are poorly stored during pretraining yields significantly worse factuality than fine-tuning on well-known facts, even when all facts are seen during pretraining.
Our results shed light on the interaction between pretrained knowledge and finetuning data and demonstrate the importance of taking into account how facts are stored in the pretrained model when fine-tuning for knowledge-intensive tasks.
arXiv Detail & Related papers (2024-06-20T23:27:06Z) - Multiple Descents in Unsupervised Learning: The Role of Noise, Domain Shift and Anomalies [14.399035468023161]
We study the presence of double descent in unsupervised learning, an area that has received little attention and is not yet fully understood.
We use synthetic and real data and identify model-wise, epoch-wise, and sample-wise double descent for various applications.
arXiv Detail & Related papers (2024-06-17T16:24:23Z) - Unfamiliar Finetuning Examples Control How Language Models Hallucinate [75.03210107477157]
Large language models are known to hallucinate when faced with unfamiliar queries.
We find that unfamiliar examples in the models' finetuning data are crucial in shaping these errors.
Our work further investigates RL finetuning strategies for improving the factuality of long-form model generations.
arXiv Detail & Related papers (2024-03-08T18:28:13Z) - An Emulator for Fine-Tuning Large Language Models using Small Language
Models [91.02498576056057]
We introduce emulated fine-tuning (EFT), a principled and practical method for sampling from a distribution that approximates the result of pre-training and fine-tuning at different scales.
We show that EFT enables test-time adjustment of competing behavioral traits like helpfulness and harmlessness without additional training.
Finally, a special case of emulated fine-tuning, which we call LM up-scaling, avoids resource-intensive fine-tuning of large pre-trained models by ensembling them with small fine-tuned models.
arXiv Detail & Related papers (2023-10-19T17:57:16Z) - An Empirical Study of Catastrophic Forgetting in Large Language Models During Continual Fine-tuning [70.48605869773814]
Catastrophic forgetting (CF) is a phenomenon that occurs in machine learning when a model forgets previously learned information while acquiring new knowledge.
This study empirically evaluates the forgetting phenomenon in large language models (LLMs) during continual instruction tuning.
arXiv Detail & Related papers (2023-08-17T02:53:23Z) - Can LMs Learn New Entities from Descriptions? Challenges in Propagating
Injected Knowledge [72.63368052592004]
We study LMs' abilities to make inferences based on injected facts (or propagate those facts)
We find that existing methods for updating knowledge show little propagation of injected knowledge.
Yet, prepending entity definitions in an LM's context improves performance across all settings.
arXiv Detail & Related papers (2023-05-02T17:59:46Z) - Large Language Models with Controllable Working Memory [64.71038763708161]
Large language models (LLMs) have led to a series of breakthroughs in natural language processing (NLP)
What further sets these models apart is the massive amounts of world knowledge they internalize during pretraining.
How the model's world knowledge interacts with the factual information presented in the context remains under explored.
arXiv Detail & Related papers (2022-11-09T18:58:29Z) - On the Interplay Between Fine-tuning and Sentence-level Probing for
Linguistic Knowledge in Pre-trained Transformers [24.858283637038422]
We study three different pre-trained models: BERT, RoBERTa, and ALBERT.
We find that for some probing tasks fine-tuning leads to substantial changes in accuracy.
While fine-tuning indeed changes the representations of a pre-trained model, only in very few cases, fine-tuning has a positive effect on probing accuracy.
arXiv Detail & Related papers (2020-10-06T10:54:00Z)
This list is automatically generated from the titles and abstracts of the papers in this site.
This site does not guarantee the quality of this site (including all information) and is not responsible for any consequences.