Spaces:
Running
Running
Ashmi Banerjee
commited on
Commit
·
af87ffb
1
Parent(s):
82a36a6
trial
Browse files- app.py +11 -0
- utils/loaders.py +1 -1
- views/questions_screen.py +0 -11
app.py
CHANGED
@@ -12,6 +12,17 @@ from css.layout import custom_css
|
|
12 |
|
13 |
load_dotenv()
|
14 |
VALIDATION_CODE = os.getenv("VALIDATION_CODE")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
15 |
|
16 |
|
17 |
def initialization():
|
|
|
12 |
|
13 |
load_dotenv()
|
14 |
VALIDATION_CODE = os.getenv("VALIDATION_CODE")
|
15 |
+
if "VALIDATION_CODE" in os.environ:
|
16 |
+
VALIDATION_CODE = os.getenv("VALIDATION_CODE")
|
17 |
+
if "DATA_REPO" in os.environ:
|
18 |
+
REPO_NAME = os.getenv("DATA_REPO")
|
19 |
+
else:
|
20 |
+
print("DATA_REPO not found in environment variables.")
|
21 |
+
if "LLAMA_DATA_FILES" in os.environ:
|
22 |
+
DATA_FILES = os.getenv("LLAMA_DATA_FILES")
|
23 |
+
else:
|
24 |
+
print("LLAMA_DATA_FILES not found in environment variables.")
|
25 |
+
|
26 |
|
27 |
|
28 |
def initialization():
|
utils/loaders.py
CHANGED
@@ -13,7 +13,7 @@ DATA_FILES = os.getenv("LLAMA_DATA_FILES")
|
|
13 |
def load_data():
|
14 |
try:
|
15 |
#TODO: change this to load the data from the database (buggy for debugging)
|
16 |
-
data = pd.read_csv("
|
17 |
return data
|
18 |
except Exception as e:
|
19 |
|
|
|
13 |
def load_data():
|
14 |
try:
|
15 |
#TODO: change this to load the data from the database (buggy for debugging)
|
16 |
+
data = pd.read_csv("data/gemini_results_subset.csv")[:5]
|
17 |
return data
|
18 |
except Exception as e:
|
19 |
|
views/questions_screen.py
CHANGED
@@ -6,17 +6,6 @@ from dotenv import load_dotenv
|
|
6 |
from views.nav_buttons import navigation_buttons
|
7 |
|
8 |
load_dotenv()
|
9 |
-
if "VALIDATION_CODE" in os.environ:
|
10 |
-
VALIDATION_CODE = os.getenv("VALIDATION_CODE")
|
11 |
-
if "DATA_REPO" in os.environ:
|
12 |
-
REPO_NAME = os.getenv("DATA_REPO")
|
13 |
-
else:
|
14 |
-
print("DATA_REPO not found in environment variables.")
|
15 |
-
if "LLAMA_DATA_FILES" in os.environ:
|
16 |
-
DATA_FILES = os.getenv("LLAMA_DATA_FILES")
|
17 |
-
else:
|
18 |
-
print("LLAMA_DATA_FILES not found in environment variables.")
|
19 |
-
|
20 |
|
21 |
|
22 |
def survey_completed():
|
|
|
6 |
from views.nav_buttons import navigation_buttons
|
7 |
|
8 |
load_dotenv()
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
9 |
|
10 |
|
11 |
def survey_completed():
|