rgp230 commited on
Commit
2398527
·
1 Parent(s): 7967a23

feat(QuestionModel): Complete for deploy

Browse files
Files changed (1) hide show
  1. src/streamlit_app.py +4 -4
src/streamlit_app.py CHANGED
@@ -17,7 +17,7 @@ class StreamlitConfigUI:
17
  A Streamlit UI class that uses ConfigParser to load settings from an INI file.
18
  """
19
 
20
- def __init__(self, config_file: str = "./streamlitui/uiconfigfile.ini"):
21
  """
22
  Initialize the UI class with configuration file.
23
 
@@ -92,9 +92,9 @@ if __name__=='__main__':
92
  user_input=ui.load_streamlit_ui()
93
  LLM_Selection=ModelSelection(user_input)
94
  if user_input["GENAI_API_KEY"]:llm=LLM_Selection.setup_llm_model()
95
- loaded_tokenizer = DistilBertTokenizerFast.from_pretrained('./train_bert/topic_classifier_model')
96
- loaded_model = TFDistilBertForSequenceClassification.from_pretrained('./train_bert/topic_classifier_model')
97
- df_keys=pd.read_csv('train_bert/training_data/Keyword_Patterns.csv')
98
 
99
  if not user_input:
100
  st.error("Error: Failed to load user input from the UI.")
 
17
  A Streamlit UI class that uses ConfigParser to load settings from an INI file.
18
  """
19
 
20
+ def __init__(self, config_file: str = "src/streamlitui/uiconfigfile.ini"):
21
  """
22
  Initialize the UI class with configuration file.
23
 
 
92
  user_input=ui.load_streamlit_ui()
93
  LLM_Selection=ModelSelection(user_input)
94
  if user_input["GENAI_API_KEY"]:llm=LLM_Selection.setup_llm_model()
95
+ loaded_tokenizer = DistilBertTokenizerFast.from_pretrained('src/train_bert/topic_classifier_model')
96
+ loaded_model = TFDistilBertForSequenceClassification.from_pretrained('src/train_bert/topic_classifier_model')
97
+ df_keys=pd.read_csv('src/train_bert/training_data/Keyword_Patterns.csv')
98
 
99
  if not user_input:
100
  st.error("Error: Failed to load user input from the UI.")