passdrill
AI & LLM Engineering · Prompt Engineering · Card 016/024 hard

Lu et al. (2022), "Fantastically Ordered Prompts and Where to Find Them," study how the order of few-shot examples within an otherwise-identical prompt affects accuracy. What did they find, and what method did they propose to pick a good order without a labeled validation set?

  1. Example order has no measurable effect on accuracy once the examples themselves are held constant, so the paper concludes ordering can safely be ignored
  2. The order of the same few-shot examples can swing accuracy from near state-of-the-art to close to random guessing; they proposed generating an artificial, unlabeled "probing" set from the language model itself and selecting the ordering whose predicted-label distribution has favorable entropy statistics on that set, without needing any labeled dev data
  3. They found the best fix was to always sort examples alphabetically by their label text, which fully eliminated order sensitivity across all models and tasks tested
  4. They found order sensitivity only affects models under one billion parameters, and it disappears automatically once a model is scaled past that size
Next card → Shuffle