Fix compilation errors + update data model