Spaces:
Sleeping
Sleeping
Commit ·
6ec5095
1
Parent(s): 2dee873
upgraded to mistral 7b v0.2
Browse files17 unmodified lines18192021212223242547 unmodified lines737475757677787928 unmodified lines10810911011011111211311490 unmodified lines20520620720720820921021117 unmodified linespinecone_index = pinecone.Index('ikigai-chat')text_vectorizer = SentenceTransformer('all-distilroberta-v1')chat_bots = { "Mistral 7B v0.2" : "mistralai/Mistral-7B-Instruct-v0.2", "Mistral 7B" : "mistralai/Mistral-7B-Instruct-v0.1", "Mistral 7B v0.1" : "mistralai/Mistral-7B-Instruct-v0.1", "Zephyr 7B-beta": "HuggingFaceH4/zephyr-7b-beta", "Zephyr 7B-alpha" : "HuggingFaceH4/zephyr-7b-alpha",}47 unmodified lines
data = { "Attribute": ["LLM", "Text Vectorizer", "Vector Database","CPU", "System RAM"], "Information": ["Mistral-7B-Instruct-v0.1","all-distilroberta-v1", "Hosted Pinecone" ,"2 vCPU", "16 GB"] "Information": ["Mistral-7B-Instruct-v0.2","all-distilroberta-v1", "Hosted Pinecone" ,"2 vCPU", "16 GB"]}df = pd.DataFrame(data)
28 unmodified lines st.session_state.rag_enabled = True
if "chat_bot" not in st.session_state : st.session_state.chat_bot = "Mistral 7B" st.session_state.chat_bot = "Mistral 7B v0.2"
with st.sidebar: st.markdown("# Retrieval Settings")90 unmodified lines len_response = (len(prompt.split()) + len(full_response.split())) * 1.25 st.session_state["tokens_used"] = len_response + st.session_state["tokens_used"]
if st.session_state["tokens_used"] > 15000 : if st.session_state["tokens_used"] > 12000 : st.session_state.history = st.session_state.history[-3:]
st.session_state.history.append([prompt, full_response])app.py+5-4