Spaces:
Runtime error
Runtime error
update
Browse files
app.py
CHANGED
@@ -65,14 +65,13 @@ with demo:
|
|
65 |
"Instruction: Given an input question, respond with syntactically correct PostgreSQL. Only use table called 'employees'.\nInput: Select names of all theemployees who have third character in their name as 't'.\nPostgreSQL query: ",
|
66 |
"Instruction: Given an input question, respond with syntactically correct PostgreSQL. Only use table called 'employees'.\nInput: Select names of all the employees who are working under 'Peter'\nPostgreSQL query: ", ], label= "Choose a sample Prompt")
|
67 |
|
68 |
-
with gr.Column:
|
69 |
-
|
70 |
-
b1 = gr.Button("Generate SQL")
|
71 |
|
72 |
with gr.Row():
|
73 |
generated_txt = gr.Textbox(lines=3)
|
74 |
-
|
75 |
-
|
76 |
b1.click(sql_generate,inputs=[example_prompt, input_prompt_sql], outputs=generated_txt)
|
77 |
|
78 |
with gr.Row():
|
|
|
65 |
"Instruction: Given an input question, respond with syntactically correct PostgreSQL. Only use table called 'employees'.\nInput: Select names of all theemployees who have third character in their name as 't'.\nPostgreSQL query: ",
|
66 |
"Instruction: Given an input question, respond with syntactically correct PostgreSQL. Only use table called 'employees'.\nInput: Select names of all the employees who are working under 'Peter'\nPostgreSQL query: ", ], label= "Choose a sample Prompt")
|
67 |
|
68 |
+
#with gr.Column:
|
69 |
+
input_prompt_sql = gr.Textbox(label="Or Write text following the example pattern given below, to get SQL commands...", value="Only use table called 'department'.\nInput: Select names of all the departments in descending alphabetical order of department names.\nPostgreSQL query: ", lines=5)
|
|
|
70 |
|
71 |
with gr.Row():
|
72 |
generated_txt = gr.Textbox(lines=3)
|
73 |
+
b1 = gr.Button("Generate SQL")
|
74 |
+
|
75 |
b1.click(sql_generate,inputs=[example_prompt, input_prompt_sql], outputs=generated_txt)
|
76 |
|
77 |
with gr.Row():
|