From 70acea30a58c55288c1d31c630801e9498b24114 Mon Sep 17 00:00:00 2001 From: Civitasv Date: Sun, 30 Apr 2023 13:19:46 +0800 Subject: Feat: add proxy settings in GUI and library. --- gui/streamlit_chat_app.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'gui/streamlit_chat_app.py') diff --git a/gui/streamlit_chat_app.py b/gui/streamlit_chat_app.py index 68011229..3d18333a 100644 --- a/gui/streamlit_chat_app.py +++ b/gui/streamlit_chat_app.py @@ -76,7 +76,7 @@ user_input = input_placeholder.text_input( submit_button = st.button("Submit") if user_input or submit_button: - output = query(user_input, st.session_state['query_method']) + output = query(user_input, st.session_state['query_method'], st.session_state['proxy']) escaped_output = output.encode('utf-8').decode('unicode-escape') st.session_state.current_conversation['user_inputs'].append(user_input) @@ -94,6 +94,9 @@ if st.sidebar.button("New Conversation"): st.session_state['query_method'] = st.sidebar.selectbox("Select API:", options=avail_query_methods, index=0) +# Proxy +st.session_state['proxy'] = st.sidebar.text_input("Proxy: ") + # Sidebar st.sidebar.header("Conversation History") -- cgit v1.2.3