add key mapping function