Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -2,9 +2,16 @@ import os
|
|
2 |
import streamlit as st
|
3 |
from groq import Groq
|
4 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
5 |
# Initialize the Groq client
|
6 |
def initialize_client():
|
7 |
-
api_key = os.getenv("
|
8 |
if not api_key:
|
9 |
raise ValueError("API Key not found. Please set GROQ_API_KEY in the environment variables.")
|
10 |
return Groq(api_key=api_key)
|
|
|
2 |
import streamlit as st
|
3 |
from groq import Groq
|
4 |
|
5 |
+
os.environ["GROQ_API_KEY"] = "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"
|
6 |
+
|
7 |
+
|
8 |
+
# Set your Groq API key here (for local testing or direct assignment)
|
9 |
+
# Uncomment the following line and replace with your actual Groq API key
|
10 |
+
# os.environ["GROQ_API_KEY"] = "your_groq_api_key_here"
|
11 |
+
|
12 |
# Initialize the Groq client
|
13 |
def initialize_client():
|
14 |
+
api_key = os.getenv("GROQ_API_KEY")
|
15 |
if not api_key:
|
16 |
raise ValueError("API Key not found. Please set GROQ_API_KEY in the environment variables.")
|
17 |
return Groq(api_key=api_key)
|