anumaurya114exp commited on
Commit
1d0f90f
·
1 Parent(s): 35cb8de

Update queryHelperManagerCoT.py

Browse files
Files changed (1) hide show
  1. queryHelperManagerCoT.py +1 -1
queryHelperManagerCoT.py CHANGED
@@ -133,7 +133,7 @@ ORDER BY chandelier_count DESC"""
133
  question = "top 5 customers who bought most chandeliers in nov 2023"
134
  promptForQuery = f"""You are a powerful text to sql model. Answer user input with sql query. And the query needs to run on {platform}. and schemaName is {schemaName}. There is example user input and desired generated sql query. Follow similar patterns as example. eg case insensitive, explicit variable declaration etc. user input : {question}, query : {exampleQuery}. and table's data is \n"""
135
  for idx, tableName in enumerate(prospectTablesAndCols.keys(), start=1):
136
- promptForQuery += f"table name is {tableName}, table data is {self.sampleData[tableName][prospectTablesAndCols[tableName]].head(gptSampleRows)}"
137
  promptForQuery += f"and table Relations are {TABLE_RELATIONS}"
138
  return promptForQuery.replace("\\"," ").replace(" "," ").replace("XXXX", " ")
139
 
 
133
  question = "top 5 customers who bought most chandeliers in nov 2023"
134
  promptForQuery = f"""You are a powerful text to sql model. Answer user input with sql query. And the query needs to run on {platform}. and schemaName is {schemaName}. There is example user input and desired generated sql query. Follow similar patterns as example. eg case insensitive, explicit variable declaration etc. user input : {question}, query : {exampleQuery}. and table's data is \n"""
135
  for idx, tableName in enumerate(prospectTablesAndCols.keys(), start=1):
136
+ promptForQuery += f"table name is {tableName}, table data is {self.sampleData[tableName][prospectTablesAndCols[tableName]].head(self.gptSampleRows)}"
137
  promptForQuery += f"and table Relations are {TABLE_RELATIONS}"
138
  return promptForQuery.replace("\\"," ").replace(" "," ").replace("XXXX", " ")
139