Elamur Research

Strong hallucinations from negation and how to fix them

Paper · 2024 · Nicholas Asher and Swarnadeep Bhar

Summary

A system can recognize each step of an argument and still give a conclusion that conflicts with those steps. The paper calls this kind of logical failure a strong hallucination. Its example comes from an entailment task, where the system correctly says that a hypothesis can be true given a premise and cannot be false given that premise. It then labels the relationship neutral, even though the instructions say that those answers establish entailment. The error can be identified from the premise, the instructions, and the response itself. It takes no additional research into the situation the sentences describe.

The authors trace the problem to a distinction between the probability of producing a string and the probability that the proposition it expresses is true. A system predicting text can reserve some probability for continuations other than a claim or its denial. An assignment of probabilities to propositions must give the claim and its denial all the probability between them, because they exhaust the possibilities. Likewise, different wordings of a logical truth must each express a proposition with probability 1, while different continuations compete for probability. The paper argues that this mismatch matters when the output probabilities of language models are used to decide what follows from a premise.

The proposed method, Λ, gets predictions for content without the relevant logical operator and applies a rule to handle what the operator changes. For a simple denial, the rule takes the complement of the probability assigned to the affirmative content. For inference with a negated premise, the procedure also needs to know the scope of negation, meaning which part of the premise it changes. A premise can deny that an action occurred while still identifying the person involved. Λ can preserve an inference supported by that identifying information. The logical adjustment is made at prediction time and can use base predictions from affirmative examples.

In synthetic yes-or-no questions, Λ matched the successful large systems and gave more consistent results with the smaller ones. In masked sentence completion, it produced 0 identical top answers across affirmative and negated prompts on each of the two evaluated datasets. On the revised entailment datasets, Llama2 7B with Λ achieved overall accuracies of 80% on ¬RTE and 72% on ¬SNLI, compared with 71% and .43, respectively, for direct Llama predictions. The reported comparison for ¬SNLI uses .43 on the table’s accuracy scale. The gains were strongest where the premise contained negation. The experiments also show where the method remains dependent on its input. A formally valid decision can carry forward a mistaken judgment about affirmative content, and the authors supplied scope distinctions for the inference data rather than training the system to find them.

Deep dive: Strong hallucinations from negation and how to fix them

Strong hallucinations from negation explains why language predictions can violate logic and how Λ improves sentence completion and inference. · about 36 minutes to read

The problem and its context

When the output contradicts its own reasoning

The paper opens with a distinction between getting the facts wrong and putting claims together in a way that cannot be right. An incorrect factual answer may be perfectly coherent among the possibilities the prompt leaves open. The answer fails because the world happens to be otherwise. A different failure occurs when an answer conflicts with the prompt and with commitments made elsewhere in the same response. A reader can identify that failure by examining how those commitments fit together. The authors investigate the latter kind of failure through reasoning.

Their motivating example is a relationship judgment about a girl riding a bicycle. The premise and hypothesis describe essentially the same activity, and the response treats them as equivalent. The prompt supplies a procedure for choosing a label. The system is to ask whether the hypothesis can be true when the premise is true and whether the hypothesis can be false when the premise is true. In the response, the system answers yes to the first question and no to the second. It then chooses neutral. Under the supplied procedure, those intermediate commitments lead to entailment.

The example is useful because it separates several skills that typically contribute to a single answer. The system must interpret each sentence, consider whether they can hold together, and use the answers to select a label. Its explanation makes it possible to inspect those steps separately. The final label conflicts with the answers the response has already given. Conversely, an explanation with an invalid step could happen to land on a correct label. An evaluation that records only the label misses that distinction.

The paper formalizes the issue in terms of degrees of belief. It treats a language system’s output in a given context as an affirmation selected using probabilities. Those probabilities can be compared with an idealized description of what it would be coherent to believe given the same evidence. The authors distinguish the objective distribution associated with the actual situation from objective distributions associated with other logically possible situations. A strong hallucination, in their definition, involves a substantial departure from what any such possible distribution could assign. Joint inconsistency between an output and its accepted evidence is a particularly clear case.

This framing gives negation a special role. If a claim and its denial are exact complements, there is no third possibility left over. One concerns the cases where the claim holds, and the other concerns all the cases where it fails. By contrast, an encoder filling a blank or a decoder continuing a passage generally has many other strings available. Producing a different sentence is always a possible event for the text generator, even when the proposition expressed by that sentence falls on one side of the original claim. The gap comes from which events the probabilities describe.

Why ordinary text prediction creates the mismatch

The architectural background is a Transformer and attention system trained to predict missing or subsequent tokens. A token contributes to later representations through operations shared across the input. Attention can give different tokens different weights, so an input containing a negative expression can produce a different representation from its affirmative counterpart. The architecture described in the paper nonetheless has no built-in requirement that the probabilities of a proposition and its denial add to 1. Learning to respond to a negative token and enforcing the probability rule for negation are separate achievements.

This distinction helps explain why the paper begins with what the output probabilities mean. In a masked prompt, several words can compete to fill the same blank. In a generated answer, different sentences and different paths through an explanation can compete to continue the same context. These are sensible competitions when the event of interest is the production of a particular string. Logical probability organizes events differently. Equivalent sentences pick out the same set of possibilities. A conjunction picks out the possibilities its components share. A sentence true by logic holds throughout the space of possibilities. These are distinctions about semantics.

