cleanup: remove dead code and duplicate docs
- Remove session-ses_2f27.md (161KB raw session log) - Remove 49 ROOT_* duplicate files across REFERENCE/ - Remove 14 duplicate files between REFERENCE/ root and history/ - Remove asr_legacy.rs (dead code, replaced by asr.rs) - Remove src/core/worker/ (duplicate JobWorker) - Remove src/core/layers/ (empty directory) - Remove 4 .bak files in src/ - Remove 7 dead private methods in worker/processor.rs - Remove backup directory from git tracking
This commit is contained in:
@@ -8,9 +8,8 @@
|
||||
import sys
|
||||
import json
|
||||
import argparse
|
||||
from typing import Dict, List, Optional, Any, Set
|
||||
from typing import Dict, List, Optional, Any
|
||||
from pathlib import Path
|
||||
import re
|
||||
|
||||
|
||||
class UnifiedSynonymProcessor:
|
||||
@@ -64,11 +63,11 @@ class UnifiedSynonymProcessor:
|
||||
return False
|
||||
|
||||
if data.get("format") != "unified_multilingual":
|
||||
print(f"錯誤: 格式必須為 'unified_multilingual'", file=sys.stderr)
|
||||
print("錯誤: 格式必須為 'unified_multilingual'", file=sys.stderr)
|
||||
return False
|
||||
|
||||
if not isinstance(data["synonym_groups"], list):
|
||||
print(f"錯誤: synonym_groups 必須是列表", file=sys.stderr)
|
||||
print("錯誤: synonym_groups 必須是列表", file=sys.stderr)
|
||||
return False
|
||||
|
||||
# 驗證每個同義詞組
|
||||
@@ -377,7 +376,7 @@ def main():
|
||||
}
|
||||
print(json.dumps(result, ensure_ascii=False, indent=2))
|
||||
else:
|
||||
print(f"跨語言同義詞映射")
|
||||
print("跨語言同義詞映射")
|
||||
print(f"術語數量: {len(cross_mapping)}")
|
||||
print("\n映射:")
|
||||
for term, synonyms in list(cross_mapping.items())[:10]: # 只顯示前10個
|
||||
@@ -415,7 +414,7 @@ def main():
|
||||
print(f" 語言: {group['language']}")
|
||||
|
||||
if group.get("is_primary"):
|
||||
print(f" 匹配類型: 主要術語")
|
||||
print(" 匹配類型: 主要術語")
|
||||
elif "matched_synonym" in group:
|
||||
print(f" 匹配類型: 同義詞 ({group['matched_synonym']})")
|
||||
elif "matched_translation" in group:
|
||||
|
||||
Reference in New Issue
Block a user