I'm facing this problem also. So I did a little testing what may cause the trouble and it seems for me it was the mouse software (Razer Synapse) that prohibited my Keyboard (Logitech G710+) from working ingame. Apperantly the thumbkeys on my mouse are defacto a secondary keyboard. And STO seems not to support 2 Keyboards…
I'm facing the same problem as the OP. Risa is dropping to 8fps (EIGHT!) on max. Details. And since I can run BF4 on max Details with stable 60fps (I play with Frame-Rate-Limiter) I would expect reaching the same result in STO. Please guys, fix this! And I would not mind if I got to use DX11 without crashing every 10…