fudii0921 commited on
Commit
8e5e795
·
verified ·
1 Parent(s): f292630

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +9 -2
app.py CHANGED
@@ -48,10 +48,17 @@ def json_to_text(outname, param_array, tablename):
48
 
49
  # Upload the final_context to the server
50
  status, response_text = upload_text_to_server(final_context, server_url, outname)
 
 
 
 
 
 
51
  print(f"アップロードのステータス: {status}")
52
- print(f"レスポンス: {response_text}")
53
 
54
- return response_text
 
55
 
56
 
57
  # Gradioの関数
 
48
 
49
  # Upload the final_context to the server
50
  status, response_text = upload_text_to_server(final_context, server_url, outname)
51
+
52
+ data = json.loads(response_text)
53
+
54
+ # メッセージを取得
55
+ message = data.get("message", "")
56
+
57
  print(f"アップロードのステータス: {status}")
58
+ print(f"レスポンス: {message}")
59
 
60
+ #return response_text
61
+ return message
62
 
63
 
64
  # Gradioの関数