extract TopicParser class and refactor Category#sort!