IPFS includes a way to mount it as a filesystem. So if you know the IPNS URL for some data, or the hash, you can access it like accessing any other file. If it's already downloaded then there shouldn't be any overhead versus just opening a file, if it hasn't it'll download it. You oughtn't need any extra library or logic for it.
That's brilliant! I think that means it should also support reading the file in chunks, as it gets downloaded, automatically.
I wonder how purging less important files is/could be handled through this? It would be good if there was some way to say, "this file is likely only going to be used temporarily (or just once), so feel free to delete it if disk space is required". That hinting might not be necessary as IPFS could use some least-recently used algorithm, but there should be some way to at least pin files, "this is really important, don't delete this".