Hyeonseo commited on
Commit
4e9814e
β€’
1 Parent(s): ff4497e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -1
app.py CHANGED
@@ -45,6 +45,9 @@ def translate_with_upload(text, file):
45
  openapi_key = text
46
 
47
  if file is not None:
 
 
 
48
  text_input = file.read().decode('utf-8')
49
  print(text_input)
50
  # ν…μŠ€νŠΈμ—μ„œ μ½”λ“œ 블둝을 μ œκ±°ν•©λ‹ˆλ‹€.
@@ -65,7 +68,7 @@ prompt_translate = gr.Interface(
65
  inputs=inputs,
66
  outputs=outputs,
67
  title="ChatGPT Korean Prompt Translation",
68
- description="Translate your text into Korean using the GPT-3 model."
69
  )
70
 
71
  prompt_translate.launch()
 
45
  openapi_key = text
46
 
47
  if file is not None:
48
+ print("Uploaded file name:", file.name)
49
+ print("Uploaded file content:")
50
+ print(file.read().decode('utf-8'))
51
  text_input = file.read().decode('utf-8')
52
  print(text_input)
53
  # ν…μŠ€νŠΈμ—μ„œ μ½”λ“œ 블둝을 μ œκ±°ν•©λ‹ˆλ‹€.
 
68
  inputs=inputs,
69
  outputs=outputs,
70
  title="ChatGPT Korean Prompt Translation",
71
+ description="Translate your text into Korean using the GPT-3 model.", verbose=True
72
  )
73
 
74
  prompt_translate.launch()