feat: export core Hermes skills
This commit is contained in:
@@ -0,0 +1,53 @@
|
||||
# Tracked Replace 相邻文本检查(2026-06-26 CT维保合同教训)
|
||||
|
||||
## 问题场景
|
||||
|
||||
R1 reviewer 发现「造与」→「造成」的 typo(R1-009),editor 执行 tracked_replace 修复。R2 reviewer 复核时发现修复后的文本为「造成济损失」——缺少「经」字,应为「造成经济损失」。
|
||||
|
||||
## 根因
|
||||
|
||||
原文为「造与与济损失」——**双重 typo**:
|
||||
1. 「造与」→ 应为「造成」(R1-009 已发现)
|
||||
2. 「济损失」→ 应为「经济损失」(**R1 reviewer 未发现**)
|
||||
|
||||
Editor 修复了 R1-009 后,渲染文本为「造成济损失」,第二个 typo 仍然存在。
|
||||
|
||||
## 教训
|
||||
|
||||
**tracked_replace 不是「只检查那一处」的信号**。当 editor 在一个段落内执行了 tracked_replace 后,reviewer 复核时必须:
|
||||
|
||||
1. **提取整个段落的「接受修订后」渲染文本**(`accept_revisions_text`),不只看 track change 标记
|
||||
2. **逐字通读整个段落**,检查是否有:
|
||||
- 与被修复 typo 相邻的**其他 typo**(如本例「济损失」缺「经」)
|
||||
- tracked_replace 操作**意外引入**的新错误(如删多了字、删错了位置)
|
||||
- 双重 DEL 导致的**文本碎片化**(如「造[-与-]成[- -][-与-]济损失」)
|
||||
|
||||
## 验证方法
|
||||
|
||||
```python
|
||||
# 对每个有 WB track changes 的段落,提取接受修订后的完整文本
|
||||
def accept_revisions_text(p):
|
||||
result = []
|
||||
for elem in p.iter():
|
||||
if elem.tag == qn('delText'):
|
||||
continue
|
||||
if elem.tag == qn('t'):
|
||||
parent = elem.getparent()
|
||||
if parent is not None and parent.tag == qn('del'):
|
||||
continue # skip runs inside w:del
|
||||
if elem.text:
|
||||
result.append(elem.text)
|
||||
return ''.join(result)
|
||||
|
||||
# 复核时对每个被修改的段落,输出完整渲染文本
|
||||
for pi in modified_paragraphs:
|
||||
text = accept_revisions_text(paras[pi])
|
||||
print(f"P{pi}: {text}")
|
||||
```
|
||||
|
||||
## 审查清单补充
|
||||
|
||||
复核轮的文字校对,在「逐字通读」基础上,对**每个有 WB track changes 的段落**额外执行:
|
||||
- 全文输出该段落的接受修订后文本
|
||||
- 人工逐字通读,检查是否有遗漏的 typo
|
||||
- 特别注意 tracked_replace 操作的**边界**(DEL/INS 前后的原文 run)
|
||||
Reference in New Issue
Block a user