Yew Chong commited on
Commit
02eae13
1 Parent(s): bc4dcba

update README

Browse files
Files changed (2) hide show
  1. README.md +4 -0
  2. app_final.py +14 -2
README.md CHANGED
@@ -21,5 +21,9 @@ pinned: false
21
 
22
  5. Open `localhost:8501`
23
 
 
 
 
 
24
 
25
  ---------------------------------
 
21
 
22
  5. Open `localhost:8501`
23
 
24
+ Login with
25
+ - username: admin, password: admin
26
+ OR
27
+ - username: student1, password: password
28
 
29
  ---------------------------------
app_final.py CHANGED
@@ -40,6 +40,18 @@ import os, dotenv
40
  from dotenv import load_dotenv
41
  load_dotenv()
42
 
 
 
 
 
 
 
 
 
 
 
 
 
43
  if not os.path.isdir("./.streamlit"):
44
  os.mkdir("./.streamlit")
45
  print('made streamlit folder')
@@ -532,7 +544,8 @@ else:
532
 
533
  elif st.session_state.scenario_tab_index == ScenarioTabIndex.PATIENT_LLM:
534
  st.header("Patient info")
535
- st.write("Pull the info here!!!")
 
536
  col1, col2, col3 = st.columns([1,3,1])
537
  with col1:
538
  back_to_scenario_btn = st.button("Back to selection", on_click=set_scenario_tab_index, args=[ScenarioTabIndex.SELECT_SCENARIO])
@@ -712,7 +725,6 @@ else:
712
  import plotly.graph_objects as go
713
  import pandas as pd
714
 
715
- os.environ["FIREBASE_CREDENTIAL"] = dotenv.get_key(dotenv.find_dotenv(), "FIREBASE_CREDENTIAL")
716
  cred = credentials.Certificate(json.loads(os.environ.get("FIREBASE_CREDENTIAL")))
717
 
718
  # Initialize Firebase (if not already initialized)
 
40
  from dotenv import load_dotenv
41
  load_dotenv()
42
 
43
+ if not os.path.isdir("./.streamlit"):
44
+ os.mkdir("./.streamlit")
45
+ print('made streamlit folder')
46
+ if not os.path.isfile("./.streamlit/secrets.toml"):
47
+ with open("./.streamlit/secrets.toml", "w") as f:
48
+ f.write(os.environ.get("STREAMLIT_SECRETS"))
49
+ print('made new file')
50
+
51
+ import os, dotenv
52
+ from dotenv import load_dotenv
53
+ load_dotenv()
54
+
55
  if not os.path.isdir("./.streamlit"):
56
  os.mkdir("./.streamlit")
57
  print('made streamlit folder')
 
544
 
545
  elif st.session_state.scenario_tab_index == ScenarioTabIndex.PATIENT_LLM:
546
  st.header("Patient info")
547
+ ## TODO: Put the patient's info here, from SCENARIO
548
+ # st.write("Pull the info here!!!")
549
  col1, col2, col3 = st.columns([1,3,1])
550
  with col1:
551
  back_to_scenario_btn = st.button("Back to selection", on_click=set_scenario_tab_index, args=[ScenarioTabIndex.SELECT_SCENARIO])
 
725
  import plotly.graph_objects as go
726
  import pandas as pd
727
 
 
728
  cred = credentials.Certificate(json.loads(os.environ.get("FIREBASE_CREDENTIAL")))
729
 
730
  # Initialize Firebase (if not already initialized)