Spaces:
Paused
Paused
Update app.py
Browse files
app.py
CHANGED
@@ -2,6 +2,31 @@
|
|
2 |
import sys
|
3 |
import os
|
4 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
5 |
data_path = os.path.join(os.path.dirname(__file__), 'localGPTUI')
|
6 |
|
7 |
# Add the data directory to sys.path
|
|
|
2 |
import sys
|
3 |
import os
|
4 |
|
5 |
+
# Diretório que você deseja listar
|
6 |
+
diretorio = os.path.dirname(__file__)
|
7 |
+
|
8 |
+
# Lista todos os arquivos no diretório
|
9 |
+
arquivos = os.listdir(diretorio)
|
10 |
+
|
11 |
+
# Imprime o nome de cada arquivo
|
12 |
+
for arquivo in arquivos:
|
13 |
+
if os.path.isfile(os.path.join(diretorio, arquivo)):
|
14 |
+
print(arquivo)
|
15 |
+
data_path = os.path.join(os.path.dirname(__file__), '.')
|
16 |
+
|
17 |
+
|
18 |
+
|
19 |
+
|
20 |
+
# Add the data directory to sys.path
|
21 |
+
sys.path.append(data_path)
|
22 |
+
|
23 |
+
from localGPTUI import frontend
|
24 |
+
|
25 |
+
localGPTUI.main()
|
26 |
+
|
27 |
+
# ingest.main()
|
28 |
+
|
29 |
+
|
30 |
data_path = os.path.join(os.path.dirname(__file__), 'localGPTUI')
|
31 |
|
32 |
# Add the data directory to sys.path
|