Order-Independence Without Fine Tuning

The development of generative language models that can create long and coherent textual outputs via autoregression has lead to a proliferation of uses and a corresponding sweep of analyses as researches work to determine the limitations of this new paradigm. Unlike humans, these 'Large Language Models' (LLMs) are highly sensitive to small changes in their inputs, leading to unwanted inconsistency in their behavior. One problematic inconsistency when LLMs are used to answer multiple-choice questions or analyze multiple inputs is order dependency: the output of an LLM can (and often does) change significantly when sub-sequences are swapped, despite both orderings being semantically identical. In this paper we present Set-Based Prompting, a technique that guarantees the output of an LLM will not have order dependence on a specified set of sub-sequences. We show that this method provably eliminates order dependency, and that it can be applied to any transformer-based LLM to enable text generation that is unaffected by re-orderings. Delving into the implications of our method, we show that, despite our inputs being out of distribution, the impact on expected accuracy is small, where the expectation is over the order of uniformly chosen shuffling of the candidate responses, and usually significantly less in practice. Thus, Set-Based Prompting can be used as a 'dropped-in' method on fully trained models. Finally, we discuss how our method's success suggests that other strong guarantees can be obtained on LLM performance via modifying the input representations.

Paper

Similar papers

Peer review

Reviewer CaKN5/10 · confidence 4/52024-07-12

Summary

State-of-the-art language models (LMs) are now used to perform tasks (such as, e.g., question answering) with no fine-tuning; these models are fed the question and target options in their context, and their next-token distribution is then used to select an answer from this set of options. LM outputs, however, are known to vary significantly based on the order in which these options are fed to it. This paper proposes set-based prompting, a method to make LMs invariant to such option reorderings. In short, the method feeds all options to a transformer model “in parallel” by modifying their position indexes to start from the same value, and by masking the attention so that options cannot attend to each other. In practice, this makes the model run slightly out of distribution, as tokens presented to the model after the QA options will be able to attend to multiple tokens with the exact same position (as the multiple options are assigned this equivalent position indexes). The paper has experiments on two tasks, question answering and language understanding.

Strengths

The paper presents a simple solution to a well known problem in NLP. The paper runs experiments with a reasonable number of language model families: gpt-2, llama2, llama3, and mistral.

Weaknesses

In my opinion, this paper presents what is a relatively simple solution as being more complex than it is. (To be clear, I think this simplicity is one of the solution’s positive aspects, and not a negative aspect. Its presentation, however, could be considerably simpler.) Further, the proof of order invariance is sold as an important contribution, but it is also relatively straightforward. Since the methodological/theoretical contributions of this paper are relatively minor, though, I would expect it to have more experiments to confirm its efficacy. The paper, however, only presents two experiments, which are not very comprehensive in assessing the method's performance. More details below. * The paper’s contribution is a simple (yet potentially efficient) method to make LMs invariant to prompt ordering. This solution amounts to reindexing token positions and slightly changing the model’s attention mask. However, the paper takes almost 6 pages to present this relatively simple solution. * The paper only runs experiments on two tasks, and with one dataset each. This is not a comprehensive evaluation. The paper could run experiments with other tasks. Specifically, analysing the performance of this method on long-context information retrieval, as in Liu et al. (2024) could be interesting. * In-context learning is another important setting in which models are susceptible to input order variation. However, the paper only focuses its experiments on zero-shot experiments. Liu et al. (2024). Lost in the middle: How language models use long contexts ------------ Edit after author responses: I thank the authors for their response, and apologise for only replying to it after the discussion deadline. While I still think that some aspects of the paper could be significantly improved, e.g., simplifying the presentation, the newly added experiments make the paper's evaluation much more comprehensible, so I am raising my scores (from 3 to 5). The experiments showing the performance degradation on the long-context experiment are quite interesting (even if they present negative results), and experiments with ICL show another important setting for which this method can be useful.

Questions

I don't have any specific questions. But as a suggestion, I think the stacked box plots in Figs 3 and 5 are quite hard to read. It would likely be easier to read them if the different conditions were presented as separate bars.

Rating

5

Confidence

4

Soundness

3

Presentation

1

Contribution

1

Limitations

The authors mention that their solution will make models run slightly out of distribution. Expanding on this point could be interesting, maybe discussing possible ways to mitigate this issue, such as fine-tuning models.

Reviewer gPKU9/10 · confidence 4/52024-07-12

Summary

The paper addresses the problem of order dependency in Large Language Models (LLMs), which causes inconsistency in outputs when the order of semantically identical sub-sequences is changed. The authors propose a technique that eliminates order dependency in transformer-based LLMs. The method is both theoretically sound and experimentally validated, showing minimal impact on accuracy despite the inputs being out of distribution. The technique can be seamlessly integrated into fully trained models. The paper also explores the potential of enhancing LLMs by incorporating metadata information similar to positional encoding.

Strengths

- The proposed method elegantly and effectively addresses the order dependency issue in LLMs with only a minor performance drop. - The method is supported by thorough experimental evaluation and theoretical guarantees, adding to its credibility. - The paper is well-written, clearly explaining the methodology and its implications. - Section 5.2 introduces an innovative idea of improving LLMs by using metadata information in a manner akin to positional encoding, which opens up exciting new avenues for research.

Weaknesses

The review does not identify any significant weaknesses in the paper. However, there are a few points of clarification needed, as outlined in the Questions section.

Questions

