   (context [this] (.getContext this)))
 
 (defprotocol ISesameRDFConverter
-  (->sesame-rdf-type [this])
-  (sesame-rdf-type->type [this]))
+  (->sesame-rdf-type [this] "Convert a native type into a Sesame RDF Type")
+  (sesame-rdf-type->type [this] "Convert a Sesaem RDF Type into a Native Type"))
 
 (defn s
-  "Cast a string to an RDF literal"
+  "Cast a string to an RDF literal.  The second optional argument can
+  either be a keyword corresponding to an RDF language tag
+  e.g. :en, :en-gb, or :fr or a string or URI in which case it is
+  assumed to be a URI identifying the RDF type of the literal."
   ([str]
      {:pre [(string? str)]}
      (reify Object

  (let [dataset (mapply make-restricted-dataset (or options {}))]
    (query-dataset repo sparql dataset)))

(defn format->parser [format]
  (let [table {RDFFormat/NTRIPLES NTriplesParserFactory
               RDFFormat/TRIX TriXParserFactory
               RDFFormat/TRIG TriGParserFactory

       (.initialize))))

(defn repo
  "Given a sesame Store of some type, return a sesame SailRepository."
  ([] (repo (MemoryStore.)))
  ([store]
     (doto (SailRepository. store)
       (.initialize))))

(defn load-rdf
  "Loads the specified RDF file into the supplied repository.

  Takes a String or File (specifying a path to an RDF file) a base-uri
  String and an RDFFormat."
  [connection file base-uri-str format]
  (.add connection (io/file file) base-uri-str format (into-array Resource [])))

(defn- query-bindings->map [qbs]
