kiyer commited on
Commit
2b8b035
1 Parent(s): 7d0b0c1

update memory mgmt?

Browse files
Files changed (1) hide show
  1. app.py +4 -0
app.py CHANGED
@@ -4,6 +4,10 @@ st.set_page_config(layout="wide")
4
  openai_key = st.secrets["openai_key"]
5
  cohere_key = st.secrets['cohere_key']
6
 
 
 
 
 
7
  import numpy as np
8
  from abc import ABC, abstractmethod
9
  from typing import List, Dict, Any, Tuple
 
4
  openai_key = st.secrets["openai_key"]
5
  cohere_key = st.secrets['cohere_key']
6
 
7
+ # clear session state to free up ram
8
+ for key in st.session_state.keys():
9
+ del st.session_state[key]
10
+
11
  import numpy as np
12
  from abc import ABC, abstractmethod
13
  from typing import List, Dict, Any, Tuple