The authors use the familiar example of a proposition and its denial to connect the distinction to the paper’s formal result. Suppose each is represented by a separate string and some probability remains for other strings. The two chosen strings receive less than the total between them. Taken as probabilities of uttering those strings, that is ordinary behavior. Taken as the probabilities of the propositions they express, it leaves probability for an impossible residual case. The same problem appears when several strings each express a logical truth. Each would require probability 1 on a propositional reading, yet a distribution over mutually exclusive text outputs cannot give that probability to every one of them.

An inference chain exposes another consequence of the distinction. If the premises entail a conclusion, the conclusion holds whenever those premises hold. The exact wording of a deductively valid conclusion can still have competing continuations. A system might state the conclusion with different words, supply an intermediate step, or go on to an unrelated statement. In the authors’ argument, equating the probability of one particular continuation with the probability of the conclusion puts the requirements of deduction and text selection in conflict.

What earlier work had tried

The paper places strong hallucinations alongside work on unfaithful generation. It discusses an existing category in which the generated content conflicts with its source. The authors sharpen the logical part of that problem by asking when a claim is incompatible with every admissible interpretation of the evidence. Their account therefore focuses on a structural cause. Work on causes such as imperfect training data or factual conflicts addresses other ways for an answer to go wrong. The paper also notes prior criticism of relying on larger systems and more data to solve hallucinations. Its formal argument concerns the role played by the output distribution, a question that remains after enlarging the training corpus.

More directly related studies examined whether predictions change appropriately when negation is introduced. The paper describes earlier difficulties on fill-in-the-blank knowledge probes and natural language inference benchmarks. It also describes a pragmatic approach by Gubelmann and Handschuh, which improved masked retrieval by attending to the contexts in which a negative utterance makes sense. Another study, by Jang and colleagues, trained an encoder on an intermediate binary judgment about whether a sentence describes a given word before evaluating negated prompts. Those approaches give the predictor additional help distinguishing relevant alternatives or recognizing negative content. The paper asks how to make the relationship between inputs and their negations explicit in the decision procedure itself.

The authors also situate Λ among systems that combine learned predictions with symbolic operations. They discuss work that adds logical gates to the architecture and work that translates a problem into a formal language for a prover. They also mention systems that generate symbolic rules as part of solving a problem. Λ takes learned judgments about ordinary language as inputs to calculations governing specific operators. The symbols supply the rules for combining judgments, while the underlying predictor supplies such information as plausible words for a blank or probable relations between affirmative clauses. This division matters because those lexical and conceptual judgments are part of what the authors want to retain.

The semantic machinery comes from earlier work on how sentences change a discourse representation. On that account, understanding a new sentence amounts to updating a structure that already contains objects and information about them. Negation constrains which extensions of that structure are compatible with the discourse. The paper adapts that idea to the possible continuations of a prompt. Its task is to connect a familiar semantic operation with predictions that were initially organized around strings, then determine where the connection can be tested with an observable output.

The method, step by step

Identify the content that the operator changes

The basic procedure begins by locating the scope of negation. Scope is the part of an expression whose interpretation the operator changes. If an input identifies a man by his blue shoes and says that he was awake, a version denying that he slept can still identify him by those shoes. A judgment about the footwear can survive the denial of sleeping. A system that complements the entire premise would handle those details together. Λ needs them apart when they contribute differently to the answer.

Once the relevant content has been isolated, the procedure asks the underlying system for the corresponding affirmative judgment. In a yes-or-no task, this can be the probability of yes given the affirmative context. In sentence completion, it is a collection of plausible words for an affirmative prompt and their scores. In natural language inference, it can be a set of directional entailment judgments concerning the original premise, the portion outside negation, and the portion under negation. The output to preserve and transform depends on what the task asks the system to predict.

The next step applies the logical relation that is available for the task. If yes and no describe exhaustive alternatives, the affirmative probability determines its complement. For a blank, the procedure scores the denial associated with each candidate separately and uses the resulting ordering. For inference labels, it uses rules that distinguish whether the hypothesis follows, conflicts with the premise, or remains open. Finally, the procedure returns the kind of output the task expects, such as a class label or a word.

How Λ applies negation to a prediction

The steps in order.

How Λ applies negation to a predictionStep 1: Identify the content under negation1. Identify the content under negationStep 2: Preserve information outside its scope2. Preserve information outside its scopeStep 3: Obtain predictions for the affirmative inputs3. Obtain predictions for the affirmative inputsStep 4: Apply probability complements or inference rules4. Apply probability complements or inference rulesStep 5: Select the answer in the task’s format5. Select the answer in the task’s format

Λ operates on quantities obtained from the predictor’s output. Its motivation concerns the meaning of the underlying representations, but the tests implement the correction through scores or relations that the predictor supplies. That is why the method can be applied to an encoder producing scores for classes as well as a decoder prompted for a textual judgment. The procedure can exploit affirmative judgments, including judgments from pretrained or fine-tuned systems. The authors’ claim about avoiding sparse negative training data concerns learning and applying this logical adjustment.

What the predictor computes

The paper starts with an attention expression to show how a token enters the representation used for a prediction. An attention head is one component that builds a weighted combination of token representations. In the paper’s notation, its contribution at a position is:

zⱼʰ = Σₖ₌₁ᴷ αⱼ,ₖʰ Wⱽʰ xₖ

Here zⱼʰ is the resulting representation at position j for head h. The summation sign Σ adds contributions indexed by k from 1 through K, where K is the number of input positions included. The term xₖ is the token representation at position k. The coefficient αⱼ,ₖʰ is the weight that head h gives to that position when building the representation at j. Wⱽʰ is the value matrix of the head, with V indicating the value transformation. Juxtaposition denotes the matrix operation followed by weighting. The equals sign identifies the representation with the resulting weighted sum.

