kolzchut-ragbot 1.7.4__tar.gz → 1.7.5__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {kolzchut_ragbot-1.7.4 → kolzchut_ragbot-1.7.5}/PKG-INFO +1 -1
- {kolzchut_ragbot-1.7.4 → kolzchut_ragbot-1.7.5}/kolzchut_ragbot/engine.py +10 -5
- {kolzchut_ragbot-1.7.4 → kolzchut_ragbot-1.7.5}/kolzchut_ragbot.egg-info/PKG-INFO +1 -1
- {kolzchut_ragbot-1.7.4 → kolzchut_ragbot-1.7.5}/pyproject.toml +1 -1
- {kolzchut_ragbot-1.7.4 → kolzchut_ragbot-1.7.5}/setup.py +1 -1
- {kolzchut_ragbot-1.7.4 → kolzchut_ragbot-1.7.5}/README.md +0 -0
- {kolzchut_ragbot-1.7.4 → kolzchut_ragbot-1.7.5}/kolzchut_ragbot/Document.py +0 -0
- {kolzchut_ragbot-1.7.4 → kolzchut_ragbot-1.7.5}/kolzchut_ragbot/IntegrateService.py +0 -0
- {kolzchut_ragbot-1.7.4 → kolzchut_ragbot-1.7.5}/kolzchut_ragbot/__init__.py +0 -0
- {kolzchut_ragbot-1.7.4 → kolzchut_ragbot-1.7.5}/kolzchut_ragbot/config.py +0 -0
- {kolzchut_ragbot-1.7.4 → kolzchut_ragbot-1.7.5}/kolzchut_ragbot/get_full_documents_utilities.py +0 -0
- {kolzchut_ragbot-1.7.4 → kolzchut_ragbot-1.7.5}/kolzchut_ragbot/llm_client.py +0 -0
- {kolzchut_ragbot-1.7.4 → kolzchut_ragbot-1.7.5}/kolzchut_ragbot/model.py +0 -0
- {kolzchut_ragbot-1.7.4 → kolzchut_ragbot-1.7.5}/kolzchut_ragbot.egg-info/SOURCES.txt +0 -0
- {kolzchut_ragbot-1.7.4 → kolzchut_ragbot-1.7.5}/kolzchut_ragbot.egg-info/dependency_links.txt +0 -0
- {kolzchut_ragbot-1.7.4 → kolzchut_ragbot-1.7.5}/kolzchut_ragbot.egg-info/requires.txt +0 -0
- {kolzchut_ragbot-1.7.4 → kolzchut_ragbot-1.7.5}/kolzchut_ragbot.egg-info/top_level.txt +0 -0
- {kolzchut_ragbot-1.7.4 → kolzchut_ragbot-1.7.5}/setup.cfg +0 -0
- {kolzchut_ragbot-1.7.4 → kolzchut_ragbot-1.7.5}/test/test_configs.py +0 -0
- {kolzchut_ragbot-1.7.4 → kolzchut_ragbot-1.7.5}/test/test_docs.py +0 -0
- {kolzchut_ragbot-1.7.4 → kolzchut_ragbot-1.7.5}/test/test_document.py +0 -0
- {kolzchut_ragbot-1.7.4 → kolzchut_ragbot-1.7.5}/test/test_engine.py +0 -0
- {kolzchut_ragbot-1.7.4 → kolzchut_ragbot-1.7.5}/test/test_model.py +0 -0
@@ -306,7 +306,13 @@ class Engine:
|
|
306
306
|
|
307
307
|
# Combine documents
|
308
308
|
top_k_documents_and_additional_document = top_k_documents.copy()
|
309
|
+
# Remove documents with the same page_id as the additional_document before appending
|
309
310
|
if additional_document:
|
311
|
+
additional_page_id = additional_document.get("page_id")
|
312
|
+
top_k_documents_and_additional_document = [
|
313
|
+
doc for doc in top_k_documents_and_additional_document
|
314
|
+
if doc.get("page_id") != additional_page_id
|
315
|
+
]
|
310
316
|
top_k_documents_and_additional_document.append(additional_document)
|
311
317
|
|
312
318
|
# Query LLM
|
@@ -326,14 +332,13 @@ class Engine:
|
|
326
332
|
}
|
327
333
|
|
328
334
|
request_params['timers_ms'] = {
|
329
|
-
"answer_time":
|
330
|
-
"retrieval_time": int(retrieval_time*1000),
|
331
|
-
"llm_time": int(gpt_elapsed*1000)
|
335
|
+
"answer_time": int(answer_time * 1000),
|
336
|
+
"retrieval_time": int(retrieval_time * 1000),
|
337
|
+
"llm_time": int(gpt_elapsed * 1000)
|
332
338
|
}
|
333
339
|
|
334
340
|
if additional_page_time:
|
335
|
-
request_params['timers_ms']['additional_page_time'] = int(additional_page_time*1000)
|
336
|
-
|
341
|
+
request_params['timers_ms']['additional_page_time'] = int(additional_page_time * 1000)
|
337
342
|
|
338
343
|
return top_k_documents, gpt_answer, stats, all_docs_and_scores, request_params
|
339
344
|
|
@@ -7,7 +7,7 @@ from setuptools import setup, find_packages
|
|
7
7
|
|
8
8
|
setup(
|
9
9
|
name='kolzchut-ragbot',
|
10
|
-
version='1.7.
|
10
|
+
version='1.7.5',
|
11
11
|
author='Shmuel Robinov',
|
12
12
|
author_email='shmuel_robinov@webiks.com',
|
13
13
|
description='A search engine using machine learning models and Elasticsearch for advanced document retrieval.',
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{kolzchut_ragbot-1.7.4 → kolzchut_ragbot-1.7.5}/kolzchut_ragbot/get_full_documents_utilities.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{kolzchut_ragbot-1.7.4 → kolzchut_ragbot-1.7.5}/kolzchut_ragbot.egg-info/dependency_links.txt
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|