code: def extract_intro_and_title(filename, docstring):
      
  
      # lstrip is just in case docstring has a '\n\n' at the beginning
      paragraphs = docstring.lstrip().split('\n\n')
      # remove comments and other syntax like `.. _link:`
      paragraphs = [p for p in paragraphs
                    if not p.startswith('.. ') and len(p) > 0]
      if len(paragraphs) == 0:
          raise ValueError(
              "Example docstring should have a header for the example title. "
              "Please check the example file:\n {}\n".format(filename))
      # Title is the first paragraph with any ReSTructuredText title chars
      # removed, i.e. lines that consist of (all the same) 7-bit non-ASCII chars.
      # This conditional is not perfect but should hopefully be good enough.
      title_paragraph = paragraphs[0]
      match = re.search(r'([\w ]+)', title_paragraph)
  
      if match is None:
          raise ValueError(
              'Could not find a title in first paragraph:\n{}'.format(
                  title_paragraph))
      title = match.group(1).strip()
      # Use the title if no other paragraphs are provided
      intro_paragraph = title if len(paragraphs) < 2 else paragraphs[1]
      # Concatenate all lines of the first paragraph and truncate at 95 chars
      intro = re.sub('\n', ' ', intro_paragraph)
      if len(intro) > 95:
          intro = intro[:95] + '...'
  
      return intro, title
docs: Extract the first paragraph of module-level docstring. max:95 char