In the background account, these contributions help form the context representation for the next prediction. The important point for Λ is that the same type of operation applies to material regardless of its linguistic role. There can be a strong learned signal associated with a negative token or a clause containing it. The weight itself says how the token contributes to a representation, while the complement law specifies a relation between the probabilities of propositions. The law is an additional requirement on how the output is interpreted and used.

For a decoder, a string receives its probability as a sequence of conditional predictions:

µ(s | C) = µ(w₁ | C) × µ(w₂ | C, w₁) × … × µ(wₘ₊₁ | C, w₁, …, wₘ)

The symbol µ is the distribution over strings or tokens. The string s consists of the successive tokens w₁ through wₘ₊₁, where w denotes a token and its subscript gives its position. The initial context is C, and m indexes the token immediately before the last one. The vertical bar means “given,” and commas on its right add conditions. The multiplication signs × combine the sequential factors. The ellipses stand for the intermediate factors and intervening tokens. This formula concerns the probability that the decoder produces that particular sequence following C.

The paper connects probabilities to an affirmation through a selection procedure. A system can select the highest-scoring candidate, move through a continuation greedily, search across candidate sequences, or sample. The authors’ basic definition treats the selected continuation as what the system affirms in that context. This step matters for interpretation. A probability mismatch can be present even when a particular decoding procedure never selects visibly contradictory outputs. The observable output is a consequence of both the probabilities and the way the system chooses among them.

Change the events to which the probabilities refer

The paper’s account of coherent probability starts with sets of possible situations. A sentence identifies the situations in which its content is true. Two logically equivalent sentences identify the same set, so they receive the same probability under a single coherent assignment. Which strings are likely to occur in a corpus is a separate question. One expression of an idea may be common and another unusual even though their truth conditions coincide.

The simplest form of the proposed adjustment is the complement rule:

Π′(¬ϕ) = 1 − Π(ϕ)

Here ϕ is the affirmative content and ¬ is the negation operator. Π denotes the input probability assignment, and Π′ denotes the assignment after applying the operator. The value 1 represents the whole space of possibilities, and the minus sign subtracts the probability of ϕ from that total. The equality defines the probability assigned to the denial through the probability of the affirmative content. The expression on the right is a quantity about truth or satisfaction as used by Λ, even when the quantity starts from a score obtained from text prediction.

The contrast underlying the authors’ first proposition can be stated with two separate formulas. When some mass goes to other strings in the predictor’s continuation space, the string probabilities satisfy:

µ(ϕ) + µ(¬ϕ) < 1

In this expression, µ is the normalized probability assignment over the possible output strings under consideration. The symbols ϕ and ¬ϕ denote the two strings selected to express a claim and its denial. The plus sign adds their probabilities. The less-than sign expresses that their combined weight falls below 1, the total weight shared among all outputs.

For the corresponding events in an objective probability distribution, the required relation is:

P(ϕ) + P(¬ϕ) = 1

Here P assigns probabilities to propositions. The two arguments refer to the possible situations where ϕ holds and to their complement. Addition combines probabilities of the disjoint events, and equality to 1 follows because together the events exhaust the possible situations. In this formula the written expressions name propositions, whereas in the preceding formula they identify particular strings.

The other part of the proposition considers logical truths and deductive steps. A proposition of the form denying a conjunction of a claim and its own denial is true by its structure. Many strings can express truths of this form. On the paper’s account, each such proposition receives probability 1. The corresponding strings cannot each receive probability 1 while competing as possible text outputs. Analogously, once a premise is taken as given, any proposition entailed by it holds with certainty. The exact string that expresses that proposition can still have alternative wordings and alternative positions in the response.

The authors extend this observation to longer reasoning chains. Their argument uses the sequential probability formula. If each next step has a conditional probability below 1, multiplying by that factor lowers the probability of the exact chain. A deduction viewed as a proposition remains certain relative to premises that entail it. The paper interprets the growing discrepancy as a reason to expect errors as a chain grows. Its example and this multiplication argument concern different levels of evidence, which matter when assessing how far the conclusion extends.

Represent updates as extensions of a context

To formalize Λ, the paper borrows a representation from dynamic semantics. A structure A is written as a pair:

A = (Uₐ, Pₐ)

A denotes the whole structure. The subscript a identifies the sets as belonging to A. Uₐ contains the objects represented in that structure, and Pₐ contains the properties or relations represented as holding of those objects. The parentheses and comma make the two sets an ordered pair. Objects and property descriptions are drawn from the information obtained by processing linguistic input.

This representation lets the authors say what it means for one piece of information to hold relative to another. They use an embedding, a mapping that preserves the relevant property assignments. An object in the first structure maps to an object in the second, and every represented relation among mapped objects must still hold there. Here an embedding is a property-preserving map between structures. Its job differs from that of a numeric token representation. If a context describes someone bearing certain properties, a successful mapping must preserve the combination, including which properties hold of the same person.

The dynamic definition of negation starts from an existing mapping for a discourse. If extending that mapping would satisfy the content under negation, the denial fails. The denial is satisfied when there is no such extension. The dependence on an existing map is important. A clause can deny a property of an already identified person. It can also deny that anyone satisfies a description. The two cases constrain different extensions, which helps explain why the linguistic form of a negative hypothesis matters for the inference data.

The authors apply this idea using continuations of the context. In the formal account, a continuation retains the context’s objects and asserted properties and can add more. A map that sends each already present object to itself preserves the original part. The probability assigned to the continuation is the probability of the proposed update given that context. It measures which continuation is favored. The preservation of already represented information follows from how the extension is defined.

