Refactors database schemas from sqlite3 to mongo