mertcobanov commited on
Commit
ec1043f
1 Parent(s): 074fb63

Fix: text input

Browse files
Files changed (1) hide show
  1. app.py +6 -4
app.py CHANGED
@@ -115,9 +115,11 @@ with gr.Blocks() as demo:
115
  )
116
  with gr.Row():
117
  img_area = gr.Image(label="Ekran Görüntüsü yükleyin 👇")
118
- ocr_result = gr.Textbox(label="Metin yükleyin 👇 ")
 
 
119
  open_api_text = gr.Textbox(label="Tam Adres")
120
- run_button = gr.Button(value="Veriyi İşle", label="Yükle")
121
  with gr.Column():
122
  with gr.Row():
123
  city = gr.Textbox(label="İl", interactive=True)
@@ -140,8 +142,8 @@ with gr.Blocks() as demo:
140
  api_name="upload_image",
141
  )
142
 
143
- ocr_result.change(
144
- openai_response, ocr_result, open_api_text, api_name="upload-text"
145
  )
146
 
147
  open_api_text.change(
 
115
  )
116
  with gr.Row():
117
  img_area = gr.Image(label="Ekran Görüntüsü yükleyin 👇")
118
+ with gr.Column():
119
+ text_area = gr.Textbox(label="Metin yükleyin 👇 ")
120
+ text_area_button = gr.Button(value='Metni Yukle', label='Submit')
121
  open_api_text = gr.Textbox(label="Tam Adres")
122
+ run_button = gr.Button(value="Veriyi İşle")
123
  with gr.Column():
124
  with gr.Row():
125
  city = gr.Textbox(label="İl", interactive=True)
 
142
  api_name="upload_image",
143
  )
144
 
145
+ text_area_button.click(
146
+ openai_response, text_area, open_api_text, api_name="upload-text"
147
  )
148
 
149
  open_api_text.change(