Eylon Caplan commited on
Commit
34245f6
·
1 Parent(s): 03d9c6c

Allow BM25_INDEX_DIR override for quick testing

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -9,8 +9,8 @@ from core_logic import (
9
  )
10
 
11
  # Path to the index directory where the Hugging Face Storage Bucket is mounted.
12
- # Assuming the bucket is mounted at /data in the Space settings.
13
- INDEX_DIR = '/data/bm25_indexes'
14
 
15
  def get_available_indices():
16
  if os.path.exists(INDEX_DIR):
 
9
  )
10
 
11
  # Path to the index directory where the Hugging Face Storage Bucket is mounted.
12
+ # Override with BM25_INDEX_DIR for local testing without code edits.
13
+ INDEX_DIR = os.getenv('BM25_INDEX_DIR', '/data/bm25_indexes')
14
 
15
  def get_available_indices():
16
  if os.path.exists(INDEX_DIR):