Author: srowen
Date: Sat Oct 4 08:42:49 2008
New Revision: 701656
URL: http://svn.apache.org/viewvc?rev=701656&view=rev
Log:
Updated references to Correlation to Similarity
Modified:
lucene/mahout/site/src/documentation/content/xdocs/taste.xml
Modified: lucene/mahout/site/src/documentation/content/xdocs/taste.xml
URL:
http://svn.apache.org/viewvc/lucene/mahout/site/src/documentation/content/xdocs/taste.xml?rev=701656&r1=701655&r2=701656&view=diff
==============================================================================
--- lucene/mahout/site/src/documentation/content/xdocs/taste.xml (original)
+++ lucene/mahout/site/src/documentation/content/xdocs/taste.xml Sat Oct 4
08:42:49 2008
@@ -23,7 +23,7 @@
<ul>
<li><code>DataModel</code></li>
- <li><code>UserCorrelation</code> and <code>ItemCorrelation</code></li>
+ <li><code>UserSimilarity</code> and <code>ItemSimilarity</code></li>
<li><code>UserNeighborhood</code></li>
<li><code>Recommender</code></li>
</ul>
@@ -69,11 +69,11 @@
</section>
-<section><title>UserCorrelation, ItemCorrelation</title>
+<section><title>UserSimilarity, ItemSimilarity</title>
-<p>A <code>UserCorrelation</code> defines a notion of similarity between two
<code>User</code>s.
+<p>A <code>UserSimilarity</code> defines a notion of similarity between two
<code>User</code>s.
This is a crucial part of a recommendation engine. These are attached to a
<code>Neighborhood</code> implementation.
-<code>ItemCorrelation</code>s are analagous, but find similarity between
<code>Item</code>s.</p>
+<code>ItemSimilarity</code>s are analagous, but find similarity between
<code>Item</code>s.</p>
</section>
@@ -82,7 +82,7 @@
<p>In a user-based recommender, recommendations are produced by finding a
"neighborhood" of
similar users near a given user. A <code>UserNeighborhood</code> defines a
means of determining
that neighborhood — for example, nearest 10 users. Implementations
typically need a
-<code>UserCorrelation</code> to operate.</p>
+<code>UserSimilarity</code> to operate.</p>
</section>
@@ -171,24 +171,24 @@
<pre>DataModel model = new FileDataModel(new File("data.txt"));
</pre>
-<p>We'll use the PearsonCorrelation implementation of
<code>UserCorrelation</code> as our user
+<p>We'll use the PearsonCorrelationSimilarity implementation of
<code>UserSimilarity</code> as our user
correlation algorithm, and add an optional preference inference algorithm:</p>
-<pre>UserCorrelation userCorrelation = new PearsonCorrelation(model);
+<pre>UserSimilarity userSimilarity = new PearsonCorrelationSimilarity(model);
// Optional:
-userCorrelation.setPreferenceInferrer(new AveragingPreferenceInferrer());
+userSimilarity.setPreferenceInferrer(new AveragingPreferenceInferrer());
</pre>
<p>Now we create a <code>UserNeighborhood</code> algorithm. Here we use
nearest-3:</p>
<pre>UserNeighborhood neighborhood =
- new NearestNUserNeighborhood(3, userCorrelation, model);
+ new NearestNUserNeighborhood(3, userSimilarity, model);
</pre>
<p>Now we can create our <code>Recommender</code>, and add a caching
decorator:</p>
<pre>Recommender recommender =
- new GenericUserBasedRecommender(model, neighborhood, userCorrelation);
+ new GenericUserBasedRecommender(model, neighborhood, userSimilarity);
Recommender cachingRecommender = new CachingRecommender(recommender);
</pre>
@@ -214,23 +214,23 @@
<pre>DataModel model = new FileDataModel(new File("data.txt"));
</pre>
-<p>We'll also need an <code>ItemCorrelation</code>. We could use
<code>PearsonCorrelation</code>,
+<p>We'll also need an <code>ItemSimilarity</code>. We could use
<code>PearsonCorrelationSimilarity</code>,
which computes item similarity in realtime, but, this is generally too slow to
be useful.
Instead, in a real application, you would feed a list of pre-computed
correlations to
-a <code>GenericItemCorrelation</code>:</p>
+a <code>GenericItemSimilarity</code>:</p>
<pre>// Construct the list of pre-compted correlations
-Collection<GenericItemCorrelation.ItemItemCorrelation> correlations =
+Collection<GenericItemSimilarity.ItemItemSimilarity> correlations =
...;
-ItemCorrelation itemCorrelation =
- new GenericItemCorrelation(correlations);
+ItemSimilarity itemSimilarity =
+ new GenericItemSimilarity(correlations);
</pre>
<p>Then we can finish as before to produce recommendations:</p>
<pre>Recommender recommender =
- new GenericItemBasedRecommender(model, itemCorrelation);
+ new GenericItemBasedRecommender(model, itemSimilarity);
Recommender cachingRecommender = new CachingRecommender(recommender);
...
List<RecommendedItem> recommendations =