Direct Democracy

Version 1.o


This scenario is my first attempt to write a Unity3D interface using Unity3D's ML-Agents package.

The player votes on bills to change the law to its preference. In this scenario, the only preference is a target price for energy. The only effects that a bill can have are to increase, decrease, or set the price. Only the system can propose a bill. The only actions that a player can take are to vote or not vote.

In each game, the preferred price, initial price, and the bill effects are random.

Technical Goals:

  1. Technical proof of concept showing integration of:

      1. Unity3D 2021.b5

      2. Unity's ML-Agents AI 15.1

      3. Python 3.7

      4. TensorFlow 1.7

  2. Create an initial framework for voting based on player preferences.

      1. Player

      2. Preferences

      3. Vote Actions

      4. Bill

      5. Law

      6. Score

  3. Train an AI neural network to understand voting based on its preferences.

Each Round:

  1. A bill is proposed by the system. The bill can:

    1. Increase the price

    2. Decrease the price

    3. Set the price

  2. For each bill, the player's options are to:

    1. Vote Yea

    2. Vote Nay

    3. Vote Abstain

    4. Do nothing

  3. If the bill passes:

    1. Then it becomes a law, and the current price is modified.

    2. Other wise, nothing happens

  4. The player's score is updated.

    1. Good move points are given for:

      1. Moving the price closer to the player's preference.

    2. Bad move points are given for:

      1. Moving the price farther from the player's preference.

Comparing players:

  1. Number of bad moves

  2. The ratio of good moves to bad moves