SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2403.20127 · 2024

The Impact of Prompts on Zero-Shot Detection of AI-Generated Text

arXiv · PDF · Open in the Atlas

Code that ran

We lifted 9 functions out of this paper's own repositories and ran 7 of them in a sandbox. "Ran" means the function executed on a synthesized input and returned a value. It is not a reproduction of the paper's results.

RepositoryRoleRan
kaito25atugich/detector canonical 7 of 9
FunctionStatusWhere it lives
find_max_index Ran kaito25atugich/detector/utils.py
pointer only (licence: NONE) · get_code("d3ccb79d5f676d7a")
get_precision_recall_metrics Ran kaito25atugich/detector/utils.py
pointer only (licence: NONE) · get_code("1952adc5b5b7b860")
get_prompt Ran kaito25atugich/detector/tmp/generate_estimation_prompts.py
pointer only (licence: NONE) · get_code("9a9e58cbb8b7370b")
get_roc_metrics Ran kaito25atugich/detector/utils.py
pointer only (licence: NONE) · get_code("4480f9be0b362363")
perplexity Ran kaito25atugich/detector/detector.py
pointer only (licence: NONE) · get_code("318a521cfba1fbf1")
preprocess_string Ran kaito25atugich/detector/detector.py
pointer only (licence: NONE) · get_code("1ebc2d66bc8ec407")
remove_special_tokens Ran kaito25atugich/detector/tmp/paraphraser.py
pointer only (licence: NONE) · get_code("f6d96afa1d60eb61")
get_paraphraser Not yet run kaito25atugich/detector/tmp/paraphraser.py
pointer only (licence: NONE) · get_code("ebcdce09885239f8")
prim_tree Not yet run kaito25atugich/detector/detector.py
pointer only (licence: NONE) · get_code("595d1d025c7e692d")

Repositories linked to this paper

Some links come from the archived Papers with Code dataset (CC BY-SA 4.0): attribution and licence.

Abstract

In recent years, there have been significant advancements in the development of Large Language Models (LLMs). While their practical applications are now widespread, their potential for misuse, such as generating fake news and committing plagiarism, has posed significant concerns. To address this issue, detectors have been developed to evaluate whether a given text is human-generated or AI-generated. Among others, zero-shot detectors stand out as effective approaches that do not require additional training data and are often likelihood-based. In chat-based applications, users commonly input prompts and utilize the AI-generated texts. However, zero-shot detectors typically analyze these texts in isolation, neglecting the impact of the original prompts. It is conceivable that this approach may lead to a discrepancy in likelihood assessments between the text generation phase and the detection phase. So far, there remains an unverified gap concerning how the presence or absence of prompts impacts detection accuracy for zero-shot detectors. In this paper, we introduce an evaluative framework to empirically analyze the impact of prompts on the detection accuracy of AI-generated text. We assess various zero-shot detectors using both white-box detection, which leverages the prompt, and black-box detection, which operates without prompt information. Our experiments reveal the significant influence of prompts on detection accuracy. Remarkably, compared with black-box detection without prompts, the white-box methods using prompts demonstrate an increase in AUC of at least $0.1$ across all zero-shot detectors tested. Code is available: \url{https://github.com/kaito25atugich/Detector}.

For agents

The same record, over MCP at https://syntology.ai/mcp:

get_harvested_code_for_paper("2403.20127")
get_code_for_paper("2403.20127")
have("2403.20127")

Connect an agent — have() is free.