Strategic advice from KataHex

From HexWiki
Revision as of 13:14, 11 May 2023 by Hexanna (Talk | contribs)

Jump to: navigation, search

Introduction

Several hex bots have popped up in the last few years. Many are neural nets and adaptations of Go bots like AlphaGo Zero. The most recent (and likely strongest) as of 2023 is KataHex, which is based on the open-source KataGo. These bots have influenced human play in many aspects already; one of the most notable is the bots' preference for the 4-4 obtuse corner over the 5-5. Many old strategy guides have become at least partially (if not mostly) outdated.

This article attempts to bring some strategy advice "up-to-date". There's a lot of random insights; most are a direct result of playing around with KataHex evaluations for hundreds of hours, including analyzing the games of strong players for common mistakes. Since this is strategic advice and not tactics, the advice won't apply 100% of the time, and many players may disagree with some parts.

Care has been taken to only draw conclusions when there are multiple examples of KataHex preferring something. However, the main goal of this article is to give actionable advice to make players stronger, and there isn't rigorous proof for basically any of these statements.

For brevity, nearly every statement should have hedging language like "usually" or "rarely" instead of "always" or "never," but this makes the article really verbose, so I only do it when it seems useful.

General

  • Playing near your own edge with no nearby stones is a bad idea in the opening and even middlegame. This is one of the most common mistakes among human players. You need a strong (often tactical) reason to do otherwise.
    • When is playing near your own edge a good idea? There are a few cases, like when you're playing adjacent to existing stones, responding to a joseki, or pushing a ladder as the attacker, but all of these involve stones in the vicinity.
    • This holds most strongly for 13×13 to 19×19, but applies more often than not to 11×11 too.
    • Playing near your own edge in the opening or early middlegame should be a "last resort," only after you've exhausted other options.
  • Many intermediate and strong players are too eager to minimax. They play bad minimaxing moves (that KataHex thinks are inferior to directly connecting) more often than they fail to minimax. The issue is that minimaxing isn't always free; your opponent can often intrude for useful territory, and sometimes the territory your opponent gains is more useful than what you gain by minimaxing. It's a difficult skill to judge which player gains more from a minimax, but there are common patterns.
  • Most of the time, you should play at Red 1 in the position below when given the opportunity, because you capture the hexes marked (*). Many players think it's too naive/obvious to be good, or that their opponent must be setting up a trap, but it's much more common that a player fails to play the move when it's in fact strong. (This pattern is common enough that it probably deserves a name.)
1

There is one main exception: this is less strong if the move you're bridging to is otherwise bad for global reasons, like it's on the second or third row of your own edge, or it's on the 5th row of your edge but you already have a bunch of other stones near that edge.

  • Be aggressive; always be ready to capitalize on an opponent's mistake. Here are a few illustrative examples of this and some of the above concepts:
    • In this game, 6. c9 was a mistake (and an example of incorrect minimaxing); 7. a10 is the standard reply. White should have played 8. b8; j4 was a mistake. Black's 9. b8 is the "capitalizing" move; KataHex already says 99% win rate for Black. In this case, there were several good options on move 9. These alternatives are threatening enough that Black didn't have to play b8, but this won't always be true, like in the next example.
    • In this game, 11. e6 was a mistake; the best move was to respond to the obtuse corner joseki with i4. Because Black did not play i4, White was able to play 12. i4, with a 70% win rate (whereas the second-best move has only a 61% win rate). If White plays elsewhere, that gives Black a chance to correct the mistake by playing i4, so i4 needs to be played immediately. Another example is in the following move; 13. g5 is a mistake because 14. h6 captures the two hexes in White's bridge. This move also needs to be played immediately because otherwise Black can then play h6; the bot says 93% win rate after 14. h6, and only 65% if White plays the reasonable-looking i10 instead. I find that even strong humans are often hesitant to play the aggressive bridge moves in situations like moves 12 and 14 here, probably because it looks like it's focusing too much on a single area of the board.
    • Here is yet another example (interestingly, White resigned in a winning position according to the bot, though the final position is highly tactical). KataHex actually thinks Black has only an 18% win rate after 26. m6. However, 27. d11 is a "minimaxing with adjacent stones" mistake, bringing Black's win rate down to 0.5%. After several inaccuracies from White, Black regained some lost ground in moves 28-32 and would have had a 30% win rate by connecting simply with 33. d13. On the other hand, KataHex thinks 33. i9 is an inaccurate attempt to minimax; the win rate is down to 9% after White replies with 34. d13.
  • Don't play a move that makes your opponent's existing stones unnecessarily well-placed relative to your new stone. This is covered briefly in a couple places in the 19×19 opening guide. Here are a couple more examples.
    • In this game (HexWorld link), what should Black play on move 27? White is threatening to connect 26 back to the 16–24 group if Black isn't careful. Black's obvious options are to play at c8 and c9. Which option is better?
    • A tempting answer is c8 because it appears to connect more closely to the top. However, note that White's stone on move 14 functions exactly like an opening a3 stone. For example, it can escape 2nd but not 3rd row ladders. If Black plays c8, White can play the A3 escape trick, as shown in this continuation. This sequence allows White to "make the most" of stone 14, and Black shouldn't allow it. Better for Black is 27. c9, which doesn't allow White to carry out a 3rd-to-5th row switchback. Indeed, KataHex evaluates c9 as 96% to win for Black and c8 as only 31%.
    • Consider this position (which is based on this game). Where should White play in the lower-right acute corner? Black had just played at the "3-7" point from White's perspective; as mentioned in the 19×19 opening guide, a strong response to 3-7 is 4-4 (at j10) instead of the usual 5-4 (at j9). A player who is short on time can play j10 without thinking too hard. As it turns out, KataHex thinks j10 is the best move, evaluating it as 85% for White, whereas j9 is only 38% because of Black's reply at j10.
  • Sometimes, you know you have a completely winning position after your opponent blunders very early in the game. Your goal is to preserve that win until the end of the game. Don't overextend yourself and try to win too "quickly", possibly making possibly suboptimal moves in the process. Even when KataHex plays itself with a significant handicap (like playing without swap), a significant fraction of the board seems necessary to carry out the win, assuming strong defense. I prefer taking my time to "fill the board" by focusing on playing moves at least as good as my opponent's, instead of worrying about connecting in as few moves as possible.

Joseki

  • The 4-3 corner move is almost always a mistake compared to the 5-4, even on 11×11. If your opponent plays 4-3, 90% of the time the best reply is 3-3. If 4-3 is played, here are some common sequences:
132
13524ab

In the second joseki, Blue should play either (a) or (b), or she can defer the question until later. On larger boards with no nearby stones, (b) is often better.

  • If your opponent plays the 5-4 joseki, a reasonable choice is to always play the 4-4 "high intrusion." KataHex prefers the 4-4 response by far, especially on 13×13 and larger. It's easily the "safest" choice, and many strong players have recently shown a clear preference for 4-4.
  • The following joseki seemed common among top players a couple years ago. However, Blue 4 is questionable, and Red 5 is also often worse than playing at one of (*). Even though Red has to defend a 3rd row ladder after playing at either (*), this is frequently preferable to letting Blue connect outright in the acute corner.
51324

TODO: advice on specific openings and board sizes