My most recent theory is that Kylo can read Sith, so he must’ve read it at some point while it was in his chambers. But again, I don’t think the film really explicitly tells us.
This actually makes the most sense, come to think of it. First Order droids also wouldn’t have the same restrictions as a Republic Era droid like 3PO.