coredipper commited on
Commit
abea930
·
verified ·
1 Parent(s): 96fec0d

Upload folder using huggingface_hub

Browse files
Files changed (2) hide show
  1. __pycache__/app.cpython-314.pyc +0 -0
  2. app.py +33 -0
__pycache__/app.cpython-314.pyc CHANGED
Binary files a/__pycache__/app.cpython-314.pyc and b/__pycache__/app.cpython-314.pyc differ
 
app.py CHANGED
@@ -101,6 +101,39 @@ PRESETS: dict[str, dict] = {
101
  "strategy": "Threshold",
102
  "threshold": "2",
103
  },
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
104
  }
105
 
106
  STRATEGY_MAP = {
 
101
  "strategy": "Threshold",
102
  "threshold": "2",
103
  },
104
+ "Byzantine voting": {
105
+ "agents": [
106
+ ("Malicious-1", 2.0, "Block", 0.95),
107
+ ("Malicious-2", 2.0, "Block", 0.90),
108
+ ("Honest-1", 1.0, "Permit", 0.85),
109
+ ("Honest-2", 1.0, "Permit", 0.80),
110
+ ("Honest-3", 1.0, "Permit", 0.75),
111
+ ],
112
+ "strategy": "Weighted",
113
+ "threshold": "",
114
+ },
115
+ "Abstention majority": {
116
+ "agents": [
117
+ ("Abstainer-1", 1.0, "Abstain", 0.50),
118
+ ("Abstainer-2", 1.0, "Abstain", 0.50),
119
+ ("Abstainer-3", 1.0, "Abstain", 0.50),
120
+ ("Voter-1", 1.0, "Permit", 0.80),
121
+ ("Voter-2", 1.0, "Block", 0.85),
122
+ ],
123
+ "strategy": "Threshold",
124
+ "threshold": "1",
125
+ },
126
+ "Dictatorial weight": {
127
+ "agents": [
128
+ ("Dictator", 100.0, "Block", 0.99),
129
+ ("Citizen-1", 1.0, "Permit", 0.90),
130
+ ("Citizen-2", 1.0, "Permit", 0.85),
131
+ ("Citizen-3", 1.0, "Permit", 0.80),
132
+ ("Citizen-4", 1.0, "Permit", 0.75),
133
+ ],
134
+ "strategy": "Weighted",
135
+ "threshold": "",
136
+ },
137
  }
138
 
139
  STRATEGY_MAP = {