sarch7040 commited on
Commit
38ef986
·
verified ·
1 Parent(s): 3486cf3

Update langchain_logic/agent_setup.py

Browse files
Files changed (1) hide show
  1. langchain_logic/agent_setup.py +4 -1
langchain_logic/agent_setup.py CHANGED
@@ -6,6 +6,8 @@ from langchain_google_genai import ChatGoogleGenerativeAI
6
  from langchain_logic.tools import schedule_appointment, search_for_appointments, delete_appointment_records, update_appointment_record, list_all_appointments
7
  from datetime import datetime
8
 
 
 
9
  def create_agent_executor():
10
  """Creates the LangChain agent and executor."""
11
  # Add the new tool to the list
@@ -16,8 +18,9 @@ def create_agent_executor():
16
  delete_appointment_records,
17
  update_appointment_record
18
  ]
 
19
 
20
- llm = ChatGoogleGenerativeAI(model="gemini-2.5-flash-lite-preview-06-17", temperature=0, google_api_key=os.getenv("GOOGLE_API_KEY"))
21
 
22
  # You can optionally update the prompt to mention the new capability
23
  prompt = ChatPromptTemplate.from_messages([
 
6
  from langchain_logic.tools import schedule_appointment, search_for_appointments, delete_appointment_records, update_appointment_record, list_all_appointments
7
  from datetime import datetime
8
 
9
+ google_api_key=os.getenv("GOOGLE_API_KEY")
10
+
11
  def create_agent_executor():
12
  """Creates the LangChain agent and executor."""
13
  # Add the new tool to the list
 
18
  delete_appointment_records,
19
  update_appointment_record
20
  ]
21
+
22
 
23
+ llm = ChatGoogleGenerativeAI(model="gemini-2.5-flash-lite-preview-06-17", temperature=0, google_api_key=google_api_key)
24
 
25
  # You can optionally update the prompt to mention the new capability
26
  prompt = ChatPromptTemplate.from_messages([