Alright, so we have a Node module string-similarity who exports two functions like this (see: https://github.com/aceakash/string-similarity/blob/master/compare-
It looks like the export { ... } line is limiting the exports. (I was unaware that it is possible to do that in a declare module block!) If I delete that line, then by default everything is exported and I'm able to access the types.