You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
30 lines
1.0 KiB
30 lines
1.0 KiB
import asyncio
|
|
from qc_engine import qc_manager
|
|
|
|
async def test_semantics():
|
|
test_cases = [
|
|
{
|
|
"name": "拼音与语义冲突测试",
|
|
"report": "患者因胸痛就诊,检查发现右肺起步器位置正常。xbjy量约20ml。测量病灶大笑约3.2cm。",
|
|
"patient_info": {"sex": "男", "age": "45"},
|
|
"examinePart": "胸部CT"
|
|
},
|
|
{
|
|
"name": "知识图谱实体位置关系测试",
|
|
"report": "超声显示:肝脏形态正常,内可见起搏器影,大小约2x3cm。骨质只能说提示疏松建议进一步检查。",
|
|
"patient_info": {"sex": "女", "age": "70"},
|
|
"examinePart": "腹部超声"
|
|
}
|
|
]
|
|
|
|
for case in test_cases:
|
|
print(f"\n" + "="*50)
|
|
print(f"🚀 开始测试:{case['name']}")
|
|
print(f"原始文本: {case['report']}")
|
|
print("-" * 20)
|
|
|
|
result = await qc_manager.run_qc(case)
|
|
print(result)
|
|
|
|
if __name__ == "__main__":
|
|
asyncio.run(test_semantics())
|
|
|