Switched to streaming for reading, writing and filtering and other changes