Getting Started: Elise Basics

Beginning a new game

After booting Elise, to begin a game you should click "Start game..." from the Game menu. This will bring up a dropdown menu from which you select the type of game you want to analyze, and also set the number of players in the game.

The game types in the dropdown are defined in the "games.definition" file in your Elise install folder. This is a text file that you can edit to define your own crossword games. See this page for further information.

Elise will then load the default word list for the game type, and also any rack statistics that exist for the word list. When it is done, you will be greeted by a screen that looks something like this:

Start screen (click for full size image)

On the left is the board for the game type. On the right, you see the player's names, scores and racks, and below that is the text pane. Most text messages from Elise, including analysis results, will appear in the text pane. You can scroll the text pane by clicking the arrows at the top or bottom.

Everything resizes if your window size changes, and it's possible that in small Elise windows the text in the text pane becomes truncated. If this happens, you can turn on "Force wide text pane" from the Board menu (or press Ctrl+T) to make the text pane wide again (it will steal the screen "real estate" from the board).

You can copy the contents of the text pane to the clipboard. Ctrl+C copies the visible text in the text pane, while Ctrl+Insert copies the entire text of the text pane, right back to the beginning of your Elise session.

Shift+B (or "Print board to text pane" from the Board menu) will copy a text representation of the current board into the text pane. This makes it easy to share the board position with others, as you can copy it from the text pane into the clipboard and paste wherever. (The characters used to represent the bonus squares come from the game definition -- you can edit them if you like. Blank tiles are shown in lowercase, other tiles are in uppercase.)

Shift+W (or "Well contents" from the Game menu) will place the distribution of unseen tiles into the text pane. In crossword games where racks are open (you can see what's on every player's rack), this will be exactly the remaining contents of the bag. In games with hidden opponent racks, this will be all unseen tiles, including both the remaining bag contents and the tiles on your opponents' racks.

Click for more information

You can right-click various objects to see more information about them. For example, if you right-click a tile (either on your rack or on the board), the number of unseen tiles of that type appears in the text pane. Right-clicking on an empty square in the board shows legal tile hooks in both directions. Right-clicking an active simulation move prints more statistics about the simulation.

If you mouse over a played word on the board, you may notice it highlighted in yellow. If you left-click the word, a definition for the word appears in the text pane. (If you are playing Clabbers or another game where anagrams of dictionary words are valid plays, then instead of a dictionary definition, you are shown a legal word to which the move anagrams.)

Player racks

Ctrl+R ("Set rack..." from the rack menu) is the most direct way to set the contents of your rack. You just type the tiles you want on the rack, using "?" for the blank. Note that you are not forced to adhere to the distribution of remaining tiles or even the rules of the game: so, for example, you can set a rack in standard Scrabble® that contains four zees and eleven tiles total.

If opponent racks are hidden in your crossword game, you can only set the current player's rack. If opponent racks are openly displayed, you can set any player's rack (this is important since any known opponent racks are used in simulation.) There are other options in the Rack menu that allow you to draw an entirely new rack from the well, or to fill a partial rack from the well.

You can shuffle the tiles on your rack by drag-and-drop, or you can press Shift+H ("Shuffle rack" from the Rack menu) to randomly shuffle their order.

Placing moves

There are three different ways to place moves on the board. The first way is to simply drag-and-drop your tiles where you want them on the board. The second way (generally faster) is to click on the board where you want the move to start. An arrow will appear. You can change the arrow from "across" to "down" by clicking the square again, or by pressing the space bar. If you type your move, the tiles appear on the board.

The arrow (left) and typing with the arrow (right)

You can press BACKSPACE to remove the last tile placed and back the arrow up. You can press ESC to remove all placed tiles from the board. You can also use the arrow keys to move the arrow around the board.

To play a blank using the arrow, press the question mark "?"; a window will pop up asking which letter the blank should represent. (This also appears if you drag-and-drop a blank from your rack.)

