Spaces:
Sleeping
Sleeping
Logeswaransr
commited on
Update interaction.py
Browse files- interaction.py +12 -0
interaction.py
CHANGED
@@ -0,0 +1,12 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
import requests
|
2 |
+
from gtts import gTTS
|
3 |
+
import base64
|
4 |
+
import os
|
5 |
+
from haystack import Document
|
6 |
+
|
7 |
+
def init_doc_store():
|
8 |
+
docs = []
|
9 |
+
for file in files:
|
10 |
+
with open(path + '/' + file, 'r') as f:
|
11 |
+
content = f.read()
|
12 |
+
docs.append(Document(content=content, meta={'name':file}))
|