P8 短板齊平:模型品質實測(granite 否決、qwen3-30b 定案)+額度撞牆三句話接上畫面

① docs/benchmarks/p8-extractor-quality/:leo 真筆記 8 篇 × 5 模型可複驗實測
   (production 同 prompt/參數、CF 原生 usage.neurons 計量)——
   scout 84 n/檔(119 檔/日)→ qwen3-30b 43 n/檔(232 檔/日)品質不降反升;
   granite 最便宜(858 檔/日)但 5/8 缺段、三元組全滅=否決。
   誠實結論:免金鑰路物理撐不起「幾千篇當天匯入」(差 13 倍),
   正解=消化節奏(3,000 篇約 13 天背景跑完、新筆記優先)+出口(Gemini/付費/ollama)。
② 撞牆體驗:quota_message 08-07 就在 status.json,App 從來沒接——
   app.go pickQuotaNotice(過期快照不說謊)+ main.js cardQuota(三句話卡)+
   progress.go ClassifyFailure 補認三句話(原本掉「其他」)。
   Go 兩 module 全綠;瀏覽器實載 dist 深淺兩主題截圖、console 0 錯。
③ 公開鏡像排除 docs/benchmarks(輸入是 leo 私人筆記)。

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
2026-08-09 00:44:34 +08:00
parent 779a1b801e
commit ef8126201c
5 changed files with 162 additions and 1 deletions
+17
View File
@@ -108,3 +108,20 @@ func TestQuotaState_InCooldown(t *testing.T) {
t.Fatal("過了冷卻時間應該解除")
}
}
// P82026-08-09):額度三句話會被存進檔案的失敗欄位(direct.go res.Error),
// 再流進 FailureBreakdown 分類。三句話文案刻意不含「額度」「4006」——
// 若 ClassifyFailure 認不得它,畫面上「今天的 AI 額度用完了」那類反而 0 份、
// 全部掉進「其他」。這支測試釘住「三句話 → 額度分類」這條線。
func TestClassifyFailure_QuotaNoticeCombined(t *testing.T) {
now := time.Date(2026, 8, 9, 3, 0, 0, 0, time.UTC)
notice := buildQuotaNotice(now, 105, nextQuotaResetTaiwan(now))
if got := ClassifyFailure(notice.Combined()); got != FailQuotaExhausted {
t.Fatalf("三句話應歸進額度分類,got %q(訊息:%s)", got, notice.Combined())
}
// 退避訊息會把三句話接在「|原因:」後(direct.go retrySkipReason)——同樣要認得
wrapped := "上次失敗(第 2 次),58m 後重試|原因:" + notice.Combined()
if got := ClassifyFailure(wrapped); got != FailQuotaExhausted {
t.Fatalf("包在退避訊息裡也應歸進額度分類,got %q", got)
}
}