Changes between Version 194 and Version 195 of WikiStart
- Timestamp:
- 06/26/19 13:27:02 (5 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
WikiStart
v194 v195 1 1 [[PageOutline]] 2 2 3 = GENIUS 2=4 Genius2is an open architecture for heterogeneous negotiating parties via the internet. It provides the basis for an implementation of a testbed for negotiating parties that includes a set of negotiation problems for benchmarking parties, a library of negotiation strategies, and analytical tools to evaluate an party's performance and their strategies allows user.5 6 == Genius 2overview7 Genius 2contains a number of components3 = GENIUS WEB = 4 ''GeniusWeb'' is an open architecture for heterogeneous negotiating parties via the internet. It provides the basis for an implementation of a testbed for negotiating parties that includes a set of negotiation problems for benchmarking parties, a library of negotiation strategies, and analytical tools to evaluate an party's performance and their strategies allows user. 5 6 == GeniusWeb overview 7 GeniusWeb contains a number of components 8 8 9 9 ||= name =||= description =||= more information =|| … … 18 18 For creating your own profile or party, you only need the core. 19 19 20 If you want to get a quick top-down idea how Genius 2works, we suggest to install the servers and contact the runserver to run a session.20 If you want to get a quick top-down idea how GeniusWeb works, we suggest to install the servers and contact the runserver to run a session. 21 21 22 22 == Installation 23 The Genius 2core code does not need to be installed.23 The GeniusWeb core code does not need to be installed. 24 24 Check the profilesserver, partiesserver and runserver wiki pages (see above) for installation details. 25 25 … … 41 41 This section gives an overview of the core functionalties. 42 42 43 The image below gives an overview class diagram with the genius2core modules and their functionalities. The figure also shows43 The image below gives an overview class diagram with the GeniusWeb core modules and their functionalities. The figure also shows 44 44 the 3 servers and the functions inside those. Click on the figure to zoom in. 45 45 … … 55 55 Your party can create any bid that it likes but the protocol will check if your bid fits in the current negotiation and may kick you out of the negotiation if you don't behave properly. 56 56 57 In Genius 2, all number values are processed as BigDecimal to avoid rounding errors.57 In GeniusWeb, all number values are processed as BigDecimal to avoid rounding errors. 58 58 59 59 == profile 60 60 A profile is a function that can tell if a bid is preferred over another bid. 61 61 There are a number of ways to do this: 62 * [source:profile/src/main/java/genius 2/profile/FullOrdering.java FullOrdering]: this provides a function {{{isPreferredOrEqual()}}} that can tell if a bid is preferred over another63 * [source:profile/src/main/java/genius 2/profile/PartialOrdering.java PartialOrdering]: as {{{FullyOrderedSpace}}}, but may not know the answer for part of the bids64 * [source:profile/src/main/java/genius 2/profile/utilityspace/UtilitySpace.java UtilitySpace]: as {{{FullOrdering}}}, but additionally this provides a function {{{getUtility(bid)}}} that maps the bid into a {{{BigDecimal}}} in [0,1]. The higher the value, the more preferred is that bid. The [source:profile/src/main/java/genius2/profile/utilityspace/LinearAdditiveUtilitySpace.java Linear Additive Space] is the most commonly used UtilitySpace. If the accuracy of {{{BigDecimal}}} is not needed, you can just call {{{BigDecimal#doubleValue()}}} to get a standard double.62 * [source:profile/src/main/java/geniusweb/profile/FullOrdering.java FullOrdering]: this provides a function {{{isPreferredOrEqual()}}} that can tell if a bid is preferred over another 63 * [source:profile/src/main/java/geniusweb/profile/PartialOrdering.java PartialOrdering]: as {{{FullyOrderedSpace}}}, but may not know the answer for part of the bids 64 * [source:profile/src/main/java/geniusweb/profile/utilityspace/UtilitySpace.java UtilitySpace]: as {{{FullOrdering}}}, but additionally this provides a function {{{getUtility(bid)}}} that maps the bid into a {{{BigDecimal}}} in [0,1]. The higher the value, the more preferred is that bid. The [source:profile/src/main/java/geniusweb/profile/utilityspace/LinearAdditiveUtilitySpace.java Linear Additive Space] is the most commonly used UtilitySpace. If the accuracy of {{{BigDecimal}}} is not needed, you can just call {{{BigDecimal#doubleValue()}}} to get a standard double. 65 65 66 66 == Party … … 86 86 ||ws:||profile||ws://localhost:8080/profilesserver/websocket/get/jobs/jobs1.json|| || 87 87 ||file:||profile||file:src/test/settings.json ||gives file relative to local current working dir|| 88 ||classpath:||party||classpath:genius 2.exampleparties.randomparty.RandomParty||must be in classpath||88 ||classpath:||party||classpath:geniusweb.exampleparties.randomparty.RandomParty||must be in classpath|| 89 89 90 90 == BidSpace … … 101 101 102 102 The basic classes defining a protocol are: 103 * The [source:/protocol/src/main/java/genius 2/protocol/NegoSettings.java NegoSettings]: these define the settings for the protocol, such as the deadline, the participants and the profile104 * The [source:/protocol/src/main/java/genius 2/protocol/NegoState.java NegoState]: this contains the current state of execution of the protocol. To give some example states: "waiting for bid from party 2", "ended with agreement", "ended because party 1 broke the protocol". A state also has various {{{with()}}} functions defining the new state from an old state and a party doing an action.105 * The [source:/protocol/src/main/java/genius 2/protocol/NegoProtocol.java NegoProtocol]: this defines what happens when a negotiation starts, when a participant enters halfway the session, what are the allowed actions, what happens if a participant breaks the protocol, etc.103 * The [source:/protocol/src/main/java/geniusweb/protocol/NegoSettings.java NegoSettings]: these define the settings for the protocol, such as the deadline, the participants and the profile 104 * The [source:/protocol/src/main/java/geniusweb/protocol/NegoState.java NegoState]: this contains the current state of execution of the protocol. To give some example states: "waiting for bid from party 2", "ended with agreement", "ended because party 1 broke the protocol". A state also has various {{{with()}}} functions defining the new state from an old state and a party doing an action. 105 * The [source:/protocol/src/main/java/geniusweb/protocol/NegoProtocol.java NegoProtocol]: this defines what happens when a negotiation starts, when a participant enters halfway the session, what are the allowed actions, what happens if a participant breaks the protocol, etc. 106 106 107 107 … … 221 221 }}} 222 222 223 You need to wrap your python party into a jar wrapper to get it accepted by the parties server. To do this, check the javadoc with the [https://tracinsy.ewi.tudelft.nl/trac/Genius2/browser/pythonadapter/src/main/java/genius 2/pythonadapter/PythonPartyAdapter.java PythonPartyAdapter].223 You need to wrap your python party into a jar wrapper to get it accepted by the parties server. To do this, check the javadoc with the [https://tracinsy.ewi.tudelft.nl/trac/Genius2/browser/pythonadapter/src/main/java/geniusweb/pythonadapter/PythonPartyAdapter.java PythonPartyAdapter]. 224 224 225 225 226 226 = Writing a party in other languages 227 227 If you want to use another language than java or python2 to write your parties, you have a number of options 228 * Make your own adapter that runs your language from Java. Check [source:pythonadapter/src/main/java/genius 2/pythonadapter/PythonPartyAdapter.java our pythonadapter] for an example how this can be done.228 * Make your own adapter that runs your language from Java. Check [source:pythonadapter/src/main/java/geniusweb/pythonadapter/PythonPartyAdapter.java our pythonadapter] for an example how this can be done. 229 229 * Write your own partiesserver that correctly implements the [https://tracinsy.ewi.tudelft.nl/trac/Genius2PartiesServer partiesserver interface]. This boils down to creating a webserver that correctly can handle calls to a number of prescribed URLs and websockets. 230 230 … … 362 362 * The parties you want to run (in compiled form) must be in your classpath 363 363 * The profiles you want to provide to the parties (alternatively you can refer to a profile on a running profile server) 364 * A settings.json file containing the [https://tracinsy.ewi.tudelft.nl/trac/Genius2/browser/protocol/src/main/java/genius 2/protocol/session SessionSettings] eg SAOP Settings. [https://tracinsy.ewi.tudelft.nl/trac/Genius2/browser/simplerunner/src/test/resources/settings.json view example file].365 * a simple stand-alone runner, eg download from [http://artifactory.ewi.tudelft.nl/artifactory/libs-release/genius 2/simplerunner/ genius2artifactory] select latest version simplerunner-<latestversion>-jar-with-dependencies.jar.364 * A settings.json file containing the [https://tracinsy.ewi.tudelft.nl/trac/Genius2/browser/protocol/src/main/java/geniusweb/protocol/session SessionSettings] eg SAOP Settings. [https://tracinsy.ewi.tudelft.nl/trac/Genius2/browser/simplerunner/src/test/resources/settings.json view example file]. 365 * a simple stand-alone runner, eg download from [http://artifactory.ewi.tudelft.nl/artifactory/libs-release/geniusweb/simplerunner/ geniusweb artifactory] select latest version simplerunner-<latestversion>-jar-with-dependencies.jar. 366 366 367 367 A complete example is available [https://tracinsy.ewi.tudelft.nl/trac/Genius2/browser/simplerunner simplerunner here] … … 393 393 * With stand-alone runner, your parties are run together in a single classloader. This is different from running in the partiesserver. 394 394 395 = Genius 2sources =395 = GeniusWeb sources = 396 396 397 397 == downloading source code 398 You can browse the genius2core sources directly using the browse button at the right top of this page.398 You can browse the GeniusWeb core sources directly using the browse button at the right top of this page. 399 399 400 400 You can download the source code of this component from … … 402 402 https://tracinsy.ewi.tudelft.nl/svn/genius2/ 403 403 404 Normal developers that write new parties do not need to install the genius2 source code. This is only needed if you want to debug/trace into the genius2 code for instance for debugging or understanding the inner workings of genius2.404 Normal developers that write new parties do not need to install the GeniusWeb source code. This is only needed if you want to debug/trace into the GeniusWeb code for instance for debugging or understanding the inner workings of geniusWeb. 405 405 406 406 == Import all sources in Eclipse