file optimizer for simplicity of the pipeline