Serhan Yılmaz
commited on
Commit
·
8dbc6b8
1
Parent(s):
98f4961
permanent storage fix
Browse files
pas2.py
CHANGED
@@ -380,8 +380,8 @@ Your response should be a JSON with the following fields:
|
|
380 |
class HallucinationDetectorApp:
|
381 |
def __init__(self):
|
382 |
self.pas2 = None
|
383 |
-
# Use persistent storage
|
384 |
-
self.data_dir = "
|
385 |
self.db_path = os.path.join(self.data_dir, "feedback.db")
|
386 |
logger.info("Initializing HallucinationDetectorApp")
|
387 |
self._initialize_database()
|
|
|
380 |
class HallucinationDetectorApp:
|
381 |
def __init__(self):
|
382 |
self.pas2 = None
|
383 |
+
# Use the default HF Spaces persistent storage location
|
384 |
+
self.data_dir = os.path.join(os.path.dirname(os.path.abspath(__file__)), "data")
|
385 |
self.db_path = os.path.join(self.data_dir, "feedback.db")
|
386 |
logger.info("Initializing HallucinationDetectorApp")
|
387 |
self._initialize_database()
|