From 1b7540143ebfc2d3c159442458d4fe695f9d4fca Mon Sep 17 00:00:00 2001 From: Marcel Date: Sun, 12 Apr 2026 23:21:51 +0200 Subject: [PATCH] fix(ocr): persist model cache across container restarts Surya downloads models from HuggingFace to /root/.cache on first use. Without a volume, every container restart re-downloads ~73MB+. Added ocr_cache volume to persist the cache. Co-Authored-By: Claude Sonnet 4.6 --- docker-compose.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docker-compose.yml b/docker-compose.yml index 7eb50ef8..782d2071 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -82,6 +82,7 @@ services: memswap_limit: 8g volumes: - ocr_models:/app/models + - ocr_cache:/root/.cache environment: KRAKEN_MODEL_PATH: /app/models/german_kurrent.mlmodel OCR_CONFIDENCE_THRESHOLD: "0.3" @@ -186,3 +187,4 @@ volumes: frontend_node_modules: maven_cache: ocr_models: + ocr_cache: