#
# KEHOME/bin/tap
# Sep/9/2003

# interpret RDF sentences using TAP KB
#	query  from remote TAP KB data
#	assert to   local  TAP KB file
# Usage:
#	tap kbdata kbfile
#	sentence
#	...
#	CONTROL-Z
# sentence ::=
#	statement
#	question
# statement ::=
#	subject predicate object
# question ::=
#	?resource genus name
#	subject predicate ?
#	subject ? ?
#	? ? object
#	? predicate object
#
# Notes:
#   genus = "Resource" searches entire hierarchy
#   name is pseudo-attribute matching at least
#	"label", "plural", and "adjective"
#   "?" predicate is changed to "arcs"
#
# Examples:
#	DickMcCullough type Person
#	?resource Resource McCullough
#	?resource Athlete Jordan
#	Person subClassOf ?
#	Person ? ?
#	? ? Person
#	? type Person
#
# For further info. see:
#   KEHOME/java/mytap.java
#   KEHOME/java/getdata.java
#   KEHOME/java/getresource.java
#   KEHOME/java/putdata.java
#   KEHOME/java/Qname.java

. systype.env
. tap.env

if [ -n "$1" ]
then kbdata="$1"
else kbdata="http://tap.stanford.edu/data/"
fi
if [ -n "$2" ]
then kbfile="$2"
else kbfile="$KEHOME/data/tap.rdf"
fi

cd "$KEHOME/java"
java mytap "$kbdata" "$kbfile"

#