Pranav1908's picture
Upload 2 files
964e707 verified
raw
history blame
No virus
407 Bytes
from fastapi import FastAPI
from app import predict
import os
from huggingface_hub import login
os.environ['HF_HOME'] = '/hug/cache/'
os.environ['TRANSFORMERS_CACHE'] = '/blabla/cache/'
app = FastAPI()
@app.get("/")
async def root():
return {"Code Review Automation":"Version 1.0 'First Draft'"}
@app.post("/AutomateReview/")
def predict(input_json: str):
return predict(input_json)