The random instance generator and other improvements.
[match/match.git] / program / ProposalMatcherConfig.hs
CommitLineData
967c39ef
MM
1module ProposalMatcherConfig where
2import Instance
d7d9561e 3
2e7d5426 4type Pref = Int
2e7d5426
MM
5
6numAsWt x = fromInteger (toInteger x) :: Wt
7
8reviewsEachProposal = 3 :: Int
9
d7d9561e 10prefIsExpert p = p <= 10
2e7d5426
MM
11prefIsKnowledgeable p = p <= 20
12
13prefIsBoring p = p > 15
14prefIsVeryBoring p = p > 25
15
d7d9561e
MM
16prefIsConflict p = p >= 40
17
2e7d5426
MM
18-- For now this is absolute. Later it might be proportional to a reviewer's
19-- target load.
20loadTolerance = 1 :: Int
d7d9561e 21
2e7d5426
MM
22-- Cost to overload by one review.
23-- tx = 0 at target load, 1 at end of tolerance.
24marginalLoadCost tx = 1000 + tx*1000 :: Wt
25
26-- Cost to review a boring (or very boring) proposal.
27-- lx = 0 at no load, 1 at target load.
28marginalBoringCost lx = 1000 + lx*1000 :: Wt
29-- Additional cost to review a very boring proposal.
30marginalVeryBoringCost lx = 1000 + lx*1000 :: Wt
31
32-- Cost to make a review.
d7d9561e 33-- I'm using quadratic cost functions as a first attempt.
2e7d5426
MM
34assignmentCost pref = (numAsWt 10 + pref) ^ 2 :: Wt
35
36-- Bonus for a first knowledgeable or expert review.
37knowledgeableBonus = 1000 :: Wt
38
39-- Bonus for an additional expert review.
40expertBonus = 1000 :: Wt