api_server ¶
Classes¶
Functions:¶
fastvideo.entrypoints.openai.api_server.create_app ¶
create_app(fastvideo_args: FastVideoArgs, output_dir: str = DEFAULT_OUTPUT_DIR, default_request: GenerationRequest | None = None) -> FastAPI
Build the FastAPI application with all routers mounted
Source code in fastvideo/entrypoints/openai/api_server.py
fastvideo.entrypoints.openai.api_server.lifespan async ¶
lifespan(app: FastAPI) -> AsyncIterator[None]
Load model on startup, clean up on shutdown
Source code in fastvideo/entrypoints/openai/api_server.py
fastvideo.entrypoints.openai.api_server.run_server ¶
run_server(fastvideo_args: FastVideoArgs, host: str = DEFAULT_HOST, port: int = DEFAULT_PORT, output_dir: str = DEFAULT_OUTPUT_DIR, default_request: GenerationRequest | None = None)
Create the app and run it with uvicorn