Guessing Amazon image URLs using GitHub Copilot

I was experimenting with the new Readwise export API and it gave me back the following JSON:

  "user_book_id": 15433610,
  "title": "Screenwriting: The Sequence Approach",
  "author": "Paul Joseph Gulino",
  "readable_title": "Screenwriting",
  "source": "kindle",
  "cover_image_url": "",
  "unique_url": null,
  "book_tags": [],
  "category": "books",
  "readwise_url": "",
  "source_url": null,
  "asin": "B00F9476Y0",
  "highlights": []

The image URL produced a tiny little image - this one:

A tiny picture of a book cover

I wanted to get back a bigger version of that image. On a hunch, I popped open a VS Code window running GitHub Copilot and typed this:
# That image but bigger:

It autocompleted for me:

Which is indeed a larger version of the image!

Screenwriting: The Sequence Approach - a much bigger book cover image, with legible text

I typed # and hit autocomplete again, to see what would happen, and got this:

# That image but smaller:

An even tinier picture of a book cover

Another correct guess. GPT-3/Copilot clearly includes training data that has seen these URLs before.

I typed # one more time and it autocompleted again to:

# That image but with a different format:

... and this time that URL is a 404. Copilot made this one up!

Here's the full flow in VS Code:

Animation showing the above prompts being executed in VS Code

Created 2022-10-15T15:10:24-07:00, updated 2022-10-15T15:27:45-07:00 · History · Edit