Prechádzať zdrojové kódy

Fix model string name for Llama-Prompt-Guard-2-86M in inference.py

Nicholas Carlini 3 dní pred
rodič
commit
3c106f3e6e

+ 1 - 1
getting-started/responsible_ai/prompt_guard/inference.py

@@ -23,7 +23,7 @@ DEFAULT_MODEL_NAME = "meta-llama/Llama-Prompt-Guard-2-86M"
 
 
 def load_model_and_tokenizer(
-    model_name: str = "meta-llama/Prompt-Guard-2-86M", device: str = DEFAULT_DEVICE
+    model_name: str = "meta-llama/Llama-Prompt-Guard-2-86M", device: str = DEFAULT_DEVICE
 ) -> Tuple[AutoModelForSequenceClassification, AutoTokenizer, str]:
     """
     Load the PromptGuard model and tokenizer, and move the model to the specified device.