Drop in a screenshot and convert it to clean code (HTML/Tailwind/React/Vue)
Python
feat: add MOCK env variable for debugging purposes
vagusxba9aa5504175
diff --git a/README.md b/README.mdindex a6dfabc8..9337a40f 100644--- a/README.md+++ b/README.md@@ -31,6 +31,9 @@ echo "OPENAI_API_KEY=sk-your-key" > .envpoetry installpoetry shellpoetry run uvicorn main:app --reload --port 7001++# Useful for debugging purposes when you don't want to waste GPT4-Vision credits+MOCK=true poetry run uvicorn main:app --reload --port 7001```Run the frontend:diff --git a/backend/main.py b/backend/main.pyindex 72b4dd7a..1dc93330 100644--- a/backend/main.py+++ b/backend/main.py@@ -33,7 +33,7 @@ app.add_middleware(# Useful for debugging purposes when you don't want to waste GPT4-Vision credits# Setting to True will stream a mock response instead of calling the OpenAI API-SHOULD_MOCK_AI_RESPONSE = False+SHOULD_MOCK_AI_RESPONSE = os.environ.get("MOCK", False)app.include_router(screenshot.router)