Do you have NFC turned on by any chance? And do you happen to have your phone in a case, maybe one you can close?
I notice the following odd behavior:
Samsung Galaxy Note 5, stock/no root, Verizon.
When NFC is on, and the phone is in my Verus portfolio case (credit cards on one side) and I put the cover part toward the back on the phone, my keyboard too vanishes. This is true whether it's Samsung's own keyboard or Swift Keyboard. Restarts didn't fix this.
Once I turned NFC off, the issue disappeared. To test this, I turned NFC on and off, and sure enough, with NFC on, the keyboard disappeared.
So...turn NFC off and see if that helps.
HTH