nitind1 commited on
Commit
4eae9f9
·
verified ·
1 Parent(s): bd68926

Upload app.py with huggingface_hub

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -66,7 +66,7 @@ from groq import Groq
66
  from mem0 import MemoryClient
67
  import streamlit as st
68
  from datetime import datetime
69
-
70
 
71
  #====================================SETUP=====================================#
72
  # Fetch secrets from Hugging Face Spaces
@@ -989,8 +989,8 @@ class NutritionBot:
989
  # Initialize the OpenAI client using the provided credentials
990
  self.client = ChatOpenAI(
991
  model_name="gpt-4o-mini", # Specify the model to use (e.g., GPT-4 optimized version)
992
- api_key=config.get("API_KEY"), # API key for authentication
993
- openai_api_base = config.get("OPENAI_API_BASE"),
994
  temperature=0 # Controls randomness in responses; 0 ensures deterministic results
995
  )
996
 
 
66
  from mem0 import MemoryClient
67
  import streamlit as st
68
  from datetime import datetime
69
+ from google.colab import userdata
70
 
71
  #====================================SETUP=====================================#
72
  # Fetch secrets from Hugging Face Spaces
 
989
  # Initialize the OpenAI client using the provided credentials
990
  self.client = ChatOpenAI(
991
  model_name="gpt-4o-mini", # Specify the model to use (e.g., GPT-4 optimized version)
992
+ api_key=os.environ["API_KEY"], # API key for authentication
993
+ openai_api_base = os.environ["OPENAI_API_BASE"],
994
  temperature=0 # Controls randomness in responses; 0 ensures deterministic results
995
  )
996