@@ -6,18 +6,13 @@ The extensive game (.efg) file format
66The extensive game (.efg) file format has been used by Gambit, with
77minor variations, to represent extensive games since circa 1994. It
88replaced an earlier format, which had no particular name but which had
9- the conventional extension .dt1. It is intended that some new formats
10- will be introduced in the future; however, this format will be
11- supported by Gambit, possibly through the use of converter programs to
12- those putative future formats, for the foreseeable future.
9+ the conventional extension .dt1.
1310
1411
1512A sample file
1613-------------
1714
18- This is a sample file illustrating the general format of the file.
19- This file is similar to the one distributed in the Gambit distribution
20- under the name bayes1a.efg::
15+ This is a sample file illustrating the general format of the file::
2116
2217 EFG 2 R "General Bayes game, one stage" { "Player 1" "Player 2" }
2318 c "ROOT" 1 "(0,1)" { "1G" 0.500000 "1B" 0.500000 } 0
@@ -53,8 +48,6 @@ under the name bayes1a.efg::
5348 t "" 16 "Outcome 16" { 10.000000 0.000000 }
5449
5550
56-
57-
5851Structure of the prologue
5952-------------------------
6053
@@ -97,11 +90,9 @@ of one line per node.
9790Each node entry begins with an unquoted character indicating the type
9891of the node. There are three node types:
9992
100-
101-
102- + c for a chance node
103- + p for a personal player node
104- + t for a terminal node
93+ + `c ` for a chance node
94+ + `p ` for a personal player node
95+ + `t ` for a terminal node
10596
10697Each node type will be discussed individually below. There are three
10798numbering conventions which are used to identify the information
@@ -116,19 +107,21 @@ integer may be used to specify information sets for different players;
116107this is not ambiguous since the player number appears as well.
117108Finally, outcomes are also arbitrarily numbered in the file format in
118109the same way in which information sets are, except for the special
119- number 0 which indicates the null outcome.
110+ number 0 which is reserved to indicate the null outcome.
111+ Outcome 0 must not have a name or payoffs specified.
120112
121113Information sets and outcomes may (and frequently will) appear
122114multiple times within a game. By convention, the second and subsequent
123115times an information set or outcome appears, the file may omit the
124116descriptive information for that information set or outcome.
125117Alternatively, the file may specify the descriptive information again;
126118however, it must precisely match the original declaration of the
127- information set or outcome. If any part of the description is omitted,
128- the whole description must be omitted.
119+ information set or outcome. Any mismatch in repeated declarations
120+ is an error, and the file is not valid.
121+ If any part of the description is omitted, the whole description must be omitted.
129122
130123Outcomes may appear at nonterminal nodes. In these cases, payoffs are
131- interepreted as incremental payoffs; the payoff to a player for a
124+ interpreted as incremental payoffs; the payoff to a player for a
132125given path through the tree is interpreted as the sum of the payoffs
133126at the outcomes encountered on that path (including at the terminal
134127node). This is ideal for the representation of games with well-
@@ -146,41 +139,28 @@ with the character c . Following this, in order, are
146139
147140+ a text string, giving the name of the node
148141+ a positive integer specifying the information set number
149- + (optional) the name of the information set
150- + (optional) a list of actions at the information set with their
142+ + (optional) the name of the information set and a list of actions at the information set with their
151143 corresponding probabilities
152144+ a nonnegative integer specifying the outcome
153- + (optional)the payoffs to each player for the outcome
154-
155-
145+ + (optional) the name of the outcome and the payoffs to each player for the outcome
156146
157147**Format of personal (player) nodes. ** Entries for personal player
158148decision nodes begin with the character p . Following this, in order,
159149are:
160150
161-
162-
163151+ a text string, giving the name of the node
164152+ a positive integer specifying the player who owns the node
165153+ a positive integer specifying the information set
166- + (optional) the name of the information set
167- + (optional) a list of action names for the information set
154+ + (optional) the name of the information set and a list of action names for the information set
168155+ a nonnegative integer specifying the outcome
169- + (optional) the name of the outcome
170- + the payoffs to each player for the outcome
171-
156+ + (optional) the name of the outcome and the payoffs to each player for the outcome
172157
173158
174159**Format of terminal nodes. ** Entries for terminal nodes begin with
175160the character t . Following this, in order, are:
176161
177-
178-
179162+ a text string, giving the name of the node
180163+ a nonnegative integer specifying the outcome
181- + (optional) the name of the outcome
182- + the payoffs to each player for the outcome
183-
184-
164+ + (optional) the name of the outcome and the payoffs to each player for the outcome
185165
186166There is no explicit end-of-file delimiter for the file.
0 commit comments