Gradio save_state problem and introducing a basic chatbot
Hello all,I have uploaded a more basic version of my chatbot tohttps://huggingface.co/spaces/gorkemgoknar/moviechatbot.If you checkout app.py code you can see how you can use a transformers model types which is not included in standart interface (do not forget requirements.txt to import modules)I also shared my model and information to usehttps://huggingface.co/gorkemgoknar/gpt2chatbotenglishA more feature rich version (including movie and character selection) is on :metayazar.com/chatbotwith Turkish version onhttps://www.metayazar.com/chatbot_trWhile building gradio app I noticed that save_state(history) get_state() does not work in embedded application. While gradio app is full screen it works but in HF spaces information is lost (likely due to Flask session not being statefull inside embedded fram).To overcome this I use a global history but likely this would make models history being shared between different users (not a problem for a demo and it may be fun), yet for information there should be a way to save state if HF Spaces would be a different product.
2021-12-22T14:02:48Z
Thanks for the detailed feedback@gorkemgoknar! I one of the Gradio developers and I’ll share this feedback with my team so that we can fix it. (We are working on a betterChatbotoutput component altogether!)