sayyedAhmed's picture
Merge branch 'main' of https://huggingface.co/sayyedAhmed/Crisis_Severity_Predictor_LSTM
4441f04
raw
history blame
729 Bytes
# import requests
# import json
# import os
# # Your Hugging Face model URL
# API_URL = "sayyedAhmed/Crisis_Severity_Predictor_LSTM" # Replace with your model's URL
# # Load your Hugging Face API token
# API_KEY = os.getenv("HF_API_KEY") # Ensure the API key is stored in the environment or replace with the actual key
# headers = {
# "Authorization": f"Bearer {API_KEY}",
# "Content-Type": "application/json"
# }
# payload = {
# "inputs": "Your test input here" # Replace this with the actual input for your model
# }
# # Make the POST request to Hugging Face Inference API
# response = requests.post(API_URL, headers=headers, json=payload)
# # Print the response (the predictions)
# print(response.json())