Files
rookiestar28 d589717f5a feat(stage3): add 35 community error patterns with i18n support
STAGE 3: F12 Pattern Expansion Complete

Changes:
1. Added 7 community pattern JSON files (35 patterns total)
   - patterns/community/controlnet.json (8 ControlNet patterns)
   - patterns/community/lora.json (6 LoRA patterns)
   - patterns/community/vae.json (5 VAE patterns)
   - patterns/community/animatediff.json (4 AnimateDiff patterns)
   - patterns/community/ipadapter.json (4 IPAdapter patterns)
   - patterns/community/facerestore.json (3 FaceRestore patterns)
   - patterns/community/misc.json (5 misc patterns)

2. Updated ERROR_KEYS in i18n.py
   - Added 35 new error keys
   - Total patterns: 57 (22 builtin + 35 community)

3. Added translations for all new patterns
   - English (en): Complete ✅
   - 繁體中文 (zh_TW): Complete ✅
   - 简体中文 (zh_CN): Complete ✅
   - Other languages (ja, de, fr, it, es, ko): Fallback to English

Pattern Categories:
- ControlNet: 8 patterns (model loading, preprocessing, sizing)
- LoRA: 6 patterns (loading, compatibility, memory)
- VAE: 5 patterns (encoding/decoding, precision, tiling)
- AnimateDiff: 4 patterns (model, frames, context, memory)
- IPAdapter: 4 patterns (model, encoding, compatibility)
- FaceRestore: 3 patterns (model, detection, memory)
- Miscellaneous: 5 patterns (checkpoint, image format, sampler, scheduler, CLIP)

Testing:
- ✅ All 9 PatternLoader unit tests pass
- ✅ 57 patterns load successfully
- ✅ Pattern matching works correctly
- ✅ Translations verified for en/zh_TW/zh_CN
2026-01-03 04:56:10 +08:00

46 lines
1.5 KiB
JSON

{
"version": "1.0.0",
"patterns": [
{
"id": "animatediff_model_not_found",
"regex": "AnimateDiff.*model not found|motion_model.*not found|Could not find motion module",
"error_key": "ANIMATEDIFF_MODEL_NOT_FOUND",
"has_groups": false,
"priority": 80,
"category": "model_loading",
"tags": ["animatediff", "motion", "model"],
"notes": "AnimateDiff motion model file not found"
},
{
"id": "animatediff_frame_mismatch",
"regex": "AnimateDiff.*frame.*mismatch|video_frames.*expected.*got|frame count.*doesn't match",
"error_key": "ANIMATEDIFF_FRAME_MISMATCH",
"has_groups": false,
"priority": 75,
"category": "workflow",
"tags": ["animatediff", "frames", "video"],
"notes": "Frame count mismatch in AnimateDiff workflow"
},
{
"id": "animatediff_context_error",
"regex": "AnimateDiff.*context.*invalid|context_length.*out of range",
"error_key": "ANIMATEDIFF_CONTEXT_ERROR",
"has_groups": false,
"priority": 70,
"category": "workflow",
"tags": ["animatediff", "context", "parameter"],
"notes": "AnimateDiff context length invalid or out of range"
},
{
"id": "animatediff_oom",
"regex": "Out of memory.*AnimateDiff|OOM.*motion.*generation|CUDA out of memory.*animate",
"error_key": "ANIMATEDIFF_OOM",
"has_groups": false,
"priority": 90,
"category": "memory",
"tags": ["animatediff", "oom", "memory"],
"notes": "Out of memory during AnimateDiff generation"
}
]
}