fixes to models, serialization and UI