docstr: Experimental completions from IPython, using Jedi. 
docstr_tok: ["Experimental","completions","from","IPython",",","using","Jedi","."]
code: def _experimental_do_complete(self, code, cursor_pos):
      """
      Experimental completions from IPython, using Jedi.
      """
      if cursor_pos is None:
          cursor_pos = len(code)
      with _provisionalcompleter():
          raw_completions = self.shell.Completer.completions(
              code, cursor_pos
          )
          completions = list(
              _rectify_completions(code, raw_completions)
          )
  
          comps = []
          for comp in completions:
              comps.append(
                  dict(
                      start=comp.start,
                      end=comp.end,
                      text=comp.text,
                      type=comp.type,
                  )
              )
  
      if completions:
          s = completions[0].start
          e = completions[0].end
          matches = [c.text for c in completions]
      else:
          s = cursor_pos
          e = cursor_pos
          matches = []
  
      return {
          "matches": matches,
          "cursor_end": e,
          "cursor_start": s,
          "metadata": {_EXPERIMENTAL_KEY_NAME: comps},
          "status": "ok",
      }
  
imports: import getpass
  import sys
  from IPython.core import release
  from ipython_genutils.py3compat import builtin_mod, PY3, unicode_type, safe_unicode
  from IPython.utils.tokenutil import token_at_cursor, line_at_cursor
  from traitlets import Instance, Type, Any, List, Bool
  from .comm import CommManager
  from .kernelbase import Kernel
  from .zmqshell import ZMQInteractiveShell
label_desc: Use image node_id 15 for calling the IPythonKernel obj's underlying member method code with example usage: obj._experimental_do_complete(code, cursor_pos) and returns: dict