diff --git a/visual-retrieval-colpali/.env.example b/visual-retrieval-colpali/.env.example index 71b1af940..b6e1fbc3f 100644 --- a/visual-retrieval-colpali/.env.example +++ b/visual-retrieval-colpali/.env.example @@ -9,4 +9,5 @@ VESPA_CLOUD_MTLS_KEY="-----BEGIN PRIVATE KEY----- -----END PRIVATE KEY-----" VESPA_CLOUD_MTLS_CERT="-----BEGIN CERTIFICATE----- ... ------END CERTIFICATE-----" \ No newline at end of file +-----END CERTIFICATE-----" +HOT_RELOAD=true \ No newline at end of file diff --git a/visual-retrieval-colpali/main.py b/visual-retrieval-colpali/main.py index 8fa9d6067..ec87bddd9 100644 --- a/visual-retrieval-colpali/main.py +++ b/visual-retrieval-colpali/main.py @@ -394,4 +394,6 @@ def get(): if __name__ == "__main__": # ModelManager.get_instance() # Initialize once at startup - serve(port=7860) + HOT_RELOAD = os.getenv("HOT_RELOAD", "False").lower() == "true" + print(f"Starting app with hot reload: {HOT_RELOAD}") + serve(port=7860, reload=HOT_RELOAD)