已覆盖只允许正确或错误,未覆盖可待确认,缺引用不再阻止正确结论。 复用统一事务写入与不可变审计重评旧待确认,保留原问答和人工结论。 验证:全仓 make verify、真实隔离 PostgreSQL 全包与 race 回归通过。
This commit is contained in:
@@ -21,3 +21,25 @@ func TestManualHistoricalAssessmentUsesRealGapsButAutomaticAdmissionRemainsSepar
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func TestCoveredPendingIsReassessedWithoutTouchingOtherNonemptyFields(t *testing.T) {
|
||||
m := recordMeta{Status: "historical_import", Question: "示例问题", Fields: map[string]string{"is_correct": "待确认", "product_category": "MG400", "problem_type": "故障", "root_cause": "结果不清"}, Coverage: dobotaiops.CheckMasterCoverage("完整实际回答", true), View: qaopsquality.View{Effective: qaopsquality.Fields{Coverage: "covered", Correctness: "pending", ProductCategory: "MG400", ProblemType: "故障", RootCause: "结果不清"}}}
|
||||
if got := needs(m, "evaluation"); !reflect.DeepEqual(got, []string{"is_correct"}) {
|
||||
t.Fatalf("obsolete pending not isolated for rejudgment: %v", got)
|
||||
}
|
||||
m.View.Effective.Coverage = "uncovered"
|
||||
if len(needs(m, "evaluation")) != 0 {
|
||||
t.Fatal("uncovered pending was unnecessarily reassessed")
|
||||
}
|
||||
}
|
||||
|
||||
func TestSupersededEvaluationPromptIsNotExecuted(t *testing.T) {
|
||||
for _, version := range []string{"qa-evaluate-evidence-v1", EvaluationPromptVersion} {
|
||||
if currentWorkPrompt(claimedWork{Kind: "evaluation", PromptVersion: version}) != (version == EvaluationPromptVersion) {
|
||||
t.Fatalf("prompt provenance not guarded: %s", version)
|
||||
}
|
||||
}
|
||||
if !currentWorkPrompt(claimedWork{Kind: "translation", PromptVersion: TranslationPromptVersion}) {
|
||||
t.Fatal("unchanged translator rejected")
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user