# -*- encoding: UTF-8 -*- dic = [[u'(?u)(?[Aa])n(?P<_>[ ][\'\u2018"\u201c]?)(?P[aeiouAEIOU]\\w*)(?P[-\u2013\'\u2019\\w]*)(?![-\\w\u2013\xad])', u'\\g\\g<_>\\g\\g', u'Did you mean: \\n http://en.wikipedia.org/wiki/English_articles#Distinction_between_a_and_an', u'm.group("vow_1") in aA or m.group("vow_1").lower() in aA', 0], [u'(?u)(?[ ][\'\u2018"\u201c]?)(?P[aeiouAEIOU]\\w*)(?P[-\u2013\'\u2019\\w]*)(?![-\\w\u2013\xad])', u'an\\g<_>\\g\\g', u'Bad article? \\n http://en.wikipedia.org/wiki/English_articles#Distinction_between_a_and_an', u'(m.group("vow_1") != m.group("vow_1").upper()) and not (m.group("vow_1") in aA or m.group("vow_1").lower() in aA) and spell(LOCALE,m.group("vow_1"))', 0], [u'(?u)(?[ ][\'\u2018"\u201c]?)(?P[bcdfghj-np-tv-zBCDFGHJ-NP-TV-Z]\\w*)(?P[-\u2013\'\u2019\\w]*)(?![-\\w\u2013\xad])', u'an\\g<_>\\g\\g', u'Did you mean: \\n http://en.wikipedia.org/wiki/English_articles#Distinction_between_a_and_an', u'm.group("con_1") in aAN or m.group("con_1").lower() in aAN', 0], [u'(?u)(?[Aa])n(?P<_>[ ][\'\u2018"\u201c]?)(?P[bcdfghj-np-tv-zBCDFGHJ-NP-TV-Z]\\w*)(?P[-\u2013\'\u2019\\w]*)(?![-\\w\u2013\xad])', u'\\g\\g<_>\\g\\g', u'Bad article? \\n http://en.wikipedia.org/wiki/English_articles#Distinction_between_a_and_an', u'(m.group("con_1") != m.group("con_1").upper()) and not (m.group("con_1") in aA or m.group("con_1").lower() in aAN) and not m.group("con_1") in aB and spell(LOCALE,m.group("con_1"))', 0], [u'(?u)((?<=[!?.] )|^)A(?P<_>[ ][\'\u2018"\u201c]?)(?P[aeiouAEIOU]\\w*)(?P[-\u2013\'\u2019\\w]*)(?![-\\w\u2013\xad])', u'An\\g<_>\\g\\g', u'Bad article? \\n http://en.wikipedia.org/wiki/English_articles#Distinction_between_a_and_an', u'(m.group("vow_1") != m.group("vow_1").upper()) and not (m.group("vow_1") in aA or m.group("vow_1").lower() in aA) and spell(LOCALE,m.group("vow_1"))', 0], [u'(?u)((?<=[!?.] )|^)A(?P<_>[ ][\'\u2018"\u201c]?)(?P[bcdfghj-np-tv-zBCDFGHJ-NP-TV-Z]\\w*)(?P[-\u2013\'\u2019\\w]*)(?![-\\w\u2013\xad])', u'An\\g<_>\\g\\g', u'Did you mean: \\n http://en.wikipedia.org/wiki/English_articles#Distinction_between_a_and_an', u'm.group("con_1") in aAN or m.group("con_1").lower() in aAN', 0], [u'(?u)(?[ ][\'\u2018"\u201c]?)(?P(8[0-9]*|1[18](000)*)(th)?)(?P[-\u2013\'\u2019\\w]*)(?![-\\w\u2013\xad])', u'an\\g<_>\\g\\g', u'Did you mean: \\n http://en.wikipedia.org/wiki/English_articles#Distinction_between_a_and_an', False, 0], [u'(?u)((?<=[!?.] )|^)A(?P<_>[ ][\'\u2018"\u201c]?)(?P(8[0-9]*|1[18](000)*)(th)?)(?P[-\u2013\'\u2019\\w]*)(?![-\\w\u2013\xad])', u'An\\g<_>\\g\\g', u'Did you mean: \\n http://en.wikipedia.org/wiki/English_articles#Distinction_between_a_and_an', False, 0], [u'(?u)(?[Aa])n(?P<_>[ ][\'\u2018"\u201c]?)(?P[0-79][0-9]*)(?P[-\u2013\'\u2019\\w]*)(?![-\\w\u2013\xad])', u'\\g\\g<_>\\g\\g', u'Did you mean: \\n http://en.wikipedia.org/wiki/English_articles#Distinction_between_a_and_an', u'not m.group("ncon_1")[:2] in ["11", "18"]', 0], [u'(?u)(?[a-z]+)(?![-\\w\u2013\xad])', u'= m.group("low_1").capitalize()', u'Missing capitalization?', u'paralcap.search(TEXT) and not abbrev.search(TEXT)', 0], [u'(?u)((?<=[!?.] )|^)(?P[a-z]+)(?![-\\w\u2013\xad])', u'= m.group("low_1").capitalize()', u'Missing capitalization?', u'option(LOCALE,"cap") and not abbrev.search(TEXT)', 0], [u'(?u) ([.?!,:;)\u201d\\]])\\b', u'\\1 ', u'Reversed space and punctuation?', False, 0], [u'(?u) +[.]', u'.', u'Extra space before the period?', u'LOCALE.Country == "US"', 0], [u'(?u) +[.]', u'.', u'Extra space before the full stop?', u'LOCALE.Country != "US"', 0], [u'(?u) +([?!,:;)\u201d\\]])', u'\\1', u'= "Extra space before the " + punct[m.group(1)] + "?"', False, 0], [u'(?u)([([\u201c]) ', u'\\1', u'= "Extra space after the " + punct[m.group(1)] + "?"', False, 0], [u'(?u)\\b(---?| --? )\\b', u' \u2013 \\n\u2014', u'En dash or em dash:', u'not option(LOCALE,"ndash") and not option(LOCALE,"mdash")', 0], [u'(?u)\\b(---?| --? |\u2014)\\b', u' \u2013 ', u'En dash:', u'option(LOCALE,"ndash") and not option(LOCALE,"mdash")', 0], [u'(?u)\\b(---?| --? | \u2013 )\\b', u'\u2014', u'Em dash:', u'option(LOCALE,"mdash")', 0], [u'(?u)(?P\\d+([.]\\d+)?)(x| x )(?P\\d+([.]\\d+)?)', u'\\g\xd7\\g', u'Multiplication sign. \\n http://en.wikipedia.org/wiki/Multiplication_sign', u'option(LOCALE,"times")', 0], [u'(?u)(?P[a-zA-Z]+)(?P[?!,:;%\u2030\u2031\u02da\u201c\u201d\u2018])(?P[a-zA-Z]+)', u'\\g\\g \\g', u'Missing space?', False, 0], [u'(?u)(?P[a-z]+)[.](?P[A-Z]+)', u'\\g. \\g', u'Missing space?', False, 0], [u'(?u)[)]', u'', u'Extra closing parenthesis?', u'option(LOCALE,"pair") and not "(" in TEXT', 0], [u'(?u)[(]', u'', u'Extra opening parenthesis?', u'option(LOCALE,"pair") and TEXT[-1] in u"?!;:\u201d\u2019" and not ")" in TEXT', 0], [u'(?u)(?[?!,:;%\u2030\u2031\u02da\u201c\u201d\u2018])|[.]) {2,3}(\\b|$)', u'\\1 ', u'Extra space.', u'option(LOCALE,"spaces2")', 0], [u'(?u)(^|\\b|(?P[?!,:;%\u2030\u2031\u02da\u201c\u201d\u2018])|[.]) {4,}(\\b|$)', u'\\1 \\n\t', u'Change multiple spaces to a single space or a tabulator:', u'option(LOCALE,"spaces3")', 0], [u'(?iu)[\\"\u201c\u201d\u201f\u201e]((?P[a-zA-Z]+)[^\\"\u201c\u201d\u201f\u201e]*)[\\"\u201c\u201f]', u'\u201c\\1\u201d', u'Quotation marks.', u'option(LOCALE,"quotation")', 0], [u'(?iu)[\\"\u201d\u201f\u201e]((?P[a-zA-Z]+)[^\\"\u201c\u201d\u201f\u201e]*)[\\"\u201c\u201d\u201f]', u'\u201c\\1\u201d', u'Quotation marks.', u'option(LOCALE,"quotation")', 0], [u"(?iu)'(?P[a-zA-Z]+)'", u'\u2018\\g\u2019', u'Quotation marks.', u'option(LOCALE,"apostrophe")', 0], [u'(?iu)[\\"\u201d\u201f\u201e]((?P[a-zA-Z]+)[^\\"\u201c\u201d\u201f\u201e]*)[\\"\u201c\u201d\u201f]', u'\u201c\\1\u201d', u'Quotation marks.', u'option(LOCALE,"apostrophe")', 0], [u"(?iu)(?P[a-zA-ZA-Z]+)'(?P\\w*)", u'\\g\u2019\\g', u'Replace typewriter apostrophe or quotation mark:', u'option(LOCALE,"apostrophe")', 0], [u"(?u)(?<= )'(?P[a-zA-Z]+)", u'\u2018\\g\\n\u2019\\g', u'Replace typewriter quotation mark or apostrophe:', u'option(LOCALE,"apostrophe")', 0], [u"(?u)^'(?P[a-zA-Z]+)", u'\u2018\\g\\n\u2019\\g', u'Replace typewriter quotation mark or apostrophe:', u'option(LOCALE,"apostrophe")', 0], [u'(?u)\\b(?P\\d\\d)(?P\\d\\d\\d)\\b', u'\\g,\\g\\n\\g\u202f\\g', u'Use thousand separator (common or ISO).', u'option(LOCALE,"numsep")', 0], [u'(?u)\\b(?P\\d{1,3})(?P\\d\\d\\d)(?P\\d\\d\\d)\\b', u'\\g,\\g,\\g\\n\\g\u202f\\g\u202f\\g', u'Use thousand separators (common or ISO).', u'option(LOCALE,"numsep")', 0], [u'(?u)\\b(?P\\d{1,3})(?P\\d\\d\\d)(?P\\d\\d\\d)(?P\\d\\d\\d)\\b', u'\\g,\\g,\\g,\\g\\n\\g\u202f\\g\u202f\\g\u202f\\g', u'Use thousand separators (common or ISO).', u'option(LOCALE,"numsep")', 0], [u'(?u)(?[a-zA-Z]+) \\1(?![-\\w\u2013\xad])', u'\\g', u'Word duplication?', u'option(LOCALE,"dup")', 0], [u'(?u)(?[a-z]+)(?![-\\w\u2013\xad])', u'\\1hese \\g\\n\\1his, \\g', u'Did you mean:', u'option(LOCALE,"grammar") and morph(LOCALE,m.group("abc_1"), "Ns")', 0], [u"(?u)(?