-
Notifications
You must be signed in to change notification settings - Fork 16
Open
Labels
Description
We want to to experiments like:
we have 10.000 users, rep and tokens distributed random, and now 3.000 users all vote alike on each contribution. What happens?
The idea is to have a library/class that
- allows for for easy defining "scenarios"
- runs them quicky (seconds range)
- give some feedback while running (see below)
- allow for saving the results of the simulation in a CSV file for further analysis or presentation
example session
> python ./simulations/majority_attack.py
setting up ...
... add 1000 users ...
... user1 has 51% rep ...
STEP 1. user1 adds contribution and votes for it
--user ------------------------------
| user1 | user2 | .....
REP | 0.5122 | 0.0001 | ...
TOK | 12 | 1 | ...
----------------------------
STEP 2. user1 adds contribution and votes for it
--------------------------------
| user1 | user2 | .....
REP | 0.5134 | 0.0001 | ...
TOK | 11.56 | 1 | ...
----------------------------
example csv output
STEP, DESCRIPTION, user1.rep, user1.tokens, user2.rep, user2.tokens, ...
1,user1 add contrib and votes for 1, 0.5122, 12, 0.0001,1
2,user1 add contrib and votes for 1, 0.5134, 11.56, 0.0001,1
example scenario definitoin
[to be done]