m3hrdadfi's picture
Hello gpt2-qa
f474d6a
raw
history blame contribute delete
409 Bytes
import re
PERSIAN_ALPHA = "ءآئابتثجحخدذرزسشصضطظعغفقلمنهوپچژکگیە" # noqa: E501
PERSIAN_DIGIT = "۰۱۲۳۴۵۶۷۸۹"
ZWNJ = "\u200c"
PUNK = '\!\"\#\$\%\&\'\(\)\*\+\,\-\.\/\:\;\<\=\>\?\@\[\]\^\_\`\{\|\}\~\«\»\؟\:\×\٬\٫\﷼\٪\،'
PERSIAN = (
"a-zA-Z0-9" +
PERSIAN_ALPHA +
PERSIAN_DIGIT +
ZWNJ +
PUNK
)
PERSIAN_REGEX = r"[^" + PERSIAN + "+]"