File size: 965 Bytes
b203bd9
ca59d84
7b6141f
493afaa
dd52485
493afaa
 
7b6141f
85e81ac
21530cd
85e81ac
 
dd52485
7b6141f
dd52485
7b6141f
 
dd52485
 
c660abf
ca59d84
ebb9ed4
7b6141f
 
b203bd9
7e9da24
 
b203bd9
333a0ef
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
import gradio as gr
import pandas as pd
import os
import docx2txt
#from docx import Document
#from datasets import load_dataset
#dataset = load_dataset("text", data_files="C:/Users/Rhodri Smith/OneDrive - Cardiff University/Desktop/ChatBot/Contamination_Monitoring/CONTAMINATION.docx")

# read in word file
#result = docx2txt.process(r"C:\Users\Rhodri Smith\Desktop\Contamination_Monitoring\CONTAMINATION.docx")


#dir_path = 'C:/Users/Rhodri Smith/OneDrive - Cardiff University/Desktop/ChatBot/Contamination_Monitoring/'
#Create a document object
#doc = Document()

#Loop through the directory and print the list of files
#for file in os.listdir(dir_path):
#    print(file)
    #doc.add_paragraph(file)

# Read the document
#for para in document.paragraphs:
#    print(para.text)

def greet(name):
    return "Hello " + name + "!"

demo = gr.Interface(
    fn=greet,
    inputs=gr.Textbox(lines=2, placeholder="Name Here..."),
    outputs="text",
)
demo.launch()