Skip to content

Instantly share code, notes, and snippets.

@benjaminjamesbush
Last active January 8, 2023 09:03
Show Gist options
  • Save benjaminjamesbush/26c0f8d3fc1a3b85043d82fb209ffc02 to your computer and use it in GitHub Desktop.
Save benjaminjamesbush/26c0f8d3fc1a3b85043d82fb209ffc02 to your computer and use it in GitHub Desktop.
Using ChatGPT to pick photos from Unsplash with Interactive Evolutionary Computation

πŸ‘€ Human πŸ‘€

Write each image in Markdown without backticks and without using a code block. Use the Unsplash API

(https://source.unsplash.com/100x100/?<PUT YOUR QUERY HERE>).

The images you generate will be placed into a Markdown table. Each table will be called a "Generation".

Each Generation will contain 9 images. The images contained within Generation g will be labled image(g,i) for i from 1 to 9. The query used to generate image(g,i) will be referred to as query(g,i) When displaying a query, only use the portion that comes after the question mark.

Each table you create should follow the following template:

Generation
(g,1) <image(g,1)> (g,2) <image(g,2)> (g,3) <image(g,3)>
<query(g,1)> <query(g,2)> <query(g,3)>
(g,4) <image(g,4)> (g,5) <image(g,5)> (g,6) <image(g,6)>
<query(g,4)> <query(g,5)> <query(g,6)>
(g,7) <image(g,7)> (g,8) <image(g,8)> (g,9) <image(g,9)>
<query(g,7)> <query(g,8)> <query(g,9)>

Replace each instance of <image(g,i)> with a generated image using the Unsplash API as described above. Replace each instance of <query(g,i)> with the query used to generate image (g,i).

You will begin by creating Generation 1.

To create the next generation, I will first select one of the images from Generation 1. The selected image will be copied over to Generation 2 and will be known as the parent image of Generation 2. This means that image(2,1) will be a copy of the selected image. The remaining 8 images for Generation 2 will be called the child images of Generation 2. The parent image of Generation 2 is also called parent of each child image of Generation 2.

The queries used to create the child images for Generation 2 should be similar to the query used to create the parent image for Generation 2. In addition, the queries used to create the child images for Generation 2 should be more specific than the query used to create the parent image for Generation 2.

When you are finished creating Generation 1, prompt me to select the parent for Generation 2.

We will collaborate to create several generations in this way.

At some point, I will ask you to show me the genealogy of some image(g,i). You will respond by telling me the parent of image(g,i). You will also report the parent of the parent of image(g,i), and so on until no more parents remain.


πŸ€– ChatGPT πŸ€–

Generation 1
(1,1)
(1,2)
(1,3)
natureanimalsflowers
(1,4)
(1,5)
(1,6)
landscapecitysky
(1,7)
(1,8)
(1,9)
oceanwaterfallmountains

You may now select the parent image for Generation 2.


πŸ‘€ Human πŸ‘€

(1,2)

πŸ€– ChatGPT πŸ€–

Generation 2
(2,1)
(2,2)
(2,3)
animalsdogscats
(2,4)
(2,5)
(2,6)
elephantslionstigers
(2,7)
(2,8)
(2,9)
bearswolvespandas

You may now select the parent image for Generation 3.


πŸ‘€ Human πŸ‘€

(2,2)

πŸ€– ChatGPT πŸ€–

Generation 3
(3,1)
(3,2)
(3,3)
dogspuppiesdogs+breeds
(3,4)
(3,5)
(3,6)
dog+parkdog+walkingdog+beach
(3,7)
(3,8)
(3,9)
dog+sittingdog+trainingdog+sleeping

You may now select the parent image for Generation 4.


πŸ‘€ Human πŸ‘€

(3,3)

πŸ€– ChatGPT πŸ€–

Generation 4
(4,1)
(4,2)
(4,3)
dogs+breedslabradorpoodle
(4,4)
(4,5)
(4,6)
german+shepherdbulldogbeagle
(4,7)
(4,8)
(4,9)
boxerrottweilerchihuahua

You may now select the parent image for Generation 5.


πŸ‘€ Human πŸ‘€

(4,9)

πŸ€– ChatGPT πŸ€–

Generation 5
(5,1)
(5,2)
(5,3)
chihuahuachihuahua+puppychihuahua+adult
(5,4)
(5,5)
(5,6)
chihuahua+playingchihuahua+sittingchihuahua+lying+down
(5,7)
(5,8)
(5,9)
chihuahua+barkingchihuahua+runningchihuahua+jumping

You may now select the parent image for Generation 6.


πŸ‘€ Human πŸ‘€

show me the genealogy of image(5,2)

πŸ€– ChatGPT πŸ€–

The genealogy of image(5,2) is as follows:

  • Parent: image(4,9)
  • Parent's parent: image(3,3)
  • Parent's parent's parent: image(2,2)
  • Parent's parent's parent's parent: image(1,2)

image(5,2) is a child image of image(4,9). image(4,9) is a child image of image(3,3). image(3,3) is a child image of image(2,2). image(2,2) is a child image of image(1,2).


πŸ‘€ Human πŸ‘€

Show me the genealogy of image(5,2) again, but this time display the referenced images and associated queries.

πŸ€– ChatGPT πŸ€–

The genealogy of image(5,2) is as follows:

  • Parent: image(4,9)
    • Query: chihuahua
  • Parent's parent: image(3,3)
    • Query: dogs+breeds
  • Parent's parent's parent: image(2,2)
    • Query: dogs
  • Parent's parent's parent's parent: image(1,2)
    • Query: animals

image(5,2) is a child image of image(4,9). image(4,9) is a child image of image(3,3).
image(3,3) is a child image of image(2,2). image(2,2) is a child image of image(1,2).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment