mirror of
https://github.com/hiyouga/LLaMA-Factory.git
synced 2026-09-14 19:25:43 +08:00
[model] add Qwen3.8 model support (#10749)
Co-authored-by: hiyouga <hiyouga@buaa.edu.cn>
This commit is contained in:
@@ -281,6 +281,14 @@ def test_qwen_tool_extractor():
|
||||
assert formatter.extract(result) == [("test_tool", """{"foo": "bar", "size": 10}""")]
|
||||
|
||||
|
||||
@pytest.mark.runs_on(["cpu", "mps"])
|
||||
def test_qwen38_tool_formatter():
|
||||
formatter = ToolFormatter(tool_format="qwen3_8")
|
||||
wrapped_tool = {"type": "function", "function": TOOLS[0]}
|
||||
output = formatter.apply(content=json.dumps(TOOLS))[0]
|
||||
assert json.dumps(wrapped_tool, ensure_ascii=False) in output
|
||||
|
||||
|
||||
@pytest.mark.runs_on(["cpu", "mps"])
|
||||
def test_qwen_multi_tool_extractor():
|
||||
formatter = ToolFormatter(tool_format="qwen")
|
||||
|
||||
Reference in New Issue
Block a user