| import gradio as gr | |
| from acrobert import acronym_linker | |
| def greet(sentence): | |
| results = acronym_linker(sentence, mode='acrobert') | |
| return results | |
| sample_list = [ | |
| "The LDA is an example of a topic model.", | |
| "Using a camera sensor, LDA judges the position of your vehicle in relation to the road markings below.", | |
| "AI is a wide-ranging branch of computer science concerned with building smart machines capable of performing tasks that typically require human intelligence. ", | |
| "In the United States, the AI for potassium for adults is 4.7 grams.", | |
| "This new genome assembly and the annotation are tagged as a RefSeq genome by NCBI and thus provide substantially enhanced genomic resources for future research involving S. scovelli.", | |
| "In this study, we found that miR-34a demonstrated greater expression in the lungs of patients with IPF and in mice with experimental pulmonary fibrosis , with its primary localization in lung fibroblasts.", | |
| ] | |
| iface = gr.Interface(fn=greet, inputs="text", outputs="text", examples=sample_list, cache_examples=False) | |
| iface.launch() |