yakine commited on
Commit
eaf6f50
·
verified ·
1 Parent(s): 1ab421e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -2
app.py CHANGED
@@ -11,6 +11,10 @@ import accelerate
11
  from accelerate import init_empty_weights, disk_offload
12
  from fastapi.middleware.cors import CORSMiddleware
13
 
 
 
 
 
14
  app.add_middleware(
15
  CORSMiddleware,
16
  allow_origins=["*"], # You can specify domains here
@@ -19,8 +23,6 @@ app.add_middleware(
19
  allow_headers=["*"],
20
  )
21
 
22
- app = FastAPI()
23
-
24
  # Access the Hugging Face API token from environment variables
25
  hf_token = os.getenv('HF_API_TOKEN')
26
 
 
11
  from accelerate import init_empty_weights, disk_offload
12
  from fastapi.middleware.cors import CORSMiddleware
13
 
14
+
15
+
16
+ app = FastAPI()
17
+
18
  app.add_middleware(
19
  CORSMiddleware,
20
  allow_origins=["*"], # You can specify domains here
 
23
  allow_headers=["*"],
24
  )
25
 
 
 
26
  # Access the Hugging Face API token from environment variables
27
  hf_token = os.getenv('HF_API_TOKEN')
28