remove the Collector class, just leave topN function that does the job