Added compression
Fixed relation type saving
Fixed #89