Spaces:
Sleeping
Sleeping
File size: 627 Bytes
ad7983e |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 |
#------------------------------------------------Import Packages---------------------------------------------#
from langchain_google_genai import GoogleGenerativeAI
from dotenv import load_dotenv
import os
#-----------------------------------------------------------------------------------------------------------#
load_dotenv()
# make a fun to load the genai model and get resposne
def load_mode_get_respose(question:str):
llm=GoogleGenerativeAI(google_api_key=os.environ['google_api'],
model='gemini-1.5-pro',temperature=0.4)
respose=llm(question)
yield respose |