The paper also defines a way to combine structures:

A + B = (Uₐ ∪ Uᵦ, Pₐ ∪ Pᵦ)

A and B are the structures being combined, and the plus sign denotes this structure operation. Uₐ and Uᵦ are their object sets, while Pₐ and Pᵦ are their sets of property assignments. The union symbol ∪ collects the elements of either set. The result has one combined object set and one combined set of properties. The pair notation has the same role as in the definition of a single structure.

Set the conditions for coherent continuations

The paper specifies several conditions that a continuation and its probability must satisfy. The first applies when the update adds a denial. If the corresponding affirmative update has probability α in the current context, the update with the denial receives its complement:

γ = 1 − α

Here α is the conditional probability of the affirmative content in the current context. The symbol γ is the conditional probability of the continuation that adds its denial. The value 1 is the probability of the total space, and subtraction leaves the part outside the affirmative event. The equality gives a condition for accepting the resulting assignment as coherent.

A further condition covers the reverse order of operations. Sometimes the evidence already includes a negated claim, and the desired continuation adds another piece of information. The relevant probability is then the probability of the added information conditional on the falsehood of the original affirmative claim. The appendix derives the expression for that update using event probabilities:

P(a | bᶜ) = P(a) × (1 − P(b | a)) / (1 − P(b))

Here a is the event corresponding to the added information and b is the event excluded by the negative context. The superscript c marks the complement bᶜ. P is a probability function and the vertical bar indicates conditioning. The numerator multiplies the probability of a by the probability that b fails given a. The slash divides by the probability that b fails. The calculation conditions on bᶜ when that event has positive probability. In the continuation rule, the events play the roles of the material supplied by the continuation and the affirmative material denied by the context.

This update accounts for the relation between the new material and the denied event. If the new material entails the denied event, it cannot hold under the negative condition. If the new material is compatible with the denial, the probability depends on how much of its original support survives within the remaining possibilities. The appendix derives this by partitioning a into its overlap with b and its overlap with the complement of b. Each part belongs to exactly one side of the partition. Conditioning retains the latter part and expresses its weight relative to the whole negative condition.

The remaining constraints concern the combination and recovery of information. If a continuation is certain given an earlier structure, then, relative to any context, the more detailed structure can be no more probable than the earlier information it includes. The extension imposes at least the commitments of the earlier structure. The paper also requires the probability of recovering the earlier structure together with a substructure of the continuation to be 1 when the full continuation is given. This captures the inference from a conjunction to information already included in it. Sequential conditioning supplies the way to add information, and this constraint supplies the way to take some of it back out.

The rules can apply recursively. When the continuation contains both a claim and its denial, their conjunction is inconsistent. Taking the negation of that conjunction gives a logical truth. The claimed probabilities follow from the meanings of the operators, whatever starting probability was assigned to the affirmative clause. The authors also represent a conditional by ruling out the combination of its antecedent with the denial of its consequent. That gives the following expression:

µ(Aϕ ⇒ Aψ | C) = 1 − µ(Aϕ | C) + µ(Aψ | Aϕ + C) × µ(Aϕ | C)

The symbols Aϕ and Aψ denote the representations of the antecedent ϕ and consequent ψ. The arrow ⇒ expresses the conditional. The symbol µ denotes the probability assignment used for continuations, C is the current context, and the vertical bar introduces the evidence. Within the conditional probability for Aψ, Aϕ + C is the structure combining the antecedent with the current context. On the right, subtracting the antecedent’s probability from 1 accounts for situations where the antecedent fails. The product accounts for situations where both antecedent and consequent hold. The outer plus sign adds those possibilities. This is the paper’s truth-conditional treatment of the construction.

From this treatment, the paper obtains the probability version of modus ponens. If the given context includes the conditional and its antecedent, the consequent has probability 1. Applied to the bicycle example, the premises of the rule are the response’s answers to the questions, and the consequence is the entailment label specified by the instructions. The rule can select that label once it receives those answers. It cannot establish by itself that the answers to the questions express sound judgments about the premise and hypothesis.

The appendix also connects the rules to general properties of coherent probability on propositions. A logically true sentence is assigned 1. If one sentence entails another, its probability is at most the probability of the consequence. For mutually inconsistent alternatives, the probability of their disjunction is the sum of their probabilities. For universal quantification, the account refers to the limit of the probabilities of conjunctions of instances as the instances are extended. The continuation semantics describes universal quantification in terms of extending each relevant embedding and existential quantification through an embedding that supplies a witness for a variable. The experiments implement the negation-focused parts of the account, while these extensions describe its formal setting.

Adapt the rules to each task

For synthetic question answering, the input combines a question with a short context, separated by the encoder’s special markers. The classification token summarizes the pair for predicting a response. The authors access the logits, the numerical scores before normalization, and apply a softmax to get probabilities over yes and no. Because this output space has exhaustive alternatives in the intended setup, a probability for yes in an affirmative context can be converted into the probability of no in that context. The same semantic relationship gives the probability of yes for the corresponding denial when the question is unchanged.

The affirmative input for masked retrieval is a sentence with one lexical item missing. A sentence-completion system commonly returns the highest-ranked candidate, but Λ needs a collection of plausible alternatives supplied by the affirmative input. The authors take the top 5 candidates. Each candidate defines a distinct filled-in affirmative proposition. Λ changes the score for each corresponding denial:

σᵢ ↦ 1 − pᵢ

