public final class BoaParty extends AbstractNegotiationParty
BoaPartyRepItem
. not for inclusion in a repository or extending.
This is converted from BOAagent
and TheBOAagent
For more information, see: Baarslag T., Hindriks K.V., Hendrikx M.,
Dirkzwager A., Jonker C.M. Decoupling Negotiating Agents to Explore the Space
of Negotiation Strategies. Proceedings of The Fifth International Workshop on
Agent-based Complex Automated Negotiations (ACAN 2012), 2012.
http://mmi.tudelft.nl/sites/default/files/boa.pdfModifier and Type | Field and Description |
---|---|
protected AcceptanceStrategy |
acceptConditions
Decides when to accept
|
protected NegotiationSession |
negotiationSession
Links to the negotiation domain
|
protected OfferingStrategy |
offeringStrategy
Decides what to offer
|
protected OMStrategy |
omStrategy
Selects which bid to send when using an opponent model
|
protected OpponentModel |
opponentModel
Approximates the utility of a bid for the opponent
|
protected OutcomeSpace |
outcomeSpace
Contains the space of possible bids
|
java.util.ArrayList<Pair<Bid,java.lang.String>> |
savedOutcomes
Store
Multi_AcceptanceCondition outcomes |
deadlines, rand, timeline, utilitySpace
Constructor and Description |
---|
BoaParty(AcceptanceStrategy ac,
java.util.Map<java.lang.String,java.lang.Double> acParams,
OfferingStrategy os,
java.util.Map<java.lang.String,java.lang.Double> osParams,
OpponentModel om,
java.util.Map<java.lang.String,java.lang.Double> omParams,
OMStrategy oms,
java.util.Map<java.lang.String,java.lang.Double> omsParams)
Stores all relevant values for initializing the components.
|
Modifier and Type | Method and Description |
---|---|
Action |
chooseAction(java.util.List<java.lang.Class<? extends Action>> possibleActions)
Chooses an action to perform.
|
void |
cleanUp()
Clears the agent's variables.
|
void |
endSession(NegotiationResult result)
Method that first calls the endSession method of each component to
receiveMessage the session data and then stores the session data if it is
not empty and is changed.
|
AcceptanceStrategy |
getAcceptanceStrategy()
Returns the acceptance strategy of the agent.
|
java.lang.String |
getDescription() |
OfferingStrategy |
getOfferingStrategy()
Returns the offering strategy of the agent.
|
OpponentModel |
getOpponentModel()
Returns the opponent model of the agent.
|
void |
init(AbstractUtilitySpace utilSpace,
Deadline dl,
TimeLineInfo tl,
long randomSeed,
AgentID agentId,
PersistentDataContainer data)
Initializes the agent and creates a new negotiation session object.
|
void |
receiveMessage(AgentID sender,
Action opponentAction)
Stores the actions made by a partner.
|
generateRandomBid, getData, getLastReceivedAction, getNumberOfParties, getPartyId, getProtocol, getRandomValue, getTimeLine, getUtility, getUtilitySpace, getUtilityWithDiscount, negotiationEnded, toString
protected AcceptanceStrategy acceptConditions
protected OfferingStrategy offeringStrategy
protected OpponentModel opponentModel
protected OMStrategy omStrategy
protected NegotiationSession negotiationSession
public java.util.ArrayList<Pair<Bid,java.lang.String>> savedOutcomes
Multi_AcceptanceCondition
outcomesprotected OutcomeSpace outcomeSpace
public BoaParty(AcceptanceStrategy ac, java.util.Map<java.lang.String,java.lang.Double> acParams, OfferingStrategy os, java.util.Map<java.lang.String,java.lang.Double> osParams, OpponentModel om, java.util.Map<java.lang.String,java.lang.Double> omParams, OMStrategy oms, java.util.Map<java.lang.String,java.lang.Double> omsParams)
ac
- acParams
- os
- osParams
- om
- omParams
- oms
- omsParams
- public void init(AbstractUtilitySpace utilSpace, Deadline dl, TimeLineInfo tl, long randomSeed, AgentID agentId, PersistentDataContainer data)
init
in interface NegotiationParty
init
in class AbstractNegotiationParty
utilSpace
- (a copy of/readonly version of) the
AbstractUtilitySpace
to be used for this session.dl
- The deadline used for this negotiation.tl
- The TimeLineInfo
about current session.randomSeed
- A random seed that can be used for creating "consistent
random" behaviour.agentId
- The agent's ID.data
- storage space where the agent can store data that is
persistent over sessions. Depending on the run settings, each
[agentclass, profiles] tuple can have its own unique storage
that persists only during the run of a tournament. Between
sessions, this data is saved to disk to avoid memory issues
when other agents are running. If the storage is not empty,
this data is retrieved at the start of each session and saved
at the end of each session. The load is timeboxed by the
negotiation settings. The save time is limited to 1 second.
The programmer should ensure that storage is actually
serializable. This call is timeboxed by the negotiation
deadline settings.public void receiveMessage(AgentID sender, Action opponentAction)
receiveMessage
in interface NegotiationParty
receiveMessage
in class AbstractNegotiationParty
opponentAction
- by opponent in current turnsender
- The initiator of the action.This is either the AgentID, or
null if the sender is not an agent (e.g., the protocol).public Action chooseAction(java.util.List<java.lang.Class<? extends Action>> possibleActions)
possibleActions
- List of all actions possible.public OfferingStrategy getOfferingStrategy()
public OpponentModel getOpponentModel()
public AcceptanceStrategy getAcceptanceStrategy()
public void endSession(NegotiationResult result)
public void cleanUp()
public java.lang.String getDescription()