Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -20,16 +20,15 @@ def launch_bot():
|
|
20 |
return response
|
21 |
|
22 |
if 'cfg' not in st.session_state:
|
23 |
-
corpus_ids = str(os.environ['corpus_ids']).split(',')
|
24 |
cfg = OmegaConf.create({
|
25 |
'customer_id': str(os.environ['customer_id']),
|
26 |
-
'corpus_ids': corpus_ids,
|
27 |
'api_key': str(os.environ['api_key']),
|
28 |
'title': os.environ['title'],
|
29 |
'description': os.environ['description'],
|
30 |
'source_data_desc': os.environ['source_data_desc'],
|
31 |
'streaming': isTrue(os.environ.get('streaming', False)),
|
32 |
-
'questions': os.environ['questions'],
|
33 |
'prompt_name': os.environ.get('prompt_name', None)
|
34 |
})
|
35 |
st.session_state.cfg = cfg
|
|
|
20 |
return response
|
21 |
|
22 |
if 'cfg' not in st.session_state:
|
|
|
23 |
cfg = OmegaConf.create({
|
24 |
'customer_id': str(os.environ['customer_id']),
|
25 |
+
'corpus_ids': list(str(eval(os.environ['corpus_ids']))),
|
26 |
'api_key': str(os.environ['api_key']),
|
27 |
'title': os.environ['title'],
|
28 |
'description': os.environ['description'],
|
29 |
'source_data_desc': os.environ['source_data_desc'],
|
30 |
'streaming': isTrue(os.environ.get('streaming', False)),
|
31 |
+
'questions': list(eval(os.environ['questions'])),
|
32 |
'prompt_name': os.environ.get('prompt_name', None)
|
33 |
})
|
34 |
st.session_state.cfg = cfg
|