bin/perfect: Write script to explore computed database

Next step: make it fall back to tree search once we get deep enough.
high/board: Fall back to tree search if cache fails