Tool Benchmarks

AI detectors / Famous texts

Is Hamlet's "To be, or not to be" AI-generated? 1 of 7 AI detectors said yes

Shakespeare's soliloquy is human writing, and Hamlet was first printed in 1603. Only Fast-DetectGPT, 1 of the 7 AI detectors we tested, flagged "To be, or not to be" as AI-generated. Fakespot (0.1%), Desklib (0.6%), TMR (4.4%), E5-small LoRA (22.7%), the OpenAI RoBERTa detector (0.0%) and MAGE all called it human.

Tested

What each AI detector said

1 of 7 detectors flagged this passage as AI-generated at their default threshold.
DetectorVerdictAI probability
Fast-DetectGPT (Qwen2.5-1.5B)AI-generatedraw score only
Desklib AI text detectorHuman0.6%
Fakespot AI text detectorHuman0.1%
MAGEHumanraw score only
E5-small LoRA detectorHuman22.7%
OpenAI RoBERTa detectorHuman0.0%
TMR (Target Mining RoBERTa)Human4.4%

The passage we tested

To be, or not to be, that is the question: Whether ’tis nobler in the mind to suffer The slings and arrows of outrageous fortune, Or to take arms against a sea of troubles, And by opposing end them? To die—to sleep, No more; and by a sleep to say we end The heart-ache, and the thousand natural shocks That...

Hamlet's "To be, or not to be" soliloquy, William Shakespeare, 1603. 275 words tested, from Project Gutenberg (public domain in the USA).

One detector said AI

Fast-DetectGPT was alone. It flagged 15.9% of the 126 human texts in our main benchmark, a rate set partly by its threshold, which we tuned on our calibration split while the other detectors used their authors’ setting. It flagged none of the 24 human fiction passages in that benchmark, the closest genre we have to a play.

The six that passed the soliloquy did so clearly. Fakespot, Desklib and the OpenAI RoBERTa detector gave it 0.6% or less, and MAGE called it human too. TMR’s pass is unusual, since it flagged 83.3% of human texts in our benchmark and 28 of the 30 famous passages.

A speech a language model knows by heart

The soliloquy is probably one of the most quoted passages in English. “To be, or not to be, that is the question”, “the slings and arrows of outrageous fortune”, “shuffled off this mortal coil”, “the undiscover’d country, from whose bourn no traveller returns”: many of its lines are stock phrases now. A language model trained on web text will have seen them countless times, in essays and quotation lists.

Fast-DetectGPT is the one detector here that works from a language model’s own predictions. It compares each word in a text with what the model expected, and AI text tends to follow the model’s expectations closely. When the model has nearly memorized a passage, human words follow its expectations closely too. That is the likeliest explanation for the flag. The classifiers work differently, by matching the look of AI text they were trained on, and blank verse full of ’tis, wish’d and contumely probably looks nothing like it.

TMR’s pass has a different cause. Our copy of the speech runs the verse lines together into one paragraph, and TMR’s verdicts follow line breaks more than wording, as the TMR page explains.

Essays that quote famous lines

Writing that quotes famous passages at length, such as an essay on Hamlet, may score as AI on detectors that work like Fast-DetectGPT, for the same reason. If a student’s literature essay gets flagged, check how much of it is quotation before reading anything into the result. The Federalist No. 10 got the same single flag from the same detector, and all 30 results are on the famous texts page.

Questions people ask

Did AI write Hamlet's soliloquy?

No. Hamlet was first printed in 1603. One of seven detectors, Fast-DetectGPT, flagged the soliloquy. It flagged 15.9% of human texts in our main test.

Why would Fast-DetectGPT think Shakespeare is AI?

Probably because the speech is so familiar. Fast-DetectGPT asks a language model how predictable each word is, and a model that has read this soliloquy many times can predict it well. To the method, predictable text looks machine-written.

Why did TMR pass Hamlet when it flags almost everything?

Our passage is a single block of text with no line breaks. TMR flagged 28 of the 30 famous texts we tested, and the only two it passed, this and The Federalist No. 10, are the two passages with one paragraph.

Other famous texts we tested