I'm gonna add a new method to file_api, to implement the above logic for use in all nargs=+ inputs.