Tooltips generation improved, added max_terms and max_words settings and limits handling