From b0113cb0fc91a73f6a3e990ad3343daf08836e76 Mon Sep 17 00:00:00 2001 From: Jiaxin Sui <95567040+plusNew001@users.noreply.github.com> Date: Mon, 1 Dec 2025 21:02:09 +0800 Subject: [PATCH] [XPU][CI] Change XPU CI Base Value (#5318) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Add '小度' keyword to assertion in run_w4a8.py * Add keywords to assertion in run_ep_online.py * Add keywords to assertion in run_w4a8.py * Update run_45T.py * Update run_ep_online.py * Refactor assertion for response content keywords * Update run_w4a8.py * Update run_w4a8.py --- tests/ci_use/XPU_45T/run_45T.py | 4 +++- tests/ci_use/XPU_45T/run_ep_online.py | 4 +++- tests/ci_use/XPU_45T/run_w4a8.py | 5 ++++- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/tests/ci_use/XPU_45T/run_45T.py b/tests/ci_use/XPU_45T/run_45T.py index 4a13becf8..d7e0cca03 100644 --- a/tests/ci_use/XPU_45T/run_45T.py +++ b/tests/ci_use/XPU_45T/run_45T.py @@ -36,7 +36,9 @@ def test_45t(): ) print(response.choices[0].message.content) # print(base_response) - assert any(keyword in response.choices[0].message.content for keyword in ["人工智能", "文心一言"]) + assert any( + keyword in response.choices[0].message.content for keyword in ["人工智能", "文心一言", "百度", "智能助手"] + ) if __name__ == "__main__": diff --git a/tests/ci_use/XPU_45T/run_ep_online.py b/tests/ci_use/XPU_45T/run_ep_online.py index d6f74b862..c0d71e4c8 100644 --- a/tests/ci_use/XPU_45T/run_ep_online.py +++ b/tests/ci_use/XPU_45T/run_ep_online.py @@ -35,7 +35,9 @@ def test_ep(): print(response.choices[0].message.content) # print(base_response) - assert any(keyword in response.choices[0].message.content for keyword in ["人工智能", "文心一言"]) + assert any( + keyword in response.choices[0].message.content for keyword in ["人工智能", "文心一言", "百度", "智能助手"] + ) if __name__ == "__main__": diff --git a/tests/ci_use/XPU_45T/run_w4a8.py b/tests/ci_use/XPU_45T/run_w4a8.py index b5eea23e1..c1e605215 100644 --- a/tests/ci_use/XPU_45T/run_w4a8.py +++ b/tests/ci_use/XPU_45T/run_w4a8.py @@ -36,7 +36,10 @@ def test_w4a8(): ) print(response.choices[0].message.content) # print(base_response) - assert any(keyword in response.choices[0].message.content for keyword in ["人工智能", "文心一言", "小度"]) + assert any( + keyword in response.choices[0].message.content + for keyword in ["人工智能", "文心一言", "小度", "百度", "智能助手"] + ) if __name__ == "__main__":