Construct Optimal Directory Trees Efficiently
One way is to use a Huffman code, over an alphabet of size $k$, whre $k$ is the number of letters you're willing to use on the keyboard.  Make the weight for an entry be the "probability" for that entry (how often that entry is selected).  Then a Huffman code will minimize the expected number of key presses.  There's a standard algorithm for constructing a Huffman code.

The potential drawback is that it doesn't use the keys of the keyboard in the way you suggest; rather than using up/down to move forward/backward in a directory, the $k=4$ keys are all treated as equal, and each keypress moves you one level down in the tree.  In other words, each directory has at most $k$ entries, and you select an entry with a single keypress.  You might or might not be happy with the user experience.  If you prefer, you can set $k=2$ and use only the up/down keys for selection (each directory has two entries; press 'up' to select the first or 'down' to select the second, and it will jump immediately to that entry).  This will require fewer key presses than the approach you are imagining, but does require you to find a way to name each of the resulting nodes in the tree with a human-understandable category (i.e., pick a name for that directory/entry).