Osascript is claimed to support python and indeed one can execute applescript commands from within python with it. I'd like to do something that's a bit the opposite: expose an app's python interface.