The symbol σᵢ is the candidate at index i on the shortlist, and pᵢ is its score on the probability scale for the affirmative prompt. The mapping arrow ↦ means that this candidate is given the displayed score in the negative prompt. The subtraction takes the complement of its affirmative probability. This operation reverses the ordering of the candidates according to their original scores. Each complement concerns the denial of a different proposition, so the negative propositions can overlap in their truth conditions. The complement scores order the candidates for the blank without needing to sum to 1 as probabilities of distinct events.

The inference experiments use a premise C and a hypothesis h. The authors construct cases with an affirmative or negated premise paired with an affirmative or negated hypothesis. For premises with narrower scope, P represents the part retained outside negation and C′ represents the part negated. The predictor is asked for judgments over affirmative inputs, including the whole premise as evidence for the hypothesis, the surviving background as evidence for the hypothesis, and the hypothesis as evidence for the scoped part of the premise. Direction matters. Knowing what a premise entails can leave open what entails the premise.

The richer label set distinguishes entailment, contradiction, and neutrality. That distinction makes it possible to transform a judgment when only the hypothesis is negated:

(C, h): E / Cn / N ⇔ (C, ¬h): Cn / E / N

C denotes the premise, h the hypothesis, and ¬h its genuine contradictory. The parentheses enclose the ordered premise and hypothesis. The colon associates the pair with a label, and the slashes present corresponding alternatives in order. E is entailment, Cn is contradiction, and N is neutrality. The double arrow ⇔ expresses equivalence between each label on the left and the corresponding label on the right. The rule holds the premise fixed. If the premise forces the hypothesis to be true, it forces the denial to be false. If the premise leaves the truth of the hypothesis open, it leaves its denial open too.

For a negated premise, the procedure also checks what follows from the part outside the operator’s scope. If that part already entails the hypothesis, denying the scoped information can preserve the entailment in consistent cases. The rules for the richer label set work out the relation between the negated premise and the affirmative hypothesis first. They then apply the label transformation to obtain the relation to the negative hypothesis. In the binary task, the non-entailment class combines cases that behave differently under this transformation. The paper supplies rules that extract some of the consequences available from positive judgments and acknowledges a gap in this setup. For instance, from entailment of h one can infer non-entailment of its contradictory under an ordinary consistent premise, while a non-entailment label for h on its own leaves open the relation to ¬h.

Prepare data that actually express the intended contrasts

The synthetic question data use affirmative and negative versions of short facts. The templates ask about objects with a color property, including cars, balls, shirts, windows, and glasses. The color slot varies across the items. The corresponding question stays fixed while the context changes. The authors use pretraining and a question-answering fine-tuning regime involving CoQA to examine how encoder behavior changes. They also use the affirmative portion of SYN for the positive-context setup and derive the corresponding negative scores through Λ. This is a use of fine-tuning.

For retrieval, the authors take negated prompts adapted from LAMA and construct affirmative counterparts. This supplies the affirmative probability scores required by Λ and allows comparisons for the same missing word position across polarity. The baseline systems can instead process both versions directly. CoQA fine-tuning supplies a comparison with an intervention that changes learned representations through training, while Λ uses its explicit transformation at prediction time.

For inference, simply deleting a negative expression would leave some original labels and references ambiguous. The authors reconstruct affirmative examples from negation adaptations of RTE and SNLI. They also correct examples where a supposedly contradictory hypothesis introduces an indefinite description that can refer to someone else. If the premise describes a tattooed woman fastening a bicycle to a post, an indefinite negative hypothesis can describe a different tattooed woman. The authors either revise the label, use a definite description to pick out the woman already introduced, or use a negative noun phrase that rules out anyone satisfying the description. Each choice is tied to the intended semantic relationship.

The annotations also identify information that projects outside the scope of negation, including material carried by some definite descriptions and adverbial clauses. The annotators use these divisions to add judgments for pieces of the premise as well as for the complete sentences. The paper makes its revised inference datasets available with the experimental prompts. In the reported inference runs, Llama2 7B supplies affirmative judgments through prompting. The logical rules then use those judgments as their inputs. The authors also run the rules with human-assigned labels to examine what happens when the base judgments are already given.

Experiments and results

Yes-or-no questions on SYN

The synthetic experiment asks whether a short context supports a yes-or-no answer about a fact directly described in it. In a typical item, the question asks about a car of a particular color. The affirmative and negative contexts differ in whether they say such a car was present. With the question held fixed, the paired contexts make it possible to measure how much the encoder’s representation changes and whether the classifier’s answer changes appropriately.

For the representation comparison, the paper examines the classification token in BERT-base and BERT-large. It uses cosine similarity, a measure of the alignment between two vectors, for affirmative and corresponding negative context pairs. The pretrained representations have reported similarities between .986 and 1. After CoQA question-answering fine-tuning, the similarities move lower. The authors report that BERT-large values for this comparison lie between 0,34 and 0,38. The histograms show that training for the task changes how strongly the representation separates the paired inputs.

The behavioral comparison uses fine-tuned BERT and RoBERTa. The large variants answer the synthetic questions correctly throughout the reported experiment. The small variants predominantly answer no. Λ matches the large systems’ results and is described as giving the most consistent answers with the smaller ones. The paper gives these outcomes qualitatively rather than reporting a full set of per-variant accuracy values. The experiment supplies evidence about a setting with a fixed, exhaustive answer space and closely paired contexts.

The authors connect the large systems’ direct success to the binary decision. For a question with only yes and no as meaningful answers, the classifier already chooses between alternatives that can approximate a proposition and its denial. Λ makes the relation explicit. This helps explain why the synthetic task can be solved even though the same fine-tuning does not remove the repeated answers observed in the larger candidate space of masked retrieval.

Masked knowledge retrieval on KS and JS

