Good question! In fact, a couple months back, I started the project planning to use the same scheme QtIrreco does -- reading individual LIRC config files provided by the user. Even as I started creating my own internal database of keysets, I still intended to keep the ability to import LIRC config files. .... My problem has always been that I just don't have enough data. The Wiki page with the Compatible Devices List should hopefully make this more useful...
So almost all Sony TVs should be supported directly from the Sony TV Keyset 1. I've checked, and the RM-887 keys fall into that keyset as well. If it doesn't work for you, please let me know!