How kijai/comfyui-liveportraitkj works
Main Components (Top Level)
• Rectangle (Blue): Face Detection Systems
• Rectangle (Green): LivePortrait Pipeline
• Rectangle (Orange): ComfyUI Node Interface
• Rectangle (Purple): Media Processing
• Diamond (Gray): External Models/Resources
Face Detection Layer
• MediaPipe Detector
• Face Alignment Detector (with subcomponents: BlazeFace, SFD, Dlib)
• Insightface Detector (optional external)
To a "Face Detection Orchestrator" component that manages them.
LivePortrait Core (Middle Layer)
Create interconnected components for:
• Appearance Feature Extractor
• Motion Extractor
• Dense Motion Module
• SPADE Generator
• Warping Network
• Stitching Retargeting Network
Utility Layer
Supporting components:
• Camera Utils
• Cropping Utils
• Face Analysis
• Landmark Runner
• Timer/Performance Monitoring
External Dependencies (Bottom Layer)
External model dependencies:
• SafeTensor Models
• MediaPipe Models
• Face Landmark Models
Key Relationships to Highlight:
Input → Face Detection → Feature Extraction → Motion Processing → Generation → Output
Special Considerations:
Interface with ComfyUI's node system
• Blue: Input/Output components
• Green: Processing components
• Orange: Interface components
• Purple: Utility components
• Gray: External dependencies
Labels and Annotations:
Hardware requirements (GPU/CPU support)
Level of Detail:
• Face detection pipeline
• LivePortrait core processing
• Real-time processing optimization
Remember to:
• Notes about scaling and performance considerations
• Real-time capabilities (~80-100ms delay)
• Automatic resource downloading mechanism
• Configuration flow from the YAML files