Inside Unity app, you can invoke the system keyboard. HoloLens2's system keyboard supports direct hand interactions.
You can see simple example of how to bring up system keyboard in Assets\MixedRealityToolkit.Examples\Demos\HandTracking\Script\OpenKeyboard.cs
public TouchScreenKeyboard keyboard;
...
public void OpenSystemKeyboard()
{
keyboard = TouchScreenKeyboard.Open("", TouchScreenKeyboardType.Default, false, false, false, false);
}
public TouchScreenKeyboard keyboard;
...
private void Update()
{
if (keyboard != null)
{
keyboardText = keyboard.text;
// Do stuff with keyboardText
}
}