We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I see you have an input field with a callback process_input:
process_input
st.text_input("Message", key="user_input", disabled=not is_openai_api_key_set(), on_change=process_input)
This callback process_input is:
def process_input(): if st.session_state["user_input"] and len(st.session_state["user_input"].strip()) > 0: user_text = st.session_state["user_input"].strip() with st.session_state["thinking_spinner"], st.spinner(f"Thinking"): query_text = st.session_state["pdfquery"].ask(user_text) st.session_state["messages"].append((user_text, True)) st.session_state["messages"].append((query_text, False))
Here you are only writing the response from the model into the st.session_state["messages"]. How the response is getting written the to the UI?
st.session_state["messages"]
Will appreciate if you can please add an explanation. Thanks.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
I see you have an input field with a callback
process_input
:This callback
process_input
is:Here you are only writing the response from the model into the
st.session_state["messages"]
. How the response is getting written the to the UI?Will appreciate if you can please add an explanation. Thanks.
The text was updated successfully, but these errors were encountered: