pitt.search.semanticvectors
Class CompareTerms

java.lang.Object
  extended by pitt.search.semanticvectors.CompareTerms

public class CompareTerms
extends java.lang.Object

Command line term vector comparison utility. This enables users to get raw similarities between two concepts. These concepts may be individual words or lists of words. For example, if your vectorfile is the (default) termvectors.bin, you should be able to run comparisons like
java pitt.search.semanticvectors.CompareTerms "blue" "red green"
which will give you the cosine similarity of the "blue" vector with the sum of the "red" and "green" vectors.
If the term NOT is used in one of the lists, subsequent terms in that list will be negated.


Constructor Summary
CompareTerms()
           
 
Method Summary
static void main(java.lang.String[] args)
          Main function for command line use.
static void usage()
          Prints the following usage message:
CompareTerms class in package pitt.search.semanticvectors
Usage: java pitt.search.semanticvectors.CompareTerms
"<QUERYTERMS1>" "<QUERYTERMS2>"
"<QUERYTERMS1,2>" should be lists of words, separated by spaces.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CompareTerms

public CompareTerms()
Method Detail

usage

public static void usage()
Prints the following usage message:
CompareTerms class in package pitt.search.semanticvectors
Usage: java pitt.search.semanticvectors.CompareTerms
"<QUERYTERMS1>" "<QUERYTERMS2>"
"<QUERYTERMS1,2>" should be lists of words, separated by spaces.
The quotes are mandatory unless you are comparing two single words.
If the term NOT is used in one of the lists, subsequent terms in
that list will be negated (as in Search class).

See Also:
Search

main

public static void main(java.lang.String[] args)
                 throws java.lang.IllegalArgumentException
Main function for command line use.

Parameters:
args - See usage();
Throws:
java.lang.IllegalArgumentException