feat: Updated backend/main.py

This commit is contained in:
sweep-ai[bot] 2023-11-30 16:34:08 +00:00 committed by GitHub
parent 2a6fc2874f
commit 47267aefb1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -17,6 +17,8 @@ from prompts import assemble_prompt
from routes import screenshot from routes import screenshot
from access_token import validate_access_token from access_token import validate_access_token
from server_status import status_router
app = FastAPI(openapi_url=None, docs_url=None, redoc_url=None) app = FastAPI(openapi_url=None, docs_url=None, redoc_url=None)
# Configure CORS # Configure CORS
@ -38,6 +40,7 @@ SHOULD_MOCK_AI_RESPONSE = bool(os.environ.get("MOCK", False))
app.include_router(screenshot.router) app.include_router(screenshot.router)
app.include_router(status_router, prefix='/status')
def write_logs(prompt_messages, completion): def write_logs(prompt_messages, completion):