Update app.py
Browse files
app.py
CHANGED
@@ -103,9 +103,9 @@ def show_confetti():
|
|
103 |
|
104 |
# Groq Llama AI API call
|
105 |
def ask_llama(conversation_history, category):
|
106 |
-
api_url = "https://api.groq.
|
107 |
headers = {
|
108 |
-
"Authorization": "Bearer
|
109 |
"Content-Type": "application/json"
|
110 |
}
|
111 |
|
@@ -117,7 +117,7 @@ def ask_llama(conversation_history, category):
|
|
117 |
] + conversation_history
|
118 |
|
119 |
data = {
|
120 |
-
"model": "llama-3.3-70b-versatile",
|
121 |
"messages": messages,
|
122 |
"temperature": 0.7,
|
123 |
"max_tokens": 100
|
|
|
103 |
|
104 |
# Groq Llama AI API call
|
105 |
def ask_llama(conversation_history, category):
|
106 |
+
api_url = "https://api.groq.com/openai/v1/chat/completions" # Updated API URL
|
107 |
headers = {
|
108 |
+
"Authorization": "Bearer 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", # Your new API key
|
109 |
"Content-Type": "application/json"
|
110 |
}
|
111 |
|
|
|
117 |
] + conversation_history
|
118 |
|
119 |
data = {
|
120 |
+
"model": "llama-3.3-70b-versatile", # The model you are using
|
121 |
"messages": messages,
|
122 |
"temperature": 0.7,
|
123 |
"max_tokens": 100
|