-
Notifications
You must be signed in to change notification settings - Fork 1
/
app.py
47 lines (39 loc) · 871 Bytes
/
app.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
from fastapi import FastAPI
from fastapi.middleware.cors import CORSMiddleware
from routers import evaluate
from routers import pre_test
from routers import mock_qa
from routers import asr
from routers import roadmap
from routers import Summarize
from internal.FFmpegSetup import manual_setup_ffmpeg
manual_setup_ffmpeg()
app = FastAPI(openapi_prefix="/ai")
app.add_middleware(
CORSMiddleware,
allow_origins=["*"],
allow_credentials=True,
allow_methods=["*"],
allow_headers=["*"]
)
app.include_router(
mock_qa.router,
tags=["mock_qa"]
)
app.include_router(asr.router)
app.include_router(
roadmap.router,
tags=["roadmap"]
)
app.include_router(
pre_test.router,
tags=["pre-test"]
)
app.include_router(
evaluate.router,
tags=["evaluate-test"]
)
app.include_router(
Summarize.router,
tags=["Summarize"]
)