File size: 400 Bytes
f14a605 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 |
from langchain_groq import ChatGroq
import os
api=os.getenv('groq_api')
def get_llm():
"""
Returns the language model instance (LLM) using ChatGroq API.
The LLM used is Llama 3.1 with a versatile 70 billion parameters model.
"""
return ChatGroq(
model="llama-3.3-70b-versatile",
temperature=0,
max_tokens=1024,
api_key=api
)
llm = get_llm()
|