The retrieval study uses two adaptations of LAMA with negated prompts. KS, from Kassner and Schütze, contributes 51 examples. JS, from Jang and colleagues, contributes 2926. For each prompt pair, an exact match means that the same word is selected as the top completion for the affirmative and negative versions. It measures agreement between the system’s own answers under the contrast. An exact match here is a count of repeated answers, so fewer is better.

With pretraining alone, RoBERTa-large repeats its top answer on 32/51 KS pairs and 1038/2926 JS pairs. BERT-large does so on 30/51 KS pairs and 970/2926 JS pairs. After CoQA fine-tuning, RoBERTa-large records 10/51 on KS and 743/2926 on JS. The corresponding BERT-large counts are 17/51 and 814/2926. The change appears with both encoders on both collections, and repeated answers remain after fine-tuning.

Repeated top completions on JS by encoder and method

CoQA fine-tuning reduces repeated answers, and Λ removes them for both encoders.

Repeated top completions on JS by encoder and methodRoBERTa-large pretrained: 1038RoBERTa-large pretrained1038RoBERTa-large CoQA fine-tuned: 743RoBERTa-large CoQA fine-tuned743RoBERTa-large with Λ (this paper): 0RoBERTa-large with Λ (this paper)0BERT-large pretrained: 970BERT-large pretrained970BERT-large CoQA fine-tuned: 814BERT-large CoQA fine-tuned814BERT-large with Λ: 0BERT-large with Λ0
The numbers
System or settingexact-match count
RoBERTa-large pretrained1038
RoBERTa-large CoQA fine-tuned743
RoBERTa-large with Λ (this paper)0
BERT-large pretrained970
BERT-large CoQA fine-tuned814
BERT-large with Λ0

Λ reports 0 exact matches on KS as well as JS with each encoder. The authors separately count nonmeaningful completions for Λ. On KS they report 0 for both RoBERTa-large and BERT-large. On JS they report 6 for RoBERTa-large and 162 for BERT-large. These counts have different meanings from the denominators quoted for the baselines. The baseline denominators are the numbers of examples. The paper’s paired figures for Λ give the repeat count and the count of defective completions.

An example concerns the place where a teacher would most likely be teaching. A baseline predicts school whether the sentence asserts or denies that the location is the most likely one. The Λ example keeps school as the affirmative prediction and selects hospital for the negative prompt. Hospital is drawn from alternatives the affirmative predictor already entertained. The example illustrates how the shortlist can maintain a plausible type of answer, while the separate count of defective completions shows what can happen when the affirmative shortlist does not supply an appropriate low-ranked candidate.

This experiment therefore records the success of a particular polarity test and a separate measure of completion quality. A system can produce a different word without producing a well-formed or informative sentence. The fit of the candidate to the context depends on the original lexical choices, and the probability transformation addresses how the candidate is ranked after negation.

Natural language inference on revised ¬RTE and ¬SNLI

The inference results use revised data from RTE and SNLI that had previously been adapted for negation. ¬RTE uses entailment and non-entailment. ¬SNLI distinguishes entailment, contradiction, and neutrality. The paper gives 41% of ¬RTE as the share associated with its reconstruction of affirmative examples. For the ¬SNLI analysis, the authors complete 117 examples with the full set of premise and hypothesis polarity configurations. The supplementary datasets contain 2306 annotated inferences, including judgments added to handle material inside and outside negation’s scope.

Accuracy is the proportion of inference labels that agree with the annotations. The paper reports results for Λ supplied with gold judgments, meaning labels assigned as part of the dataset preparation. For ¬RTE it also runs a basic version assuming that negation takes scope over the whole premise. In the operational comparison, one setting asks Llama2 7B for labels on the target configurations directly. The other uses Llama’s predictions on the affirmative inputs and lets Λ derive the labels for cases involving negation. The paper’s full score aggregates across the available polarity configurations.

Overall label accuracy on revised ¬RTE

With gold inputs, scoped Λ gives the highest accuracy, and Λ also improves on direct prompting with predicted inputs.

Overall label accuracy on revised ¬RTEDirect Llama prompting: .71Direct Llama prompting.71Llama with Λ: .8Llama with Λ.8Basic Λ with gold inputs: .85Basic Λ with gold inputs.85Scoped Λ with gold inputs (this paper): .94Scoped Λ with gold inputs (this paper).94
The numbers
System or settingaccuracy
Direct Llama prompting.71
Llama with Λ.8
Basic Λ with gold inputs.85
Scoped Λ with gold inputs (this paper).94

For the affirmative inputs on revised ¬RTE, the prose reports 73% accuracy for the full premise and hypothesis, 76% for the preserved material as evidence for the hypothesis, and 83% for the reverse judgment it identifies as (h, C). The scope procedure also uses the reverse judgment involving the scoped component C′. The reported overall accuracy is 80% for Llama with Λ and 71% for Llama alone. With a negative premise and affirmative hypothesis, the table gives .76 with Λ and .63 for direct prompting. With both negated, it gives .76 and .70, respectively. When only the hypothesis is negated, it records .89 with Λ and .76 without it.

The revised ¬SNLI results show a different profile. On the affirmative judgments used by the procedure, the authors find prompts that give 78% accuracy on the premise and hypothesis, 69% on the retained material and hypothesis, and 70% on the hypothesis and scoped material in the reverse direction. Llama with Λ attains 72% overall in the paper’s prose, corresponding to .72 in the results table. Direct prompting scores .43 overall. In cases with the premise negated, direct prompting scores .12 for an affirmative hypothesis and .11 for a negated one. With Λ, the score for each of those configurations is .67. With negation restricted to the hypothesis, the scores are .77 with Λ and .71 for the direct system.

