import gradio as gr | |
from langchain_community.document_loaders import TextLoader | |
def greet(name): | |
return "Hello " + name + "!!" | |
loader = TextLoader("test.txt") | |
data = loader.load() | |
iface = gr.Interface(fn=greet, inputs="text", outputs="text") | |
iface.launch() | |