Fetching metadata from the HF Docker repository...
-
Sync from GitHub 7c37dac9
-
Comparison (#22)β
Carlos Salgado
* feat: add pre-commit hook to block root-level fix/apply scripts
- Add .pre-commit-config.yaml with local hook block-root-fix-scripts
- Add scripts/block_root_fix_scripts.py to check for *fix*.py and apply_*.py at root
- Add pre-commit to dev dependencies in pyproject.toml
- Document hook behavior in AGENTS.md
* feat: clean up app.py + add CVD selector & WCAG comparison tests
- Remove any self-modifying patterns from app.py
- Ensure idiomatic Gradio structure: pure functions, single Blocks, event wiring
- Add tests/test_cvd_selector.py (22 tests: CVD selector, cache, split-view layout)
- Add tests/test_wcag_comparison.py (10 tests: format_wcag_comparison behavior)
- All 42 tests pass (smoke + CVD selector + WCAG comparison)
-
fix: route inference through Modal endpoint instead of HF Router (#15)β
Carlos Salgado
* test: add E2E tests with real Modal/HF Router inference
- test_cvd_simulation_makes_buttons_indistinguishable: validates CVD pipeline
- test_analyze_with_vlm_produces_wcag_json: real VLM call, WCAG JSON structure
- test_run_analysis_full_pipeline: complete Gradio pipeline function
- 41/41 tests green
* fix: route inference through Modal endpoint instead of HF Router
app_space.py:
- Remove direct HF Router OpenAI calls (no more OpenAI import)
- Add _call_modal_analyze() helper: upload β predict β poll SSE
- analyze_with_vlm() now calls Modal endpoint (https://narwall-tech--color-ux-access-ui.modal.run/)
- Modal returns WCAG JSON via Gradio API: [dict] array β unwrap to plain dict
- HF_TOKEN not needed for inference; Space secrets only need MODAL_URL
tests/:
- tests/test_modal_integration.py: RED tests for Modal call (upload file β predict β poll)
- tests/test_vlm_model_selection.py: rewrite to test Modal path (mock _call_modal_analyze)
- tests/test_e2e.py: removed (tested old HF Rβ¦