The third way to place a move is to have Elise generate possible moves, and then click on a move displayed in the text pane (we'll examine that below.)

To commit a move that you've placed on the board (by either drag-and-drop or by using the arrow), press ENTER (or "Move" from the Move menu). The move will be scored, a new rack will be drawn, and the turn will pass to the next player. If you play an unacceptable word to the board, you will be warned but given the option to commit the move anyway. If the move violates the rules in some other way (for example, the move does not touch any other tiles or does not pass through the center square on the first turn) you cannot commit the move.

Important: By default, you can only type letters onto the board that appear on your rack, unless you have an available blank (in that case, the blank will be played as that letter.) If, however, you set "Free-form mode" from the Rack menu, then you can make any legal move, regardless of the contents of your rack or of the remaining well. This is helpful if you are trying to set up a game state quickly, or if you are having Elise play against an opponent whose rack is unknown.

Special moves, such as passing your turn with or without exchanging tiles, are accomplished by selecting "Exchange..." (Shift+X) or "Pass" (Shift+P) from the Move menu. If you are exchanging tiles, you will be asked which tiles to keep.

Undo and redo

Committed moves in Elise are placed on an undo stack. This stack is saved from the start of the session to the finish, even across multiple new games or game position loads. You can press Ctrl+Z to undo the previous move and Ctrl+Y to redo it. Note that (as of version 0.0.1) only committed moves are placed on the undo stack. New word list loads or new racks are not.

Other cosmetic and UI options

Instead of using "Player 1", "Player 2", etc. you can set the names of your players from "Player names..." in the Game menu.

Shift+L ("Show row/column labels" from the Board menu) draws row and column labels around the perimeter of the board.

The "Tiles" menu allows you to change the appearance of your tiles. You can choose from a variety of textures. You can choose custom solid colors for your tiles and the letters. You can choose whether to draw the tile score in the corner. You can also choose how played blank tiles are drawn: you can draw them as blank, or you can draw the letter that they represent, perhaps in a different color than the other tiles to make them easy to pick out.

Using quick move find

Elise can be asked to generate the possible moves from any position using the "Quick move find" (Shift+Q) option from the Move menu. Quick move find, as its name suggests, is nearly instantaneous (the exceptions would be cases like difficult endgame searches or games with unusually large racks, especially with lots of blanks).

The output of quick move find appears in the text pane. The output will look like this:

Sample "quick move find" output

For each move, the word is displayed (with letters represented by blank tiles in lowercase) in the first column. The second column gives the square where the move begins in a standard notation (in English-language play, rows are numbered top to bottom, columns are given letters from left to right) and its direction (across moves are displayed row first, down moves are displayed column first.) The third column is the score, and the final column shows the tiles left on the rack after making this move (if any).

The moves are sorted in order of quality, according to Elise's "best fast" move evaluation. See this page for more information about the "best fast" evaluation. Along with score, "best fast" evaluation takes into account the value of the remaining rack leave (considering the makeup of the well), bonus squares exposed or closed by the move, bingo lanes, and so on.

Moves are displayed 20 at a time. To see the next 20 moves, you can press the "y" key, or you can click on the "Type 'y' to see more moves" message in the text pane.

If you move your mouse pointer over a move, Elise will show you that move placed on the board. If you then click on the move, that move will be made.

Highlighted moves are shown on the board (click for full size)

Quick move generation can also generate end game moves. By default, in a 2-player end game (meaning the bag of tiles is empty), Elise's quick move find will use an exhaustive search to determine its best move. This search is not necessarily "greedy" (meaning that Elise does not necessarily maximize its final score or winning margin) but it should find a winning move, if one is possible.

Sample end game move output

Above is an example of Elise's output when generating end game moves. Moves #1-4 are colored green - these are winning moves; if you make those moves, your opponent cannot legally win or tie with their tiles. Moves #5-14 are colored red - these are moves that are not winning; if you make those moves, your opponent, with correct play, will win or tie. Moves #15-20 are colored white; this indicates that the end game code did not search under these moves. (Since winning moves were found, the search completed.) They may be winning or not winning.

As with regular quick game moves, moving the mouse cursor over an end game move shows its placement on the board, and clicking will commit the move.

By turning off "Quick move uses endgame code" in the Move menu, you can see how the moves are ordered by the regular "best fast" algorithms even during the end game.

Using simulation move find

Elise's quick move find is pretty strong and plays respectably well, however, Elise's simulation facilities play a much stronger game and can find clever moves that quick move would miss.

Elise's simulation works by "lookahead": first, Elise determines a set of moves that might be the best move (these are "candidate moves".) Then, for each candidate move, Elise plays the move on the board and gives random rack draws to its opponents. (The distribution of the opponent racks generated by lookahead may be totally random, or it may be influenced by a tile guess -- see the next section.) Elise then finds its opponents' best moves (using the quick algorithms) and plays them on the board. It plays ahead like this a set number of moves ("ply"), and then records the result. The entire process is repeated as many as thousands of times. The results from these lookahead simulations give Elise an expected range of possible game results from playing each candidate move. By comparing these results, Elise gradually eliminates weaker moves until it is left with one move that it is confident is the best.

To find simulation moves, select "Fast lookahead..." from the Move menu (or press Shift+F). This dialog appears:

The simulation dialog

In this dialog, you set the parameters of the lookahead simulation. The "number of ply" value gives the number of moves Elise looks ahead. In a two-player game, "3-ply" simulation would mean that the current turn is played, then your opponent's reply (ply 1), then your next turn (ply 2), then your opponent's next move (ply 3).

The higher the lookahead ply value, the stronger Elise's play. Over tournaments of hundreds of games, 4 ply simulation consistently beats 3 ply simulation, 5 ply consistently beats 4 ply, etc. The downside is that higher-ply simulations take longer than lower-ply simulations to finish.

By setting the ply to a very high value (30 ply, say, or more, depending on the number of tiles in the game) you can actually simulate to the end of the game every time. Be aware that this will be quite slow on most machines, with simulations taking several minutes at least to finish.

The "number of threads" spin control allows to you set the number of threads, and correspondingly the maximum number of CPU cores, that Elise will use during the simulation. Elise's simulation is fully multi-threaded, and will take advantage of multiprocessor CPUs to allow for faster and deeper simulation. If you want to limit the amount of CPU resources that Elise uses, you can set this value lower; your simulation will be slower as a result.

The "Attempt to maximize" dropdown allows you to specify what Elise is trying to maximize in searching for an optimal move. "Win probability" attempts to maximize the estimated win probability. "Point spread" attempts to maximize the point spread of the position -- the difference between your score and your opponents'. Generally speaking, win probability is stronger for most games, however there are situations when maximizing for spread makes more sense. For example, if you are far, far ahead or far, far behind, the win probability for any move will be at or very near the extreme values (0% or 100%). Win probability simulations might take a long time to converge on a single move in those cases. Point spread optimization, however, may converge quickly and give you the best move in this situation.

If you want to limit the amount of time spent in simulation, you can select a time limit from the "Allow simulation to run" drop down. These time limits run from 30 seconds to 10 minutes. It is possible, of course, that with a time limit Elise does not get enough time to determine the best move with any confidence; this is especially likely if the number of candidate moves has not fallen significantly by the time simulation terminates.

The check box "Guess opponent's rack distribution" controls whether Elise will try to make a tile guess or not before commencing simulation. Tile guesses can improve the accuracy of Elise's simulation and the strength of its play. They will be discussed in more detail in the next section.

Elise during lookahead simulation

After you press "OK", Elise's simulation begins. Elise will periodically update the status of the simulation in the text pane, printing the current number of candidate moves. You can press the ESC key to terminate the simulation early.

If you press the TAB key, the board will disappear and in its place, the simulation results in progress will appear. These will update, showing you the current simulation status. If you press TAB again, you will return to the view of the board.

When the simulation finishes, the results are displayed similarly to quick move:

Results of lookahead simulation

There is some new information shown, however. Along with the word, the square played, and the score, towards the right we have two figures separated by a slash and a final value in parentheses. The first value (immediately to the left of the slash) is the average spread value -- that is, the average difference in score between you and your opponents. Positive indicates that, on average, you are ahead after that many ply, while negative indicates you are behind after that many ply. The second value, the percentage value to the right of the slash, is the estimated winning probability. In Scrabble®, Clabbers, and games with similar scoring, this is an estimate of the actual winning probability. In other games, this is actually the probability that you are in the lead after the number of ply simulated (for very high ply values or towards the end of the game, this is effectively the same thing as a true win probability.) The third number, in parentheses, is the number of simulations done for that candidate move.

Just as in quick move, hovering over a move in the text pane will show the move placed on the board, and clicking on the move commits it. Right-clicking on a simulation move will show you more information about the simulation, for example, the median spread value.

If you hold down the SHIFT button while previewing a simulation move, the board will be replaced with a heat map, showing the spaces your opponent is most likely to play in reply if you make the move. The top number in each square indicates the percentage of the time your opponent will play that square on his next turn, and the bottom number indicates the average score of your opponent's moves playing that tile.

Note that, in simulation, Elise is primarily interested in establishing which move is the best. It does not have the goal of getting the second-best, third-best, etc. moves in the correct order. This is why moves that are significantly weaker than the best move will normally get very few simulations, and while their rough order might be accurate, Elise's simulation does not attempt to find the exact placement and order of sub-optimal moves.

Tile guesses

Let's say it's the beginning of a game of Scrabble®, and your opponent has the first move. He plays SMILEY at 8G for 30 points, leaving one tile on his rack. What is that one tile?

Well, assuming that your opponent is a strong player and unlikely to miss a bingo, it's very unlikely that one tile is an S -- he could have played MESSILY for up to 82 points instead of SMILEY for 30. For the same reason, it's unlikely that leftover tile was the blank. And again, if he is a strong player, then surely the leftover tile was not an X -- then XYLEM for 50 points would have been possible, leaving quality tiles IS on the rack.

You can go through the whole alphabet that way, and it turns out that any of ABDFKMNPRSTUVWXYZ? are highly unlikely, assuming a strong opponent. With any of those tiles as the seventh opponent tile, there are several plays (sometimes dozens of plays) better than SMILEY 8G.

You can use that information to your advantage -- if your opponent didn't have any of those tiles leftover on his rack, then he is less likely than pure chance to hold them now. He might well have drawn some with those 6 tiles from the bag, of course, but you know he is less likely to hold any of those tiles than he would have been without the knowledge of his last play.

Elise can do this kind of tile guessing, and more. It considers its opponents' previous moves, as well as previous exchanges and blank plays, to determine which tiles are more likely to be held by its opponents than chance and which tiles are less likely.

Here is an example output tile guess:

Sample tile guess output

First, the odds of the opponent holding each tile (based on the tile guesses) are compared to the odds of the opponent drawing the tile from the unknown tiles purely by chance, and each tile is displayed in four categories: "significantly more likely than chance", "more likely than chance", "less likely than chance", and "much less likely than chance".

The "most likely to least likely" line shows the tiles in order of the absolute probability of Elise's opponent holding at least one, according to the tile guesses, from most likely to least likely. In this case, "Q" is relatively more likely than chance to be on Elise's opponent's rack, and "L" is relatively less likely than chance to appear, but in absolute terms, "L" is still more likely to appear than "Q" on the opponent's rack because there are 4 ells in the bag and only 1 cue.

Note that "Y" appears in square brackets in the "most likely to least likely" line. This indicates that Elise thinks that "Y" had zero probability of being in its opponent's rack leave last turn. There might be one or more wyes on the opponent's rack now, of course, since tiles were drawn from the bag.

The final line of the tile guess gives you information about the expected value of the opponent's current rack. This is based on the rack statistics, and gives the opponent's rack's value compared to the overall average rack.

Elise's tile guesses are used when filling the opponent racks during simulation. They are especially valuable late in the game, when being able to successfully guess about the presence or absence of particular power tiles on the opposing rack may make the difference between winning or losing the game.

Now, it is true that, in making its tile guesses, Elise assumes its opponent is quite strong and does not ever miss big plays. In practice, this is a reasonable assumption -- although suboptimal move by its opponent might upset Elise's tile guesses, suboptimal play is also unlikely to beat Elise in any case.

Analyze any given move with simulation

Maybe you are trying to do some in-depth analysis on a game and have come across a difficult position. Two or more moves seem to be almost exactly as good. It would be swell to do tens of thousands of simulations on the moves quickly and determine which one is actually best. Or perhaps you want to analyze a move that contains a "phony" (an illegal word), and so does not appear in Elise's move generation.

This is where you might want to try Elise's "Analyze move..." function (on the Move menu, or press Shift+A).

The analyze move dialog

The dropdown allows you to select which move to analyze. This dropdown will be automatically populated with the top 50 moves (according to quick move find), as well as any move that you have placed on the board (but not committed). This move could include bogus words if desired; Elise will analyze that move under the assumption that it is not challenged.

Just as with lookahead move generation, you can specify the number of ply to lookahead, the number of threads to use, and whether to make a opponent tile guess or not. For deep analysis you may want to set the ply value high.

After you press "OK", Elise will begin simulation. It will continue until you stop it with the ESC key. Updates will be printed in the text pane about every 1,000 simulations with information about the simulation.

Sample output from move analysis

As of version 0.1.8, you can press TAB to see more detailed information about the move -- which opponent replies are most likely and most dangerous, your bingo probability next turn and opponent's, etc. Pressing the SHIFT key will show you the heat map for the analyzed move.

After you press ESC, Elise will stop simulation and output a final update. This update will contain the mean point spread for the simulations (along with the standard deviation and a 2-standard deviation interval for the spread), the mean win probability (along with standard deviation and a 2-standard deviation interval), as well as the median, 25th and 75th percentile for the spread and win probability.

There's more!

These are the most basic and important functions you need to know about in order to use Elise. However, there are several other useful or interesting features of the engine: for example, it has a tournament mode in which it attempts to make all moves in a game within a certain amount of clock time. These additional features are described on the next page.