Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -3,6 +3,7 @@ import os
|
|
| 3 |
import openai
|
| 4 |
import requests
|
| 5 |
import json
|
|
|
|
| 6 |
|
| 7 |
|
| 8 |
prompt_templates = {}
|
|
@@ -36,8 +37,12 @@ def getQuestionAndPrompt():
|
|
| 36 |
choice2=download_prompt_templates2()
|
| 37 |
return choice1,choice2
|
| 38 |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 39 |
question_textbox = gr.Textbox(label="", lines=10)
|
| 40 |
prompt_textbox = gr.Textbox(label="", lines=10)
|
| 41 |
-
gr.Interface(fn=
|
| 42 |
inputs=[],
|
| 43 |
outputs=[question_textbox, prompt_textbox]).launch()
|
|
|
|
| 3 |
import openai
|
| 4 |
import requests
|
| 5 |
import json
|
| 6 |
+
import pandas as pd
|
| 7 |
|
| 8 |
|
| 9 |
prompt_templates = {}
|
|
|
|
| 37 |
choice2=download_prompt_templates2()
|
| 38 |
return choice1,choice2
|
| 39 |
|
| 40 |
+
def test():
|
| 41 |
+
table = pd.read_csv("prompts.csv", header=0).astype(str)
|
| 42 |
+
return "",table
|
| 43 |
+
|
| 44 |
question_textbox = gr.Textbox(label="", lines=10)
|
| 45 |
prompt_textbox = gr.Textbox(label="", lines=10)
|
| 46 |
+
gr.Interface(fn=table,
|
| 47 |
inputs=[],
|
| 48 |
outputs=[question_textbox, prompt_textbox]).launch()
|