Dev.to AI πŸ€– Ai πŸ‘ 0 πŸ“– 5 min read

Before you trust an AI detector's accuracy number, ask these five questions

When an AI detector claims "99% accurate", I want to see the test behind that number. On its own, it tells you almost nothing. Accurate on what kind of writing? How many texts? Which mistakes: flagging a person's essay a

When an AI detector claims "99% accurate", I want to see the test behind that number. On its own, it tells you almost nothing. Accurate on what kind of writing? How many texts? Which mistakes: flagging a person's essay as AI, or letting AI text through? Those two mistakes cost different people very different things.

If you're picking a detector for a class, an editorial team or your own drafts, the useful thing to look for is the test write-up behind the number. Below are the five questions I'd put to it, with a published example of each answer. The examples come from one detector's write-up, How We Test Our AI Detector Before It Goes Live, which reports its English test in enough detail to check.

1. Were the test texts kept out of tuning?

Tuning on the test texts can inflate the score. Ask when the team set those texts aside and whether the results influenced the release settings. In the English write-up, the team says it set the texts aside before tuning and locked the settings before scoring them. If a report skips that detail, ask how tuning and testing were kept separate.

2. Was the split by author, or just by text?

This one is easy to miss. Suppose a newsletter writer's earlier issues were used for tuning and their later issues for testing. The score then tells you how the detector handles more work from a writer it already knows. A student or freelancer whose work is new to the detector is a different test.

A stricter test keeps everything by the same author, or written to the same prompt, on one side of the split. Ask how the team kept texts by each known author, and answers to each shared prompt, together when it split the data. That split shows how the detector handles writers and prompts it didn't see during tuning.

3. How many human texts were tested, and how many were flagged?

For anyone grading or editing, the false positive is the mistake that matters most. A person whose own work gets flagged may have to dig out drafts to prove they wrote it.

So the first number to find is not "accuracy" but "human texts called AI, out of how many". The Medium write-up gives 0 of 1,097 human-written English texts called "likely AI-written", alongside 291 of 300 unedited AI texts caught. Read the two counts together. A detector that flags nothing has a 0% false positive rate and catches no AI text.

4. Did the test include second-language writers?

In 2023, Liang and colleagues tested seven detectors on 91 TOEFL essays. On average, the detectors wrongly flagged about 61% of them as AI-written. After the researchers used ChatGPT to revise the essays' word choices, the average false positive rate fell from 61.3% to 11.6%.

If a detector will be used on international students or on non-native writers, ask for a separate false positive rate for that group. The English write-up above used its own set of 557 texts by non-native English writers and labeled none of them "likely AI-written".

Then check the other languages. The slide deck Checking text for AI in Spanish, Portuguese and French reports a separate test for each language. Of the human-written texts, the detector flagged 1 of 518 in Spanish, 3 of 788 in Portuguese and 2 of 938 in French. A verdict takes at least 150 words in English, or 200 in Spanish, Portuguese or French, and only English and Portuguese get sentence highlights.

The same deck covers a case that trips people up: a Portuguese essay with an English abstract. The detector groups the paragraphs by language. If one language meets its word minimum and makes up at least 80% of the words it scored, that language gets the only verdict. Otherwise, each language that meets its own minimum gets a verdict. If you work in more than one language, rules like these affect you more than the headline number does.

5. What's the confidence bound, not just the rate?

"0 of 1,097" does not mean "never wrong". A test set is a sample, and another sample could turn up a mistake. The upper end of a 95% Wilson interval shows how high the false positive rate could plausibly be, given the sample size, and for a count of zero it's easy to work out yourself.

For a 95% Wilson interval with zero flags out of n texts, the upper end is roughly 3.84 / (n + 3.84). Plug in the numbers:

Human texts tested Flagged 95% Wilson upper bound
100 0 about 3.7%
557 0 about 0.68%
1,097 0 about 0.35%

The same zero means very different things depending on the size of the test. With only 100 essays and zero flags, I'd still allow for more than one false flag per 30 essays.

The same team's six-slide summary, How we test an AI detector before release, puts each count next to its 95% bound on one slide. I'd ask vendors to give the count, rate and bound on the same line for each test group.

What a test usually leaves out

Even a careful write-up has limits, and a good one lists them. Three to check for:

  • Edited AI text. The 291-of-300 result above covers unedited AI output. Ask whether the test also included AI drafts reworked by hand; a catch rate on raw output doesn't tell you about those.
  • Short texts. A 120-word bio falls below the 150-word minimum for an English verdict in the test above. Check the tool's minimum before relying on it for short answers.
  • Other languages. Each language needs its own test set and its own numbers.

A short version to send a vendor

If you only have time for one email, ask:

  1. How many human texts did you test, and how many were flagged as AI?
  2. Did you set the test texts aside before tuning? How did you handle authors and prompts that appeared more than once?
  3. Did the test include non-native writers, and what were the results for them?
  4. What are the 95% bounds, not just the rates?
  5. Which languages and lengths do those numbers apply to?

If the reply is just "99%", ask how many human-written texts were flagged, out of how many. And whatever the numbers say, treat a high score on someone's work as a reason to reread it and ask about their drafts, not as proof of who wrote it.

πŸ“° Read the original article on Dev.to AI

Originally published by Dev.to AI. Aggregated on AIWithGhost for educational purposes β€” full credit and traffic to the original publisher.