fix(report): keep the chat annual card's Tajika list, finish KP headings, say the dasha caveat once (BUG-1282)

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017eEAG8HD3mm8gsKXgk8uU8
This commit is contained in:
Jesse_Chen
2026-10-08 22:30:33 +08:00
co-authored by Claude Opus 5.5
parent b8eef75871
commit a13f5c2683
9 changed files with 116 additions and 18 deletions
+11 -2
View File
@@ -223,8 +223,8 @@ def _sanitize_pl9_ai_density_markdown(markdown: str, title: str = "印度占星
text = text.replace("Natural friends", "天然友星")
text = text.replace("Natural enemies", "天然敌星")
text = text.replace("Temporary relation", "临时关系")
text = text.replace("Natal / KP Ruling Planets", "本命 / KP 征象星")
text = text.replace("Ruling Planets", "征象星")
text = text.replace("Natal / KP Ruling Planets", "本命 / KP 主宰星")
text = text.replace("Ruling Planets", "主宰星")
text = text.replace("Sub-Planets", "副行星")
text = text.replace("Planetary", "行星")
text = text.replace("Planets", "行星")
@@ -437,6 +437,13 @@ def _sanitize_pl9_ai_density_markdown(markdown: str, title: str = "印度占星
"Bhinnashtakavarga": "Bhinnashtakavarga 单星八分表",
"KP 行星 星座ificators": "KP 行星征象星",
"KP 宫位 Cusps and 星座ificators": "KP 宫头与征象星",
# Since the term pass stopped rewriting inside words (BUG-1274),
# "Significators" arrives intact; these keys match that spelling.
"KP 宫位 Cusps and Significators": "KP 宫头与征象星",
"KP 行星 Significators": "KP 行星征象星",
"KP Significators / 行星 宫主": "KP 征象星 / 行星主星",
"KP Chart / Cusps": "KP 星盘 / 宫头",
"Annual Tajika瑜伽 Rows": "年度 Tajika 瑜伽行",
"KP 星座ificators / 行星 Lords": "KP 征象星 / 行星主星",
"Upagraha / Sub-行星s 点位": "Upagraha / 副行星点位",
"大运 Tables": "Dasha 表格",
@@ -467,6 +474,8 @@ def _sanitize_pl9_ai_density_markdown(markdown: str, title: str = "印度占星
text = replace_natural_language_term(text, "house condition", "宫位条件")
for raw, public in zh_heading_repairs.items():
text = text.replace(raw, public)
# Heading lines only: a Latin yoga name keeps a space before 瑜伽 ("Dhana 瑜伽").
text = re.sub(r"(?m)^(#{1,6} .*?[A-Za-z])瑜伽", r"\1 瑜伽", text)
text = replace_natural_language_term(text, " condition", "宫条件")
zh_public_key_repairs = {
"mangal_dosha": "火星婚姻煞",