code: def glob_to_db(
      user_path,
      chunk=True,
      chunk_size=512,
      verbose=False,
      fail_any_exception=False,
      n_jobs=-1,
      url=None,
      # urls
      use_unstructured=True,
      use_playwright=False,
      use_selenium=False,
      use_scrapeplaywright=False,
      use_scrapehttp=False,
      # pdfs
      use_pymupdf="auto",
      use_unstructured_pdf="auto",
      use_pypdf="auto",
      enable_pdf_ocr="auto",
      try_pdf_as_html="auto",
      enable_pdf_doctr="auto",
      # images
      enable_ocr=False,
      enable_doctr=False,
      enable_pix2struct=False,
      enable_captions=True,
      enable_llava=True,
      enable_transcriptions=True,
      captions_model=None,
      caption_loader=None,
      doctr_loader=None,
      llava_model=None,
      llava_prompt=None,
      asr_model=None,
      asr_loader=None,
      # json
      jq_schema=".[]",
      extract_frames=10,
      db_type=None,
      selected_file_types=None,
      is_public=False,
  ):
      assert db_type is not None
  
      loaders_and_settings = dict(
          # diag/error handling
          verbose=verbose,
          fail_any_exception=fail_any_exception,
          # speed
          n_jobs=n_jobs,
          # chunking
          chunk=chunk,
          chunk_size=chunk_size,
          # urls
          use_unstructured=use_unstructured,
          use_playwright=use_playwright,
          use_selenium=use_selenium,
          use_scrapeplaywright=use_scrapeplaywright,
          use_scrapehttp=use_scrapehttp,
          # pdfs
          use_pymupdf=use_pymupdf,
          use_unstructured_pdf=use_unstructured_pdf,
          use_pypdf=use_pypdf,
          enable_pdf_ocr=enable_pdf_ocr,
          try_pdf_as_html=try_pdf_as_html,
          enable_pdf_doctr=enable_pdf_doctr,
          # images
          enable_ocr=enable_ocr,
          enable_doctr=enable_doctr,
          enable_pix2struct=enable_pix2struct,
          enable_captions=enable_captions,
          enable_llava=enable_llava,
          enable_transcriptions=enable_transcriptions,
          captions_model=captions_model,
          caption_loader=caption_loader,
          doctr_loader=doctr_loader,
          llava_model=llava_model,
          llava_prompt=llava_prompt,
          asr_model=asr_model,
          asr_loader=asr_loader,
          # json
          jq_schema=jq_schema,
          extract_frames=extract_frames,
          db_type=db_type,
          is_public=is_public,
      )
      sources1 = path_to_docs(
          user_path,
          url=url,
          **loaders_and_settings,
          selected_file_types=selected_file_types,
      )
      return sources1
  
imports: import ast
  import os
  import sys
  from typing import Union, List
  from gpt_langchain import path_to_docs, get_some_dbs_from_hf, all_db_zips, some_db_zips, create_or_update_db, get_persist_directory, get_existing_db
  from utils import H2O_Fire, makedirs, n_gpus_global
label_desc: Use image node_id 1 for calling a global function with example usage: glob_to_db(user_path, chunk, chunk_size, verbose, fail_any_exception, n_jobs, url, use_unstructured, use_playwright, use_selenium, use_scrapeplaywright, use_scrapehttp, use_pymupdf, use_unstructured_pdf, use_pypdf, enable_pdf_ocr, try_pdf_as_html, enable_pdf_doctr, enable_ocr, enable_doctr, enable_pix2struct, enable_captions, enable_llava, enable_transcriptions, captions_model, caption_loader, doctr_loader, llava_model, llava_prompt, asr_model, asr_loader, jq_schema, extract_frames, db_type, selected_file_types, is_public) and returns: sources1