4.3 Microeconomic Mechanism
4.3.3 Utility Function
Whenever an intra- or inter- profile conflict is detected, user goals, such as availability of information for the ‘access proceedings’ service of the conference application, or privacy for the instant messaging functionality, must be taken into account. In other words, users should be allowed to influence the conflict resolution process operated by the middleware as they are the only ones who know what their goals are at that moment, and how different outcomes are valued.
Utility functions serve this purpose. A utility functionui translates peeri’s goals into a
valueui,j, that represents the price the peer is currently willing to pay to have policy pj
applied, that is, to see its goals fulfilled. The following holds:
ui,j ≥0, ∀i∈[1, n], j ∈[1, m].
As in human auctions, values cannot be negative; a valueui,j = 0 means that policypj is
not relevant to peeri, that is, the peer does not receive any benefit from applyingpj (this
is a plausible ‘machine’ representation of a human who refrains from bidding).
Utility functions varydynamicallyto reflect changes in the user goals; however, the value they return is computed overstatic policy specifications which estimate the consumption of resources that applying the policy entails, and thebenefits it gives in terms of quality- of-service. If R⊂Σ∗ defines the set of resource names that the middleware monitors, and Q⊂Σ∗ the set of benefits achieved by applying policies in P, then a policy specification can be described as a domain set:
PSPEC =℘({R∪Q} × level)
wherelevel ::= 010|. . .|0LMAX0 is an estimate of resource consumption/benefit achieved that the policy developers compute before delivering the policy. Policy specifications are therefore divided into two parts: one that provides an estimate of the consumption of resources that applying the policy would cause, and one that estimates the level of quality- of-service that is expected to result from the application of this policy. We assume these ratings are computed by policy developers and provided together with the policy code.
Chapter 4 4.3 Microeconomic Mechanism
The more accurate these ratings are, the more faithfully user goals will be translated into bids; however, we do not require these numbers to be ‘absolute’, so that the specifications of all possible policies can be compared. The accuracy of estimates is local to the policies associated with a service. For example, the estimated consumption of battery to send en- crypted messages must be higher than the one estimated to send plain messages; however, we do not care how battery consumption for the ‘encryptedMsg’ policy of the ‘messaging’ service compares to the ‘cacheAbstract’ policy of the ‘access proceedings’ service.
For each application, a utility function is then defined that makes explicit the resources the user is interested in preserving, and the quality-of-service parameters he/she wishes to achieve. Users associate weights with each of these resources/parameters that represent the importance they attribute to them (the higher the weight, the more important the resource/QoS parameter). The abstract syntax of a utility function is given in Figure 4.8, wherecb name∈(R∪Q) is a name that uniquely identifies a resource or benefit inside a policy specification, and weight::= 010|. . .|0WMAX0 represents the importance the user associates with a particular resource/benefit.
uf unction ::= addendList |ε
addendList ::= addend addendList |addend addend ::= cb name weight
Figure 4.8: Utility Function Abstract Syntax.
Both the resources/benefits listed in an utility function, and the weights associated with them, may vary over time, in order to represent current user needs, with regard to a par- ticular application, as faithfully as possible. Although we consider the issue of generating weights that represent user needs as faithfully as possible a matter of future research, we will give a flavour of how these numbers can be obtained from users and be directly used in Chapter 6.
Whenever a peer peeri is involved in a bidding process, its utility function is retrieved
and used to find the peer utility value ui,j for each conflicting policy pj. The semantics
of a utility function is presented in Figure 4.9. The following auxiliary functions have been used: S : (R∪Q)→PSPEC→level, that, given a resource/benefit namecb name, and a policy specification ps, fetches the level associated with cb name in ps (if the utility function tries to retrieve a value for a resource/benefit that does not appear in the policy specification, the returned value is 0). intval is a function that, given a literal in {010, . . . ,0MAX0}, returns the corresponding integer value in [1,MAX]. LM AX∗W M AX∗
RQM AX represents the maximum bid an application can place, whereRQM AX is the maximum number of resources/benefits of interest to an application.
Chapter 4 4.3 Microeconomic Mechanism
U : uf unction→PSPEC→ R+
U[[addend addendList]]ps = U[[addend]]ps + U[[addendList]]ps U[[addend]]ps = U[[cb name weight]]ps
U[[cb name weight]]ps = intval(S[[cb name]]ps) ∗ intval(weight)
LM AX∗W M AX ∗RQM AX ,
U[[ε]]ps = 0
Figure 4.9: Semantics of Utility Functions.
level(i.e., policy developer’s estimate) is fetched from a policy specification. This value is then multiplied by theweightthe user has associated with this resource/benefit in the util- ity function (the higher the multiplying factor, the more important the resource/benefit). These values are then added, and the sum is returned and interpreted as the price the ap- plication is willing to pay to have that policy applied. As shown, each value is normalised to vary in a range [0,1], so that different bids can be compared effectively, and money fairly redistributed (see Section 4.3.4).
Note that, to avoid incompatibility among the prices bid during a conflict resolution process, utility functions are locked at the beginning of an auction, and cannot be modified until the auction finishes. Thus, applications cannot ‘cheat’ and associate high bids with the policies they value most, while bidding zero for the others, to increase the chances of having the policy they value most finally applied, as this would require applications to change the weights of their utility functions during the auction.