Skip to content

Commit

Permalink
fix: fix qwen2 vl unstable output
Browse files Browse the repository at this point in the history
  • Loading branch information
IcyKallen committed Feb 28, 2025
1 parent 96e97b7 commit 46909fc
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
Binary file modified source/lambda/job/dep/dist/llm_bot_dep-0.1.0-py3-none-any.whl
Binary file not shown.
3 changes: 2 additions & 1 deletion source/lambda/job/dep/llm_bot_dep/splitter_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,8 @@ def find_child(headers: dict, header_id: str):

def parse_string_to_xml_node(xml_string):
try:
xml_node = etree.fromstring(xml_string.replace("&", "&"))
parser = etree.XMLParser(recover=True)
xml_node = etree.fromstring(xml_string.replace("&", "&"), parser)
return xml_node
except etree.XMLSyntaxError as e:
logger.error(f"Error parsing XML: {e}")
Expand Down

0 comments on commit 46909fc

Please sign in to comment.