Spaces:
Runtime error
Runtime error
Kushwanth Chowday Kandala
commited on
Commit
•
557b724
1
Parent(s):
160526f
IndexError: index out of range in self
Browse files
app.py
CHANGED
@@ -7,7 +7,7 @@ from io import StringIO
|
|
7 |
import PyPDF2
|
8 |
from tqdm import tqdm
|
9 |
import math
|
10 |
-
from transformers import pipeline
|
11 |
# import json
|
12 |
|
13 |
# st.config(PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION="python")
|
@@ -133,7 +133,7 @@ def chat_actions():
|
|
133 |
p = math.pow(1024, 2)
|
134 |
mbsize = round(len(bytesize) / p, 2)
|
135 |
st.write(f"Text lenth of {len(consolidated_text)} characters with {mbsize}MB size")
|
136 |
-
promt_engineer(consolidated_text)
|
137 |
|
138 |
for res in result['matches']:
|
139 |
st.session_state["chat_history"].append(
|
|
|
7 |
import PyPDF2
|
8 |
from tqdm import tqdm
|
9 |
import math
|
10 |
+
# from transformers import pipeline
|
11 |
# import json
|
12 |
|
13 |
# st.config(PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION="python")
|
|
|
133 |
p = math.pow(1024, 2)
|
134 |
mbsize = round(len(bytesize) / p, 2)
|
135 |
st.write(f"Text lenth of {len(consolidated_text)} characters with {mbsize}MB size")
|
136 |
+
promt_engineer(consolidated_text[:1024])
|
137 |
|
138 |
for res in result['matches']:
|
139 |
st.session_state["chat_history"].append(
|