niro commited on
Commit
1ed62f9
·
1 Parent(s): f65d1fe
Files changed (2) hide show
  1. main.py +1 -1
  2. question.py +5 -1
main.py CHANGED
@@ -15,6 +15,7 @@ from stats import get_usage_today
15
  supabase_url = st.secrets.supabase_url
16
  supabase_key = st.secrets.supabase_service_key
17
  # openai_api_key = st.secrets.openai_api_key
 
18
  openai_api_key = st.secrets.openai_api_key_head+st.secrets.openai_api_key_tail
19
 
20
  anthropic_api_key = st.secrets.anthropic_api_key
@@ -36,7 +37,6 @@ st.set_page_config(
36
  initial_sidebar_state="expanded",
37
  )
38
 
39
-
40
  st.title("🧠 VantiGPT - Your second brain 🧠")
41
  st.markdown("ask your data anything.")
42
  if self_hosted == "false":
 
15
  supabase_url = st.secrets.supabase_url
16
  supabase_key = st.secrets.supabase_service_key
17
  # openai_api_key = st.secrets.openai_api_key
18
+
19
  openai_api_key = st.secrets.openai_api_key_head+st.secrets.openai_api_key_tail
20
 
21
  anthropic_api_key = st.secrets.anthropic_api_key
 
37
  initial_sidebar_state="expanded",
38
  )
39
 
 
40
  st.title("🧠 VantiGPT - Your second brain 🧠")
41
  st.markdown("ask your data anything.")
42
  if self_hosted == "false":
question.py CHANGED
@@ -10,10 +10,14 @@ from stats import add_usage
10
 
11
  memory = ConversationBufferMemory(
12
  memory_key="chat_history", return_messages=True)
13
- openai_api_key = st.secrets.openai_api_key_head+st.secrets.openai_api_key_tail
 
14
  anthropic_api_key = st.secrets.anthropic_api_key
15
  logger = get_logger(__name__)
16
 
 
 
 
17
 
18
  def count_tokens(question, model):
19
  count = f'Words: {len(question.split())}'
 
10
 
11
  memory = ConversationBufferMemory(
12
  memory_key="chat_history", return_messages=True)
13
+ # st.text(st.secrets)
14
+ # openai_api_key = st.secrets.openai_api_key_head+st.secrets.openai_api_key_tail
15
  anthropic_api_key = st.secrets.anthropic_api_key
16
  logger = get_logger(__name__)
17
 
18
+ openai_api_key = st.secrets.openai_api_key_head+st.secrets.openai_api_key_tail
19
+ print('niro','niro', openai_api_key)
20
+
21
 
22
  def count_tokens(question, model):
23
  count = f'Words: {len(question.split())}'