Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SimpleTagger에 postprocessor가 있어도 단어가 출력되지 않는 문제 #88

Open
gem763 opened this issue Mar 3, 2019 · 0 comments

Comments

@gem763
Copy link

gem763 commented Mar 3, 2019

잘 쓰고 있습니다. 감사합니다.

SimpleTagger 생성시 postprocessor를 넣었음에도, 일부 단어가 출력되지 않는 경우가 있습니다.
이를테면,

pos_dict = {
    'Noun': {'가성비', '소문', '크록스', '키작녀', '최고'},
}

dictionary = Dict(pos_dict)
generator = LRTemplateMatcher(dictionary)    
evaluator = LREvaluator()
postprocessor = UnknowLRPostprocessor()
tagger = SimpleTagger(generator, evaluator, postprocessor)

print(tagger.tag('가성비 좋기로 소문난 크록스 그 중에서도 레이웨지는 키작녀에게 최고지'))

#[('가성비', 'Noun'), ('소문', 'Noun'), ('난', None), ('크록스', 'Noun'), ('키작녀', 'Noun'), ('에게', None), ('최고', 'Noun'), ('지', None)]

여기서 다음 어절들: 좋기로 중에서도 레이웨지는 이 통째로 출력되지 않습니다.

generator.generate('좋기로')

에서, (당연하게도) 빈 리스트가 출력되는 걸 보니,
한 어절에서 "적어도 일부분"은 사전에 등록되어 있어야 되는 것 같네요.
lovit님의 의도가 맞는지요?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant