Story Cloze
Tests whether a model can choose the right ending for a short five-sentence story about everyday life.
At a glance
What it tests
ROCStories are tiny five-sentence stories about everyday life. The Story Cloze Test removes the last sentence and offers two candidates: the real ending and a plausible-sounding wrong one written by a different person.
Choosing correctly means tracking what the characters wanted and what would naturally follow — commonsense about causes and goals rather than facts.
GPT-1 fine-tuned on it (86.5%) and GPT-3 evaluated it few-shot (87.7%). It has mostly been retired since; the data needs a request form and the ending-writers left stylistic cues that models exploit.
Examples
Items from the dataset (or representative items where the originals are not freely redistributable).
Reported results
Scores reported on this benchmark, with the evaluation setting each one used.
| Setting | Reported | Context |
|---|---|---|
| Fine-tuned (2016 test set) | 86.5 acc | Prior best 77.6 (val-LS-skip); an 8.9-point jump |
| Few-shot (70 examples), 2016 test set | 87.7 acc | Zero-shot 83.2; fine-tuned SOTA then 91.8 |
State of the art
Few-shot: PaLM 540B 89.0 (5-shot). Rarely reported since 2022. Source: arxiv.org ↗ · checked October 2026.
Quickstart
Load the benchmark and score a Hugging Face causal LM on it in a few lines.
pip install -U datasets transformers evaluate lm-eval sacrebleu rouge-score scikit-learn
input_sentence_1…4, sentence_quiz1, sentence_quiz2, answer_right_ending (1 or 2). Requires manual download: request the CSVs at cs.rochester.edu/nlp/rocstories and pass `data_dir=`.
from datasets import load_dataset ds = load_dataset("story_cloze", "2016", split="test") print(ds) # columns: input_sentence_1…4, sentence_quiz1, sentence_quiz2, answer_right_ending (1 or 2) print(ds[0])
Two helpers cover every benchmark in this collection: loglik for anything multiple-choice (score each option, pick the highest) and generate for anything free-form. Swap MODEL for whatever you are evaluating.
import torch from transformers import AutoTokenizer, AutoModelForCausalLM MODEL = "gpt2" # or "Qwen/Qwen2.5-1.5B", "meta-llama/Llama-3.2-1B", … tok = AutoTokenizer.from_pretrained(MODEL); model = AutoModelForCausalLM.from_pretrained(MODEL, torch_dtype=torch.bfloat16).eval().to("cuda") @torch.no_grad() def loglik(context, continuation): """Sum of log-probs of `continuation` tokens given `context` — the standard multiple-choice scorer.""" ids = tok(context + continuation, return_tensors="pt").input_ids.to(model.device) n_ctx = len(tok(context).input_ids) logp = model(ids).logits.log_softmax(-1)[0, :-1] return logp.gather(1, ids[0, 1:, None])[n_ctx - 1:].sum().item() @torch.no_grad() def generate(prompt, max_new_tokens=32, stop=None): ids = tok(prompt, return_tensors="pt").input_ids.to(model.device) out = model.generate(ids, max_new_tokens=max_new_tokens, do_sample=False, pad_token_id=tok.eos_token_id) text = tok.decode(out[0, ids.shape[1]:], skip_special_tokens=True) return text.split(stop)[0] if stop else text
# Multiple choice by length-normalised log-likelihood of each ending (acc_norm) def choices(ex): if "endings" in ex: return ex["ctx"], ex["endings"], int(ex["label"]) # HellaSwag if "sol1" in ex: return ex["goal"], [ex["sol1"], ex["sol2"]], ex["label"] # PIQA story = " ".join(ex[f"input_sentence_{i}"] for i in range(1, 5)) # Story Cloze return story, [ex["sentence_quiz1"], ex["sentence_quiz2"]], ex["answer_right_ending"] - 1 acc = 0 for ex in ds: ctx, ends, gold = choices(ex) s = [loglik(ctx, " " + e) / max(1, len(e)) for e in ends] acc += int(s.index(max(s)) == gold) print("acc_norm", acc / len(ds))
Task name(s): storycloze_2016. The harness reproduces the GPT-3 prompt formats and reports the standard metric.
lm_eval --model hf --model_args pretrained=gpt2,dtype=bfloat16 \
--tasks storycloze_2016 --num_fewshot 0 --batch_size auto --output_path results/Pitfalls
- Not on the Hub as a free download — you must request access and point `load_dataset` at the local folder.
- The 2016 and 2018 test sets differ in size; GPT-1/3 numbers are on 2016.
- Ending-only baselines reach ~70% because wrong endings are stylistically different; report one.
References
- Paper (NAACL 2016)https://aclanthology.org/N16-1098/
- ROCStories sitehttps://cs.rochester.edu/nlp/rocstories/
- Hugging Face (manual download)https://huggingface.co/datasets/story_cloze