Spaces:
Running
on
Zero
Running
on
Zero
Lord-Raven
commited on
Commit
·
d184de8
1
Parent(s):
d54f118
Messing with CORS
Browse files
app.py
CHANGED
|
@@ -5,13 +5,13 @@ from transformers import AutoTokenizer
|
|
| 5 |
from fastapi import FastAPI
|
| 6 |
from fastapi.middleware.cors import CORSMiddleware
|
| 7 |
|
| 8 |
-
classifier = pipeline(task='zero-shot-classification', model='
|
| 9 |
|
| 10 |
app = FastAPI()
|
| 11 |
|
| 12 |
app.add_middleware(
|
| 13 |
CORSMiddleware,
|
| 14 |
-
allow_origins=["https://statosphere-3704059fdd7e.c5v4v4jx6pq5.win"],
|
| 15 |
allow_credentials=True,
|
| 16 |
allow_methods=["*"],
|
| 17 |
allow_headers=["*"],
|
|
|
|
| 5 |
from fastapi import FastAPI
|
| 6 |
from fastapi.middleware.cors import CORSMiddleware
|
| 7 |
|
| 8 |
+
classifier = pipeline(task='zero-shot-classification', model='xenova/mobilebert-uncased-mnli')
|
| 9 |
|
| 10 |
app = FastAPI()
|
| 11 |
|
| 12 |
app.add_middleware(
|
| 13 |
CORSMiddleware,
|
| 14 |
+
allow_origins=["https://jhuhman.com"], #["https://statosphere-3704059fdd7e.c5v4v4jx6pq5.win"],
|
| 15 |
allow_credentials=True,
|
| 16 |
allow_methods=["*"],
|
| 17 |
allow_headers=["*"],
|