Generating captchas using generative imaging models
Methods and systems for generating completely automated public Turing test (CAPTCHA) images are provided. In some examples, a method includes generating a plurality of images using a generative imaging model, providing the plurality of images to a user with a description that corresponds to one of a similarity or difference between the plurality of images, receiving a selection of an image of the plurality of images, determining if the selection is correct based on the provided description, and outputting an indication of whether the selection is correct.
1 . A method for generating captcha images, the method comprising:
generating a plurality of images using a generative imaging model, the generating comprising providing a plurality of prompts to the generative imaging model, each prompt of the plurality of prompts corresponding to a respective image of the plurality of images;
providing the plurality of images to a user with a description corresponding to one of a similarity or difference between the plurality of images;
receiving a selection of an image of the plurality of images;
determining if the selection is correct based on the provided description and the plurality of prompts provided to the generative imaging model;
outputting an indication of whether the selection is correct; and
if the description is correct, based on the indication, granting a user access to a computer system protected by the generated images or, if the description is incorrect, based on the indication, rejecting access to the computer system.
2 . The method of claim 1 , wherein each of the plurality of images are generated based on a plurality of categories of variables.
3 . The method of claim 2 , wherein the plurality of categories of variables comprise a subject, a verb, a setting, and a style.
4 . The method of claim 2 , wherein the similarity or difference is associated with a category of the plurality of categories of variables.
5 . The method of claim 1 , wherein the providing a plurality of images comprises displaying the plurality of images on a display screen of a computing device.
6 . The method of claim 1 , wherein the plurality of images is a first plurality of images, wherein the indication indicates that the selection is not correct, and wherein the method further comprises generating a second plurality of images using the generative imaging model.
7 . The method of claim 1 , wherein the indication indicates that the description is not correct, and wherein the method further comprises:
receiving a signal corresponding to the user terminating providing descriptions; and
providing the prompt based on which the one or more images were generated.
8 . A method for generating captcha images, the method comprising:
generating one or more images using a generative imaging model, wherein each of the one or more images are generated based on a respective prompt;
providing the one or more images to a user;
receiving a description of the one or more images;
comparing the description of the one or more images to the respective prompts of the images, wherein the comparing comprises:
generating an input embedding based on the received description;
generating a prompt embedding based on the prompts used to generate the one or more images;
determining a semantic distance between the input embedding and the prompt embedding within a vector space; and
comparing the semantic distance to a similarity threshold, thereby determining if the description is correct;
outputting an indication of whether the description is correct, based on the comparison; and
if the description is correct, based on the indication, granting a user access to a computer system protected by the generated images or, if the description is incorrect, based on the indication, not granting access to the computer system.
9 . The method of claim 8 , wherein the description comprises natural language.
10 . The method of claim 8 , wherein each of the plurality of images are generated based on a plurality of categories of variables.
11 . The method of claim 10 , wherein the plurality of categories of variables comprise a subject, a verb, a setting, and a style.
12 . The method of claim 8 , wherein the one or more images are a plurality of images, and wherein the description comprises a description of one of a similarity or difference between the plurality of images.
13 . The method of claim 8 , wherein the providing a plurality of images comprises displaying the plurality of images on a display screen of a computing device.
14 . The method of claim 8 , wherein the indication indicates that the description is not correct, and wherein the method further comprises:
receiving a signal corresponding to the user terminating providing descriptions; and
providing the prompt based on which the one or more images were generated.
15 . A method for generating captcha images, the method comprising:
generating a plurality of images using a generative imaging model, wherein each image of the plurality of images is generated based on a respective prompt;
providing the plurality of images to a user;
receiving a description of similarities or differences between the plurality of images;
comparing the description to similarities or differences between the prompts based on which the plurality of images were generated;
outputting an indication of whether the description is correct, based on the comparison; and
if the description is correct, based on the indication, granting a user access to a computer system protected by the generated images or, if the description is incorrect, based on the indication, rejecting access to the computer system.
16 . The method of claim 15 , wherein the description comprises natural language.
17 . The method of claim 15 , wherein each of the plurality of images are generated based on a plurality of categories of variables.
18 . The method of claim 17 , wherein the plurality of categories of variables comprise a subject, a verb, a setting, and a style.
19 . The method of claim 18 , wherein the similarities or differences between the prompts are based on similarities or differences between the plurality of categories of variables.
20 . The method of claim 15 , wherein the comparing comprises:
generating an input embedding based on the received description of similarities or differences;
generating a prompt embedding based on the similarities or difference between the prompts;
determining a distance between the input embedding and the prompt embedding within a vector space; and
comparing the distance to a similarity threshold, thereby determining if the description is correct.