Files
backend_v2/db/migrations/2026-09-30-02-title-cn-memory.sql
toom1996 1b06bd5bda update
2026-09-30 11:58:32 +08:00

13 lines
768 B
SQL
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

-- 标题中文翻译记忆表:记录「英文标题 → 人工确认的中文标题」映射。
--
-- 用途:标题高度固定(品牌/年份/季节/系列/城市),绝大多数可规则翻译;
-- 人工在后台纠正过的中文标题写入本表,之后无论入库还是编辑都优先命中,永久精确。
-- 写入方:仅由人工编辑保存时(BackstageHandler 的 Remember)upsert;
-- 入库(ingest)只读取不写入,避免把规则猜测的半成品固化成「真理」。
-- 读取方:TranslateService.SuggestTitleCn 记忆优先、规则兜底。
CREATE TABLE IF NOT EXISTS title_cn_memory (
title_en text NOT NULL PRIMARY KEY,
title_cn text NOT NULL,
updated_at integer NOT NULL DEFAULT 0
);