Spaces:
Build error
Build error
import gradio as gr | |
import pandas as pd | |
def process_inputs(text, file): | |
data = pd.read_csv(file.name) | |
return f"{text}\n\n{data.to_string()}" | |
iface = gr.Interface( | |
fn=process_inputs, | |
inputs=[ | |
gr.inputs.Textbox(lines=2, placeholder="OpenAI API"), | |
gr.Dataframe(row_count = (2, "dynamic"), col_count=(4,"dynamic"), label="Input Data", interactive=1), | |
], | |
outputs=gr.outputs.Textbox(), | |
) | |
iface.launch() | |