Lab 8: Competing learning agents negotiate a territory

5DV248 - Competition and coordination (Wooldridge social ability; syllabus FSR 5 and FSR 8). BLUE and PURPLE are two Q-learning agents competing for gems. At the start of each match the current leader may PROPOSE a territorial split; the other accepts or rejects by expected utility. Self-interest plus communication = a market.
The contest arena

Negotiation enabled (PROPOSE / ACCEPT / REJECT)
Negotiation log (FIPA ACL performatives)
Score per match (gems collected)

Without an accepted proposal the arena is a free contest: both agents race to the same gems and waste steps. Communication between self-interested agents does not imply kindness - the proposer tries to keep the better half, and the receiver only accepts offers it expects to beat its contest share.