Shunfeng Zheng commited on
Commit
444aed6
·
verified ·
1 Parent(s): fe690f8

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +8 -7
app.py CHANGED
@@ -232,13 +232,14 @@ def extract_spatial_entities(text):
232
  def process_api(input_text):
233
  # 这里编写实际的后端处理逻辑
234
 
235
- return {
236
- "status": "success",
237
- # "result": f"Processed: {input_text.upper()}",
238
- # "result": f"Processed: {nlp(input_text).to_json()}",
239
- "result": f"Processed: {extract_spatial_entities(input_text)}",
240
- "timestamp": time.time()
241
- }
 
242
 
243
  # 设置API格式为JSON
244
  gr.Interface(
 
232
  def process_api(input_text):
233
  # 这里编写实际的后端处理逻辑
234
 
235
+ # return {
236
+ # "status": "success",
237
+ # # "result": f"Processed: {input_text.upper()}",
238
+ # # "result": f"Processed: {nlp(input_text).to_json()}",
239
+ # "result": f"Processed: {extract_spatial_entities(input_text)}",
240
+ # "timestamp": time.time()
241
+ # }
242
+ return extract_spatial_entities(input_text)
243
 
244
  # 设置API格式为JSON
245
  gr.Interface(