002 / app.py
CaiRou-Huang's picture
Create app.py
fa0c876
raw
history blame contribute delete
340 Bytes
import requests
API_URL = "/static-proxy?url=https%3A%2F%2Fapi-inference.huggingface.co%2Fmodels%2Fgpt2%26quot%3B%3C%2Fspan%3E%3C!-- HTML_TAG_END -->
headers = {"Authorization": f"Bearer {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}"}
def query(payload):
response = requests.post(API_URL, headers=headers, json=payload)
return response.json()
data = query("Can you please let us know more details about your ")