The keyboard module allows you to bind an action to a given combination of keys. In this example, we bind the addition of a node to a combination, and the removal of a node to another combination: Press ALT + A to add a node to the graph Press ALT + R to remove a node from the graph