This 13MP module looks awfully similar, no?
As it so happens, I measured my SP5509 before mounting it. Width and height matches closely. The JAL-IMX135-E10B is 8.6 x 16.7mm, while the SP5509 is 8.5 x 17.4mm (the length includes the flex cable and connector). Both seems to use a "2 lane MIPI interface" (whatever that is).
However, the JAL-IMX135-E10B datasheet says its "lens" is 5.75mm thick (possibly plus mounting and the flex cable), while the SP5509 is 4.00mm thick in total (my calipers says 4.04mm, including the blue protective sticker).
Given its 1.12um BSI pixels, one could easily think the SP5509 could be better. At "only" 5MP, it's 1/5" type sensor size shouldn't have to be a problem, but for some reason, the images are indeed quite terrible. Given the lack of detail in even the best of light, it kind of looks like the Gemini would be doing something weird, like upsampling a screen grab of the viewfinder stream.
While it likely wouldn't solve anything, maybe I should try to estimate the useful level of detail at different resolutions. If nothing else, should it turn out that 5MP images only contains, say, 2MP worth of detail, at least I could lower the resolution to that when taking pictures, and get smaller files.
As for truly compact cameras, they seem to have been pushed out of the market by smartphones. I used to have good experiences with the Canon Ixus series, but current models seems to have grown thicker to fit more zoom. Casio and Sony used to make thin cameras too, but no longer it seems. Perhaps you can find something cheap second hand, though finding replacement battery packs might be tricky.