def parse_paragraphs(self, markup):
<EOL>refs = ["<STR_LIT>", "<STR_LIT>", "<STR_LIT>", "<STR_LIT>", "<STR_LIT>"]<EOL>exclude = ["<STR_LIT>", "<STR_LIT>", "<STR_LIT>", "<STR_LIT>", "<STR_LIT>", "<STR_LIT>", "<STR_LIT>"]<EOL>exclude.extend(refs)<EOL>paragraphs = []<EOL>paragraph = WikipediaParagraph(self.title)<EOL>paragraph_data = "<STR_LIT>"<EOL>for chunk in markup.split("<STR_LIT:\n>"):<EOL><INDENT>if not chunk.startswith("<STR_LIT:U+0020>"):<EOL><INDENT>chunk = chunk.strip()<EOL><DEDENT>if chunk.startswith("<STR_LIT:=>"):<EOL><INDENT>if paragraph.title.lower() in refsor (paragraph.parent and paragraph.parent.title.lower() in refs):<EOL><INDENT>self.parse_paragraph_references(paragraph_data)<EOL><DEDENT>paragraph.extend(self.parse_paragraph(paragraph_data))<EOL>paragraphs.append(paragraph)<EOL>title = chunk.strip().strip("<STR_LIT:=>")<EOL>title = self.plain(title)<EOL>paragraph = WikipediaParagraph(title)<EOL>paragraph.depth = self.parse_paragraph_heading_depth(chunk)<EOL>if paragraph.title.lower() not in exclude:<EOL><INDENT>paragraph = self.connect_paragraph(paragraph, paragraphs)<EOL><DEDENT>paragraph_data = "<STR_LIT>"<EOL><DEDENT>elif re.search(re.compile("<STR_LIT>", re.I), chunk):<EOL><INDENT>paragraph.main = [link.strip("<STR_LIT>") for link in chunk.split("<STR_LIT:|>")[<NUM_LIT:1>:]]<EOL>paragraph.main = [re.sub(re.compile("<STR_LIT>", re.I), "<STR_LIT>", link) <EOL>for link in paragraph.main]<EOL><DEDENT>elif re.search(re.compile("<STR_LIT>", re.I), chunk):<EOL><INDENT>paragraph.related = [link.strip("<STR_LIT>") for link in chunk.split("<STR_LIT:|>")[<NUM_LIT:1>:]]<EOL><DEDENT>else:<EOL><INDENT>paragraph_data += chunk +"<STR_LIT:\n>"<EOL><DEDENT><DEDENT>if paragraph.title.lower() in refsor (paragraph.parent and paragraph.parent.title.lower() in refs):<EOL><INDENT>self.parse_paragraph_references(paragraph_data)<EOL><DEDENT>paragraph.extend(self.parse_paragraph(paragraph_data))<EOL>paragraphs.append(paragraph)<EOL>paragraphs_exclude = []<EOL>for paragraph in paragraphs:<EOL><INDENT>if paragraph.title.lower() not in excludeand not (paragraph.parent and paragraph.parent.title.lower() in exclude):<EOL><INDENT>paragraphs_exclude.append(paragraph)<EOL><DEDENT><DEDENT>if len(paragraphs_exclude) == <NUM_LIT:1> andlen(paragraphs_exclude[<NUM_LIT:0>]) == <NUM_LIT:0>:<EOL><INDENT>return []<EOL><DEDENT>return paragraphs_exclude<EOL>
Returns a list of paragraphs in the markup.

        A paragraph has a title and multiple lines of plain text.
        A paragraph might have parent and child paragraphs,
        denoting subtitles or bigger chapters.

        A paragraph might have links to additional articles.

        Formats numbered lists by replacing # by 1.
        Formats bulleted sublists like ** or *** with indentation.