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

extract_wikitext_from_json.py 함수 split function에서 begin_marker, end_marker 같은 경우에 split이 제대로 되지 않는 문제 #9

Open
dylangim20 opened this issue Oct 20, 2020 · 2 comments

Comments

@dylangim20
Copy link

안녕하세요. 프로젝트 공유해주셔서 감사합니다. 잘 활용하고 있습니다.

간단한 오류인 것 같은데, split 함수에서 begin_marker와 end_marker가 같은 경우에 split이 원하는 동작이 (prefix, sub, suffix의 온전한 분리) 이루어지지 않는 것 같습니다.

e = s.index(end_marker, b)에서
아래처럼 index를 b 대신 b + len(begin_marker) 로 시작하면 될 것 같습니다.
e = s.index(end_marker, b + len(begin_marker))

(혹시나 제가 틀릴 수도 있습니다!)
감사합니다.

@lovit
Copy link
Owner

lovit commented Oct 20, 2020

@thkhard

리뷰와 커멘트 감사합니다. 언급해주신 부분은 제 실수가 맞습니다.
용례가 태그를 begin_marker, end_marker 로 이용하고 있기 때문에 어쩌면 데이터셋에는 차이가 없을 수도 있을듯 합니다.
해당 부분 수정 후, 데이터셋의 차이가 있다면 파일을 다시 release 하겠습니다.
데이터셋의 차이가 없다면 이 이슈에 커멘트로 기록해 두겠습니다!

lovit added a commit that referenced this issue Oct 20, 2020
lovit added a commit that referenced this issue Oct 25, 2020
lovit added a commit that referenced this issue Oct 25, 2020
lovit added a commit that referenced this issue Oct 25, 2020
@lovit
Copy link
Owner

lovit commented Oct 25, 2020

커멘트해주신 내용들에 의해 데이터가 변경된 부분이 존재하여, 변경 후 v0.3 으로 재배포 하였습니다. 감사합니다.

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

2 participants