from fastapi import FastAPI from transformers import pipeline app = FastAPI() # Load a Hugging Face model model = pipeline("text-classification", model="distilbert-base-uncased-finetuned-sst-2-english") print("i am gherer enjoying ") @app.post("/predict") async def predict(): return { "i am in lodhran "}