File size: 310 Bytes
d31040e 2d4a4ca d31040e 2d4a4ca d31040e 2d4a4ca d31040e |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 |
import gradio as gr
from transformers import pipeline
generator = pipeline("text-generation", model="AdaptLLM/law-LLM")
def generate(input):
return generator(
input,
max_length=10,
num_return_sequences=1,
)
iface = gr.Interface(fn=generate, inputs="text", outputs="text")
iface.launch()
|