abstract out the file ingestion from the constructor