st-chat icon indicating copy to clipboard operation
st-chat copied to clipboard

Sub - Message

Open masterchop opened this issue 11 months ago • 0 comments

On the example.py we can see that we have a dialog box for the user and the bot, when the bot responds is it possible to create a submessage? i want to provide sources but only if you want to see the sub-message otherwise it will be hidden. Is it possible with this library?

if st.session_state['generated']:

for i in range(len(st.session_state['generated'])-1, -1, -1):
    message(st.session_state["generated"][i], key=str(i))
    message(st.session_state['past'][i], is_user=True, key=str(i) + '_user')

Thanks

masterchop avatar Mar 13 '24 00:03 masterchop