I actually made something similar in Python.