Update app.py
Browse files
app.py
CHANGED
|
@@ -167,11 +167,13 @@ def create_vector_db(final_items):
|
|
| 167 |
Once the summarizing is done, write 'END'.
|
| 168 |
"""
|
| 169 |
|
| 170 |
-
|
| 171 |
prompt
|
| 172 |
)
|
| 173 |
|
| 174 |
-
|
|
|
|
|
|
|
| 175 |
|
| 176 |
if final_items:
|
| 177 |
db.add(
|
|
@@ -215,11 +217,13 @@ def generate_response(db, query_text, previous_context):
|
|
| 215 |
|
| 216 |
Once you are done summarizing, type 'END'.
|
| 217 |
"""
|
| 218 |
-
|
| 219 |
prompt_template
|
| 220 |
)
|
| 221 |
|
| 222 |
-
|
|
|
|
|
|
|
| 223 |
|
| 224 |
|
| 225 |
def streamlit_app():
|
|
|
|
| 167 |
Once the summarizing is done, write 'END'.
|
| 168 |
"""
|
| 169 |
|
| 170 |
+
response2 = llm.generate(
|
| 171 |
prompt
|
| 172 |
)
|
| 173 |
|
| 174 |
+
response = response2["choices"][0]["text"].strip()
|
| 175 |
+
|
| 176 |
+
documents.append(response)
|
| 177 |
|
| 178 |
if final_items:
|
| 179 |
db.add(
|
|
|
|
| 217 |
|
| 218 |
Once you are done summarizing, type 'END'.
|
| 219 |
"""
|
| 220 |
+
response2 = llm(
|
| 221 |
prompt_template
|
| 222 |
)
|
| 223 |
|
| 224 |
+
response = response2["choices"][0]["text"].strip()
|
| 225 |
+
|
| 226 |
+
print(response)
|
| 227 |
|
| 228 |
|
| 229 |
def streamlit_app():
|