(models, hardware, **kwargs)
| 414 | captured: dict[str, object] = {} |
| 415 | |
| 416 | def fake_rank_models(models, hardware, **kwargs): |
| 417 | captured["fit_filter"] = kwargs.get("fit_filter") |
| 418 | return [ |
| 419 | CompatibilityResult( |
| 420 | model=model, |
| 421 | gguf_variant=None, |
| 422 | can_run=True, |
| 423 | vram_required_bytes=4 * 1024**3, |
| 424 | vram_available_bytes=8 * 1024**3, |
| 425 | fit_type="full_gpu", |
| 426 | quality_score=80.0, |
| 427 | ) |
| 428 | ] |
| 429 | |
| 430 | monkeypatch.setattr( |
| 431 | "whichllm.hardware.detector.detect_hardware", lambda: _hw_with_gpu(8) |
nothing calls this directly
no test coverage detected