Extract trigrams from lemmas in tab separated full form/lemma list. Count the number of occurences of each trigram. Spaces are added before and after each lemma.
To run the program you need Bracmat. (https://github.com/BartJongejan/Bracmat)
The generated trigram list can be used by CSTlemma (https://github.com/kuhumcst/cstlemma) to disambiguate between lemma candidates. This works well for Middle Low German.