Overall label accuracy on revised ¬SNLI

Applying Λ to predicted inputs improves overall accuracy, and gold inputs give the highest score.

Overall label accuracy on revised ¬SNLIDirect Llama prompting: .43Direct Llama prompting.43Llama with Λ: .72Llama with Λ.72Scoped Λ with gold inputs (this paper): .96Scoped Λ with gold inputs (this paper).96
The numbers
System or settingaccuracy
Direct Llama prompting.43
Llama with Λ.72
Scoped Λ with gold inputs (this paper).96

The gold-input scores show what the rules do with the required judgments available in the annotations. On revised ¬SNLI, the table reports .96 overall and records .96 with only the hypothesis negated, .97 with only the premise negated, and .95 with both negated. These scores describe a diagnostic setting. For applications without the corresponding annotations, the relevant hybrid result is the one using affirmative judgments predicted by Llama.

The authors also try prompts that elicit reasoning about the possible truth and falsehood of the hypothesis. They report that the format that worked best for their comparison asked the system to answer those questions and use them to choose a label. Longer prompts worked better for the whole premise and hypothesis, while shorter prompts worked better for the component judgments. The paper reports that about 12% of the generated reasoning chains in this analysis were incorrect in a way Λ could repair. Repair did not raise the label scores. The authors therefore used Llama’s predicted labels for the affirmative judgments in the main hybrid runs. The distinction between repairing an inference and improving its conclusion explains why these results are reported separately.

What the ablations show

Scope changes which entailments survive

The clearest component comparison is the gold-input experiment on revised ¬RTE. The basic algorithm assumes whole-premise negation, while the scoped algorithm can preserve material outside the operator. The table gives .85 overall for the basic version and .94 for the scoped version. Since the necessary labels are supplied, this comparison isolates what the assumptions about scope change more directly than the comparison between prompted Llama and the hybrid.

The result by configuration helps locate the effect. With only the hypothesis negated, each procedure scores .89. The contrast concerns the treatment of the premise, which has stayed affirmative in this case. With only the premise negated, the score is .76 for the basic version and .96 for the scoped version. When both premise and hypothesis are negated, the figures are .91 and .98. That pattern is consistent with preserving information that the negation leaves in force. The scoped procedure can still draw a conclusion from that material even when a different proposition in the premise has been denied.

The gold-input comparison also helps explain the residual difficulty with hypothesis negation on ¬RTE. The binary labels collapse neutral and contradictory cases into non-entailment. If the affirmative hypothesis is already contradictory to the premise, its denial follows. If the affirmative hypothesis is merely compatible with the premise, denying it may leave the relation neutral. The same input label can therefore conceal different logical relations. A more precise account of which part of the premise is negated cannot fill in that missing information when the premise is left unchanged.

The source of the input judgments matters

Supplying gold labels tests what Λ can derive under the annotated decomposition. Supplying predicted labels adds errors from the affirmative reasoning task. The two settings differ substantially even though the logical rules are the same. On ¬RTE, the scoped rule set gives .94 overall with gold input and .8 with Llama input. On ¬SNLI, the figures are .96 and .72. These comparisons locate part of the remaining error upstream of the logical operations. A coherent inference from a mistaken entailment, contradiction, or neutrality judgment can yield a wrong answer.

The reasoning-chain analysis offers an example of the same dependency at the level of an explanation. A response can give answers to the auxiliary questions that select one label under the stated rule and then output a different label. Correcting the last step makes the explanation and label consistent with the intermediate answers. Whether that label matches the annotation depends on whether the answers themselves were correct. In the reported prompts, fixing the derivation did not improve aggregate label accuracy. The consequence concerns this intervention on the generated chains. The larger gains in the main comparison come from constructing answers for negated inputs using predictions obtained on the corresponding affirmative material.

Fine-tuning changes sensitivity before the rules change the decision

The SYN representations and the retrieval baselines supply another controlled comparison. In SYN, paired classification representations become less similar after CoQA fine-tuning. This gives evidence that the encoder learned to respond differently to positive and negative contexts under a question-answering objective. The fine-tuned large systems’ success shows that this distinction can support a simple binary answer.

In masked retrieval, CoQA fine-tuning also reduces the frequency of repeated answers. Its effect is incomplete for both encoders. A retrieval prompt makes the system choose among words, each of which expresses a different proposition when placed in the sentence. Learning to classify a paired question and context does not impose a complement relationship among those distinct filled-in propositions. Applying the score transformation changes the ranking directly, which accounts for the disappearance of identical top choices in the tested prompt pairs.

The alternative-completion analysis adds a further distinction. With identical ranking rules, the observed number of nonmeaningful JS outputs still varies by encoder. This is consistent with Λ depending on which affirmative alternatives each encoder proposes. The result is informative about the role of candidate quality, although the paper does not vary the shortlist size to identify which part of the remaining error comes from the chosen cutoff. The experiment controls the scoring operation while changing the source of its candidates.

Limitations

Limits the authors identify

The authors restrict the main experiments to outputs that are straightforward to evaluate. A yes-or-no answer, a word for a blank, and a relation label each give a defined comparison target. The paper includes an example and a small analysis of longer generated reasoning in the inference task. The authors describe full text generation as a setting they have yet to investigate deeply. They also report difficulty eliciting reasoning chains and explanations from Llama reliably. As a result, the principal empirical results describe constrained outputs even though the formal motivation concerns general text prediction.

Scope is an explicit source of remaining error. The authors did not train the systems to locate logical operator scope for the inference experiments. They use linguistically informed annotations of what the denial applies to and what remains available as background information. Their procedure also leaves the scope of the hypothesis untreated in the reported scoped algorithms. The authors say that their treatment falls short of capturing interactions among several logical operators. A system deployed on arbitrary inputs would need to determine whether a negative expression scopes over a whole clause, a predicate, or some more local part, and it would need to keep track of those relations when there is more than one operator.

The authors report that affirmative inference was itself unstable under prompting. Changing the format or length of the prompt affected the predictions used by Λ. They did not fine-tune Llama for the reported NLI task and identify NLI fine-tuning, training for scope, and a more varied dataset as future work. Their preliminary point about plausible logical forms concerns an indication that scope prediction may be feasible. It is separate from the results obtained with the annotated scope distinctions.

The paper also distinguishes a logically admissible output from a pragmatically appropriate one. In an ordinary negative utterance, speakers usually have particular alternatives in mind. A filled-in sentence can be coherent and grammatical yet offer an irrelevant or uninformative denial. The paper’s shortlist uses the affirmative predictor to supply alternatives, and the logical calculation reorders them. The authors describe learning additional pragmatic constraints as future work. The current complement transformation supplies the polarity relation while leaving relevance to the candidate choices and the surrounding procedure.

Limits visible in the formal argument and evaluation

The mismatch in the first proposition is a result about interpreting string scores as proposition probabilities. It applies when the relevant strings are assigned probabilities in a common continuation space and other strings receive some of the mass. The result establishes a departure from the exact complement law. The definition of strong hallucination also uses the idea of a significant divergence. The presence of positive mass elsewhere establishes a strict inequality but gives no general size for the gap. Likewise, demonstrating incoherence at the distribution level leaves a further question about which output a particular selection procedure will produce. The authors themselves illustrate this separation in their discussion of betting, where a distribution can fail a coherence test without visibly affirming both members of a contradiction.

There is also a gap between the product argument for reasoning chains and a guarantee of a wrong next step. Every factor below 1 makes the probability of an exact extended string smaller. That observation alone leaves the relative probabilities of competing next steps undetermined. Valid next steps could remain favored at every position while the probability of any single complete chain still falls. The paper’s argument provides a reason to distinguish the probability of a deduction from the probability of a verbatim derivation. Its claim of eventual substantive error requires an additional premise about how the probabilities of valid and invalid continuations behave.

The binary entailment case needs a related distinction between an entailment judgment and the probability that the embedded proposition is true. The paper states a complement expression for entailment scores when the hypothesis is negated. If those scores are interpreted literally as probabilities that the entailment label applies, ordinary non-entailment of h does not entail ¬h. A premise can leave h and its denial both open. The complement law is exact for a proposition and its denial, and the three-label mapping explicitly preserves neutral cases. For binary labels, the paper’s acknowledgment that its procedure cannot recover some entailments of negative hypotheses is important when interpreting the formula and the reported accuracy.

In retrieval, 0 exact matches primarily demonstrates that the procedure delivers the polarity contrast it was designed to enforce. Reversing the scores on a shared shortlist favors a different end of the list for the negative prompt. The test cannot by itself establish that the negative completion refers to a relevant alternative, that its sentence is true, or that the same approach would work when a suitable word is absent from the shortlist. The separate counts of nonmeaningful completions provide some evidence about usability on the evaluated prompts. They leave open the stronger question of whether the outputs are factually and pragmatically appropriate in a broader set of contexts.

The inference benchmarks give the authors close control over scope and reference, which is helpful for testing deductions. Their corrected and annotated examples consequently test the procedure under those particular semantic distinctions. The gold-input scores depend on access to labeled judgments about the components. The prompted scores depend on whether the same affirmative relationships can be recovered without those labels. Neither setting measures end-to-end performance on unannotated text where the location and scope of negation, the identity of the entities, and the relevant inferential relation must all be discovered together.

Finally, the advantage of using affirmative data describes what Λ requires for its logical operation. The encoder experiments also use pretrained systems and, in some settings, CoQA fine-tuning. The paper does not establish that those earlier training corpora lack negative language. Its result is that the proposed transformation can be supplied with affirmative task judgments and used to derive outputs for negated cases, avoiding a separate requirement to learn that transformation from paired negative training examples.

What came after

No subsequent studies are identified for this paper. The authors leave several directions open, including learning to determine scope, improving the affirmative judgments that feed Λ, and extending the method to longer reasoning chains. They also propose using learned pragmatic constraints to choose among logically admissible continuations. These are proposed extensions of the reported work. The experiments here establish how the procedure behaves when scopes and contrasts have been made explicit and the output can be checked as a short answer, a completion, or an inference label.

Cite

Cite as Nicholas Asher and Swarnadeep Bhar. 2024. Strong hallucinations from negation and how to fix them. Findings of the Association for Computational Linguistics: ACL 2024.

The paper itself, not this page. BibTeX from the library's record of the work. DOI 10.18653/v1/2024.findings-acl.752

@inproceedings{asher2024strong,
  title = {{Strong hallucinations from negation and how to fix them}},
  author = {Nicholas Asher and Swarnadeep Bhar},
  booktitle = {Findings of the Association for Computational Linguistics: ACL 2024},
  year = {2024},
  doi = {10.18653/v1/2024.findings-acl.752},
  url = {https://doi.org/10.18653/v1/2024.findings-acl.752}
}

↑ back to top

This page in Markdown https://md.research.elamur.ai/free/en/papers/asher-2024-strong-hallucinations-negation-how-fix/