The USPTO Patent Exploring Tool (UPET) provides Python code for downloading, parsing, and loading USPTO patent bulk data into a local MySQL database.