Jun 19, 2008 - X-Hinter, we describe a Java API that provides a set of li- braries and tools to build social ... formation (e.g., eBlogger, MySpace, Facebook). People can ... uj is defined as the. 1http://wiki.limewire.org/index.php?title=Overview.
X-Hinter: a Framework for Implementing Social Oriented Recommender Systems André Panisson, Giancarlo Ruffo and Rossano Schifanella Dipartimento di Informatica, Università di Torino Corso Svizzera, 185 - 10149, Torino (ITALY)
{panisson,ruffo,schifane}@di.unito.it
ABSTRACT
gation of like minded people. Social networking and analysis [2] is a pretty mature field that gives tools and structures for detecting self organizing aggregations of users and for studying their structural properties. We developed a generalized model, called X-Hinter, that exploits the connectivity properties of a family of social networks, named Affinity Networks, to propose a connectioncentric recommender engine to be applied in a wide range of platforms. Moreover, we designed a Java API that provides a set of libraries and tools to build social recommender systems based on X-Hinter model. Finally, in order to endorse the functionality of such framework, we implemented a prototype of a recommender system, named DeHinter, on top of the Limewire1 Peer-to-Peer (P2P) file sharing application.
Accordingly to the nature of data-driven applications that produce information overload, users need a support to make choices, even without sufficient personal experience of the alternatives. In this context, social networking techniques could be useful applied for finding affinities between users and filter information in a personalized way. After proposing a generalized model for social recommender systems, called X-Hinter, we describe a Java API that provides a set of libraries and tools to build social filtering systems in a wide range of domains. A prototype implementation, named DeHinter, shows the feasibility of the proposed approach in a P2P file sharing application.
Categories and Subject Descriptors
2. THE X-HINTER MODEL
C.2.4 [Distributed Systems]: Distributed applications
To take advantage of social relationships, we need to define the concept of affinity among users. For this purpose, the affinity function Aff (ui , uj ) returns a similarity evaluation for any pair of users (ui , uj ). Affinities can be estimated taking into account many parameters: resources in common, similar behaviors, comparable ratings assigned to items, and so on. The resulting Affinity Network is represented by a graph Gθ where nodes are users and there exists an edge between ui and uj iff Aff (ui , uj ) > θ, where θ is a given connectivity threshold. Function Aff must be carefully chosen in order to deal with Affinity Networks showing Small World features. A small world network is characterized by short paths connecting most pairs of vertices and by the transitivity property [3]. Several social networks show small world patterns; relevantly to the present discussion, we identified a class of Affinity Networks in the Gnutella P2P file sharing system [4], that could be used for recommendation purposes. Given an affinity graph Gθ showing small world features, we designed a recommendation engine able to suggest items to users according to spontaneous social relationships. For this purpose, we define a set of parameters that estimate the relevance reli (sk ) of an item sk for the user ui . These parameters are the Affinity Function, the Feedback Rating, and the Tightness Coefficient. The Affinity Aff (ui , uj ) between users ui and uj is defined as described above, and subject to the constraint that the resulting network shows a small-world topology. The Feedback Rating rate(uj , sk ) is an explicit feedback on item sk given by uj . Finally, the Tightness Coefficient Tij of nodes ui and uj is defined as the
General Terms Algorithms, Design, Experimentation
Keywords Social Networks, Recommender Systems, Peer-to-Peer
1.
INTRODUCTION
Social Networking sites and self-organized communities are rapidly filling the Web with all sort of information about user tastes and preferences. This information is available in a lot of different sites that allows users to join a given community and distribute their own files, like photos (e.g. Flickr), videos (e.g., YouTube, Joost), music (e.g., Emule, Gnutella), blogs, personal data, and any other personal information (e.g., eBlogger, MySpace, Facebook). People can access these services from their desktops and laptops as well as from their cell phones, and handheld devices. In this extremely interactive environment, exposed to information overload, users need a support to make choices, and recommender systems [1] have evolved and applied in many areas. Beside well known proposals mainly focused on collaboratives filtering and content based techniques, the inherent social aspect of the recommendation process leads to a connection-oriented viewpoint in which users make relationships each other shaping a sort of spontaneous aggreCopyright is held by the author/owner(s). HT’08, June 19-21, 2008, Pittsburgh, Pennsylvania, USA. ACM 978-1-59593-985-2/08/06.
1
235
http://wiki.limewire.org/index.php?title=Overview
ratio of arcs that their neighbors have in common and the maximum number of links between their neighbors; the goal of this parameter is exploiting the high average value of the clustering coefficient in the affinity network, in order to give priority to items related to most representative neighbors. Therefore, relevance reli (sk ) is computed as a function of Tij , rate(uj , sk ) and Aff (ui , uj ). Such a function may vary accordingly to the peculiar domain. Observe that recommendations are performed without content based information: only social relationships are taken into account. Moreover, an user can calculate locally reli (sk ) values if she accepts to exchange some (not sensitive) data with her friends. This makes the engine adaptive to highly distributed environment where it is difficult (or unwilling) to interact with a central repository, and where content based information are not reliable.
3.
nEngine, when he wants to reimplement the getRecommendationList operation. (c) The programmer may subclass RecommendationEngineDAO, if other types of internal data structure are needed. There are currently three different data structure implementations of RecommendationEngineDAO: (1) sets; (2) a weighted graph structure; and (3) a database structure. The simplest one and, how we observed, best performing with high volume data is based on sets.
4. THE DEHINTER PROTOTYPE In order to verify the functionality of the X-Hinter API, we implemented a prototype of a recommendation system over the Limewire P2P file sharing application. This application works on top of the Gnutella network, so all the information about the network, such as hosts and shared resources, are taken using the available Gnutella messages. When the application is executed, a RecommendationEngine is created and initialized. The local shared files are added to the engine as resources, and a monitor starts to verify when local files are added and removed. For each shared file, a search is made in the network, to find peers that share the same resources. Each peer found is added to a buffer of peers, the data collection started, and each buffered peer’s files list is browsed. Moreover, in order to avoid messages overloading during data collection, a limited number of peers can be browsed at the same time. In this way, the information about each new peer is added incrementally into the recommendation engine: at the startup of the application, the user will see a low reliable list of recommended files, but the list starts to be more reliable during the data collection. When data collection finishes, collected data is saved and stored. Hence, even if the user leaves the application, he may load stored data again without starting a new collection phase. New data is collected only if the set of local shared files is changed, or when a given TTL expires. The threshold property is calculated dynamically, and its value θ depends on the number of available partners. If the number of partners is low, a low threshold value is used, to guarantee a high connectivity of the graph. But if the number of partners starts to grow, the threshold value is increased, limiting the number of partners to a configurable maximum value, and avoiding unlimited growing of the data structure.
THE X-HINTER SOCIAL API
The X-Hinter social API is a Java implementation of the X-Hinter model, with customization options. A Host represents the user, or the point where the resources are available to the network. Any Host have a set of Resources and its ratings. The center of the API is the RecommendationEngine, that offers to the programmer the following basic operations: addHost, to add a Host and its set of Resources and ratings in the engine’s data structure; addLocalResource, to inform that a given resource is being shared and rated by the local Host; getRecommendationList, that returns the list of recommended Resources. To control the engine lifecycle, the operation start allocate resources and initialize the data structure, while the stop operation executes cleanup and save data information. The threshold property controls the connectivity of the Affinity Graph. RecommendationEngine
Host
+ start() : void + addHost(host : Host) : void + addLocalResource(resource : Resource) : void + getRecommendationList() : SortedSet + setThreshold(threshold : double) : void + setAffinityFunction(function : AffinityFunction) : void + stop() : void
*
Resource
SetBasedRecommendationDAO
RecommendationDAO
AffinityFunction
AbstractRecommendationEngine
+ getAffinityValue(h1 : Host, h2 : Host) : double
Acknowledgments
SimpleRecommendationEngine + getAffinityValue(h1 : Host, h2 : Host) : double + getRecommendationList() : SortedSet
This work has been partially supported by the MIUR within the “PROFILES” project (PRIN) and by the Torino Wireless Foundation within the “RD-PVR” project. Panisson has been supported by the WWS mobility program founded by the CRT Foundation.
Figure 1: X-Hinter Recommendatin Engine API AbstractRecommendationEngine implements most of the operations of the RecommendationEngine interface. Its concrete implementation is SimpleRecommendationEngine, and it is also an implementation of AffinityFunction, returning the percentage of resources in common between (ui , uj ). The implemented operation getRecommendationList calculates the weight w(sk ) and order it. To customize the engine, there are some options available: (a) setAffinityFunction sets the function that calculates the affinity value between two Hosts; it takes as parameter an implementation of the AffinityFunction interface. (b) The programmer may subclass AbstractRecommendatio-
5. REFERENCES
[1] P. Resnick and H. R. Varian, “Recommender systems introduction to the special section.” Communication ACM, vol. 40, no. 3, pp. 56–58, 1997. [2] S. Milgram, “The small world problem,” Psychology Today, vol. 2, pp. 60–67, 1967. [3] D. J. Watts and S. H. Strogatz, “Collective dynamics of ’small-world’ networks.” Nature, vol. 393, no. 6684, pp. 440–442, June 1998. [4] G. Ruffo, R. Schifanella, and E. Ghiringhello, “A decentralized recommendation system based on self-organizing partnerships.” in Networking, ser. LNCS, vol. 3976. Springer, 2006, pp. 618–629.
236