syntax.py 文件源码

python
阅读 25 收藏 0 点赞 0 评论 0

项目:nlp_experiments 作者: amirhdrz 项目源码 文件源码
def _test(text=None):
    if text is not None:
        text = "What are the prerequisites for csc369?\n"


    tokenizer = RegexpTokenizer('[\w\d]+')
    word_tokens = tokenizer.tokenize(query)
    # TODO: how to tokenize 'u of t' and 'uoft'
    # TODO: use Bing Spell Check API
    tokens = [Token(tk) for tk in word_tokens]
    ser = RegexpEntityRecognizer()
    ser.process(tokens)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号