Scihub checks Libgen first when looking up an article or book, and if there is no hit it will attempt to retrieve the document from the publisher directly using stored authentication credentials. The retrieved file will be later uploaded to Libgen by Scihub for caching purposes.