From 019676670bc28cf27f4e295bdd26ea6513580126 Mon Sep 17 00:00:00 2001 From: ThearchyHelios Date: Wed, 21 Oct 2026 19:09:20 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8F=AF=E9=AA=8C=E8=AF=81=E6=8A=A5=E5=91=8A?= =?UTF-8?q?=E7=9A=84=E6=A0=B8=E5=AF=B9=E9=A1=B5=EF=BC=9A=E6=AD=A3=E6=96=87?= =?UTF-8?q?=E9=87=8C=E7=9A=84=E5=88=A4=E5=AE=9A=E8=AF=AD=E8=A2=AB=E6=94=B9?= =?UTF-8?q?=E8=BF=87=E6=97=B6=EF=BC=8C=E5=8E=9F=E5=9B=A0=E5=86=99=E3=80=8C?= =?UTF-8?q?=E6=AD=A3=E6=96=87=E6=98=BE=E7=A4=BA=E3=80=8C=E2=80=A6=E3=80=8D?= =?UTF-8?q?=EF=BC=8C=E5=88=86=E6=9E=90=E7=BB=93=E8=AE=BA=E9=87=8C=E7=9A=84?= =?UTF-8?q?=E5=88=A4=E5=AE=9A=E8=AF=AD=E6=98=AF=E3=80=8C=E2=80=A6=E3=80=8D?= =?UTF-8?q?=E3=80=8D=E3=80=82=E5=88=A4=E5=AE=9A=E8=AF=AD=E7=9A=84=E5=BC=95?= =?UTF-8?q?=E7=94=A8=E4=B8=8D=E5=B8=A6=E5=80=BC=EF=BC=88=E5=88=A4=E5=AE=9A?= =?UTF-8?q?=E8=AF=AD=E5=B0=B1=E6=98=AF=E7=BB=93=E8=AE=BA=E9=87=8C=E7=9A=84?= =?UTF-8?q?=E9=82=A3=E5=8F=A5=E8=AF=9D=EF=BC=89=EF=BC=8C=E5=8E=9F=E6=9D=A5?= =?UTF-8?q?=E7=85=A7=E6=95=B0=E5=AD=97=E7=9A=84=E5=86=99=E6=B3=95=E6=8B=BC?= =?UTF-8?q?=E6=88=90=E3=80=8C=E5=BC=95=E7=94=A8=E7=9A=84=E5=80=BC=E6=98=AF?= =?UTF-8?q?=E7=A9=BA=E5=80=BC=EF=BC=88NULL=EF=BC=89=E3=80=8D=EF=BC=8C?= =?UTF-8?q?=E8=AF=BB=E8=B5=B7=E6=9D=A5=E5=83=8F=E5=BC=95=E7=94=A8=E6=9C=AC?= =?UTF-8?q?=E8=BA=AB=E6=98=AF=E7=A9=BA=E7=9A=84=EF=BC=9B=E5=85=B7=E5=90=8D?= =?UTF-8?q?=E7=9A=84=E6=95=B0=E3=80=81=E7=BB=93=E6=9E=9C=E8=A1=A8=E7=9A=84?= =?UTF-8?q?=E6=A0=BC=E7=85=A7=E6=97=A7=E5=86=99=E5=BC=95=E7=94=A8=E7=9A=84?= =?UTF-8?q?=E5=80=BC=E5=92=8C=E6=8C=89=E6=98=BE=E7=A4=BA=E8=A7=84=E5=88=99?= =?UTF-8?q?=E5=BA=94=E6=98=BE=E7=A4=BA=E7=9A=84=E5=AD=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- backend/app/bundle/verifier.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/backend/app/bundle/verifier.js b/backend/app/bundle/verifier.js index 767828fe..a0ad030a 100644 --- a/backend/app/bundle/verifier.js +++ b/backend/app/bundle/verifier.js @@ -198,6 +198,8 @@ /** cited 已经加好引号(空值写「空值(NULL)」);expected 和引用的值写法一样时不写(文字取值) */ numShownDiffers: (shown, cited, expected) => `正文显示「${shown}」,引用的值是${cited}` + (expected == null ? '' : `,按显示规则应显示为「${expected}」`), + /** 判定语的引用不带值(判定语就是结论里的那句话):只点名正文显示的字和结论里的判定语,不写「引用的值是空值」 */ + numPhraseDiffers: (shown, expected) => `正文显示「${shown}」,分析结论里的判定语是「${expected}」`, numShownUnknown: (why) => `无法核对显示文字:${why}`, shownFormat: (fmt) => `显示格式「${fmt}」无法识别`, shownConv: (conv) => `换算「${conv}」无法识别`, @@ -1619,6 +1621,9 @@ info.expected = expected const shown = String(seg.text ?? '') if (pyStrip(shown) === pyStrip(expected)) return { ...info, result: PASS, shownOk: true } + if (info.cite.kind === 'analysis' && !Object.prototype.hasOwnProperty.call(info.cite, 'value')) { + return { ...info, result: FAIL, reason: T.numPhraseDiffers(shown, expected) } + } const value = info.cite.value const cited = typeof value === 'number' ? numberText(value, info.citedToken) : value == null ? null : textOf(value) return { ...info, result: FAIL, reason: T.numShownDiffers(shown, cited == null ? T.nullValue : `「${cited}」`,