Spaces:
Running
Running
luanpoppe
commited on
Commit
·
605a49c
1
Parent(s):
7757039
feat: melhorando contextuals
Browse files
_utils/vector_stores/Vector_store_class.py
CHANGED
@@ -21,7 +21,14 @@ class VectorStore:
|
|
21 |
# Prepare texts with context
|
22 |
if is_contextualized_chunk:
|
23 |
texts = [
|
24 |
-
f"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
25 |
for chunk in chunks
|
26 |
]
|
27 |
else:
|
|
|
21 |
# Prepare texts with context
|
22 |
if is_contextualized_chunk:
|
23 |
texts = [
|
24 |
+
f"""<one_chunk>
|
25 |
+
<document_id>{chunk.id_do_processo}</document_id>
|
26 |
+
<document_context>Document_context{chunk.context}</document_context>
|
27 |
+
<document_contextual_summary>{chunk.contextual_summary}</document_contextual_summary>
|
28 |
+
<document_content>Document_content: {chunk.content}</document_content>
|
29 |
+
</one_chunk>
|
30 |
+
|
31 |
+
"""
|
32 |
for chunk in chunks
|
33 |
]
|
34 |
else:
|