Hello,
I read this article to learn how to compute embeddings for texts: Getting Started With Embeddings
Here is the code I am running.
api_url = https://api-inference.huggingface.co/pipeline/feature-extraction/sentence-transformers/all-MiniLM-L6-v2
headers = {"Authorization": f"Bearer {api_token}"}
texts = ["How do I get a replacement Medicare card?",
"What is the monthly premium for Medicare Part B?",
]
response = requests.post(api_url, headers=headers, json={"inputs": texts, "options": {"wait_for_model": True}})
Unfortunately, I always get a 404 error.
Am I missing something?
Thank everyone for helping!
J-C