So I was almost right, almost everything I want to do was straightforward
How can I get access to the calibre metadata of a book being converted? Specifically, I would like the ISO639 language identifier.
Also, what do I need to do in order to make 'kepub' show up as a selection in the list of formats a device can accept? When I open calibre's preferences, go to Plugins, and choose a device driver I can see all the formats calibre supports and some of them are selected according to what the device supports. Do I just need to add 'kepub' to the FORMATS list for the device driver?