class_docstr: This annotator base class hosts a lightweight server that accepts
  annotation requests from CoreNLP.
  Each annotator simply defines 3 functions: requires, provides and annotate.
  
  This class takes care of defining appropriate endpoints to interface
  with CoreNLP.
docstr: Runs the server using Python's simple HTTPServer.
  TODO: make this multithreaded.
docstr_tok: ["Runs","the","server","using","Python","'s","simple","HTTPServer",".","TODO",":","make","this","multithreaded","."]
code: def run(self):
      """
      Runs the server using Python's simple HTTPServer.
      TODO: make this multithreaded.
      """
      httpd = HTTPServer((self.host, self.port), self._Handler)
      sa = httpd.socket.getsockname()
      serve_message = "Serving HTTP on {host} port {port} (http://{host}:{port}/) ..."
      print(serve_message.format(host=sa[0], port=sa[1]))
      try:
          httpd.serve_forever()
      except KeyboardInterrupt:
          print("\nKeyboard interrupt received, exiting.")
          httpd.shutdown()
  
file_path: stanza/stanza/server/annotator.py
imports: import io
  from multiprocessing import Process
  from http.server import BaseHTTPRequestHandler, HTTPServer
  from http import client
  from stanza.protobuf import Document, parseFromDelimitedString, writeToDelimitedString
label_desc: Use image node_id 7 for calling the Annotator obj's underlying member method code with example usage: obj.run() without return types