Spaces:
Running
Running
File size: 767 Bytes
b16ee7a e45da9f 64ace6e b16ee7a 5d0e6ea 64ace6e 1ffe070 92e4478 c7757cd 92e4478 c1d5d41 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
import gradio as gr
import addressrec
import json
def greet(address):
result = addressrec.run(address, True, False)
return json.dumps(result, indent=4, ensure_ascii=False)
textbox = gr.Textbox(label="输入你的地址:",value="王志超029-68216000新疆维吾尔自治区乌鲁木齐市沙依巴克区西虹东路463号", placeholder="王志超029-68216000新疆维吾尔自治区乌鲁木齐市沙依巴克区西虹东路463号", lines=2)
title = "地址识别py版本,请输入地址进行测试"
github_link = "<a href='https://github.com/wzc570738205/smartParsePro-py'> 🧩GitHub</a>"
description = f"{github_link}<br><br>"
iface = gr.Interface(fn=greet, inputs=textbox, outputs='text', title=title, description=description)
iface.launch()
|