- What is the impact of not enumerating the candidate answers (e.g., using A, B, C, D) versus simply using “”? This aspect does not appear to be addressed in the main text. - Regarding Figure 3, the proposed method seems to perform better than the worst-case scenario. However, if the goal is to achieve the highest score, it appears that the order-dependent method might still be preferable. Can the authors elaborate on this? - Why do the results differ in llama3? A more detailed explanation would help clarify this variation. This paper presents a significant advancement in addressing order dependency in LLMs. The method is both theoretically and experimentally robust, providing a practical solution with minimal performance trade-offs. The clear writing and innovative approach, particularly in Section 5.2, add to the paper’s strengths. Addressing the questions and clarifying the identified points would further enhance the paper. Overall, this work is a valuable contribution to the field and is strongly recommended for acceptance. [edit: I increase my rating to Very Strong Accept, see my comment on author's rebuttal for justification]

Rating

9

Confidence

4

Soundness

4

Presentation

4

Contribution

4

Limitations

Limitations are adressed in the paper

Reviewer bKgM5/10 · confidence 4/52024-07-16

Summary

The paper aims to address an issue within large language models (LLMs): their sensitivity to the order of input sequences, known as order dependency. This problem causes LLMs to produce inconsistent outputs when the order of semantically identical inputs is changed. ### Key Contributions: 1. **Set-Based Prompting Technique**: The authors propose a novel technique called Set-Based Prompting, which ensures that the output of an LLM is invariant to the order of a specified set of sub-sequences. This method modifies the input representation by removing the order information from the inputs. 2. **Theoretical Guarantees**: The paper provides theoretical proofs demonstrating that Set-Based Prompting eliminates order dependency for any transformer-based LLM. 3. **Empirical Evaluation**: The authors test their method on multiple LLMs, including GPT-2, Llama 2, Llama 3, and Mistral, using tasks like multiple-choice questions from the CommonSenseQA and MMLU datasets. They show that while Set-Based Prompting can slightly impact performance, it generally maintains accuracy within acceptable bounds and eliminates the variation caused by different orderings. ------------------------------------------------------------------------ Thank you for your replies and I raised my score accordingly.

Strengths

### Strengths - **Theoretical Rigor**: The paper includes rigorous theoretical proofs that validate the effectiveness of Set-Based Prompting in eliminating order dependency. - **Empirical Validation**: The extensive empirical evaluation on multiple models (GPT-2, Llama 2, Llama 3, and Mistral) on two datasets (CommonSenseQA and MMLU) demonstrates the robustness and applicability of the method.

Weaknesses

### Weaknesses #### Implementation Complexity - **Engineering Trick Perception**: The method may be perceived as an engineering workaround rather than a fundamental advancement. It requires users to input sub-sequence information, which can be seen as an additional burden and may limit the method's practical applicability. Providing a more automated or integrated approach could make the technique more user-friendly. #### Limited Improvement in Performance - **Marginal Accuracy Gains**: While the method ensures order independence, the actual improvement in model performance (accuracy) is limited. The results show that Set-Based Prompting maintains accuracy within the variation caused by different orderings but does not significantly enhance it. Highlighting specific scenarios where this method offers substantial performance gains could strengthen the paper's impact. #### Dependency on User Input - **Manual Sub-Sequence Specification**: The requirement for users to specify sub-sequences manually can be a significant limitation. This dependency on user input reduces the method's usability and scalability, particularly for large datasets or applications where manual specification is impractical. Exploring ways to automate the identification of sub-sequences would be a valuable enhancement. #### Evaluation Scope - **Limited Dataset Variety**: The evaluation is primarily conducted on multiple-choice question datasets (CommonSenseQA and MMLU). While these are standard benchmarks, the scope of evaluation could be broadened. #### Theoretical vs. Practical Benefits - **Practical Utility of Theoretical Guarantees**: While the theoretical guarantees are robust, the practical benefits might not be as compelling if the accuracy remains within the range of existing variations. Providing more concrete examples or case studies where order independence significantly improves real-world applications could make the practical utility of the method more apparent. #### Misleading Paper Title - **Title Naming Concerns**: I do not think that the proposed method is kind of "prompting" paper. It does change the internal implementation of LLMs instead of simply "prompting" them.

Questions

What will be the benchmark performance under chain of thought prompting of this method compared to default chain-of-thought prompting baseline?

Rating

5

Confidence

4

Soundness

3

Presentation

2

Contribution

2

Limitations

See more details in Weaknesses section.

Reviewer gPKU2024-08-09

Thank you for the rebuttal and the clarifications to my questions. I must admit that I am surprised by the low ratings given in the other reviews. This paper proposes an elegant and creative method for addressing an important issue observed in LLMs (the authors convincingly explained why order-dependency in language models is problematic). It is supported by thorough experimental evaluation and theoretical guarantees. Moreover, it paves the way for promising applications that extend beyond the specific case of multiple-choice questions, as discussed in Section 5.2 and supported by the additional results for in-context learning provided during this rebuttal. Given these strengths, I believe this paper deserves to be accepted at the conference. Based on the rebuttal, I have decided to increase my initial rating to 9, hoping that this might encourage other reviewers to reconsider their ratings.

Authorsrebuttal2024-08-12

Thank you for the kind response. We agree with your summary of this work.

Program Chairsdecision2024-09-25

Decision

Accept (poster)

© 2026 NYSGPT2525 LLC