You can turn photos of math worksheets into additional practice problems using OpenAI's gpt-4-vision-preview and Python.<p>Today, we’re going to use ChatGPT, in Python, to take an image of a 6th grade math worksheet and generate a similar problem set. Why? Once in a while, I come up with practice problems to supplement my daughter’s math homework. It takes time to write good ones, and although I really enjoy personalizing them, I wouldn’t mind saving some time.<p>This blog post will cover:<p>* Using gpt-4-vision-preview via the OpenAI Python SDK to generate a worksheet from an uploaded photo.
* Iterating until we are happy with the results.<p>In subsequent blog posts, we will use the generated assignment to:<p>* Ask gpt-4 to spit out LaTeX code so we can generate a PDF of the new assignment.<p>* Experiment with generating a very simple, pure HTML/JS based flash card example.