Skip to contents

Predict if text was generated by AI

Usage

gptzero_predict_text(text)

Arguments

text

text to upload

Value

a tibble of sentence-level assessments

Examples

if (FALSE) { # gptzeror::gptzero_has_key()
# Requires API Key
abstr <- 'Congressional district lines in many U.S. states are drawn by partisan
actors, raising concerns about gerrymandering. To separate the partisan effects
of redistricting from the effects of other factors including geography and
redistricting rules, we compare possible party compositions of the U.S. House
under the enacted plan to those under a set of alternative simulated plans
that serve as a non-partisan baseline. We find that partisan gerrymandering
is widespread in the 2020 redistricting cycle, but most of the electoral bias
it creates cancels at the national level, giving Republicans two additional
seats on average. Geography and redistricting rules separately contribute a
moderate pro-Republican bias. Finally, we find that partisan gerrymandering
reduces electoral competition and makes the partisan composition of the U.S. House
less responsive to shifts in the national vote.'

abstr <- gsub('\\n', ' ', abstr) # remove the "\n"s

gptzero_predict_text(abstr)
}