Hey there! Thanks for trying out the macro and I'm glad to see it's proven useful for you.
The only way I can think of to easily modify it to differentiate between medical and non-medical words is to use two different triggers, and use the two different CLI programs (aspell and hunspell) according to which trigger you used.
For an idea of what I mean by this, see these two screenshots which are part of another macro I built that also uses Aspell.
Obviously you could simplify that by just using the actual triggers in the switch action; again this is just an example taken from my other aforementioned macro here: