-
Notifications
You must be signed in to change notification settings - Fork 3k
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
Fix FAQ docx ui upload parsing support and reformat docx.py #3645
Conversation
n=split_length, | ||
step=split_length - split_overlap) | ||
else: | ||
segments = windowed(elements, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这个if else 看起来是不必要,直接通过split_overlap数值来决定就行
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
已修改
if "meta" not in doc.keys() or doc["meta"] is None: | ||
doc["meta"] = {} | ||
if (split_answers): | ||
text_arr = doc["content"].split('\t') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
split_answers 具体是代表啥含义了?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
FAQ智能问答需要读取文件的问答对,split_answers表示把问答对按照\t分开
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
PR types
PR changes
Description