{"record":{"id":"2f5c653af8b74309","repo":"vllm-project/vllm","slug":"no-recipe-model-matched-requested-r","errorCode":null,"errorMessage":"No recipe model matched {requested!r}.","messagePattern":"No recipe model matched (.+?)\\.","errorType":"exception","errorClass":"ValueError","httpStatus":null,"severity":"error","filePath":"tools/recipes/recipe_json_to_vllm_config.py","lineNumber":236,"sourceCode":"            continue\n        if 1 <= index <= len(items):\n            return items[index - 1]\n        print(f\"Enter a number from 1 to {len(items)}.\")\n\n\ndef select_model(models: list[dict[str, Any]], requested: str | None) -> dict[str, Any]:\n    query = requested\n    while True:\n        if not query:\n            query = prompt(\"Model search (for example: llama 3.1): \")\n\n        matches = search_models(models, query)\n        if matches:\n            print(\"\\nMatching models:\")\n            return choose_from_menu(matches, model_label, \"Select model: \")\n\n        if requested:\n            raise ValueError(f\"No recipe model matched {requested!r}.\")\n\n        print(f\"No recipe model matched {query!r}. Try again.\")\n        query = None\n\n\ndef select_hardware(\n    by_hardware: dict[str, str], requested: str | None\n) -> tuple[str, str]:\n    hardware_ids = sorted(by_hardware)\n\n    if requested:\n        selected = next(\n            (hw for hw in hardware_ids if hw.lower() == requested.lower()),\n            None,\n        )\n        if selected is None:\n            raise ValueError(\n                f\"Hardware {requested!r} is not available for this model. \"","sourceCodeStart":218,"sourceCodeEnd":254,"githubUrl":"https://github.com/vllm-project/vllm/blob/c794754062d49a8fdb63ab3c5215b488b865030c/tools/recipes/recipe_json_to_vllm_config.py#L218-L254","documentation":"select_model() searches the recipe catalog with your --model string; when an explicit (non-interactive) request yields no matches after scoring, it raises ValueError naming the requested string. This only fires when the query came from the CLI — interactive queries loop instead.","triggerScenarios":"Passing --model with a string that fuzzy-matches nothing in models.json (typpos, unknown model names, or models absent from the recipe catalog).","commonSituations":"Asking for a newly released or niche model that has no published recipe; HF repo id spelled differently from the catalog's title/hf_id; using an alias the search doesn't know.","solutions":["Retry with a shorter, canonical fragment of the model name (e.g. 'llama 3.1' or 'qwen 2.5 72b').","Confirm the model is listed in the Recipes API's models.json before requesting it.","Drop --model to enter interactive search and browse what actually matches."],"exampleFix":"# before\npython tools/recipes/recipe_json_to_vllm_config.py --model \"llamma 3\"\n# -> ValueError: No recipe model matched 'llamma 3'.\n\n# after\npython tools/recipes/recipe_json_to_vllm_config.py --model \"llama 3\"","handlingStrategy":"validation","validationCode":"matches = search_models(models, requested)\nif requested and not matches:\n    raise SystemExit(f\"No recipe model matched {requested!r}; try a shorter query or drop --model\")","typeGuard":null,"tryCatchPattern":"try:\n    model = select_model(models, args.model)\nexcept ValueError as e:\n    raise SystemExit(f\"model selection failed: {e}\") from e","preventionTips":["Verify the model appears in the Recipes models.json listing before scripting against it.","Use broad search fragments in automation; keep exact names for humans."],"tags":["cli","recipes","search","tooling"],"backgroundTag":null,"analyzedSha":"c794754062d49a8fdb63ab3c5215b488b865030c","analyzedAt":"2026-08-14T21:17:39.825Z","schemaVersion":2},"datasetVersion":"2026-08-15T17:31:12.345Z"}