source: src/main/java/agents/ImmediateAcceptor.java@ 126

Last change on this file since 126 was 126, checked in by Aron Hammond, 6 years ago

Added function to calculate opposition to MultiLateralAnalysis.java

Moved code to add RLBOA listeners to RLBOAUtils is misc package

Added input for strategyParameters to SessionPanel (gui)

!! close SessionInfo after tournament; this caused /tmp/ to fill up with GeniusData files

Our own package:

  • Added opponents and strategies that are mentioned in the report
  • Change class hierarchy, agents can now extend from RLBOAagentBilateral to inherit RL functionality.
  • States extend from AbstractState
File size: 890 bytes
Line 
1package agents;
2
3import genius.core.Bid;
4import genius.core.SupportedNegotiationSetting;
5
6/**
7 * This agent does not concede, but will accept anything equal to or above the
8 * reservation value. For undiscounted domain only.
9 */
10public class ImmediateAcceptor extends TimeDependentAgent {
11 @Override
12 public double getE() {
13 return 0;
14 }
15
16 @Override
17 public String getName() {
18 return "Immediate Acceptor";
19 }
20
21 @Override
22 public boolean isAcceptable(Bid plannedBid) {
23 Bid opponentLastBid = getOpponentLastBid();
24 if (getUtility(opponentLastBid) >= utilitySpace.getReservationValue())
25 return true;
26 return false;
27 }
28
29 @Override
30 public SupportedNegotiationSetting getSupportedNegotiationSetting() {
31 return SupportedNegotiationSetting.getLinearUtilitySpaceInstance();
32 }
33
34 @Override
35 public String getDescription() {
36 return "accept when offer is above reservation value";
37 }
38
39}
Note: See TracBrowser for help on using the repository browser.