Fix the command-line tool to work with ActiveRecord
Add Corpora model