class_docstr: Main class which handles parsing with Spacy-BIST parser.
  
  Args:
      verbose (bool, optional): Controls output verbosity.
      spacy_model (str, optional): Spacy model to use
      (see https://spacy.io/api/top-level#spacy.load).
      bist_model (str, optional): Path to a .model file to load. Defaults pre-trained model'.
class_docstr_tok: ["Main","class","which","handles","parsing","with","Spacy-BIST","parser",".","Args",":","verbose","(","bool",",","optional",")",":","Controls","output","verbosity",".","spacy_model","(","str",",","optional",")",":","Spacy","model","to","use","(","see","https",":","\/\/spacy.io\/api\/top-level","#","spacy.load",")",".","bist_model","(","str",",","optional",")",":","Path","to","a",".model","file","to","load",".","Defaults","pre-trained","model","'","."]
docstr: Parse a raw text document.
  
  Args:
      doc_text (str)
      show_tok (bool, optional): Specifies whether to include token text in output.
      show_doc (bool, optional): Specifies whether to include document text in output.
  
  Returns:
      CoreNLPDoc: The annotated document.
docstr_tok: ["Parse","a","raw","text","document",".","Args",":","doc_text","(","str",")","show_tok","(","bool",",","optional",")",":","Specifies","whether","to","include","token","text","in","output",".","show_doc","(","bool",",","optional",")",":","Specifies","whether","to","include","document","text","in","output",".","Returns",":","CoreNLPDoc",":","The","annotated","document","."]
code: def parse(self, doc_text, show_tok=True, show_doc=True):
      """Parse a raw text document.
  
      Args:
          doc_text (str)
          show_tok (bool, optional): Specifies whether to include token text in output.
          show_doc (bool, optional): Specifies whether to include document text in output.
  
      Returns:
          CoreNLPDoc: The annotated document.
      """
      validate((doc_text, str), (show_tok, bool), (show_doc, bool))
      doc_conll = self.to_conll(doc_text)
      parsed_doc = CoreNLPDoc()
  
      if show_doc:
          parsed_doc.doc_text = doc_text
  
      for sent_conll in self.bist_parser.predict_conll(doc_conll):
          parsed_sent = []
          conj_governors = {"and": set(), "or": set()}
  
          for tok in sent_conll:
              gov_id = int(tok.pred_parent_id)
              rel = tok.pred_relation
  
              if tok.form != "*root*":
                  if tok.form.lower() == "and":
                      conj_governors["and"].add(gov_id)
                  if tok.form.lower() == "or":
                      conj_governors["or"].add(gov_id)
  
                  if rel == "conj":
                      if gov_id in conj_governors["and"]:
                          rel += "_and"
                      if gov_id in conj_governors["or"]:
                          rel += "_or"
  
                  parsed_tok = {
                      "start": tok.misc,
                      "len": len(tok.form),
                      "pos": tok.pos,
                      "ner": tok.feats,
                      "lemma": tok.lemma,
                      "gov": gov_id - 1,
                      "rel": rel,
                  }
  
                  if show_tok:
                      parsed_tok["text"] = tok.form
                  parsed_sent.append(parsed_tok)
          if parsed_sent:
              parsed_doc.sentences.append(parsed_sent)
      return parsed_doc
  
file_path: nlp-architect/nlp_architect/pipelines/spacy_bist.py
imports: from os import path, makedirs
  from nlp_architect.common.core_nlp_doc import CoreNLPDoc, _spacy_pos_to_ptb
  from nlp_architect.data.conll import ConllEntry
  from nlp_architect.models.bist_parser import BISTModel
  from nlp_architect import LIBRARY_OUT
  from nlp_architect.utils.io import download_unzip
  from nlp_architect.utils.io import validate
  from nlp_architect.utils.text import SpacyInstance
label_desc: Use image node_id 3 for calling the SpacyBISTParser obj's underlying member method code with example usage: obj.parse(doc_text, show_tok, show_doc) and returns: parsed_doc