Implement input handling for Piper