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