Move param definitions to validation pool
This commit is contained in:
parent
b02efb66ad
commit
81823cd009
|
@ -1,10 +1,36 @@
|
|||
import { ReputationHolder } from '../reputation/reputation-holder.js';
|
||||
import { Stake } from '../supporting/stake.js';
|
||||
import { Voter } from '../supporting/voter.js';
|
||||
import params from '../../params.js';
|
||||
import { Action } from '../display/action.js';
|
||||
import { displayNumber } from '../../util/helpers.js';
|
||||
|
||||
const params = {
|
||||
/* Validation Pool parameters */
|
||||
mintingRatio: () => 1, // c1
|
||||
// NOTE: c2 overlaps with c3 and adds excess complexity, so we omit it for now
|
||||
stakeForAuthor: 0.5, // c3
|
||||
winningRatio: 0.5, // c4
|
||||
quorum: 0, // c5
|
||||
activeVoterThreshold: null, // c6
|
||||
voteDuration: {
|
||||
// c7
|
||||
min: 0,
|
||||
max: null,
|
||||
},
|
||||
// NOTE: c8 is the token loss ratio, which is specified as a runtime argument
|
||||
contentiousDebate: {
|
||||
period: 5000, // c9
|
||||
stages: 3, // c10
|
||||
},
|
||||
lockingTimeExponent: 0, // c11
|
||||
|
||||
/* Forum parameters */
|
||||
initialPostValue: () => 1, // q1
|
||||
revaluationLimit: 1, // q2
|
||||
referenceChainLimit: 3, // q3
|
||||
leachingValue: 1, // q4
|
||||
};
|
||||
|
||||
const ValidationPoolStates = Object.freeze({
|
||||
OPEN: 'OPEN',
|
||||
CLOSED: 'CLOSED',
|
||||
|
|
|
@ -1,28 +0,0 @@
|
|||
const params = {
|
||||
/* Validation Pool parameters */
|
||||
mintingRatio: () => 1, // c1
|
||||
// NOTE: c2 overlaps with c3 and adds excess complexity, so we omit it for now
|
||||
stakeForAuthor: 0.5, // c3
|
||||
winningRatio: 0.5, // c4
|
||||
quorum: 0, // c5
|
||||
activeVoterThreshold: null, // c6
|
||||
voteDuration: {
|
||||
// c7
|
||||
min: 0,
|
||||
max: null,
|
||||
},
|
||||
// NOTE: c8 is the token loss ratio, which is specified as a runtime argument
|
||||
contentiousDebate: {
|
||||
period: 5000, // c9
|
||||
stages: 3, // c10
|
||||
},
|
||||
lockingTimeExponent: 0, // c11
|
||||
|
||||
/* Forum parameters */
|
||||
initialPostValue: () => 1, // q1
|
||||
revaluationLimit: 1, // q2
|
||||
referenceChainLimit: 3, // q3
|
||||
leachingValue: 1, // q4
|
||||
};
|
||||
|
||||
export default params;
|
|
@ -2,7 +2,6 @@ import { Box } from '../../../classes/display/box.js';
|
|||
import { Scene } from '../../../classes/display/scene.js';
|
||||
import { Expert } from '../../../classes/actors/expert.js';
|
||||
import { PostContent } from '../../../classes/supporting/post-content.js';
|
||||
import params from '../../../params.js';
|
||||
import { DAO } from '../../../classes/dao/dao.js';
|
||||
import { delayOrWait } from '../../../classes/display/controls.js';
|
||||
|
||||
|
@ -77,14 +76,6 @@ export class ForumTest {
|
|||
scene.withFlowchart();
|
||||
scene.withTable();
|
||||
|
||||
scene.addDisplayValue('c3. stakeForAuthor').set(params.stakeForAuthor);
|
||||
scene.addDisplayValue('q2. revaluationLimit').set(params.revaluationLimit);
|
||||
scene
|
||||
.addDisplayValue('q3. referenceChainLimit')
|
||||
.set(params.referenceChainLimit);
|
||||
scene.addDisplayValue('q4. leachingValue').set(params.leachingValue);
|
||||
scene.addDisplayValue(' ');
|
||||
|
||||
// If we're going to announce experts, announce the DAO so it appears first.
|
||||
this.dao = new DAO('DAO', scene, { announce: this.options.displayAuthors });
|
||||
this.forum = this.dao.forum;
|
||||
|
|
Loading…
Reference in New Issue