yvann-ba / Robby-chatbot

AI chatbot 🤖 for chat with CSV, PDF, TXT files 📄 and YTB videos 🎥 | using Langchain🦜 | OpenAI | Streamlit ⚡
MIT License
782 stars 289 forks source link

token exceeds limit error fix #37

Closed chinesewebman closed 1 year ago

chinesewebman commented 1 year ago

this can prevent token exceeds limit error fix from OpenAI occurs. it's for gpt-3.5, if you choose gpt-4, maybe want to save the value in st.session_state, change it to 8192 or 32768 for gpt4-8k and gpt4-32k