Clean up code, model and diagram