codet5 / app.py
Ahsen Khaliq
Update app.py
5978a76
raw
history blame contribute delete
843 Bytes
import gradio as gr
title = "CodeT5"
description = "Gradio Demo for CodeT5: Identifier-aware Unified Pre-trained Encoder-Decoder Models for Code Understanding and Generation. To use it, simply add your text, or click one of the examples to load them. Read more at the links below."
article = "<p style='text-align: center'><a href='https://arxiv.org/abs/2109.00859' target='_blank'>CodeT5: Identifier-aware Unified Pre-trained Encoder-Decoder Models for Code Understanding and Generation</a> | <a href='https://github.com/salesforce/CodeT5' target='_blank'>Github Repo</a></p>"
examples = [
["def greet(user): print(f'hello <extra_id_0>!') </s>"]
]
gr.Interface.load("huggingface/Salesforce/codet5-base", inputs=gr.inputs.Textbox(lines=5, label="Input Text"),title=title,description=description,article=article, examples=examples).launch()