kezb90/PDF_To_Word ? reverse-engineered prompt
Reverse engineered prompt
Build me a Python tool that turns a PDF into an editable Word document.
I want to drop in a PDF and get back a .docx file that keeps the text, images, and general page structure as close to the original as possible. It should go page by page, extract the text, pull out embedded images, and insert everything into the Word file in a clean readable way with page breaks where it makes sense.
Please make it easy to run from a single script, and if any page has missing text or images, handle that gracefully instead of crashing. Use current docs online if you need to, and keep the setup simple so I can install the needed packages and run it locally. If there’s a sensible default output name, use that, but let me pass in my own PDF and output file too.
Are you gonna build this?
make sure you review the code using coderabbit