How I created these caps:
You have to make sure that you prepare your keycaps with a sharp, deep enough groove. The inlays need some empty volume to fit into. I used arial black for the caps
(the depicted caps are a variation of the excellent work of DesignersMind on ThingiVerse, https://www.thingiverse.com/thing:4403859/files) in the main project photos, the engraved characters are about 1mm deep. Shallow grooves mess up the surface of the inlay.
I printed my caps using a SLA printer (Photon Mono X) in 0.05 layers with a standard black resin, just to make sure that the concept itself will work without special materials. So there is much headroom for even better optics.
I chose to spraypaint the keycaps with acrylic paint before proceeding. It greatly improves the surface structure of the keycaps. If you plan for further cap-smoothing, you should do so before applying the inlay.
After the paint has dried, i took a modest amount (about pea sized) of really cheap white airdrying modeling clay (I literally took the cheapest stuff I could find, <3€ for 500g delivered) and just massaged it into the grooves until I was convinced that the whole space was completely filled. I then used some clear water to remove the excess material and to smoothe out the surface of the inlay.
After letting everything dry out, you should apply some clear protective coating of your choice. I experimented with matte and shining finishs and they both work pretty well.
Above are some earlier versions with thinner characters (0.35mm width), You can clearly see where the inlay was not able to penetrate deep enough into the groove (i.e. the zero of 'P08'). A font this thin did lead to some problems during printing, too. But even this version looks decent from a normal viewing distance. There is still some room for improvement left, if you desire really thin characters.
As these modeling clays are available in a diverse set of colours, your imagination can go wild in choosing the colors you want.
If you want a really durable inlay, you can use a heat-curing modeling clay (i.e. Fimo). Just make sure that all your used materials make it through the heating process. I would not dare to try that with PLA printed caps, though. :D