Process video files to detect and identify faces of contestants from ViuTV's 全民造星 IV competition using face recognition. Manages contestant database, generates embeddings, and handles deployment to Cloudflare Workers.
Process video files from ViuTV's 全民造星 IV competition to detect and identify contestant faces using face recognition technology.
This skill helps you work with a face recognition video processing system that:
**NEVER delete, move, or modify without explicit user permission:**
**NEVER restore legacy files:**
When working with this system, recognize these key components:
**First-time setup:**
```bash
git clone https://github.com/yellowcandle/mv-face-recognition.git
cd mv-face-recognition
node scripts/setup-environment.js
```
**Download contestant data from HuggingFace:**
```bash
python scripts/upload_dataset_to_hf.py --download-only --download-dir source/photo/contestants
```
**Option A - Full automated pipeline (recommended):**
```bash
node scripts/run-full-pipeline.js
```
**Option B - Process individual video:**
```bash
cd mvp-processor
python process_video.py --input ../source/videos/your-video.mp4
```
**Option C - Batch processing:**
```bash
node scripts/batch-process-videos.js
```
**Always build from mvp-processor directory:**
```bash
cd mvp-processor
npm run build
```
**Verify SvelteKit build:**
```bash
ls -la build/_app/
```
**Automated deployment:**
```bash
node scripts/deploy-cloudflare.js
```
**Manual deployment steps:**
```bash
cd mvp-processor && npm run build && cd ..
node scripts/update-worker-assets.js
cd worker && wrangler deploy
```
**Verify deployment:**
```bash
curl -s "https://mv-face-recognition-api.herballemon.workers.dev/" | head -10
```
**Frontend tests:**
```bash
cd frontend
npm run test # Unit + component tests
npm run test:e2e # Playwright E2E tests
npm run test:coverage # Coverage report
```
**Python tests:**
```bash
cd mvp-processor
pytest tests/ --cov=. --cov-report=html
```
**Worker tests:**
```bash
cd worker
npm test
```
**Upload new photos to HuggingFace:**
```bash
python scripts/upload_dataset_to_hf.py --upload
```
**NEVER add photos back to Git:**
**Always document changes in DESIGN.md:**
**NEVER modify README.md without explicit permission**
1. Contestant photos live on HuggingFace, NOT in Git
2. Download photos before face recognition processing
3. Use `upload_dataset_to_hf.py` for all photo management
4. Rate limit: 256 commits/hour on HuggingFace (use batch uploads)
1. Frontend is ONLY in `mvp-processor/` directory
2. Use SvelteKit 2.x, NOT legacy Vite+Svelte
3. Build command MUST use `sveltekit()` plugin in vite.config.js
4. Verify `_app/` directory exists after build
1. Always test build before deploying to Cloudflare
2. Verify asset embedding includes `_app/` directory
3. Check all routes work: /, /video-player, /processing, /analytics
4. Test video player shows actual videos, not placeholders
1. Maintain coverage thresholds: Frontend 85%+, Python 80%+, Worker 90%+
2. Run integration tests before deployment
3. Never lower coverage requirements without justification
4. All 5 CI/CD jobs must pass before merge
**Issue: Photos missing locally**
```bash
python scripts/upload_dataset_to_hf.py --download-only --download-dir source/photo/contestants
```
**Issue: Deployment serves wrong app**
```bash
cd mvp-processor && rm -rf build && npm run build
ls -la build/_app/
cd .. && node scripts/update-worker-assets.js && cd worker && wrangler deploy
```
**Issue: Face recognition not working**
```bash
cat metadata/contestant_info.csv | wc -l # Should be 97 (96 + header)
ls -la source/photo/contestants/*/embeddings/
```
**Issue: Tests failing**
```bash
cd frontend && npm run test -- -u
cd mvp-processor && pip install -r requirements.txt
```
**Frontend Routes:**
**API Endpoints** (21 total):
**Video Processing:**
**Frontend:**
**Storage:**
**Complete workflow for new video:**
```bash
cp new-episode.mp4 source/videos/
python scripts/upload_dataset_to_hf.py --download-only --download-dir source/photo/contestants
cd mvp-processor
python process_video.py --input ../source/videos/new-episode.mp4
cd ..
node scripts/run-full-pipeline.js
```
Leave a review
No reviews yet. Be the first to review this skill!
# Download SKILL.md from killerskills.ai/api/skills/mv-face-recognition-processor/raw