Implemented n-gram table node.
Refactored existing NGramCounter (and supported node class) code.