# set config for uvicorn workers | |
from uvicorn.workers import UvicornWorker | |
class ConfigurableWorker(UvicornWorker): | |
""" | |
Define a UvicornWorker that can be configured by modifying its class attribute. | |
""" | |
CONFIG_KWARGS = { | |
"root_path": "/ai", | |
"ws_ping_interval": 5, | |
"ws_ping_timeout": 200, | |
} | |