santacl commited on
Commit
bc62be8
Β·
verified Β·
1 Parent(s): 7c1e03c

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +9 -1
app.py CHANGED
@@ -38,7 +38,15 @@ model = PeftModel.from_pretrained(base, adapter_repo, subfolder="checkpoint-240"
38
  print("Model ready")
39
 
40
  # RATE LIMITER
41
- app = FastAPI(title="Dolphin-12B-LoRA API")
 
 
 
 
 
 
 
 
42
 
43
  limiter = Limiter(key_func=get_remote_address)
44
  app.state.limiter = limiter
 
38
  print("Model ready")
39
 
40
  # RATE LIMITER
41
+ app = FastAPI(title="PROMETHEUS")
42
+
43
+ app.add_middleware(
44
+ CORSMiddleware,
45
+ allow_origins=["*"],
46
+ allow_credentials=True,
47
+ allow_methods=["*"],
48
+ allow_headers=["*"],
49
+ )
50
 
51
  limiter = Limiter(key_func=get_remote_address)
52
  app.state.limiter = limiter