refactor translation model generator to use translation model class