Hello to everybody.
So first a real big thank-you-all to the community and Kovid. You provide me with so many useful tipps and advices about calibre! I visit the forum since years and learned a lot. In fact - almost every problem that ever occured to me was asked and solved by some members sometimes. But now I have a problem which I simply cannot figure out because I don't really understand Phyton (and yes I try since some weeks

).
So here's the problem. Sometimes after a scan and ocr there may be many words with false divisions. So in German (which is my main paper-book-library) like 'Maschi ne' instead of 'Maschine'.
It would be great to have a Phyton expression:
If to words divided by space are _not_ found in the dictionary pull them together but only if the new word _is_ in the dictionary.
Example in German:
'betrach ten' should then look like 'betrachten' but
'Josef Bankl' shouldn't be converted to JosefBankl
In this case the Editors inbuilt Phyton-Expression is not really helpful because it pulls all words together which are part of the dictionary. Like making 'nachdem' from 'nach dem'. But these have different meanings and should remain untouched.
So hopefully I'm not the only one with this problem and it's not a big waste of your time to think about it.
And sorry for my miserable english.
Any advice would be great.

Sincerely, Steve