Mac Book Pro file sharing stops working
The following might be one of the issues but it hasn't fixed the issue for me so I'll continue to look for a solution.  Opening preferences, sharing and enabling and disabling sharing causes the sharing to start working again so possibly I just need a cron job that runs every so often and does whatever the gui is doing in the background.  The other possible hint is that my monitors are typically asleep so I might test around disabling the &quot;turn display off after&quot; or &quot;automatic graphics switching&quot; features.
The OSX powernap feature and SMB don't like each other.  I've quoted and pasted the link below describing the problem.  The answer is also apple recommended so that leads credence to it.

“Enable Power Nap” selected in the Energy Saver settings was forcing the network drives to dismount. I disabled that setting two days ago, and the network backups have properly worked the past two nights; the network drives also remain mounted as I can see when I come into the office in the morning. This behavior is counterintuitive given that the entire point of a Power Nap is to permit the computer to perform network based operations as per Apple’s own words:
“While sleeping, your Mac can back ip using Time Machine and periodically check for new email, calendar, and other iCloud updates”
Yet, this very same feature causes network drives to dismount once the Mac goes to sleep.  As I stated in the original post, this appears to be a longstanding problem that needs to be corrected in macOS, as many Mac users, particularly those in work environments, need to connect to servers, NAS, etc. that are not set up with Mac-centric protocols.

https://discussions.apple.com/thread/7842881
I'll update once I've had a chance to test out disabling the other energy features and see that I don't encounter any more issues with the file sharing.