Psd2HTML was possibly my first macOS App, you could feed in a PSD file and it would output HTML
It wasn't the first go at the problem. Three years earlier I'd built Rapid PSD, which did the same thing as a web service — you uploaded the PSD and the markup came back by email. This was the same idea with the work moved onto your own machine.
The caveat being that you had to have a very good layer system.
No data ever left your mac, as it ran, it downloaded a script to splice your PSD and output the HTML