The exact way to implement it is this:
https://bazaar.launchpad.net/~widelands-dev/widelands/trunk/view/head:/utils/glossary_checks.py
This will get rid of about 95% of false positives in my locale.
All we would need in the glossary to avoid ugly hacks is 1 textarea where translators can add a list of inflected forms, 1 term per line. And if the locale has a good hunspell stemmer, that won’t even be needed.