Sayandip commited on
Commit
411fd2c
·
verified ·
1 Parent(s): d8369ce

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +9 -1
app.py CHANGED
@@ -70,7 +70,15 @@ subjects_df = fetch_table("subjects")
70
  # --- Define SQL tool for the agent ---
71
  @tool
72
  def sql_engine(query: str) -> list:
73
- """Executes SQL queries on students and subjects and returns list of tuples."""
 
 
 
 
 
 
 
 
74
  try:
75
  print(f"🧩 Executing query: {query}")
76
  with engine.connect() as con:
 
70
  # --- Define SQL tool for the agent ---
71
  @tool
72
  def sql_engine(query: str) -> list:
73
+ """
74
+ Executes SQL queries on the available tables: students and subjects.
75
+
76
+ Args:
77
+ query (str): The SQL query string to execute.
78
+
79
+ Returns:
80
+ list: List of tuples containing the query results.
81
+ """
82
  try:
83
  print(f"🧩 Executing query: {query}")
84
  with engine.connect() as con: