P1-3 镜牢饰品选择按体系关键词排序

Browse Source
- 包住 Mirror.acquire_ego_gift(type=1):上游取到卡片列表时整屏 OCR 一次,
  按坐标把文字归到卡上,命中当前体系关键词行数多的排前面;排序稳定,
  白棉花、已持有、体系图标仍由上游原逻辑处理,调用结束还原 find_element
- OCR 读引擎逐行结果,不用会合并同名文本的 {文本: 坐标},也不用 my_crop
- 关键词表 lc_mcp/data/gift_keywords.json,匹配前做与选队相同的归一(含震颐/沉论误读)
- LCP_GIFT_KEYWORDS=0 关闭(与上游完全一致),=<路径> 换表;表读不了记 [ERROR] 不装
- 单测执行上游真实 acquire_ego_gift,覆盖两张/三张卡、选一/选二、已持有、白棉花、误读

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
yws
2026-11-14 07:00:24 +00:00
co-authored by Claude Opus 5.5
parent e08edda27d
commit 2f8f15a886
6 changed files with 500 additions and 1 deletions
+2 -1
View File
@@ -13,7 +13,7 @@ from . import killswitch, preflight
from .aalc_engine import bootstrap from .aalc_engine import bootstrap
from .aalc_patches import (WindowGuard, driver_click_tasks, headless_hdr_warning, from .aalc_patches import (WindowGuard, driver_click_tasks, headless_hdr_warning,
install_default_battle_team, install_exact_team_match, install_default_battle_team, install_exact_team_match,
install_robust_set_foreground, install_shop_lists, install_gift_preference, install_robust_set_foreground, install_shop_lists,
install_system_team_selection, install_typed_keyboard_road, install_system_team_selection, install_typed_keyboard_road,
mirror_progress, stop_driver_click) mirror_progress, stop_driver_click)
from .game_lock import GameBusyError, exclusive_game from .game_lock import GameBusyError, exclusive_game
@@ -130,6 +130,7 @@ def _run(task, params):
install_system_team_selection(log=log) install_system_team_selection(log=log)
install_shop_lists(log=log) install_shop_lists(log=log)
install_typed_keyboard_road(log=log) install_typed_keyboard_road(log=log)
install_gift_preference(log=log)
guard = WindowGuard(screen, cfg, log=log) guard = WindowGuard(screen, cfg, log=log)
guard.start() guard.start()
restore_path = os.environ.get(RESTORE_ENV) restore_path = os.environ.get(RESTORE_ENV)