Spaces:
Sleeping
Sleeping
File size: 398 Bytes
be6358b f256faf 6efd257 f256faf 51c8824 f256faf 57e8869 f256faf |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
import os
from groq import Groq
def responsr(prompt):
client = Groq(
api_key=os.environ['key'],
)
chat_completion = client.chat.completions.create(
messages=[
{
"role": "user",
"content": prompt,
}
],
model="llama3-8b-8192",
)
return (chat_completion.choices[0].message.content) |