[39] | 1 | package geniusweb.opponentmodel;
|
---|
| 2 |
|
---|
| 3 | import geniusweb.actions.Action;
|
---|
| 4 | import geniusweb.issuevalue.Bid;
|
---|
| 5 | import geniusweb.issuevalue.Domain;
|
---|
| 6 | import geniusweb.profile.Profile;
|
---|
| 7 | import geniusweb.profile.utilityspace.UtilitySpace;
|
---|
| 8 | import geniusweb.progress.Progress;
|
---|
| 9 | import geniusweb.references.Parameters;
|
---|
| 10 |
|
---|
| 11 | /**
|
---|
| 12 | * An opponentmodel estimates a {@link UtilitySpace} from received opponent
|
---|
| 13 | * actions.
|
---|
| 14 | * <h2>Requirement</h2> A OpponentModel must have a constructor that takes the
|
---|
| 15 | * Domain as argument. unfortunately this can not be enforced in a java
|
---|
| 16 | * interface
|
---|
| 17 | *
|
---|
| 18 | * <p>
|
---|
| 19 | * <em>MUST</em> have an empty constructor as these are also used as part of the
|
---|
| 20 | * BOA framework.
|
---|
| 21 | *
|
---|
| 22 | */
|
---|
| 23 | public interface OpponentModel extends Profile {
|
---|
| 24 |
|
---|
| 25 | /**
|
---|
| 26 | * Initializes the model. This function must be called first after
|
---|
| 27 | * constructing an instance. It can also be called again later, if there is
|
---|
| 28 | * a change in the domain or resBid.
|
---|
| 29 | * <p>
|
---|
| 30 | * This late-initialization is to support boa models that have late
|
---|
| 31 | * initialization.
|
---|
| 32 | *
|
---|
| 33 | * @param domain the domain to work with. Must be not null.
|
---|
| 34 | * @param resBid the reservation bid, or null if no reservationbid is
|
---|
| 35 | * available.
|
---|
| 36 | * @return OpponentModel that uses given domain and reservationbid.
|
---|
| 37 | *
|
---|
| 38 | */
|
---|
| 39 | OpponentModel with(Domain domain, Bid resBid);
|
---|
| 40 |
|
---|
| 41 | /**
|
---|
| 42 | *
|
---|
| 43 | * @param parameters Opponent-model specific {@link Parameters}
|
---|
| 44 | * @return an updated OpponentMode, with parameters used. Each
|
---|
| 45 | * implementation of OpponentModel is free to use parameters as it
|
---|
| 46 | * likes. For instance to set learning speed.
|
---|
| 47 | */
|
---|
| 48 | OpponentModel with(Parameters parameters);
|
---|
| 49 |
|
---|
| 50 | /**
|
---|
| 51 | * Update this with a new action that was done by the opponent that this
|
---|
| 52 | * model is modeling. {@link #with(Domain, Bid)} must be called before
|
---|
| 53 | * calling this.
|
---|
| 54 | *
|
---|
| 55 | * @param action the new incoming action.
|
---|
| 56 | * @param progress the current progress of the negotiation. Calls to this
|
---|
| 57 | * must be done with increasing progress.
|
---|
| 58 | * @return the updated {@link OpponentModel}
|
---|
| 59 | */
|
---|
| 60 | OpponentModel with(Action action, Progress progress);
|
---|
| 61 |
|
---|
| 62 | }
|
---|